aws-cdk-lib 2.137.0__py3-none-any.whl → 2.139.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of aws-cdk-lib might be problematic. Click here for more details.

Files changed (73) hide show
  1. aws_cdk/__init__.py +8 -0
  2. aws_cdk/_jsii/__init__.py +1 -1
  3. aws_cdk/_jsii/{aws-cdk-lib@2.137.0.jsii.tgz → aws-cdk-lib@2.139.0.jsii.tgz} +0 -0
  4. aws_cdk/aws_amplify/__init__.py +29 -113
  5. aws_cdk/aws_apigateway/__init__.py +29 -16
  6. aws_cdk/aws_appconfig/__init__.py +315 -77
  7. aws_cdk/aws_appintegrations/__init__.py +55 -6
  8. aws_cdk/aws_apprunner/__init__.py +5 -2
  9. aws_cdk/aws_appsync/__init__.py +400 -13
  10. aws_cdk/aws_aps/__init__.py +64 -47
  11. aws_cdk/aws_autoscaling/__init__.py +62 -60
  12. aws_cdk/aws_b2bi/__init__.py +2 -6
  13. aws_cdk/aws_backup/__init__.py +53 -57
  14. aws_cdk/aws_batch/__init__.py +109 -0
  15. aws_cdk/aws_bcmdataexports/__init__.py +1114 -0
  16. aws_cdk/aws_bedrock/__init__.py +4144 -0
  17. aws_cdk/aws_chatbot/__init__.py +6 -4
  18. aws_cdk/aws_cleanrooms/__init__.py +526 -3
  19. aws_cdk/aws_cleanroomsml/__init__.py +960 -0
  20. aws_cdk/aws_cloudtrail/__init__.py +10 -10
  21. aws_cdk/aws_cloudwatch/__init__.py +244 -8
  22. aws_cdk/aws_codebuild/__init__.py +27 -22
  23. aws_cdk/aws_codeconnections/__init__.py +435 -0
  24. aws_cdk/aws_cognito/__init__.py +175 -79
  25. aws_cdk/aws_datazone/__init__.py +22 -0
  26. aws_cdk/aws_deadline/__init__.py +5394 -0
  27. aws_cdk/aws_dms/__init__.py +2 -4
  28. aws_cdk/aws_ec2/__init__.py +402 -247
  29. aws_cdk/aws_ecr/__init__.py +630 -0
  30. aws_cdk/aws_ecs/__init__.py +361 -20
  31. aws_cdk/aws_efs/__init__.py +594 -2
  32. aws_cdk/aws_elasticache/__init__.py +86 -32
  33. aws_cdk/aws_elasticloadbalancingv2/__init__.py +75 -10
  34. aws_cdk/aws_emr/__init__.py +2 -2
  35. aws_cdk/aws_entityresolution/__init__.py +1982 -773
  36. aws_cdk/aws_events_targets/__init__.py +17 -4
  37. aws_cdk/aws_globalaccelerator/__init__.py +443 -0
  38. aws_cdk/aws_iam/__init__.py +1 -2
  39. aws_cdk/aws_internetmonitor/__init__.py +14 -6
  40. aws_cdk/aws_ivs/__init__.py +1273 -71
  41. aws_cdk/aws_kms/__init__.py +44 -0
  42. aws_cdk/aws_lambda/__init__.py +9 -0
  43. aws_cdk/aws_mediatailor/__init__.py +41 -0
  44. aws_cdk/aws_oam/__init__.py +204 -0
  45. aws_cdk/aws_personalize/__init__.py +8 -6
  46. aws_cdk/aws_pinpoint/__init__.py +5 -3
  47. aws_cdk/aws_pipes/__init__.py +5 -1
  48. aws_cdk/aws_quicksight/__init__.py +12 -6
  49. aws_cdk/aws_rds/__init__.py +370 -96
  50. aws_cdk/aws_redshiftserverless/__init__.py +157 -0
  51. aws_cdk/aws_route53/__init__.py +587 -14
  52. aws_cdk/aws_sagemaker/__init__.py +233 -2
  53. aws_cdk/aws_securityhub/__init__.py +4940 -102
  54. aws_cdk/aws_securitylake/__init__.py +1326 -89
  55. aws_cdk/aws_ses_actions/__init__.py +155 -0
  56. aws_cdk/aws_sns/__init__.py +61 -4
  57. aws_cdk/aws_ssm/__init__.py +5 -2
  58. aws_cdk/aws_ssmcontacts/__init__.py +11 -4
  59. aws_cdk/aws_stepfunctions/__init__.py +8 -16
  60. aws_cdk/aws_stepfunctions_tasks/__init__.py +676 -1
  61. aws_cdk/aws_timestream/__init__.py +1045 -0
  62. aws_cdk/aws_transfer/__init__.py +19 -10
  63. aws_cdk/aws_verifiedpermissions/__init__.py +114 -37
  64. aws_cdk/aws_wisdom/__init__.py +2 -2
  65. aws_cdk/aws_workspacesthinclient/__init__.py +8 -8
  66. aws_cdk/custom_resources/__init__.py +688 -26
  67. aws_cdk/cx_api/__init__.py +17 -0
  68. {aws_cdk_lib-2.137.0.dist-info → aws_cdk_lib-2.139.0.dist-info}/METADATA +3 -3
  69. {aws_cdk_lib-2.137.0.dist-info → aws_cdk_lib-2.139.0.dist-info}/RECORD +73 -69
  70. {aws_cdk_lib-2.137.0.dist-info → aws_cdk_lib-2.139.0.dist-info}/LICENSE +0 -0
  71. {aws_cdk_lib-2.137.0.dist-info → aws_cdk_lib-2.139.0.dist-info}/NOTICE +0 -0
  72. {aws_cdk_lib-2.137.0.dist-info → aws_cdk_lib-2.139.0.dist-info}/WHEEL +0 -0
  73. {aws_cdk_lib-2.137.0.dist-info → aws_cdk_lib-2.139.0.dist-info}/top_level.txt +0 -0
@@ -1183,6 +1183,32 @@ tasks.GlueDataBrewStartJobRun(self, "Task",
1183
1183
  )
1184
1184
  ```
1185
1185
 
1186
+ ## Invoke HTTP API
1187
+
1188
+ Step Functions supports [calling third-party APIs](https://docs.aws.amazon.com/step-functions/latest/dg/connect-third-party-apis.html) with credentials managed by Amazon EventBridge [Connections](https://docs.aws.amazon.com/eventbridge/latest/APIReference/API_Connection.html).
1189
+
1190
+ The following snippet creates a new API destination connection, and uses it to make a POST request to the specified URL. The endpoint response is available at the `$.ResponseBody` path.
1191
+
1192
+ ```python
1193
+ import aws_cdk.aws_events as events
1194
+
1195
+
1196
+ connection = events.Connection(self, "Connection",
1197
+ authorization=events.Authorization.basic("username", SecretValue.unsafe_plain_text("password"))
1198
+ )
1199
+
1200
+ tasks.HttpInvoke(self, "Invoke HTTP API",
1201
+ api_root="https://api.example.com",
1202
+ api_endpoint=sfn.TaskInput.from_text("https://api.example.com/path/to/resource"),
1203
+ body=sfn.TaskInput.from_object({"foo": "bar"}),
1204
+ connection=connection,
1205
+ headers=sfn.TaskInput.from_object({"Content-Type": "application/json"}),
1206
+ method=sfn.TaskInput.from_text("POST"),
1207
+ query_string_parameters=sfn.TaskInput.from_object({"id": "123"}),
1208
+ url_encoding_format=tasks.URLEncodingFormat.BRACKETS
1209
+ )
1210
+ ```
1211
+
1186
1212
  ## Lambda
1187
1213
 
1188
1214
  Step Functions supports [AWS Lambda](https://docs.aws.amazon.com/step-functions/latest/dg/connect-lambda.html) through the service integration pattern.
@@ -1653,7 +1679,9 @@ from ..aws_ecs import (
1653
1679
  TaskDefinition as _TaskDefinition_a541a103,
1654
1680
  )
1655
1681
  from ..aws_eks import ICluster as _ICluster_6b2b80df
1656
- from ..aws_events import IEventBus as _IEventBus_88d13111
1682
+ from ..aws_events import (
1683
+ IConnection as _IConnection_afaa0769, IEventBus as _IEventBus_88d13111
1684
+ )
1657
1685
  from ..aws_iam import (
1658
1686
  IGrantable as _IGrantable_71c4f5de,
1659
1687
  IPrincipal as _IPrincipal_539bb2fd,
@@ -23490,6 +23518,543 @@ class GlueStartJobRunProps(_TaskStateBaseProps_3a62b6d0):
23490
23518
  )
23491
23519
 
23492
23520
 
23521
+ class HttpInvoke(
23522
+ _TaskStateBase_b5c0a816,
23523
+ metaclass=jsii.JSIIMeta,
23524
+ jsii_type="aws-cdk-lib.aws_stepfunctions_tasks.HttpInvoke",
23525
+ ):
23526
+ '''A Step Functions Task to call a public third-party API.
23527
+
23528
+ :exampleMetadata: infused
23529
+
23530
+ Example::
23531
+
23532
+ import aws_cdk.aws_events as events
23533
+
23534
+
23535
+ connection = events.Connection(self, "Connection",
23536
+ authorization=events.Authorization.basic("username", SecretValue.unsafe_plain_text("password"))
23537
+ )
23538
+
23539
+ tasks.HttpInvoke(self, "Invoke HTTP API",
23540
+ api_root="https://api.example.com",
23541
+ api_endpoint=sfn.TaskInput.from_text("https://api.example.com/path/to/resource"),
23542
+ body=sfn.TaskInput.from_object({"foo": "bar"}),
23543
+ connection=connection,
23544
+ headers=sfn.TaskInput.from_object({"Content-Type": "application/json"}),
23545
+ method=sfn.TaskInput.from_text("POST"),
23546
+ query_string_parameters=sfn.TaskInput.from_object({"id": "123"}),
23547
+ url_encoding_format=tasks.URLEncodingFormat.BRACKETS
23548
+ )
23549
+ '''
23550
+
23551
+ def __init__(
23552
+ self,
23553
+ scope: _constructs_77d1e7e8.Construct,
23554
+ id: builtins.str,
23555
+ *,
23556
+ api_endpoint: _TaskInput_91b91b91,
23557
+ api_root: builtins.str,
23558
+ connection: _IConnection_afaa0769,
23559
+ method: _TaskInput_91b91b91,
23560
+ body: typing.Optional[_TaskInput_91b91b91] = None,
23561
+ headers: typing.Optional[_TaskInput_91b91b91] = None,
23562
+ query_string_parameters: typing.Optional[_TaskInput_91b91b91] = None,
23563
+ url_encoding_format: typing.Optional["URLEncodingFormat"] = None,
23564
+ comment: typing.Optional[builtins.str] = None,
23565
+ credentials: typing.Optional[typing.Union[_Credentials_2cd64c6b, typing.Dict[builtins.str, typing.Any]]] = None,
23566
+ heartbeat: typing.Optional[_Duration_4839e8c3] = None,
23567
+ heartbeat_timeout: typing.Optional[_Timeout_d7c10551] = None,
23568
+ input_path: typing.Optional[builtins.str] = None,
23569
+ integration_pattern: typing.Optional[_IntegrationPattern_949291bc] = None,
23570
+ output_path: typing.Optional[builtins.str] = None,
23571
+ result_path: typing.Optional[builtins.str] = None,
23572
+ result_selector: typing.Optional[typing.Mapping[builtins.str, typing.Any]] = None,
23573
+ state_name: typing.Optional[builtins.str] = None,
23574
+ task_timeout: typing.Optional[_Timeout_d7c10551] = None,
23575
+ timeout: typing.Optional[_Duration_4839e8c3] = None,
23576
+ ) -> None:
23577
+ '''
23578
+ :param scope: -
23579
+ :param id: Descriptive identifier for this chainable.
23580
+ :param api_endpoint: The API endpoint to call, relative to ``apiRoot``.
23581
+ :param api_root: Permissions are granted to call all resources under this path.
23582
+ :param connection: The EventBridge Connection to use for authentication.
23583
+ :param method: The HTTP method to use.
23584
+ :param body: The body to send to the HTTP endpoint. Default: - No body is sent with the request.
23585
+ :param headers: The headers to send to the HTTP endpoint. Default: - No additional headers are added to the request.
23586
+ :param query_string_parameters: The query string parameters to send to the HTTP endpoint. Default: - No query string parameters are sent in the request.
23587
+ :param url_encoding_format: Determines whether to apply URL encoding to the request body, and which array encoding format to use. ``URLEncodingFormat.NONE`` passes the JSON-serialized ``RequestBody`` field as the HTTP request body. Otherwise, the HTTP request body is the URL-encoded form data of the ``RequestBody`` field using the specified array encoding format, and the ``Content-Type`` header is set to ``application/x-www-form-urlencoded``. Default: - URLEncodingFormat.NONE
23588
+ :param comment: An optional description for this state. Default: - No comment
23589
+ :param credentials: Credentials for an IAM Role that the State Machine assumes for executing the task. This enables cross-account resource invocations. Default: - None (Task is executed using the State Machine's execution role)
23590
+ :param heartbeat: (deprecated) Timeout for the heartbeat. Default: - None
23591
+ :param heartbeat_timeout: Timeout for the heartbeat. [disable-awslint:duration-prop-type] is needed because all props interface in aws-stepfunctions-tasks extend this interface Default: - None
23592
+ :param input_path: JSONPath expression to select part of the state to be the input to this state. May also be the special value JsonPath.DISCARD, which will cause the effective input to be the empty object {}. Default: - The entire task input (JSON path '$')
23593
+ :param integration_pattern: AWS Step Functions integrates with services directly in the Amazon States Language. You can control these AWS services using service integration patterns. Depending on the AWS Service, the Service Integration Pattern availability will vary. Default: - ``IntegrationPattern.REQUEST_RESPONSE`` for most tasks. ``IntegrationPattern.RUN_JOB`` for the following exceptions: ``BatchSubmitJob``, ``EmrAddStep``, ``EmrCreateCluster``, ``EmrTerminationCluster``, and ``EmrContainersStartJobRun``.
23594
+ :param output_path: JSONPath expression to select select a portion of the state output to pass to the next state. May also be the special value JsonPath.DISCARD, which will cause the effective output to be the empty object {}. Default: - The entire JSON node determined by the state input, the task result, and resultPath is passed to the next state (JSON path '$')
23595
+ :param result_path: JSONPath expression to indicate where to inject the state's output. May also be the special value JsonPath.DISCARD, which will cause the state's input to become its output. Default: - Replaces the entire input with the result (JSON path '$')
23596
+ :param result_selector: The JSON that will replace the state's raw result and become the effective result before ResultPath is applied. You can use ResultSelector to create a payload with values that are static or selected from the state's raw result. Default: - None
23597
+ :param state_name: Optional name for this state. Default: - The construct ID will be used as state name
23598
+ :param task_timeout: Timeout for the task. [disable-awslint:duration-prop-type] is needed because all props interface in aws-stepfunctions-tasks extend this interface Default: - None
23599
+ :param timeout: (deprecated) Timeout for the task. Default: - None
23600
+ '''
23601
+ if __debug__:
23602
+ type_hints = typing.get_type_hints(_typecheckingstub__380dcb304dd02d709d798634fa365c757bcaa7593ab7542271009736c47d0329)
23603
+ check_type(argname="argument scope", value=scope, expected_type=type_hints["scope"])
23604
+ check_type(argname="argument id", value=id, expected_type=type_hints["id"])
23605
+ props = HttpInvokeProps(
23606
+ api_endpoint=api_endpoint,
23607
+ api_root=api_root,
23608
+ connection=connection,
23609
+ method=method,
23610
+ body=body,
23611
+ headers=headers,
23612
+ query_string_parameters=query_string_parameters,
23613
+ url_encoding_format=url_encoding_format,
23614
+ comment=comment,
23615
+ credentials=credentials,
23616
+ heartbeat=heartbeat,
23617
+ heartbeat_timeout=heartbeat_timeout,
23618
+ input_path=input_path,
23619
+ integration_pattern=integration_pattern,
23620
+ output_path=output_path,
23621
+ result_path=result_path,
23622
+ result_selector=result_selector,
23623
+ state_name=state_name,
23624
+ task_timeout=task_timeout,
23625
+ timeout=timeout,
23626
+ )
23627
+
23628
+ jsii.create(self.__class__, self, [scope, id, props])
23629
+
23630
+ @jsii.member(jsii_name="buildTaskPolicyStatements")
23631
+ def _build_task_policy_statements(self) -> typing.List[_PolicyStatement_0fe33853]:
23632
+ return typing.cast(typing.List[_PolicyStatement_0fe33853], jsii.invoke(self, "buildTaskPolicyStatements", []))
23633
+
23634
+ @builtins.property
23635
+ @jsii.member(jsii_name="taskMetrics")
23636
+ def _task_metrics(self) -> typing.Optional[_TaskMetricsConfig_32ea9403]:
23637
+ return typing.cast(typing.Optional[_TaskMetricsConfig_32ea9403], jsii.get(self, "taskMetrics"))
23638
+
23639
+ @builtins.property
23640
+ @jsii.member(jsii_name="taskPolicies")
23641
+ def _task_policies(self) -> typing.Optional[typing.List[_PolicyStatement_0fe33853]]:
23642
+ return typing.cast(typing.Optional[typing.List[_PolicyStatement_0fe33853]], jsii.get(self, "taskPolicies"))
23643
+
23644
+
23645
+ @jsii.data_type(
23646
+ jsii_type="aws-cdk-lib.aws_stepfunctions_tasks.HttpInvokeProps",
23647
+ jsii_struct_bases=[_TaskStateBaseProps_3a62b6d0],
23648
+ name_mapping={
23649
+ "comment": "comment",
23650
+ "credentials": "credentials",
23651
+ "heartbeat": "heartbeat",
23652
+ "heartbeat_timeout": "heartbeatTimeout",
23653
+ "input_path": "inputPath",
23654
+ "integration_pattern": "integrationPattern",
23655
+ "output_path": "outputPath",
23656
+ "result_path": "resultPath",
23657
+ "result_selector": "resultSelector",
23658
+ "state_name": "stateName",
23659
+ "task_timeout": "taskTimeout",
23660
+ "timeout": "timeout",
23661
+ "api_endpoint": "apiEndpoint",
23662
+ "api_root": "apiRoot",
23663
+ "connection": "connection",
23664
+ "method": "method",
23665
+ "body": "body",
23666
+ "headers": "headers",
23667
+ "query_string_parameters": "queryStringParameters",
23668
+ "url_encoding_format": "urlEncodingFormat",
23669
+ },
23670
+ )
23671
+ class HttpInvokeProps(_TaskStateBaseProps_3a62b6d0):
23672
+ def __init__(
23673
+ self,
23674
+ *,
23675
+ comment: typing.Optional[builtins.str] = None,
23676
+ credentials: typing.Optional[typing.Union[_Credentials_2cd64c6b, typing.Dict[builtins.str, typing.Any]]] = None,
23677
+ heartbeat: typing.Optional[_Duration_4839e8c3] = None,
23678
+ heartbeat_timeout: typing.Optional[_Timeout_d7c10551] = None,
23679
+ input_path: typing.Optional[builtins.str] = None,
23680
+ integration_pattern: typing.Optional[_IntegrationPattern_949291bc] = None,
23681
+ output_path: typing.Optional[builtins.str] = None,
23682
+ result_path: typing.Optional[builtins.str] = None,
23683
+ result_selector: typing.Optional[typing.Mapping[builtins.str, typing.Any]] = None,
23684
+ state_name: typing.Optional[builtins.str] = None,
23685
+ task_timeout: typing.Optional[_Timeout_d7c10551] = None,
23686
+ timeout: typing.Optional[_Duration_4839e8c3] = None,
23687
+ api_endpoint: _TaskInput_91b91b91,
23688
+ api_root: builtins.str,
23689
+ connection: _IConnection_afaa0769,
23690
+ method: _TaskInput_91b91b91,
23691
+ body: typing.Optional[_TaskInput_91b91b91] = None,
23692
+ headers: typing.Optional[_TaskInput_91b91b91] = None,
23693
+ query_string_parameters: typing.Optional[_TaskInput_91b91b91] = None,
23694
+ url_encoding_format: typing.Optional["URLEncodingFormat"] = None,
23695
+ ) -> None:
23696
+ '''Properties for calling an external HTTP endpoint with HttpInvoke.
23697
+
23698
+ :param comment: An optional description for this state. Default: - No comment
23699
+ :param credentials: Credentials for an IAM Role that the State Machine assumes for executing the task. This enables cross-account resource invocations. Default: - None (Task is executed using the State Machine's execution role)
23700
+ :param heartbeat: (deprecated) Timeout for the heartbeat. Default: - None
23701
+ :param heartbeat_timeout: Timeout for the heartbeat. [disable-awslint:duration-prop-type] is needed because all props interface in aws-stepfunctions-tasks extend this interface Default: - None
23702
+ :param input_path: JSONPath expression to select part of the state to be the input to this state. May also be the special value JsonPath.DISCARD, which will cause the effective input to be the empty object {}. Default: - The entire task input (JSON path '$')
23703
+ :param integration_pattern: AWS Step Functions integrates with services directly in the Amazon States Language. You can control these AWS services using service integration patterns. Depending on the AWS Service, the Service Integration Pattern availability will vary. Default: - ``IntegrationPattern.REQUEST_RESPONSE`` for most tasks. ``IntegrationPattern.RUN_JOB`` for the following exceptions: ``BatchSubmitJob``, ``EmrAddStep``, ``EmrCreateCluster``, ``EmrTerminationCluster``, and ``EmrContainersStartJobRun``.
23704
+ :param output_path: JSONPath expression to select select a portion of the state output to pass to the next state. May also be the special value JsonPath.DISCARD, which will cause the effective output to be the empty object {}. Default: - The entire JSON node determined by the state input, the task result, and resultPath is passed to the next state (JSON path '$')
23705
+ :param result_path: JSONPath expression to indicate where to inject the state's output. May also be the special value JsonPath.DISCARD, which will cause the state's input to become its output. Default: - Replaces the entire input with the result (JSON path '$')
23706
+ :param result_selector: The JSON that will replace the state's raw result and become the effective result before ResultPath is applied. You can use ResultSelector to create a payload with values that are static or selected from the state's raw result. Default: - None
23707
+ :param state_name: Optional name for this state. Default: - The construct ID will be used as state name
23708
+ :param task_timeout: Timeout for the task. [disable-awslint:duration-prop-type] is needed because all props interface in aws-stepfunctions-tasks extend this interface Default: - None
23709
+ :param timeout: (deprecated) Timeout for the task. Default: - None
23710
+ :param api_endpoint: The API endpoint to call, relative to ``apiRoot``.
23711
+ :param api_root: Permissions are granted to call all resources under this path.
23712
+ :param connection: The EventBridge Connection to use for authentication.
23713
+ :param method: The HTTP method to use.
23714
+ :param body: The body to send to the HTTP endpoint. Default: - No body is sent with the request.
23715
+ :param headers: The headers to send to the HTTP endpoint. Default: - No additional headers are added to the request.
23716
+ :param query_string_parameters: The query string parameters to send to the HTTP endpoint. Default: - No query string parameters are sent in the request.
23717
+ :param url_encoding_format: Determines whether to apply URL encoding to the request body, and which array encoding format to use. ``URLEncodingFormat.NONE`` passes the JSON-serialized ``RequestBody`` field as the HTTP request body. Otherwise, the HTTP request body is the URL-encoded form data of the ``RequestBody`` field using the specified array encoding format, and the ``Content-Type`` header is set to ``application/x-www-form-urlencoded``. Default: - URLEncodingFormat.NONE
23718
+
23719
+ :exampleMetadata: infused
23720
+
23721
+ Example::
23722
+
23723
+ import aws_cdk.aws_events as events
23724
+
23725
+
23726
+ connection = events.Connection(self, "Connection",
23727
+ authorization=events.Authorization.basic("username", SecretValue.unsafe_plain_text("password"))
23728
+ )
23729
+
23730
+ tasks.HttpInvoke(self, "Invoke HTTP API",
23731
+ api_root="https://api.example.com",
23732
+ api_endpoint=sfn.TaskInput.from_text("https://api.example.com/path/to/resource"),
23733
+ body=sfn.TaskInput.from_object({"foo": "bar"}),
23734
+ connection=connection,
23735
+ headers=sfn.TaskInput.from_object({"Content-Type": "application/json"}),
23736
+ method=sfn.TaskInput.from_text("POST"),
23737
+ query_string_parameters=sfn.TaskInput.from_object({"id": "123"}),
23738
+ url_encoding_format=tasks.URLEncodingFormat.BRACKETS
23739
+ )
23740
+ '''
23741
+ if isinstance(credentials, dict):
23742
+ credentials = _Credentials_2cd64c6b(**credentials)
23743
+ if __debug__:
23744
+ type_hints = typing.get_type_hints(_typecheckingstub__9c1bbcee50744a26bccfe1fdf126df22aaaf9a0e25bc51ef9803628b561dd275)
23745
+ check_type(argname="argument comment", value=comment, expected_type=type_hints["comment"])
23746
+ check_type(argname="argument credentials", value=credentials, expected_type=type_hints["credentials"])
23747
+ check_type(argname="argument heartbeat", value=heartbeat, expected_type=type_hints["heartbeat"])
23748
+ check_type(argname="argument heartbeat_timeout", value=heartbeat_timeout, expected_type=type_hints["heartbeat_timeout"])
23749
+ check_type(argname="argument input_path", value=input_path, expected_type=type_hints["input_path"])
23750
+ check_type(argname="argument integration_pattern", value=integration_pattern, expected_type=type_hints["integration_pattern"])
23751
+ check_type(argname="argument output_path", value=output_path, expected_type=type_hints["output_path"])
23752
+ check_type(argname="argument result_path", value=result_path, expected_type=type_hints["result_path"])
23753
+ check_type(argname="argument result_selector", value=result_selector, expected_type=type_hints["result_selector"])
23754
+ check_type(argname="argument state_name", value=state_name, expected_type=type_hints["state_name"])
23755
+ check_type(argname="argument task_timeout", value=task_timeout, expected_type=type_hints["task_timeout"])
23756
+ check_type(argname="argument timeout", value=timeout, expected_type=type_hints["timeout"])
23757
+ check_type(argname="argument api_endpoint", value=api_endpoint, expected_type=type_hints["api_endpoint"])
23758
+ check_type(argname="argument api_root", value=api_root, expected_type=type_hints["api_root"])
23759
+ check_type(argname="argument connection", value=connection, expected_type=type_hints["connection"])
23760
+ check_type(argname="argument method", value=method, expected_type=type_hints["method"])
23761
+ check_type(argname="argument body", value=body, expected_type=type_hints["body"])
23762
+ check_type(argname="argument headers", value=headers, expected_type=type_hints["headers"])
23763
+ check_type(argname="argument query_string_parameters", value=query_string_parameters, expected_type=type_hints["query_string_parameters"])
23764
+ check_type(argname="argument url_encoding_format", value=url_encoding_format, expected_type=type_hints["url_encoding_format"])
23765
+ self._values: typing.Dict[builtins.str, typing.Any] = {
23766
+ "api_endpoint": api_endpoint,
23767
+ "api_root": api_root,
23768
+ "connection": connection,
23769
+ "method": method,
23770
+ }
23771
+ if comment is not None:
23772
+ self._values["comment"] = comment
23773
+ if credentials is not None:
23774
+ self._values["credentials"] = credentials
23775
+ if heartbeat is not None:
23776
+ self._values["heartbeat"] = heartbeat
23777
+ if heartbeat_timeout is not None:
23778
+ self._values["heartbeat_timeout"] = heartbeat_timeout
23779
+ if input_path is not None:
23780
+ self._values["input_path"] = input_path
23781
+ if integration_pattern is not None:
23782
+ self._values["integration_pattern"] = integration_pattern
23783
+ if output_path is not None:
23784
+ self._values["output_path"] = output_path
23785
+ if result_path is not None:
23786
+ self._values["result_path"] = result_path
23787
+ if result_selector is not None:
23788
+ self._values["result_selector"] = result_selector
23789
+ if state_name is not None:
23790
+ self._values["state_name"] = state_name
23791
+ if task_timeout is not None:
23792
+ self._values["task_timeout"] = task_timeout
23793
+ if timeout is not None:
23794
+ self._values["timeout"] = timeout
23795
+ if body is not None:
23796
+ self._values["body"] = body
23797
+ if headers is not None:
23798
+ self._values["headers"] = headers
23799
+ if query_string_parameters is not None:
23800
+ self._values["query_string_parameters"] = query_string_parameters
23801
+ if url_encoding_format is not None:
23802
+ self._values["url_encoding_format"] = url_encoding_format
23803
+
23804
+ @builtins.property
23805
+ def comment(self) -> typing.Optional[builtins.str]:
23806
+ '''An optional description for this state.
23807
+
23808
+ :default: - No comment
23809
+ '''
23810
+ result = self._values.get("comment")
23811
+ return typing.cast(typing.Optional[builtins.str], result)
23812
+
23813
+ @builtins.property
23814
+ def credentials(self) -> typing.Optional[_Credentials_2cd64c6b]:
23815
+ '''Credentials for an IAM Role that the State Machine assumes for executing the task.
23816
+
23817
+ This enables cross-account resource invocations.
23818
+
23819
+ :default: - None (Task is executed using the State Machine's execution role)
23820
+
23821
+ :see: https://docs.aws.amazon.com/step-functions/latest/dg/concepts-access-cross-acct-resources.html
23822
+ '''
23823
+ result = self._values.get("credentials")
23824
+ return typing.cast(typing.Optional[_Credentials_2cd64c6b], result)
23825
+
23826
+ @builtins.property
23827
+ def heartbeat(self) -> typing.Optional[_Duration_4839e8c3]:
23828
+ '''(deprecated) Timeout for the heartbeat.
23829
+
23830
+ :default: - None
23831
+
23832
+ :deprecated: use ``heartbeatTimeout``
23833
+
23834
+ :stability: deprecated
23835
+ '''
23836
+ result = self._values.get("heartbeat")
23837
+ return typing.cast(typing.Optional[_Duration_4839e8c3], result)
23838
+
23839
+ @builtins.property
23840
+ def heartbeat_timeout(self) -> typing.Optional[_Timeout_d7c10551]:
23841
+ '''Timeout for the heartbeat.
23842
+
23843
+ [disable-awslint:duration-prop-type] is needed because all props interface in
23844
+ aws-stepfunctions-tasks extend this interface
23845
+
23846
+ :default: - None
23847
+ '''
23848
+ result = self._values.get("heartbeat_timeout")
23849
+ return typing.cast(typing.Optional[_Timeout_d7c10551], result)
23850
+
23851
+ @builtins.property
23852
+ def input_path(self) -> typing.Optional[builtins.str]:
23853
+ '''JSONPath expression to select part of the state to be the input to this state.
23854
+
23855
+ May also be the special value JsonPath.DISCARD, which will cause the effective
23856
+ input to be the empty object {}.
23857
+
23858
+ :default: - The entire task input (JSON path '$')
23859
+ '''
23860
+ result = self._values.get("input_path")
23861
+ return typing.cast(typing.Optional[builtins.str], result)
23862
+
23863
+ @builtins.property
23864
+ def integration_pattern(self) -> typing.Optional[_IntegrationPattern_949291bc]:
23865
+ '''AWS Step Functions integrates with services directly in the Amazon States Language.
23866
+
23867
+ You can control these AWS services using service integration patterns.
23868
+
23869
+ Depending on the AWS Service, the Service Integration Pattern availability will vary.
23870
+
23871
+ :default:
23872
+
23873
+ - ``IntegrationPattern.REQUEST_RESPONSE`` for most tasks.
23874
+ ``IntegrationPattern.RUN_JOB`` for the following exceptions:
23875
+ ``BatchSubmitJob``, ``EmrAddStep``, ``EmrCreateCluster``, ``EmrTerminationCluster``, and ``EmrContainersStartJobRun``.
23876
+
23877
+ :see: https://docs.aws.amazon.com/step-functions/latest/dg/connect-supported-services.html
23878
+ '''
23879
+ result = self._values.get("integration_pattern")
23880
+ return typing.cast(typing.Optional[_IntegrationPattern_949291bc], result)
23881
+
23882
+ @builtins.property
23883
+ def output_path(self) -> typing.Optional[builtins.str]:
23884
+ '''JSONPath expression to select select a portion of the state output to pass to the next state.
23885
+
23886
+ May also be the special value JsonPath.DISCARD, which will cause the effective
23887
+ output to be the empty object {}.
23888
+
23889
+ :default:
23890
+
23891
+ - The entire JSON node determined by the state input, the task result,
23892
+ and resultPath is passed to the next state (JSON path '$')
23893
+ '''
23894
+ result = self._values.get("output_path")
23895
+ return typing.cast(typing.Optional[builtins.str], result)
23896
+
23897
+ @builtins.property
23898
+ def result_path(self) -> typing.Optional[builtins.str]:
23899
+ '''JSONPath expression to indicate where to inject the state's output.
23900
+
23901
+ May also be the special value JsonPath.DISCARD, which will cause the state's
23902
+ input to become its output.
23903
+
23904
+ :default: - Replaces the entire input with the result (JSON path '$')
23905
+ '''
23906
+ result = self._values.get("result_path")
23907
+ return typing.cast(typing.Optional[builtins.str], result)
23908
+
23909
+ @builtins.property
23910
+ def result_selector(
23911
+ self,
23912
+ ) -> typing.Optional[typing.Mapping[builtins.str, typing.Any]]:
23913
+ '''The JSON that will replace the state's raw result and become the effective result before ResultPath is applied.
23914
+
23915
+ You can use ResultSelector to create a payload with values that are static
23916
+ or selected from the state's raw result.
23917
+
23918
+ :default: - None
23919
+
23920
+ :see: https://docs.aws.amazon.com/step-functions/latest/dg/input-output-inputpath-params.html#input-output-resultselector
23921
+ '''
23922
+ result = self._values.get("result_selector")
23923
+ return typing.cast(typing.Optional[typing.Mapping[builtins.str, typing.Any]], result)
23924
+
23925
+ @builtins.property
23926
+ def state_name(self) -> typing.Optional[builtins.str]:
23927
+ '''Optional name for this state.
23928
+
23929
+ :default: - The construct ID will be used as state name
23930
+ '''
23931
+ result = self._values.get("state_name")
23932
+ return typing.cast(typing.Optional[builtins.str], result)
23933
+
23934
+ @builtins.property
23935
+ def task_timeout(self) -> typing.Optional[_Timeout_d7c10551]:
23936
+ '''Timeout for the task.
23937
+
23938
+ [disable-awslint:duration-prop-type] is needed because all props interface in
23939
+ aws-stepfunctions-tasks extend this interface
23940
+
23941
+ :default: - None
23942
+ '''
23943
+ result = self._values.get("task_timeout")
23944
+ return typing.cast(typing.Optional[_Timeout_d7c10551], result)
23945
+
23946
+ @builtins.property
23947
+ def timeout(self) -> typing.Optional[_Duration_4839e8c3]:
23948
+ '''(deprecated) Timeout for the task.
23949
+
23950
+ :default: - None
23951
+
23952
+ :deprecated: use ``taskTimeout``
23953
+
23954
+ :stability: deprecated
23955
+ '''
23956
+ result = self._values.get("timeout")
23957
+ return typing.cast(typing.Optional[_Duration_4839e8c3], result)
23958
+
23959
+ @builtins.property
23960
+ def api_endpoint(self) -> _TaskInput_91b91b91:
23961
+ '''The API endpoint to call, relative to ``apiRoot``.
23962
+
23963
+ Example::
23964
+
23965
+ sfn.TaskInput.from_text("path/to/resource")
23966
+ '''
23967
+ result = self._values.get("api_endpoint")
23968
+ assert result is not None, "Required property 'api_endpoint' is missing"
23969
+ return typing.cast(_TaskInput_91b91b91, result)
23970
+
23971
+ @builtins.property
23972
+ def api_root(self) -> builtins.str:
23973
+ '''Permissions are granted to call all resources under this path.
23974
+
23975
+ Example::
23976
+
23977
+ "https://api.example.com"
23978
+ '''
23979
+ result = self._values.get("api_root")
23980
+ assert result is not None, "Required property 'api_root' is missing"
23981
+ return typing.cast(builtins.str, result)
23982
+
23983
+ @builtins.property
23984
+ def connection(self) -> _IConnection_afaa0769:
23985
+ '''The EventBridge Connection to use for authentication.'''
23986
+ result = self._values.get("connection")
23987
+ assert result is not None, "Required property 'connection' is missing"
23988
+ return typing.cast(_IConnection_afaa0769, result)
23989
+
23990
+ @builtins.property
23991
+ def method(self) -> _TaskInput_91b91b91:
23992
+ '''The HTTP method to use.
23993
+
23994
+ Example::
23995
+
23996
+ sfn.TaskInput.from_text("GET")
23997
+ '''
23998
+ result = self._values.get("method")
23999
+ assert result is not None, "Required property 'method' is missing"
24000
+ return typing.cast(_TaskInput_91b91b91, result)
24001
+
24002
+ @builtins.property
24003
+ def body(self) -> typing.Optional[_TaskInput_91b91b91]:
24004
+ '''The body to send to the HTTP endpoint.
24005
+
24006
+ :default: - No body is sent with the request.
24007
+ '''
24008
+ result = self._values.get("body")
24009
+ return typing.cast(typing.Optional[_TaskInput_91b91b91], result)
24010
+
24011
+ @builtins.property
24012
+ def headers(self) -> typing.Optional[_TaskInput_91b91b91]:
24013
+ '''The headers to send to the HTTP endpoint.
24014
+
24015
+ :default: - No additional headers are added to the request.
24016
+
24017
+ Example::
24018
+
24019
+ sfn.TaskInput.from_object({"Content-Type": "application/json"})
24020
+ '''
24021
+ result = self._values.get("headers")
24022
+ return typing.cast(typing.Optional[_TaskInput_91b91b91], result)
24023
+
24024
+ @builtins.property
24025
+ def query_string_parameters(self) -> typing.Optional[_TaskInput_91b91b91]:
24026
+ '''The query string parameters to send to the HTTP endpoint.
24027
+
24028
+ :default: - No query string parameters are sent in the request.
24029
+ '''
24030
+ result = self._values.get("query_string_parameters")
24031
+ return typing.cast(typing.Optional[_TaskInput_91b91b91], result)
24032
+
24033
+ @builtins.property
24034
+ def url_encoding_format(self) -> typing.Optional["URLEncodingFormat"]:
24035
+ '''Determines whether to apply URL encoding to the request body, and which array encoding format to use.
24036
+
24037
+ ``URLEncodingFormat.NONE`` passes the JSON-serialized ``RequestBody`` field as the HTTP request body.
24038
+ Otherwise, the HTTP request body is the URL-encoded form data of the ``RequestBody`` field using the
24039
+ specified array encoding format, and the ``Content-Type`` header is set to ``application/x-www-form-urlencoded``.
24040
+
24041
+ :default: - URLEncodingFormat.NONE
24042
+ '''
24043
+ result = self._values.get("url_encoding_format")
24044
+ return typing.cast(typing.Optional["URLEncodingFormat"], result)
24045
+
24046
+ def __eq__(self, rhs: typing.Any) -> builtins.bool:
24047
+ return isinstance(rhs, self.__class__) and rhs._values == self._values
24048
+
24049
+ def __ne__(self, rhs: typing.Any) -> builtins.bool:
24050
+ return not (rhs == self)
24051
+
24052
+ def __repr__(self) -> str:
24053
+ return "HttpInvokeProps(%s)" % ", ".join(
24054
+ k + "=" + repr(v) for k, v in self._values.items()
24055
+ )
24056
+
24057
+
23493
24058
  @jsii.enum(jsii_type="aws-cdk-lib.aws_stepfunctions_tasks.HttpMethod")
23494
24059
  class HttpMethod(enum.Enum):
23495
24060
  '''Http Methods that API Gateway supports.
@@ -31672,6 +32237,59 @@ class TransformS3DataSource:
31672
32237
  )
31673
32238
 
31674
32239
 
32240
+ @jsii.enum(jsii_type="aws-cdk-lib.aws_stepfunctions_tasks.URLEncodingFormat")
32241
+ class URLEncodingFormat(enum.Enum):
32242
+ '''The style used when applying URL encoding to array values.
32243
+
32244
+ :exampleMetadata: infused
32245
+
32246
+ Example::
32247
+
32248
+ import aws_cdk.aws_events as events
32249
+
32250
+
32251
+ connection = events.Connection(self, "Connection",
32252
+ authorization=events.Authorization.basic("username", SecretValue.unsafe_plain_text("password"))
32253
+ )
32254
+
32255
+ tasks.HttpInvoke(self, "Invoke HTTP API",
32256
+ api_root="https://api.example.com",
32257
+ api_endpoint=sfn.TaskInput.from_text("https://api.example.com/path/to/resource"),
32258
+ body=sfn.TaskInput.from_object({"foo": "bar"}),
32259
+ connection=connection,
32260
+ headers=sfn.TaskInput.from_object({"Content-Type": "application/json"}),
32261
+ method=sfn.TaskInput.from_text("POST"),
32262
+ query_string_parameters=sfn.TaskInput.from_object({"id": "123"}),
32263
+ url_encoding_format=tasks.URLEncodingFormat.BRACKETS
32264
+ )
32265
+ '''
32266
+
32267
+ BRACKETS = "BRACKETS"
32268
+ '''Encode arrays using brackets.
32269
+
32270
+ For example, {'array': ['a','b','c']} encodes to 'array[]=a&array[]=b&array[]=c'
32271
+ '''
32272
+ COMMAS = "COMMAS"
32273
+ '''Encode arrays using commas.
32274
+
32275
+ For example, {'array': ['a','b','c']} encodes to 'array=a,b,c,d'
32276
+ '''
32277
+ DEFAULT = "DEFAULT"
32278
+ '''Apply the default URL encoding style (INDICES).'''
32279
+ INDICES = "INDICES"
32280
+ '''Encode arrays using the index value.
32281
+
32282
+ For example, {'array': ['a','b','c']} encodes to 'array[0]=a&array[1]=b&array[2]=c'
32283
+ '''
32284
+ NONE = "NONE"
32285
+ '''Do not apply URL encoding.'''
32286
+ REPEAT = "REPEAT"
32287
+ '''Repeat key for each item in the array.
32288
+
32289
+ For example, {'array': ['a','b','c']} encodes to 'array[]=a&array[]=b&array[]=c'
32290
+ '''
32291
+
32292
+
31675
32293
  class VirtualClusterInput(
31676
32294
  metaclass=jsii.JSIIMeta,
31677
32295
  jsii_type="aws-cdk-lib.aws_stepfunctions_tasks.VirtualClusterInput",
@@ -32151,6 +32769,8 @@ __all__ = [
32151
32769
  "GlueStartCrawlerRunProps",
32152
32770
  "GlueStartJobRun",
32153
32771
  "GlueStartJobRunProps",
32772
+ "HttpInvoke",
32773
+ "HttpInvokeProps",
32154
32774
  "HttpMethod",
32155
32775
  "HttpMethods",
32156
32776
  "IContainerDefinition",
@@ -32212,6 +32832,7 @@ __all__ = [
32212
32832
  "TransformOutput",
32213
32833
  "TransformResources",
32214
32834
  "TransformS3DataSource",
32835
+ "URLEncodingFormat",
32215
32836
  "VirtualClusterInput",
32216
32837
  "VpcConfig",
32217
32838
  ]
@@ -34408,6 +35029,60 @@ def _typecheckingstub__6a5a6a067402f20efc3f218ecff8d7cae8c7206cf0bfb73907469d47f
34408
35029
  """Type checking stubs"""
34409
35030
  pass
34410
35031
 
35032
+ def _typecheckingstub__380dcb304dd02d709d798634fa365c757bcaa7593ab7542271009736c47d0329(
35033
+ scope: _constructs_77d1e7e8.Construct,
35034
+ id: builtins.str,
35035
+ *,
35036
+ api_endpoint: _TaskInput_91b91b91,
35037
+ api_root: builtins.str,
35038
+ connection: _IConnection_afaa0769,
35039
+ method: _TaskInput_91b91b91,
35040
+ body: typing.Optional[_TaskInput_91b91b91] = None,
35041
+ headers: typing.Optional[_TaskInput_91b91b91] = None,
35042
+ query_string_parameters: typing.Optional[_TaskInput_91b91b91] = None,
35043
+ url_encoding_format: typing.Optional[URLEncodingFormat] = None,
35044
+ comment: typing.Optional[builtins.str] = None,
35045
+ credentials: typing.Optional[typing.Union[_Credentials_2cd64c6b, typing.Dict[builtins.str, typing.Any]]] = None,
35046
+ heartbeat: typing.Optional[_Duration_4839e8c3] = None,
35047
+ heartbeat_timeout: typing.Optional[_Timeout_d7c10551] = None,
35048
+ input_path: typing.Optional[builtins.str] = None,
35049
+ integration_pattern: typing.Optional[_IntegrationPattern_949291bc] = None,
35050
+ output_path: typing.Optional[builtins.str] = None,
35051
+ result_path: typing.Optional[builtins.str] = None,
35052
+ result_selector: typing.Optional[typing.Mapping[builtins.str, typing.Any]] = None,
35053
+ state_name: typing.Optional[builtins.str] = None,
35054
+ task_timeout: typing.Optional[_Timeout_d7c10551] = None,
35055
+ timeout: typing.Optional[_Duration_4839e8c3] = None,
35056
+ ) -> None:
35057
+ """Type checking stubs"""
35058
+ pass
35059
+
35060
+ def _typecheckingstub__9c1bbcee50744a26bccfe1fdf126df22aaaf9a0e25bc51ef9803628b561dd275(
35061
+ *,
35062
+ comment: typing.Optional[builtins.str] = None,
35063
+ credentials: typing.Optional[typing.Union[_Credentials_2cd64c6b, typing.Dict[builtins.str, typing.Any]]] = None,
35064
+ heartbeat: typing.Optional[_Duration_4839e8c3] = None,
35065
+ heartbeat_timeout: typing.Optional[_Timeout_d7c10551] = None,
35066
+ input_path: typing.Optional[builtins.str] = None,
35067
+ integration_pattern: typing.Optional[_IntegrationPattern_949291bc] = None,
35068
+ output_path: typing.Optional[builtins.str] = None,
35069
+ result_path: typing.Optional[builtins.str] = None,
35070
+ result_selector: typing.Optional[typing.Mapping[builtins.str, typing.Any]] = None,
35071
+ state_name: typing.Optional[builtins.str] = None,
35072
+ task_timeout: typing.Optional[_Timeout_d7c10551] = None,
35073
+ timeout: typing.Optional[_Duration_4839e8c3] = None,
35074
+ api_endpoint: _TaskInput_91b91b91,
35075
+ api_root: builtins.str,
35076
+ connection: _IConnection_afaa0769,
35077
+ method: _TaskInput_91b91b91,
35078
+ body: typing.Optional[_TaskInput_91b91b91] = None,
35079
+ headers: typing.Optional[_TaskInput_91b91b91] = None,
35080
+ query_string_parameters: typing.Optional[_TaskInput_91b91b91] = None,
35081
+ url_encoding_format: typing.Optional[URLEncodingFormat] = None,
35082
+ ) -> None:
35083
+ """Type checking stubs"""
35084
+ pass
35085
+
34411
35086
  def _typecheckingstub__b1d56e9269c0540407e74b7d6334bbf508d8b37f4f0aa662ec8b33fee107376a(
34412
35087
  task: ISageMakerTask,
34413
35088
  ) -> None: