aws-cdk-lib 2.147.3__py3-none-any.whl → 2.148.1__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.
- aws_cdk/__init__.py +7 -5
- aws_cdk/_jsii/__init__.py +1 -1
- aws_cdk/_jsii/{aws-cdk-lib@2.147.3.jsii.tgz → aws-cdk-lib@2.148.1.jsii.tgz} +0 -0
- aws_cdk/alexa_ask/__init__.py +1 -1
- aws_cdk/assertions/__init__.py +1 -1
- aws_cdk/aws_accessanalyzer/__init__.py +1 -1
- aws_cdk/aws_acmpca/__init__.py +1 -1
- aws_cdk/aws_amazonmq/__init__.py +1 -1
- aws_cdk/aws_amplify/__init__.py +1 -1
- aws_cdk/aws_amplifyuibuilder/__init__.py +1 -1
- aws_cdk/aws_apigateway/__init__.py +1 -1
- aws_cdk/aws_apigatewayv2/__init__.py +1 -1
- aws_cdk/aws_apigatewayv2_authorizers/__init__.py +1 -1
- aws_cdk/aws_apigatewayv2_integrations/__init__.py +1 -1
- aws_cdk/aws_appconfig/__init__.py +1 -1
- aws_cdk/aws_appflow/__init__.py +1 -1
- aws_cdk/aws_appintegrations/__init__.py +1 -1
- aws_cdk/aws_applicationautoscaling/__init__.py +1 -1
- aws_cdk/aws_applicationinsights/__init__.py +1 -1
- aws_cdk/aws_applicationsignals/__init__.py +143 -87
- aws_cdk/aws_appmesh/__init__.py +1 -1
- aws_cdk/aws_apprunner/__init__.py +1 -1
- aws_cdk/aws_appstream/__init__.py +1 -1
- aws_cdk/aws_appsync/__init__.py +1 -1
- aws_cdk/aws_apptest/__init__.py +3042 -0
- aws_cdk/aws_aps/__init__.py +1 -1
- aws_cdk/aws_arczonalshift/__init__.py +1 -1
- aws_cdk/aws_athena/__init__.py +1 -1
- aws_cdk/aws_auditmanager/__init__.py +1 -1
- aws_cdk/aws_autoscaling/__init__.py +1 -1
- aws_cdk/aws_autoscaling_common/__init__.py +1 -1
- aws_cdk/aws_autoscaling_hooktargets/__init__.py +1 -1
- aws_cdk/aws_autoscalingplans/__init__.py +1 -1
- aws_cdk/aws_b2bi/__init__.py +1 -1
- aws_cdk/aws_backup/__init__.py +4 -6
- aws_cdk/aws_backupgateway/__init__.py +1 -1
- aws_cdk/aws_batch/__init__.py +1 -216
- aws_cdk/aws_bcmdataexports/__init__.py +1 -1
- aws_cdk/aws_bedrock/__init__.py +178 -1
- aws_cdk/aws_billingconductor/__init__.py +1 -1
- aws_cdk/aws_budgets/__init__.py +1 -1
- aws_cdk/aws_cassandra/__init__.py +1 -1
- aws_cdk/aws_ce/__init__.py +1 -1
- aws_cdk/aws_certificatemanager/__init__.py +1 -1
- aws_cdk/aws_chatbot/__init__.py +1 -1
- aws_cdk/aws_cleanrooms/__init__.py +1 -1
- aws_cdk/aws_cleanroomsml/__init__.py +1 -1
- aws_cdk/aws_cloud9/__init__.py +1 -1
- aws_cdk/aws_cloudformation/__init__.py +1 -1
- aws_cdk/aws_cloudfront/__init__.py +1 -1
- aws_cdk/aws_cloudfront/experimental/__init__.py +44 -0
- aws_cdk/aws_cloudfront_origins/__init__.py +1 -1
- aws_cdk/aws_cloudtrail/__init__.py +20 -12
- aws_cdk/aws_cloudwatch/__init__.py +1 -1
- aws_cdk/aws_cloudwatch_actions/__init__.py +1 -1
- aws_cdk/aws_codeartifact/__init__.py +11 -9
- aws_cdk/aws_codebuild/__init__.py +193 -6
- aws_cdk/aws_codecommit/__init__.py +1 -1
- aws_cdk/aws_codeconnections/__init__.py +1 -1
- aws_cdk/aws_codedeploy/__init__.py +35 -4
- aws_cdk/aws_codeguruprofiler/__init__.py +1 -1
- aws_cdk/aws_codegurureviewer/__init__.py +1 -1
- aws_cdk/aws_codepipeline/__init__.py +1 -1
- aws_cdk/aws_codepipeline_actions/__init__.py +1 -1
- aws_cdk/aws_codestar/__init__.py +1 -1
- aws_cdk/aws_codestarconnections/__init__.py +1 -1
- aws_cdk/aws_codestarnotifications/__init__.py +1 -1
- aws_cdk/aws_cognito/__init__.py +56 -18
- aws_cdk/aws_comprehend/__init__.py +1 -1
- aws_cdk/aws_config/__init__.py +1 -1
- aws_cdk/aws_connect/__init__.py +1 -1
- aws_cdk/aws_connectcampaigns/__init__.py +1 -1
- aws_cdk/aws_controltower/__init__.py +1 -1
- aws_cdk/aws_cur/__init__.py +1 -1
- aws_cdk/aws_customerprofiles/__init__.py +1 -1
- aws_cdk/aws_databrew/__init__.py +1 -1
- aws_cdk/aws_datapipeline/__init__.py +1 -1
- aws_cdk/aws_datasync/__init__.py +12 -12
- aws_cdk/aws_datazone/__init__.py +1 -1
- aws_cdk/aws_dax/__init__.py +1 -1
- aws_cdk/aws_deadline/__init__.py +3 -2
- aws_cdk/aws_detective/__init__.py +1 -1
- aws_cdk/aws_devicefarm/__init__.py +1 -1
- aws_cdk/aws_devopsguru/__init__.py +1 -1
- aws_cdk/aws_directoryservice/__init__.py +1 -1
- aws_cdk/aws_dlm/__init__.py +1 -1
- aws_cdk/aws_dms/__init__.py +2 -2
- aws_cdk/aws_docdb/__init__.py +1 -1
- aws_cdk/aws_docdbelastic/__init__.py +1 -1
- aws_cdk/aws_dynamodb/__init__.py +1 -1
- aws_cdk/aws_ec2/__init__.py +24 -26
- aws_cdk/aws_ecr/__init__.py +1 -1
- aws_cdk/aws_ecr_assets/__init__.py +1 -1
- aws_cdk/aws_ecs/__init__.py +29 -25
- aws_cdk/aws_ecs_patterns/__init__.py +1 -1
- aws_cdk/aws_efs/__init__.py +1 -1
- aws_cdk/aws_eks/__init__.py +619 -31
- aws_cdk/aws_elasticache/__init__.py +29 -18
- aws_cdk/aws_elasticbeanstalk/__init__.py +1 -1
- aws_cdk/aws_elasticloadbalancing/__init__.py +1 -1
- aws_cdk/aws_elasticloadbalancingv2/__init__.py +4 -4
- aws_cdk/aws_elasticloadbalancingv2_actions/__init__.py +1 -1
- aws_cdk/aws_elasticloadbalancingv2_targets/__init__.py +1 -1
- aws_cdk/aws_elasticsearch/__init__.py +1 -1
- aws_cdk/aws_emr/__init__.py +1 -1
- aws_cdk/aws_emrcontainers/__init__.py +1 -1
- aws_cdk/aws_emrserverless/__init__.py +34 -7
- aws_cdk/aws_entityresolution/__init__.py +1 -1
- aws_cdk/aws_events/__init__.py +1 -1
- aws_cdk/aws_events_targets/__init__.py +1 -1
- aws_cdk/aws_eventschemas/__init__.py +1 -1
- aws_cdk/aws_evidently/__init__.py +1 -1
- aws_cdk/aws_finspace/__init__.py +1 -1
- aws_cdk/aws_fis/__init__.py +1 -1
- aws_cdk/aws_fms/__init__.py +1 -1
- aws_cdk/aws_forecast/__init__.py +1 -1
- aws_cdk/aws_frauddetector/__init__.py +1 -1
- aws_cdk/aws_fsx/__init__.py +186 -2
- aws_cdk/aws_gamelift/__init__.py +10 -6
- aws_cdk/aws_globalaccelerator/__init__.py +1 -1
- aws_cdk/aws_globalaccelerator_endpoints/__init__.py +1 -1
- aws_cdk/aws_glue/__init__.py +18 -14
- aws_cdk/aws_grafana/__init__.py +9 -5
- aws_cdk/aws_greengrass/__init__.py +1 -1
- aws_cdk/aws_greengrassv2/__init__.py +1 -1
- aws_cdk/aws_groundstation/__init__.py +1 -1
- aws_cdk/aws_guardduty/__init__.py +171 -132
- aws_cdk/aws_healthimaging/__init__.py +1 -1
- aws_cdk/aws_healthlake/__init__.py +1 -1
- aws_cdk/aws_iam/__init__.py +1 -1
- aws_cdk/aws_identitystore/__init__.py +1 -1
- aws_cdk/aws_imagebuilder/__init__.py +1 -1
- aws_cdk/aws_inspector/__init__.py +1 -1
- aws_cdk/aws_inspectorv2/__init__.py +1 -1
- aws_cdk/aws_internetmonitor/__init__.py +1 -1
- aws_cdk/aws_iot/__init__.py +1 -1
- aws_cdk/aws_iot1click/__init__.py +1 -1
- aws_cdk/aws_iotanalytics/__init__.py +1 -1
- aws_cdk/aws_iotcoredeviceadvisor/__init__.py +1 -1
- aws_cdk/aws_iotevents/__init__.py +1 -1
- aws_cdk/aws_iotfleethub/__init__.py +1 -1
- aws_cdk/aws_iotfleetwise/__init__.py +1 -1
- aws_cdk/aws_iotsitewise/__init__.py +1 -1
- aws_cdk/aws_iotthingsgraph/__init__.py +1 -1
- aws_cdk/aws_iottwinmaker/__init__.py +1 -1
- aws_cdk/aws_iotwireless/__init__.py +1 -1
- aws_cdk/aws_ivs/__init__.py +1 -1
- aws_cdk/aws_ivschat/__init__.py +1 -1
- aws_cdk/aws_kafkaconnect/__init__.py +1 -1
- aws_cdk/aws_kendra/__init__.py +1 -1
- aws_cdk/aws_kendraranking/__init__.py +1 -1
- aws_cdk/aws_kinesis/__init__.py +1 -1
- aws_cdk/aws_kinesisanalytics/__init__.py +93 -1
- aws_cdk/aws_kinesisanalyticsv2/__init__.py +93 -1
- aws_cdk/aws_kinesisfirehose/__init__.py +301 -94
- aws_cdk/aws_kinesisvideo/__init__.py +1 -1
- aws_cdk/aws_kms/__init__.py +16 -15
- aws_cdk/aws_lakeformation/__init__.py +1 -1
- aws_cdk/aws_lambda/__init__.py +160 -1
- aws_cdk/aws_lambda_destinations/__init__.py +1 -1
- aws_cdk/aws_lambda_event_sources/__init__.py +1 -1
- aws_cdk/aws_lambda_nodejs/__init__.py +1 -1
- aws_cdk/aws_lex/__init__.py +1 -1
- aws_cdk/aws_licensemanager/__init__.py +1 -1
- aws_cdk/aws_lightsail/__init__.py +1 -1
- aws_cdk/aws_location/__init__.py +1 -1
- aws_cdk/aws_logs/__init__.py +1 -1
- aws_cdk/aws_logs_destinations/__init__.py +1 -1
- aws_cdk/aws_lookoutequipment/__init__.py +1 -1
- aws_cdk/aws_lookoutmetrics/__init__.py +1 -1
- aws_cdk/aws_lookoutvision/__init__.py +1 -1
- aws_cdk/aws_m2/__init__.py +1 -1
- aws_cdk/aws_macie/__init__.py +1 -1
- aws_cdk/aws_managedblockchain/__init__.py +1 -1
- aws_cdk/aws_mediaconnect/__init__.py +1 -1
- aws_cdk/aws_mediaconvert/__init__.py +1 -1
- aws_cdk/aws_medialive/__init__.py +1 -1
- aws_cdk/aws_mediapackage/__init__.py +1 -1
- aws_cdk/aws_mediapackagev2/__init__.py +33 -1
- aws_cdk/aws_mediastore/__init__.py +1 -1
- aws_cdk/aws_mediatailor/__init__.py +1 -1
- aws_cdk/aws_memorydb/__init__.py +1 -1
- aws_cdk/aws_msk/__init__.py +1 -1
- aws_cdk/aws_mwaa/__init__.py +1 -1
- aws_cdk/aws_neptune/__init__.py +1 -1
- aws_cdk/aws_neptunegraph/__init__.py +1 -1
- aws_cdk/aws_networkfirewall/__init__.py +1 -1
- aws_cdk/aws_networkmanager/__init__.py +10 -10
- aws_cdk/aws_nimblestudio/__init__.py +1 -1
- aws_cdk/aws_oam/__init__.py +1 -1
- aws_cdk/aws_omics/__init__.py +2 -2
- aws_cdk/aws_opensearchserverless/__init__.py +1 -1
- aws_cdk/aws_opensearchservice/__init__.py +1 -1
- aws_cdk/aws_opsworks/__init__.py +1 -1
- aws_cdk/aws_opsworkscm/__init__.py +8 -4
- aws_cdk/aws_organizations/__init__.py +1 -1
- aws_cdk/aws_osis/__init__.py +1 -1
- aws_cdk/aws_panorama/__init__.py +1 -1
- aws_cdk/aws_paymentcryptography/__init__.py +1 -1
- aws_cdk/aws_pcaconnectorad/__init__.py +1 -1
- aws_cdk/aws_personalize/__init__.py +1 -1
- aws_cdk/aws_pinpoint/__init__.py +1 -1
- aws_cdk/aws_pinpointemail/__init__.py +1 -1
- aws_cdk/aws_pipes/__init__.py +1 -1
- aws_cdk/aws_proton/__init__.py +1 -1
- aws_cdk/aws_qbusiness/__init__.py +1 -1
- aws_cdk/aws_qldb/__init__.py +1 -1
- aws_cdk/aws_quicksight/__init__.py +1 -1
- aws_cdk/aws_ram/__init__.py +1 -1
- aws_cdk/aws_rds/__init__.py +515 -34
- aws_cdk/aws_redshift/__init__.py +10 -10
- aws_cdk/aws_redshiftserverless/__init__.py +1 -1
- aws_cdk/aws_refactorspaces/__init__.py +1 -1
- aws_cdk/aws_rekognition/__init__.py +1 -1
- aws_cdk/aws_resiliencehub/__init__.py +1 -1
- aws_cdk/aws_resourceexplorer2/__init__.py +1 -1
- aws_cdk/aws_resourcegroups/__init__.py +1 -1
- aws_cdk/aws_robomaker/__init__.py +1 -1
- aws_cdk/aws_rolesanywhere/__init__.py +1 -1
- aws_cdk/aws_route53/__init__.py +1 -1
- aws_cdk/aws_route53_patterns/__init__.py +1 -1
- aws_cdk/aws_route53_targets/__init__.py +1 -1
- aws_cdk/aws_route53profiles/__init__.py +1 -1
- aws_cdk/aws_route53recoverycontrol/__init__.py +1 -1
- aws_cdk/aws_route53recoveryreadiness/__init__.py +1 -1
- aws_cdk/aws_route53resolver/__init__.py +1 -1
- aws_cdk/aws_rum/__init__.py +1 -1
- aws_cdk/aws_s3/__init__.py +30 -6
- aws_cdk/aws_s3_assets/__init__.py +1 -1
- aws_cdk/aws_s3_deployment/__init__.py +1 -1
- aws_cdk/aws_s3_notifications/__init__.py +1 -1
- aws_cdk/aws_s3express/__init__.py +1 -1
- aws_cdk/aws_s3objectlambda/__init__.py +1 -1
- aws_cdk/aws_s3outposts/__init__.py +1 -1
- aws_cdk/aws_sagemaker/__init__.py +1 -1
- aws_cdk/aws_sam/__init__.py +1 -1
- aws_cdk/aws_scheduler/__init__.py +1 -1
- aws_cdk/aws_sdb/__init__.py +1 -1
- aws_cdk/aws_secretsmanager/__init__.py +1 -1
- aws_cdk/aws_securityhub/__init__.py +1 -1
- aws_cdk/aws_securitylake/__init__.py +1 -1
- aws_cdk/aws_servicecatalog/__init__.py +1 -1
- aws_cdk/aws_servicecatalogappregistry/__init__.py +1 -1
- aws_cdk/aws_servicediscovery/__init__.py +21 -4
- aws_cdk/aws_ses/__init__.py +86 -1
- aws_cdk/aws_ses_actions/__init__.py +1 -1
- aws_cdk/aws_shield/__init__.py +1 -1
- aws_cdk/aws_signer/__init__.py +42 -1
- aws_cdk/aws_simspaceweaver/__init__.py +1 -1
- aws_cdk/aws_sns/__init__.py +1 -1
- aws_cdk/aws_sns_subscriptions/__init__.py +1 -1
- aws_cdk/aws_sqs/__init__.py +7 -9
- aws_cdk/aws_ssm/__init__.py +106 -37
- aws_cdk/aws_ssmcontacts/__init__.py +1 -1
- aws_cdk/aws_ssmincidents/__init__.py +1 -1
- aws_cdk/aws_sso/__init__.py +1 -1
- aws_cdk/aws_stepfunctions/__init__.py +1 -1
- aws_cdk/aws_stepfunctions_tasks/__init__.py +793 -152
- aws_cdk/aws_supportapp/__init__.py +1 -1
- aws_cdk/aws_synthetics/__init__.py +1 -1
- aws_cdk/aws_systemsmanagersap/__init__.py +1 -1
- aws_cdk/aws_timestream/__init__.py +1 -1
- aws_cdk/aws_transfer/__init__.py +1 -1
- aws_cdk/aws_verifiedpermissions/__init__.py +602 -9
- aws_cdk/aws_voiceid/__init__.py +1 -1
- aws_cdk/aws_vpclattice/__init__.py +1 -1
- aws_cdk/aws_waf/__init__.py +1 -1
- aws_cdk/aws_wafregional/__init__.py +1 -1
- aws_cdk/aws_wafv2/__init__.py +1 -1
- aws_cdk/aws_wisdom/__init__.py +1 -1
- aws_cdk/aws_workspaces/__init__.py +774 -1
- aws_cdk/aws_workspacesthinclient/__init__.py +1 -1
- aws_cdk/aws_workspacesweb/__init__.py +5 -5
- aws_cdk/aws_xray/__init__.py +1 -1
- aws_cdk/cloud_assembly_schema/__init__.py +1 -1
- aws_cdk/cloudformation_include/__init__.py +1 -1
- aws_cdk/custom_resources/__init__.py +1 -1
- aws_cdk/cx_api/__init__.py +19 -1
- aws_cdk/lambda_layer_awscli/__init__.py +1 -1
- aws_cdk/lambda_layer_kubectl/__init__.py +1 -1
- aws_cdk/lambda_layer_node_proxy_agent/__init__.py +1 -1
- aws_cdk/pipelines/__init__.py +2 -2
- aws_cdk/region_info/__init__.py +1 -1
- aws_cdk/triggers/__init__.py +1 -1
- {aws_cdk_lib-2.147.3.dist-info → aws_cdk_lib-2.148.1.dist-info}/METADATA +2 -2
- aws_cdk_lib-2.148.1.dist-info/RECORD +291 -0
- aws_cdk_lib-2.147.3.dist-info/RECORD +0 -290
- {aws_cdk_lib-2.147.3.dist-info → aws_cdk_lib-2.148.1.dist-info}/LICENSE +0 -0
- {aws_cdk_lib-2.147.3.dist-info → aws_cdk_lib-2.148.1.dist-info}/NOTICE +0 -0
- {aws_cdk_lib-2.147.3.dist-info → aws_cdk_lib-2.148.1.dist-info}/WHEEL +0 -0
- {aws_cdk_lib-2.147.3.dist-info → aws_cdk_lib-2.148.1.dist-info}/top_level.txt +0 -0
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
'''
|
|
1
|
+
r'''
|
|
2
2
|
# Tasks for AWS Step Functions
|
|
3
3
|
|
|
4
4
|
[AWS Step Functions](https://docs.aws.amazon.com/step-functions/latest/dg/welcome.html) is a web service that enables you to coordinate the
|
|
@@ -25,7 +25,9 @@ This module is part of the [AWS Cloud Development Kit](https://github.com/aws/aw
|
|
|
25
25
|
|
|
26
26
|
* [Call REST API Endpoint](#call-rest-api-endpoint)
|
|
27
27
|
* [Call HTTP API Endpoint](#call-http-api-endpoint)
|
|
28
|
-
|
|
28
|
+
* [AWS SDK](#aws-sdk)
|
|
29
|
+
|
|
30
|
+
* [Cross-region AWS API call](#cross-region-aws-api-call)
|
|
29
31
|
* [Athena](#athena)
|
|
30
32
|
|
|
31
33
|
* [StartQueryExecution](#startqueryexecution)
|
|
@@ -209,7 +211,7 @@ invoke_task = tasks.CallApiGatewayHttpApiEndpoint(self, "Call HTTP API",
|
|
|
209
211
|
)
|
|
210
212
|
```
|
|
211
213
|
|
|
212
|
-
|
|
214
|
+
## AWS SDK
|
|
213
215
|
|
|
214
216
|
Step Functions supports calling [AWS service's API actions](https://docs.aws.amazon.com/step-functions/latest/dg/supported-services-awssdk.html)
|
|
215
217
|
through the service integration pattern.
|
|
@@ -266,6 +268,27 @@ detect_labels = tasks.CallAwsService(self, "DetectLabels",
|
|
|
266
268
|
)
|
|
267
269
|
```
|
|
268
270
|
|
|
271
|
+
### Cross-region AWS API call
|
|
272
|
+
|
|
273
|
+
You can call AWS API in a different region from your state machine by using the `CallAwsServiceCrossRegion` construct. In addition to the properties for `CallAwsService` construct, you have to set `region` property to call the API.
|
|
274
|
+
|
|
275
|
+
```python
|
|
276
|
+
# my_bucket: s3.Bucket
|
|
277
|
+
|
|
278
|
+
get_object = tasks.CallAwsServiceCrossRegion(self, "GetObject",
|
|
279
|
+
region="ap-northeast-1",
|
|
280
|
+
service="s3",
|
|
281
|
+
action="getObject",
|
|
282
|
+
parameters={
|
|
283
|
+
"Bucket": my_bucket.bucket_name,
|
|
284
|
+
"Key": sfn.JsonPath.string_at("$.key")
|
|
285
|
+
},
|
|
286
|
+
iam_resources=[my_bucket.arn_for_objects("*")]
|
|
287
|
+
)
|
|
288
|
+
```
|
|
289
|
+
|
|
290
|
+
Other properties such as `additionalIamStatements` can be used in the same way as the `CallAwsService` task.
|
|
291
|
+
|
|
269
292
|
## Athena
|
|
270
293
|
|
|
271
294
|
Step Functions supports [Athena](https://docs.aws.amazon.com/step-functions/latest/dg/connect-athena.html) through the service integration pattern.
|
|
@@ -6632,189 +6655,749 @@ class CallApiGatewayRestApiEndpointProps(CallApiGatewayEndpointBaseProps):
|
|
|
6632
6655
|
return typing.cast(typing.Optional[_Duration_4839e8c3], result)
|
|
6633
6656
|
|
|
6634
6657
|
@builtins.property
|
|
6635
|
-
def method(self) -> "HttpMethod":
|
|
6636
|
-
'''Http method for the API.'''
|
|
6637
|
-
result = self._values.get("method")
|
|
6638
|
-
assert result is not None, "Required property 'method' is missing"
|
|
6639
|
-
return typing.cast("HttpMethod", result)
|
|
6640
|
-
|
|
6641
|
-
@builtins.property
|
|
6642
|
-
def api_path(self) -> typing.Optional[builtins.str]:
|
|
6643
|
-
'''Path parameters appended after API endpoint.
|
|
6658
|
+
def method(self) -> "HttpMethod":
|
|
6659
|
+
'''Http method for the API.'''
|
|
6660
|
+
result = self._values.get("method")
|
|
6661
|
+
assert result is not None, "Required property 'method' is missing"
|
|
6662
|
+
return typing.cast("HttpMethod", result)
|
|
6663
|
+
|
|
6664
|
+
@builtins.property
|
|
6665
|
+
def api_path(self) -> typing.Optional[builtins.str]:
|
|
6666
|
+
'''Path parameters appended after API endpoint.
|
|
6667
|
+
|
|
6668
|
+
:default: - No path
|
|
6669
|
+
'''
|
|
6670
|
+
result = self._values.get("api_path")
|
|
6671
|
+
return typing.cast(typing.Optional[builtins.str], result)
|
|
6672
|
+
|
|
6673
|
+
@builtins.property
|
|
6674
|
+
def auth_type(self) -> typing.Optional[AuthType]:
|
|
6675
|
+
'''Authentication methods.
|
|
6676
|
+
|
|
6677
|
+
:default: AuthType.NO_AUTH
|
|
6678
|
+
'''
|
|
6679
|
+
result = self._values.get("auth_type")
|
|
6680
|
+
return typing.cast(typing.Optional[AuthType], result)
|
|
6681
|
+
|
|
6682
|
+
@builtins.property
|
|
6683
|
+
def headers(self) -> typing.Optional[_TaskInput_91b91b91]:
|
|
6684
|
+
'''HTTP request information that does not relate to contents of the request.
|
|
6685
|
+
|
|
6686
|
+
:default: - No headers
|
|
6687
|
+
'''
|
|
6688
|
+
result = self._values.get("headers")
|
|
6689
|
+
return typing.cast(typing.Optional[_TaskInput_91b91b91], result)
|
|
6690
|
+
|
|
6691
|
+
@builtins.property
|
|
6692
|
+
def query_parameters(self) -> typing.Optional[_TaskInput_91b91b91]:
|
|
6693
|
+
'''Query strings attatched to end of request.
|
|
6694
|
+
|
|
6695
|
+
:default: - No query parameters
|
|
6696
|
+
'''
|
|
6697
|
+
result = self._values.get("query_parameters")
|
|
6698
|
+
return typing.cast(typing.Optional[_TaskInput_91b91b91], result)
|
|
6699
|
+
|
|
6700
|
+
@builtins.property
|
|
6701
|
+
def request_body(self) -> typing.Optional[_TaskInput_91b91b91]:
|
|
6702
|
+
'''HTTP Request body.
|
|
6703
|
+
|
|
6704
|
+
:default: - No request body
|
|
6705
|
+
'''
|
|
6706
|
+
result = self._values.get("request_body")
|
|
6707
|
+
return typing.cast(typing.Optional[_TaskInput_91b91b91], result)
|
|
6708
|
+
|
|
6709
|
+
@builtins.property
|
|
6710
|
+
def api(self) -> _IRestApi_1f02523d:
|
|
6711
|
+
'''API to call.'''
|
|
6712
|
+
result = self._values.get("api")
|
|
6713
|
+
assert result is not None, "Required property 'api' is missing"
|
|
6714
|
+
return typing.cast(_IRestApi_1f02523d, result)
|
|
6715
|
+
|
|
6716
|
+
@builtins.property
|
|
6717
|
+
def stage_name(self) -> builtins.str:
|
|
6718
|
+
'''Name of the stage where the API is deployed to in API Gateway.'''
|
|
6719
|
+
result = self._values.get("stage_name")
|
|
6720
|
+
assert result is not None, "Required property 'stage_name' is missing"
|
|
6721
|
+
return typing.cast(builtins.str, result)
|
|
6722
|
+
|
|
6723
|
+
def __eq__(self, rhs: typing.Any) -> builtins.bool:
|
|
6724
|
+
return isinstance(rhs, self.__class__) and rhs._values == self._values
|
|
6725
|
+
|
|
6726
|
+
def __ne__(self, rhs: typing.Any) -> builtins.bool:
|
|
6727
|
+
return not (rhs == self)
|
|
6728
|
+
|
|
6729
|
+
def __repr__(self) -> str:
|
|
6730
|
+
return "CallApiGatewayRestApiEndpointProps(%s)" % ", ".join(
|
|
6731
|
+
k + "=" + repr(v) for k, v in self._values.items()
|
|
6732
|
+
)
|
|
6733
|
+
|
|
6734
|
+
|
|
6735
|
+
class CallAwsService(
|
|
6736
|
+
_TaskStateBase_b5c0a816,
|
|
6737
|
+
metaclass=jsii.JSIIMeta,
|
|
6738
|
+
jsii_type="aws-cdk-lib.aws_stepfunctions_tasks.CallAwsService",
|
|
6739
|
+
):
|
|
6740
|
+
'''A StepFunctions task to call an AWS service API.
|
|
6741
|
+
|
|
6742
|
+
:exampleMetadata: infused
|
|
6743
|
+
|
|
6744
|
+
Example::
|
|
6745
|
+
|
|
6746
|
+
# my_bucket: s3.Bucket
|
|
6747
|
+
|
|
6748
|
+
get_object = tasks.CallAwsService(self, "GetObject",
|
|
6749
|
+
service="s3",
|
|
6750
|
+
action="getObject",
|
|
6751
|
+
parameters={
|
|
6752
|
+
"Bucket": my_bucket.bucket_name,
|
|
6753
|
+
"Key": sfn.JsonPath.string_at("$.key")
|
|
6754
|
+
},
|
|
6755
|
+
iam_resources=[my_bucket.arn_for_objects("*")]
|
|
6756
|
+
)
|
|
6757
|
+
'''
|
|
6758
|
+
|
|
6759
|
+
def __init__(
|
|
6760
|
+
self,
|
|
6761
|
+
scope: _constructs_77d1e7e8.Construct,
|
|
6762
|
+
id: builtins.str,
|
|
6763
|
+
*,
|
|
6764
|
+
action: builtins.str,
|
|
6765
|
+
iam_resources: typing.Sequence[builtins.str],
|
|
6766
|
+
service: builtins.str,
|
|
6767
|
+
additional_iam_statements: typing.Optional[typing.Sequence[_PolicyStatement_0fe33853]] = None,
|
|
6768
|
+
iam_action: typing.Optional[builtins.str] = None,
|
|
6769
|
+
parameters: typing.Optional[typing.Mapping[builtins.str, typing.Any]] = None,
|
|
6770
|
+
comment: typing.Optional[builtins.str] = None,
|
|
6771
|
+
credentials: typing.Optional[typing.Union[_Credentials_2cd64c6b, typing.Dict[builtins.str, typing.Any]]] = None,
|
|
6772
|
+
heartbeat: typing.Optional[_Duration_4839e8c3] = None,
|
|
6773
|
+
heartbeat_timeout: typing.Optional[_Timeout_d7c10551] = None,
|
|
6774
|
+
input_path: typing.Optional[builtins.str] = None,
|
|
6775
|
+
integration_pattern: typing.Optional[_IntegrationPattern_949291bc] = None,
|
|
6776
|
+
output_path: typing.Optional[builtins.str] = None,
|
|
6777
|
+
result_path: typing.Optional[builtins.str] = None,
|
|
6778
|
+
result_selector: typing.Optional[typing.Mapping[builtins.str, typing.Any]] = None,
|
|
6779
|
+
state_name: typing.Optional[builtins.str] = None,
|
|
6780
|
+
task_timeout: typing.Optional[_Timeout_d7c10551] = None,
|
|
6781
|
+
timeout: typing.Optional[_Duration_4839e8c3] = None,
|
|
6782
|
+
) -> None:
|
|
6783
|
+
'''
|
|
6784
|
+
:param scope: -
|
|
6785
|
+
:param id: Descriptive identifier for this chainable.
|
|
6786
|
+
:param action: The API action to call. Use camelCase.
|
|
6787
|
+
:param iam_resources: The resources for the IAM statement that will be added to the state machine role's policy to allow the state machine to make the API call. By default the action for this IAM statement will be ``service:action``.
|
|
6788
|
+
:param service: The AWS service to call.
|
|
6789
|
+
:param additional_iam_statements: Additional IAM statements that will be added to the state machine role's policy. Use in the case where the call requires more than a single statement to be executed, e.g. ``rekognition:detectLabels`` requires also S3 permissions to read the object on which it must act. Default: - no additional statements are added
|
|
6790
|
+
:param iam_action: The action for the IAM statement that will be added to the state machine role's policy to allow the state machine to make the API call. Use in the case where the IAM action name does not match with the API service/action name, e.g. ``s3:ListBuckets`` requires ``s3:ListAllMyBuckets``. Default: - service:action
|
|
6791
|
+
:param parameters: Parameters for the API action call. Use PascalCase for the parameter names. Default: - no parameters
|
|
6792
|
+
:param comment: An optional description for this state. Default: - No comment
|
|
6793
|
+
: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)
|
|
6794
|
+
:param heartbeat: (deprecated) Timeout for the heartbeat. Default: - None
|
|
6795
|
+
: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
|
|
6796
|
+
: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 '$')
|
|
6797
|
+
: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``.
|
|
6798
|
+
: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 '$')
|
|
6799
|
+
: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 '$')
|
|
6800
|
+
: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
|
|
6801
|
+
:param state_name: Optional name for this state. Default: - The construct ID will be used as state name
|
|
6802
|
+
: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
|
|
6803
|
+
:param timeout: (deprecated) Timeout for the task. Default: - None
|
|
6804
|
+
'''
|
|
6805
|
+
if __debug__:
|
|
6806
|
+
type_hints = typing.get_type_hints(_typecheckingstub__e4534f8232f0840d6ef9dc3920130b2d24934f22c4483b9bd14a19e8152f0b6f)
|
|
6807
|
+
check_type(argname="argument scope", value=scope, expected_type=type_hints["scope"])
|
|
6808
|
+
check_type(argname="argument id", value=id, expected_type=type_hints["id"])
|
|
6809
|
+
props = CallAwsServiceProps(
|
|
6810
|
+
action=action,
|
|
6811
|
+
iam_resources=iam_resources,
|
|
6812
|
+
service=service,
|
|
6813
|
+
additional_iam_statements=additional_iam_statements,
|
|
6814
|
+
iam_action=iam_action,
|
|
6815
|
+
parameters=parameters,
|
|
6816
|
+
comment=comment,
|
|
6817
|
+
credentials=credentials,
|
|
6818
|
+
heartbeat=heartbeat,
|
|
6819
|
+
heartbeat_timeout=heartbeat_timeout,
|
|
6820
|
+
input_path=input_path,
|
|
6821
|
+
integration_pattern=integration_pattern,
|
|
6822
|
+
output_path=output_path,
|
|
6823
|
+
result_path=result_path,
|
|
6824
|
+
result_selector=result_selector,
|
|
6825
|
+
state_name=state_name,
|
|
6826
|
+
task_timeout=task_timeout,
|
|
6827
|
+
timeout=timeout,
|
|
6828
|
+
)
|
|
6829
|
+
|
|
6830
|
+
jsii.create(self.__class__, self, [scope, id, props])
|
|
6831
|
+
|
|
6832
|
+
@builtins.property
|
|
6833
|
+
@jsii.member(jsii_name="taskMetrics")
|
|
6834
|
+
def _task_metrics(self) -> typing.Optional[_TaskMetricsConfig_32ea9403]:
|
|
6835
|
+
return typing.cast(typing.Optional[_TaskMetricsConfig_32ea9403], jsii.get(self, "taskMetrics"))
|
|
6836
|
+
|
|
6837
|
+
@builtins.property
|
|
6838
|
+
@jsii.member(jsii_name="taskPolicies")
|
|
6839
|
+
def _task_policies(self) -> typing.Optional[typing.List[_PolicyStatement_0fe33853]]:
|
|
6840
|
+
return typing.cast(typing.Optional[typing.List[_PolicyStatement_0fe33853]], jsii.get(self, "taskPolicies"))
|
|
6841
|
+
|
|
6842
|
+
|
|
6843
|
+
class CallAwsServiceCrossRegion(
|
|
6844
|
+
_TaskStateBase_b5c0a816,
|
|
6845
|
+
metaclass=jsii.JSIIMeta,
|
|
6846
|
+
jsii_type="aws-cdk-lib.aws_stepfunctions_tasks.CallAwsServiceCrossRegion",
|
|
6847
|
+
):
|
|
6848
|
+
'''A Step Functions task to call an AWS service API across regions.
|
|
6849
|
+
|
|
6850
|
+
This task creates a Lambda function to call cross-region AWS API and invokes it.
|
|
6851
|
+
|
|
6852
|
+
:exampleMetadata: infused
|
|
6853
|
+
|
|
6854
|
+
Example::
|
|
6855
|
+
|
|
6856
|
+
# my_bucket: s3.Bucket
|
|
6857
|
+
|
|
6858
|
+
get_object = tasks.CallAwsServiceCrossRegion(self, "GetObject",
|
|
6859
|
+
region="ap-northeast-1",
|
|
6860
|
+
service="s3",
|
|
6861
|
+
action="getObject",
|
|
6862
|
+
parameters={
|
|
6863
|
+
"Bucket": my_bucket.bucket_name,
|
|
6864
|
+
"Key": sfn.JsonPath.string_at("$.key")
|
|
6865
|
+
},
|
|
6866
|
+
iam_resources=[my_bucket.arn_for_objects("*")]
|
|
6867
|
+
)
|
|
6868
|
+
'''
|
|
6869
|
+
|
|
6870
|
+
def __init__(
|
|
6871
|
+
self,
|
|
6872
|
+
scope: _constructs_77d1e7e8.Construct,
|
|
6873
|
+
id: builtins.str,
|
|
6874
|
+
*,
|
|
6875
|
+
action: builtins.str,
|
|
6876
|
+
iam_resources: typing.Sequence[builtins.str],
|
|
6877
|
+
region: builtins.str,
|
|
6878
|
+
service: builtins.str,
|
|
6879
|
+
additional_iam_statements: typing.Optional[typing.Sequence[_PolicyStatement_0fe33853]] = None,
|
|
6880
|
+
endpoint: typing.Optional[builtins.str] = None,
|
|
6881
|
+
iam_action: typing.Optional[builtins.str] = None,
|
|
6882
|
+
parameters: typing.Optional[typing.Mapping[builtins.str, typing.Any]] = None,
|
|
6883
|
+
retry_on_service_exceptions: typing.Optional[builtins.bool] = None,
|
|
6884
|
+
comment: typing.Optional[builtins.str] = None,
|
|
6885
|
+
credentials: typing.Optional[typing.Union[_Credentials_2cd64c6b, typing.Dict[builtins.str, typing.Any]]] = None,
|
|
6886
|
+
heartbeat: typing.Optional[_Duration_4839e8c3] = None,
|
|
6887
|
+
heartbeat_timeout: typing.Optional[_Timeout_d7c10551] = None,
|
|
6888
|
+
input_path: typing.Optional[builtins.str] = None,
|
|
6889
|
+
integration_pattern: typing.Optional[_IntegrationPattern_949291bc] = None,
|
|
6890
|
+
output_path: typing.Optional[builtins.str] = None,
|
|
6891
|
+
result_path: typing.Optional[builtins.str] = None,
|
|
6892
|
+
result_selector: typing.Optional[typing.Mapping[builtins.str, typing.Any]] = None,
|
|
6893
|
+
state_name: typing.Optional[builtins.str] = None,
|
|
6894
|
+
task_timeout: typing.Optional[_Timeout_d7c10551] = None,
|
|
6895
|
+
timeout: typing.Optional[_Duration_4839e8c3] = None,
|
|
6896
|
+
) -> None:
|
|
6897
|
+
'''
|
|
6898
|
+
:param scope: -
|
|
6899
|
+
:param id: Descriptive identifier for this chainable.
|
|
6900
|
+
:param action: The API action to call. Use camelCase.
|
|
6901
|
+
:param iam_resources: The resources for the IAM statement that will be added to the Lambda function role's policy to allow the state machine to make the API call.
|
|
6902
|
+
:param region: The AWS region to call this AWS API for.
|
|
6903
|
+
:param service: The AWS service to call in AWS SDK for JavaScript v3 style.
|
|
6904
|
+
:param additional_iam_statements: Additional IAM statements that will be added to the state machine role's policy. Use in the case where the call requires more than a single statement to be executed, e.g. ``rekognition:detectLabels`` requires also S3 permissions to read the object on which it must act. Default: - no additional statements are added
|
|
6905
|
+
:param endpoint: The AWS API endpoint. Default: Do not override API endpoint.
|
|
6906
|
+
:param iam_action: The action for the IAM statement that will be added to the Lambda function role's policy to allow the state machine to make the API call. By default the action for this IAM statement will be ``service:action``. Use in the case where the IAM action name does not match with the API service/action name, e.g. ``s3:ListBuckets`` requires ``s3:ListAllMyBuckets``. Default: - service:action
|
|
6907
|
+
:param parameters: Parameters for the API action call. Use PascalCase for the parameter names. Default: - no parameters
|
|
6908
|
+
:param retry_on_service_exceptions: Whether to retry on the backend Lambda service exceptions. This handles ``Lambda.ServiceException``, ``Lambda.AWSLambdaException``, ``Lambda.SdkClientException``, and ``Lambda.ClientExecutionTimeoutException`` with an interval of 2 seconds, a back-off rate of 2 and 6 maximum attempts. Default: true
|
|
6909
|
+
:param comment: An optional description for this state. Default: - No comment
|
|
6910
|
+
: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)
|
|
6911
|
+
:param heartbeat: (deprecated) Timeout for the heartbeat. Default: - None
|
|
6912
|
+
: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
|
|
6913
|
+
: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 '$')
|
|
6914
|
+
: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``.
|
|
6915
|
+
: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 '$')
|
|
6916
|
+
: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 '$')
|
|
6917
|
+
: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
|
|
6918
|
+
:param state_name: Optional name for this state. Default: - The construct ID will be used as state name
|
|
6919
|
+
: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
|
|
6920
|
+
:param timeout: (deprecated) Timeout for the task. Default: - None
|
|
6921
|
+
'''
|
|
6922
|
+
if __debug__:
|
|
6923
|
+
type_hints = typing.get_type_hints(_typecheckingstub__788d4ab0ebc83fedbcaa927c3a9c9a8e1a7299ac43edcd72cc49a907a5b183b1)
|
|
6924
|
+
check_type(argname="argument scope", value=scope, expected_type=type_hints["scope"])
|
|
6925
|
+
check_type(argname="argument id", value=id, expected_type=type_hints["id"])
|
|
6926
|
+
props = CallAwsServiceCrossRegionProps(
|
|
6927
|
+
action=action,
|
|
6928
|
+
iam_resources=iam_resources,
|
|
6929
|
+
region=region,
|
|
6930
|
+
service=service,
|
|
6931
|
+
additional_iam_statements=additional_iam_statements,
|
|
6932
|
+
endpoint=endpoint,
|
|
6933
|
+
iam_action=iam_action,
|
|
6934
|
+
parameters=parameters,
|
|
6935
|
+
retry_on_service_exceptions=retry_on_service_exceptions,
|
|
6936
|
+
comment=comment,
|
|
6937
|
+
credentials=credentials,
|
|
6938
|
+
heartbeat=heartbeat,
|
|
6939
|
+
heartbeat_timeout=heartbeat_timeout,
|
|
6940
|
+
input_path=input_path,
|
|
6941
|
+
integration_pattern=integration_pattern,
|
|
6942
|
+
output_path=output_path,
|
|
6943
|
+
result_path=result_path,
|
|
6944
|
+
result_selector=result_selector,
|
|
6945
|
+
state_name=state_name,
|
|
6946
|
+
task_timeout=task_timeout,
|
|
6947
|
+
timeout=timeout,
|
|
6948
|
+
)
|
|
6949
|
+
|
|
6950
|
+
jsii.create(self.__class__, self, [scope, id, props])
|
|
6951
|
+
|
|
6952
|
+
@builtins.property
|
|
6953
|
+
@jsii.member(jsii_name="lambdaFunction")
|
|
6954
|
+
def _lambda_function(self) -> _IFunction_6adb0ab8:
|
|
6955
|
+
return typing.cast(_IFunction_6adb0ab8, jsii.get(self, "lambdaFunction"))
|
|
6956
|
+
|
|
6957
|
+
@builtins.property
|
|
6958
|
+
@jsii.member(jsii_name="taskMetrics")
|
|
6959
|
+
def _task_metrics(self) -> typing.Optional[_TaskMetricsConfig_32ea9403]:
|
|
6960
|
+
return typing.cast(typing.Optional[_TaskMetricsConfig_32ea9403], jsii.get(self, "taskMetrics"))
|
|
6961
|
+
|
|
6962
|
+
@builtins.property
|
|
6963
|
+
@jsii.member(jsii_name="taskPolicies")
|
|
6964
|
+
def _task_policies(self) -> typing.Optional[typing.List[_PolicyStatement_0fe33853]]:
|
|
6965
|
+
return typing.cast(typing.Optional[typing.List[_PolicyStatement_0fe33853]], jsii.get(self, "taskPolicies"))
|
|
6966
|
+
|
|
6967
|
+
|
|
6968
|
+
@jsii.data_type(
|
|
6969
|
+
jsii_type="aws-cdk-lib.aws_stepfunctions_tasks.CallAwsServiceCrossRegionProps",
|
|
6970
|
+
jsii_struct_bases=[_TaskStateBaseProps_3a62b6d0],
|
|
6971
|
+
name_mapping={
|
|
6972
|
+
"comment": "comment",
|
|
6973
|
+
"credentials": "credentials",
|
|
6974
|
+
"heartbeat": "heartbeat",
|
|
6975
|
+
"heartbeat_timeout": "heartbeatTimeout",
|
|
6976
|
+
"input_path": "inputPath",
|
|
6977
|
+
"integration_pattern": "integrationPattern",
|
|
6978
|
+
"output_path": "outputPath",
|
|
6979
|
+
"result_path": "resultPath",
|
|
6980
|
+
"result_selector": "resultSelector",
|
|
6981
|
+
"state_name": "stateName",
|
|
6982
|
+
"task_timeout": "taskTimeout",
|
|
6983
|
+
"timeout": "timeout",
|
|
6984
|
+
"action": "action",
|
|
6985
|
+
"iam_resources": "iamResources",
|
|
6986
|
+
"region": "region",
|
|
6987
|
+
"service": "service",
|
|
6988
|
+
"additional_iam_statements": "additionalIamStatements",
|
|
6989
|
+
"endpoint": "endpoint",
|
|
6990
|
+
"iam_action": "iamAction",
|
|
6991
|
+
"parameters": "parameters",
|
|
6992
|
+
"retry_on_service_exceptions": "retryOnServiceExceptions",
|
|
6993
|
+
},
|
|
6994
|
+
)
|
|
6995
|
+
class CallAwsServiceCrossRegionProps(_TaskStateBaseProps_3a62b6d0):
|
|
6996
|
+
def __init__(
|
|
6997
|
+
self,
|
|
6998
|
+
*,
|
|
6999
|
+
comment: typing.Optional[builtins.str] = None,
|
|
7000
|
+
credentials: typing.Optional[typing.Union[_Credentials_2cd64c6b, typing.Dict[builtins.str, typing.Any]]] = None,
|
|
7001
|
+
heartbeat: typing.Optional[_Duration_4839e8c3] = None,
|
|
7002
|
+
heartbeat_timeout: typing.Optional[_Timeout_d7c10551] = None,
|
|
7003
|
+
input_path: typing.Optional[builtins.str] = None,
|
|
7004
|
+
integration_pattern: typing.Optional[_IntegrationPattern_949291bc] = None,
|
|
7005
|
+
output_path: typing.Optional[builtins.str] = None,
|
|
7006
|
+
result_path: typing.Optional[builtins.str] = None,
|
|
7007
|
+
result_selector: typing.Optional[typing.Mapping[builtins.str, typing.Any]] = None,
|
|
7008
|
+
state_name: typing.Optional[builtins.str] = None,
|
|
7009
|
+
task_timeout: typing.Optional[_Timeout_d7c10551] = None,
|
|
7010
|
+
timeout: typing.Optional[_Duration_4839e8c3] = None,
|
|
7011
|
+
action: builtins.str,
|
|
7012
|
+
iam_resources: typing.Sequence[builtins.str],
|
|
7013
|
+
region: builtins.str,
|
|
7014
|
+
service: builtins.str,
|
|
7015
|
+
additional_iam_statements: typing.Optional[typing.Sequence[_PolicyStatement_0fe33853]] = None,
|
|
7016
|
+
endpoint: typing.Optional[builtins.str] = None,
|
|
7017
|
+
iam_action: typing.Optional[builtins.str] = None,
|
|
7018
|
+
parameters: typing.Optional[typing.Mapping[builtins.str, typing.Any]] = None,
|
|
7019
|
+
retry_on_service_exceptions: typing.Optional[builtins.bool] = None,
|
|
7020
|
+
) -> None:
|
|
7021
|
+
'''Properties for calling an AWS service's API action from your state machine across regions.
|
|
7022
|
+
|
|
7023
|
+
:param comment: An optional description for this state. Default: - No comment
|
|
7024
|
+
: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)
|
|
7025
|
+
:param heartbeat: (deprecated) Timeout for the heartbeat. Default: - None
|
|
7026
|
+
: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
|
|
7027
|
+
: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 '$')
|
|
7028
|
+
: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``.
|
|
7029
|
+
: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 '$')
|
|
7030
|
+
: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 '$')
|
|
7031
|
+
: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
|
|
7032
|
+
:param state_name: Optional name for this state. Default: - The construct ID will be used as state name
|
|
7033
|
+
: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
|
|
7034
|
+
:param timeout: (deprecated) Timeout for the task. Default: - None
|
|
7035
|
+
:param action: The API action to call. Use camelCase.
|
|
7036
|
+
:param iam_resources: The resources for the IAM statement that will be added to the Lambda function role's policy to allow the state machine to make the API call.
|
|
7037
|
+
:param region: The AWS region to call this AWS API for.
|
|
7038
|
+
:param service: The AWS service to call in AWS SDK for JavaScript v3 style.
|
|
7039
|
+
:param additional_iam_statements: Additional IAM statements that will be added to the state machine role's policy. Use in the case where the call requires more than a single statement to be executed, e.g. ``rekognition:detectLabels`` requires also S3 permissions to read the object on which it must act. Default: - no additional statements are added
|
|
7040
|
+
:param endpoint: The AWS API endpoint. Default: Do not override API endpoint.
|
|
7041
|
+
:param iam_action: The action for the IAM statement that will be added to the Lambda function role's policy to allow the state machine to make the API call. By default the action for this IAM statement will be ``service:action``. Use in the case where the IAM action name does not match with the API service/action name, e.g. ``s3:ListBuckets`` requires ``s3:ListAllMyBuckets``. Default: - service:action
|
|
7042
|
+
:param parameters: Parameters for the API action call. Use PascalCase for the parameter names. Default: - no parameters
|
|
7043
|
+
:param retry_on_service_exceptions: Whether to retry on the backend Lambda service exceptions. This handles ``Lambda.ServiceException``, ``Lambda.AWSLambdaException``, ``Lambda.SdkClientException``, and ``Lambda.ClientExecutionTimeoutException`` with an interval of 2 seconds, a back-off rate of 2 and 6 maximum attempts. Default: true
|
|
7044
|
+
|
|
7045
|
+
:exampleMetadata: infused
|
|
7046
|
+
|
|
7047
|
+
Example::
|
|
7048
|
+
|
|
7049
|
+
# my_bucket: s3.Bucket
|
|
7050
|
+
|
|
7051
|
+
get_object = tasks.CallAwsServiceCrossRegion(self, "GetObject",
|
|
7052
|
+
region="ap-northeast-1",
|
|
7053
|
+
service="s3",
|
|
7054
|
+
action="getObject",
|
|
7055
|
+
parameters={
|
|
7056
|
+
"Bucket": my_bucket.bucket_name,
|
|
7057
|
+
"Key": sfn.JsonPath.string_at("$.key")
|
|
7058
|
+
},
|
|
7059
|
+
iam_resources=[my_bucket.arn_for_objects("*")]
|
|
7060
|
+
)
|
|
7061
|
+
'''
|
|
7062
|
+
if isinstance(credentials, dict):
|
|
7063
|
+
credentials = _Credentials_2cd64c6b(**credentials)
|
|
7064
|
+
if __debug__:
|
|
7065
|
+
type_hints = typing.get_type_hints(_typecheckingstub__992363fbcea98bcb2c2657a6b897b7392fc6dc4d41155241ad7622bdc9d61923)
|
|
7066
|
+
check_type(argname="argument comment", value=comment, expected_type=type_hints["comment"])
|
|
7067
|
+
check_type(argname="argument credentials", value=credentials, expected_type=type_hints["credentials"])
|
|
7068
|
+
check_type(argname="argument heartbeat", value=heartbeat, expected_type=type_hints["heartbeat"])
|
|
7069
|
+
check_type(argname="argument heartbeat_timeout", value=heartbeat_timeout, expected_type=type_hints["heartbeat_timeout"])
|
|
7070
|
+
check_type(argname="argument input_path", value=input_path, expected_type=type_hints["input_path"])
|
|
7071
|
+
check_type(argname="argument integration_pattern", value=integration_pattern, expected_type=type_hints["integration_pattern"])
|
|
7072
|
+
check_type(argname="argument output_path", value=output_path, expected_type=type_hints["output_path"])
|
|
7073
|
+
check_type(argname="argument result_path", value=result_path, expected_type=type_hints["result_path"])
|
|
7074
|
+
check_type(argname="argument result_selector", value=result_selector, expected_type=type_hints["result_selector"])
|
|
7075
|
+
check_type(argname="argument state_name", value=state_name, expected_type=type_hints["state_name"])
|
|
7076
|
+
check_type(argname="argument task_timeout", value=task_timeout, expected_type=type_hints["task_timeout"])
|
|
7077
|
+
check_type(argname="argument timeout", value=timeout, expected_type=type_hints["timeout"])
|
|
7078
|
+
check_type(argname="argument action", value=action, expected_type=type_hints["action"])
|
|
7079
|
+
check_type(argname="argument iam_resources", value=iam_resources, expected_type=type_hints["iam_resources"])
|
|
7080
|
+
check_type(argname="argument region", value=region, expected_type=type_hints["region"])
|
|
7081
|
+
check_type(argname="argument service", value=service, expected_type=type_hints["service"])
|
|
7082
|
+
check_type(argname="argument additional_iam_statements", value=additional_iam_statements, expected_type=type_hints["additional_iam_statements"])
|
|
7083
|
+
check_type(argname="argument endpoint", value=endpoint, expected_type=type_hints["endpoint"])
|
|
7084
|
+
check_type(argname="argument iam_action", value=iam_action, expected_type=type_hints["iam_action"])
|
|
7085
|
+
check_type(argname="argument parameters", value=parameters, expected_type=type_hints["parameters"])
|
|
7086
|
+
check_type(argname="argument retry_on_service_exceptions", value=retry_on_service_exceptions, expected_type=type_hints["retry_on_service_exceptions"])
|
|
7087
|
+
self._values: typing.Dict[builtins.str, typing.Any] = {
|
|
7088
|
+
"action": action,
|
|
7089
|
+
"iam_resources": iam_resources,
|
|
7090
|
+
"region": region,
|
|
7091
|
+
"service": service,
|
|
7092
|
+
}
|
|
7093
|
+
if comment is not None:
|
|
7094
|
+
self._values["comment"] = comment
|
|
7095
|
+
if credentials is not None:
|
|
7096
|
+
self._values["credentials"] = credentials
|
|
7097
|
+
if heartbeat is not None:
|
|
7098
|
+
self._values["heartbeat"] = heartbeat
|
|
7099
|
+
if heartbeat_timeout is not None:
|
|
7100
|
+
self._values["heartbeat_timeout"] = heartbeat_timeout
|
|
7101
|
+
if input_path is not None:
|
|
7102
|
+
self._values["input_path"] = input_path
|
|
7103
|
+
if integration_pattern is not None:
|
|
7104
|
+
self._values["integration_pattern"] = integration_pattern
|
|
7105
|
+
if output_path is not None:
|
|
7106
|
+
self._values["output_path"] = output_path
|
|
7107
|
+
if result_path is not None:
|
|
7108
|
+
self._values["result_path"] = result_path
|
|
7109
|
+
if result_selector is not None:
|
|
7110
|
+
self._values["result_selector"] = result_selector
|
|
7111
|
+
if state_name is not None:
|
|
7112
|
+
self._values["state_name"] = state_name
|
|
7113
|
+
if task_timeout is not None:
|
|
7114
|
+
self._values["task_timeout"] = task_timeout
|
|
7115
|
+
if timeout is not None:
|
|
7116
|
+
self._values["timeout"] = timeout
|
|
7117
|
+
if additional_iam_statements is not None:
|
|
7118
|
+
self._values["additional_iam_statements"] = additional_iam_statements
|
|
7119
|
+
if endpoint is not None:
|
|
7120
|
+
self._values["endpoint"] = endpoint
|
|
7121
|
+
if iam_action is not None:
|
|
7122
|
+
self._values["iam_action"] = iam_action
|
|
7123
|
+
if parameters is not None:
|
|
7124
|
+
self._values["parameters"] = parameters
|
|
7125
|
+
if retry_on_service_exceptions is not None:
|
|
7126
|
+
self._values["retry_on_service_exceptions"] = retry_on_service_exceptions
|
|
7127
|
+
|
|
7128
|
+
@builtins.property
|
|
7129
|
+
def comment(self) -> typing.Optional[builtins.str]:
|
|
7130
|
+
'''An optional description for this state.
|
|
7131
|
+
|
|
7132
|
+
:default: - No comment
|
|
7133
|
+
'''
|
|
7134
|
+
result = self._values.get("comment")
|
|
7135
|
+
return typing.cast(typing.Optional[builtins.str], result)
|
|
7136
|
+
|
|
7137
|
+
@builtins.property
|
|
7138
|
+
def credentials(self) -> typing.Optional[_Credentials_2cd64c6b]:
|
|
7139
|
+
'''Credentials for an IAM Role that the State Machine assumes for executing the task.
|
|
7140
|
+
|
|
7141
|
+
This enables cross-account resource invocations.
|
|
7142
|
+
|
|
7143
|
+
:default: - None (Task is executed using the State Machine's execution role)
|
|
7144
|
+
|
|
7145
|
+
:see: https://docs.aws.amazon.com/step-functions/latest/dg/concepts-access-cross-acct-resources.html
|
|
7146
|
+
'''
|
|
7147
|
+
result = self._values.get("credentials")
|
|
7148
|
+
return typing.cast(typing.Optional[_Credentials_2cd64c6b], result)
|
|
7149
|
+
|
|
7150
|
+
@builtins.property
|
|
7151
|
+
def heartbeat(self) -> typing.Optional[_Duration_4839e8c3]:
|
|
7152
|
+
'''(deprecated) Timeout for the heartbeat.
|
|
7153
|
+
|
|
7154
|
+
:default: - None
|
|
7155
|
+
|
|
7156
|
+
:deprecated: use ``heartbeatTimeout``
|
|
7157
|
+
|
|
7158
|
+
:stability: deprecated
|
|
7159
|
+
'''
|
|
7160
|
+
result = self._values.get("heartbeat")
|
|
7161
|
+
return typing.cast(typing.Optional[_Duration_4839e8c3], result)
|
|
7162
|
+
|
|
7163
|
+
@builtins.property
|
|
7164
|
+
def heartbeat_timeout(self) -> typing.Optional[_Timeout_d7c10551]:
|
|
7165
|
+
'''Timeout for the heartbeat.
|
|
7166
|
+
|
|
7167
|
+
[disable-awslint:duration-prop-type] is needed because all props interface in
|
|
7168
|
+
aws-stepfunctions-tasks extend this interface
|
|
7169
|
+
|
|
7170
|
+
:default: - None
|
|
7171
|
+
'''
|
|
7172
|
+
result = self._values.get("heartbeat_timeout")
|
|
7173
|
+
return typing.cast(typing.Optional[_Timeout_d7c10551], result)
|
|
7174
|
+
|
|
7175
|
+
@builtins.property
|
|
7176
|
+
def input_path(self) -> typing.Optional[builtins.str]:
|
|
7177
|
+
'''JSONPath expression to select part of the state to be the input to this state.
|
|
7178
|
+
|
|
7179
|
+
May also be the special value JsonPath.DISCARD, which will cause the effective
|
|
7180
|
+
input to be the empty object {}.
|
|
7181
|
+
|
|
7182
|
+
:default: - The entire task input (JSON path '$')
|
|
7183
|
+
'''
|
|
7184
|
+
result = self._values.get("input_path")
|
|
7185
|
+
return typing.cast(typing.Optional[builtins.str], result)
|
|
7186
|
+
|
|
7187
|
+
@builtins.property
|
|
7188
|
+
def integration_pattern(self) -> typing.Optional[_IntegrationPattern_949291bc]:
|
|
7189
|
+
'''AWS Step Functions integrates with services directly in the Amazon States Language.
|
|
7190
|
+
|
|
7191
|
+
You can control these AWS services using service integration patterns.
|
|
7192
|
+
|
|
7193
|
+
Depending on the AWS Service, the Service Integration Pattern availability will vary.
|
|
7194
|
+
|
|
7195
|
+
:default:
|
|
7196
|
+
|
|
7197
|
+
- ``IntegrationPattern.REQUEST_RESPONSE`` for most tasks.
|
|
7198
|
+
``IntegrationPattern.RUN_JOB`` for the following exceptions:
|
|
7199
|
+
``BatchSubmitJob``, ``EmrAddStep``, ``EmrCreateCluster``, ``EmrTerminationCluster``, and ``EmrContainersStartJobRun``.
|
|
7200
|
+
|
|
7201
|
+
:see: https://docs.aws.amazon.com/step-functions/latest/dg/connect-supported-services.html
|
|
7202
|
+
'''
|
|
7203
|
+
result = self._values.get("integration_pattern")
|
|
7204
|
+
return typing.cast(typing.Optional[_IntegrationPattern_949291bc], result)
|
|
7205
|
+
|
|
7206
|
+
@builtins.property
|
|
7207
|
+
def output_path(self) -> typing.Optional[builtins.str]:
|
|
7208
|
+
'''JSONPath expression to select select a portion of the state output to pass to the next state.
|
|
7209
|
+
|
|
7210
|
+
May also be the special value JsonPath.DISCARD, which will cause the effective
|
|
7211
|
+
output to be the empty object {}.
|
|
7212
|
+
|
|
7213
|
+
:default:
|
|
7214
|
+
|
|
7215
|
+
- The entire JSON node determined by the state input, the task result,
|
|
7216
|
+
and resultPath is passed to the next state (JSON path '$')
|
|
7217
|
+
'''
|
|
7218
|
+
result = self._values.get("output_path")
|
|
7219
|
+
return typing.cast(typing.Optional[builtins.str], result)
|
|
7220
|
+
|
|
7221
|
+
@builtins.property
|
|
7222
|
+
def result_path(self) -> typing.Optional[builtins.str]:
|
|
7223
|
+
'''JSONPath expression to indicate where to inject the state's output.
|
|
7224
|
+
|
|
7225
|
+
May also be the special value JsonPath.DISCARD, which will cause the state's
|
|
7226
|
+
input to become its output.
|
|
7227
|
+
|
|
7228
|
+
:default: - Replaces the entire input with the result (JSON path '$')
|
|
7229
|
+
'''
|
|
7230
|
+
result = self._values.get("result_path")
|
|
7231
|
+
return typing.cast(typing.Optional[builtins.str], result)
|
|
7232
|
+
|
|
7233
|
+
@builtins.property
|
|
7234
|
+
def result_selector(
|
|
7235
|
+
self,
|
|
7236
|
+
) -> typing.Optional[typing.Mapping[builtins.str, typing.Any]]:
|
|
7237
|
+
'''The JSON that will replace the state's raw result and become the effective result before ResultPath is applied.
|
|
7238
|
+
|
|
7239
|
+
You can use ResultSelector to create a payload with values that are static
|
|
7240
|
+
or selected from the state's raw result.
|
|
7241
|
+
|
|
7242
|
+
:default: - None
|
|
7243
|
+
|
|
7244
|
+
:see: https://docs.aws.amazon.com/step-functions/latest/dg/input-output-inputpath-params.html#input-output-resultselector
|
|
7245
|
+
'''
|
|
7246
|
+
result = self._values.get("result_selector")
|
|
7247
|
+
return typing.cast(typing.Optional[typing.Mapping[builtins.str, typing.Any]], result)
|
|
7248
|
+
|
|
7249
|
+
@builtins.property
|
|
7250
|
+
def state_name(self) -> typing.Optional[builtins.str]:
|
|
7251
|
+
'''Optional name for this state.
|
|
7252
|
+
|
|
7253
|
+
:default: - The construct ID will be used as state name
|
|
7254
|
+
'''
|
|
7255
|
+
result = self._values.get("state_name")
|
|
7256
|
+
return typing.cast(typing.Optional[builtins.str], result)
|
|
7257
|
+
|
|
7258
|
+
@builtins.property
|
|
7259
|
+
def task_timeout(self) -> typing.Optional[_Timeout_d7c10551]:
|
|
7260
|
+
'''Timeout for the task.
|
|
7261
|
+
|
|
7262
|
+
[disable-awslint:duration-prop-type] is needed because all props interface in
|
|
7263
|
+
aws-stepfunctions-tasks extend this interface
|
|
7264
|
+
|
|
7265
|
+
:default: - None
|
|
7266
|
+
'''
|
|
7267
|
+
result = self._values.get("task_timeout")
|
|
7268
|
+
return typing.cast(typing.Optional[_Timeout_d7c10551], result)
|
|
7269
|
+
|
|
7270
|
+
@builtins.property
|
|
7271
|
+
def timeout(self) -> typing.Optional[_Duration_4839e8c3]:
|
|
7272
|
+
'''(deprecated) Timeout for the task.
|
|
7273
|
+
|
|
7274
|
+
:default: - None
|
|
7275
|
+
|
|
7276
|
+
:deprecated: use ``taskTimeout``
|
|
7277
|
+
|
|
7278
|
+
:stability: deprecated
|
|
7279
|
+
'''
|
|
7280
|
+
result = self._values.get("timeout")
|
|
7281
|
+
return typing.cast(typing.Optional[_Duration_4839e8c3], result)
|
|
7282
|
+
|
|
7283
|
+
@builtins.property
|
|
7284
|
+
def action(self) -> builtins.str:
|
|
7285
|
+
'''The API action to call.
|
|
6644
7286
|
|
|
6645
|
-
|
|
7287
|
+
Use camelCase.
|
|
6646
7288
|
'''
|
|
6647
|
-
result = self._values.get("
|
|
6648
|
-
|
|
7289
|
+
result = self._values.get("action")
|
|
7290
|
+
assert result is not None, "Required property 'action' is missing"
|
|
7291
|
+
return typing.cast(builtins.str, result)
|
|
6649
7292
|
|
|
6650
7293
|
@builtins.property
|
|
6651
|
-
def
|
|
6652
|
-
'''
|
|
7294
|
+
def iam_resources(self) -> typing.List[builtins.str]:
|
|
7295
|
+
'''The resources for the IAM statement that will be added to the Lambda function role's policy to allow the state machine to make the API call.'''
|
|
7296
|
+
result = self._values.get("iam_resources")
|
|
7297
|
+
assert result is not None, "Required property 'iam_resources' is missing"
|
|
7298
|
+
return typing.cast(typing.List[builtins.str], result)
|
|
6653
7299
|
|
|
6654
|
-
|
|
7300
|
+
@builtins.property
|
|
7301
|
+
def region(self) -> builtins.str:
|
|
7302
|
+
'''The AWS region to call this AWS API for.
|
|
7303
|
+
|
|
7304
|
+
Example::
|
|
7305
|
+
|
|
7306
|
+
"us-east-1"
|
|
6655
7307
|
'''
|
|
6656
|
-
result = self._values.get("
|
|
6657
|
-
|
|
7308
|
+
result = self._values.get("region")
|
|
7309
|
+
assert result is not None, "Required property 'region' is missing"
|
|
7310
|
+
return typing.cast(builtins.str, result)
|
|
6658
7311
|
|
|
6659
7312
|
@builtins.property
|
|
6660
|
-
def
|
|
6661
|
-
'''
|
|
7313
|
+
def service(self) -> builtins.str:
|
|
7314
|
+
'''The AWS service to call in AWS SDK for JavaScript v3 style.
|
|
6662
7315
|
|
|
6663
|
-
:
|
|
7316
|
+
:see: https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/
|
|
7317
|
+
|
|
7318
|
+
Example::
|
|
7319
|
+
|
|
7320
|
+
"s3"
|
|
6664
7321
|
'''
|
|
6665
|
-
result = self._values.get("
|
|
6666
|
-
|
|
7322
|
+
result = self._values.get("service")
|
|
7323
|
+
assert result is not None, "Required property 'service' is missing"
|
|
7324
|
+
return typing.cast(builtins.str, result)
|
|
6667
7325
|
|
|
6668
7326
|
@builtins.property
|
|
6669
|
-
def
|
|
6670
|
-
|
|
7327
|
+
def additional_iam_statements(
|
|
7328
|
+
self,
|
|
7329
|
+
) -> typing.Optional[typing.List[_PolicyStatement_0fe33853]]:
|
|
7330
|
+
'''Additional IAM statements that will be added to the state machine role's policy.
|
|
6671
7331
|
|
|
6672
|
-
|
|
7332
|
+
Use in the case where the call requires more than a single statement to
|
|
7333
|
+
be executed, e.g. ``rekognition:detectLabels`` requires also S3 permissions
|
|
7334
|
+
to read the object on which it must act.
|
|
7335
|
+
|
|
7336
|
+
:default: - no additional statements are added
|
|
6673
7337
|
'''
|
|
6674
|
-
result = self._values.get("
|
|
6675
|
-
return typing.cast(typing.Optional[
|
|
7338
|
+
result = self._values.get("additional_iam_statements")
|
|
7339
|
+
return typing.cast(typing.Optional[typing.List[_PolicyStatement_0fe33853]], result)
|
|
6676
7340
|
|
|
6677
7341
|
@builtins.property
|
|
6678
|
-
def
|
|
6679
|
-
'''
|
|
7342
|
+
def endpoint(self) -> typing.Optional[builtins.str]:
|
|
7343
|
+
'''The AWS API endpoint.
|
|
6680
7344
|
|
|
6681
|
-
:default:
|
|
7345
|
+
:default: Do not override API endpoint.
|
|
6682
7346
|
'''
|
|
6683
|
-
result = self._values.get("
|
|
6684
|
-
return typing.cast(typing.Optional[
|
|
7347
|
+
result = self._values.get("endpoint")
|
|
7348
|
+
return typing.cast(typing.Optional[builtins.str], result)
|
|
6685
7349
|
|
|
6686
7350
|
@builtins.property
|
|
6687
|
-
def
|
|
6688
|
-
'''
|
|
6689
|
-
result = self._values.get("api")
|
|
6690
|
-
assert result is not None, "Required property 'api' is missing"
|
|
6691
|
-
return typing.cast(_IRestApi_1f02523d, result)
|
|
7351
|
+
def iam_action(self) -> typing.Optional[builtins.str]:
|
|
7352
|
+
'''The action for the IAM statement that will be added to the Lambda function role's policy to allow the state machine to make the API call.
|
|
6692
7353
|
|
|
6693
|
-
|
|
6694
|
-
def stage_name(self) -> builtins.str:
|
|
6695
|
-
'''Name of the stage where the API is deployed to in API Gateway.'''
|
|
6696
|
-
result = self._values.get("stage_name")
|
|
6697
|
-
assert result is not None, "Required property 'stage_name' is missing"
|
|
6698
|
-
return typing.cast(builtins.str, result)
|
|
7354
|
+
By default the action for this IAM statement will be ``service:action``.
|
|
6699
7355
|
|
|
6700
|
-
|
|
6701
|
-
|
|
7356
|
+
Use in the case where the IAM action name does not match with the
|
|
7357
|
+
API service/action name, e.g. ``s3:ListBuckets`` requires ``s3:ListAllMyBuckets``.
|
|
6702
7358
|
|
|
6703
|
-
|
|
6704
|
-
|
|
7359
|
+
:default: - service:action
|
|
7360
|
+
'''
|
|
7361
|
+
result = self._values.get("iam_action")
|
|
7362
|
+
return typing.cast(typing.Optional[builtins.str], result)
|
|
6705
7363
|
|
|
6706
|
-
|
|
6707
|
-
|
|
6708
|
-
|
|
6709
|
-
)
|
|
7364
|
+
@builtins.property
|
|
7365
|
+
def parameters(self) -> typing.Optional[typing.Mapping[builtins.str, typing.Any]]:
|
|
7366
|
+
'''Parameters for the API action call.
|
|
6710
7367
|
|
|
7368
|
+
Use PascalCase for the parameter names.
|
|
6711
7369
|
|
|
6712
|
-
|
|
6713
|
-
|
|
6714
|
-
|
|
6715
|
-
|
|
6716
|
-
):
|
|
6717
|
-
'''A StepFunctions task to call an AWS service API.
|
|
7370
|
+
:default: - no parameters
|
|
7371
|
+
'''
|
|
7372
|
+
result = self._values.get("parameters")
|
|
7373
|
+
return typing.cast(typing.Optional[typing.Mapping[builtins.str, typing.Any]], result)
|
|
6718
7374
|
|
|
6719
|
-
|
|
7375
|
+
@builtins.property
|
|
7376
|
+
def retry_on_service_exceptions(self) -> typing.Optional[builtins.bool]:
|
|
7377
|
+
'''Whether to retry on the backend Lambda service exceptions.
|
|
6720
7378
|
|
|
6721
|
-
|
|
7379
|
+
This handles ``Lambda.ServiceException``, ``Lambda.AWSLambdaException``,
|
|
7380
|
+
``Lambda.SdkClientException``, and ``Lambda.ClientExecutionTimeoutException``
|
|
7381
|
+
with an interval of 2 seconds, a back-off rate
|
|
7382
|
+
of 2 and 6 maximum attempts.
|
|
6722
7383
|
|
|
6723
|
-
|
|
6724
|
-
|
|
6725
|
-
get_object = tasks.CallAwsService(self, "GetObject",
|
|
6726
|
-
service="s3",
|
|
6727
|
-
action="getObject",
|
|
6728
|
-
parameters={
|
|
6729
|
-
"Bucket": my_bucket.bucket_name,
|
|
6730
|
-
"Key": sfn.JsonPath.string_at("$.key")
|
|
6731
|
-
},
|
|
6732
|
-
iam_resources=[my_bucket.arn_for_objects("*")]
|
|
6733
|
-
)
|
|
6734
|
-
'''
|
|
7384
|
+
:default: true
|
|
6735
7385
|
|
|
6736
|
-
|
|
6737
|
-
self,
|
|
6738
|
-
scope: _constructs_77d1e7e8.Construct,
|
|
6739
|
-
id: builtins.str,
|
|
6740
|
-
*,
|
|
6741
|
-
action: builtins.str,
|
|
6742
|
-
iam_resources: typing.Sequence[builtins.str],
|
|
6743
|
-
service: builtins.str,
|
|
6744
|
-
additional_iam_statements: typing.Optional[typing.Sequence[_PolicyStatement_0fe33853]] = None,
|
|
6745
|
-
iam_action: typing.Optional[builtins.str] = None,
|
|
6746
|
-
parameters: typing.Optional[typing.Mapping[builtins.str, typing.Any]] = None,
|
|
6747
|
-
comment: typing.Optional[builtins.str] = None,
|
|
6748
|
-
credentials: typing.Optional[typing.Union[_Credentials_2cd64c6b, typing.Dict[builtins.str, typing.Any]]] = None,
|
|
6749
|
-
heartbeat: typing.Optional[_Duration_4839e8c3] = None,
|
|
6750
|
-
heartbeat_timeout: typing.Optional[_Timeout_d7c10551] = None,
|
|
6751
|
-
input_path: typing.Optional[builtins.str] = None,
|
|
6752
|
-
integration_pattern: typing.Optional[_IntegrationPattern_949291bc] = None,
|
|
6753
|
-
output_path: typing.Optional[builtins.str] = None,
|
|
6754
|
-
result_path: typing.Optional[builtins.str] = None,
|
|
6755
|
-
result_selector: typing.Optional[typing.Mapping[builtins.str, typing.Any]] = None,
|
|
6756
|
-
state_name: typing.Optional[builtins.str] = None,
|
|
6757
|
-
task_timeout: typing.Optional[_Timeout_d7c10551] = None,
|
|
6758
|
-
timeout: typing.Optional[_Duration_4839e8c3] = None,
|
|
6759
|
-
) -> None:
|
|
6760
|
-
'''
|
|
6761
|
-
:param scope: -
|
|
6762
|
-
:param id: Descriptive identifier for this chainable.
|
|
6763
|
-
:param action: The API action to call. Use camelCase.
|
|
6764
|
-
:param iam_resources: The resources for the IAM statement that will be added to the state machine role's policy to allow the state machine to make the API call. By default the action for this IAM statement will be ``service:action``.
|
|
6765
|
-
:param service: The AWS service to call.
|
|
6766
|
-
:param additional_iam_statements: Additional IAM statements that will be added to the state machine role's policy. Use in the case where the call requires more than a single statement to be executed, e.g. ``rekognition:detectLabels`` requires also S3 permissions to read the object on which it must act. Default: - no additional statements are added
|
|
6767
|
-
:param iam_action: The action for the IAM statement that will be added to the state machine role's policy to allow the state machine to make the API call. Use in the case where the IAM action name does not match with the API service/action name, e.g. ``s3:ListBuckets`` requires ``s3:ListAllMyBuckets``. Default: - service:action
|
|
6768
|
-
:param parameters: Parameters for the API action call. Use PascalCase for the parameter names. Default: - no parameters
|
|
6769
|
-
:param comment: An optional description for this state. Default: - No comment
|
|
6770
|
-
: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)
|
|
6771
|
-
:param heartbeat: (deprecated) Timeout for the heartbeat. Default: - None
|
|
6772
|
-
: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
|
|
6773
|
-
: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 '$')
|
|
6774
|
-
: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``.
|
|
6775
|
-
: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 '$')
|
|
6776
|
-
: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 '$')
|
|
6777
|
-
: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
|
|
6778
|
-
:param state_name: Optional name for this state. Default: - The construct ID will be used as state name
|
|
6779
|
-
: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
|
|
6780
|
-
:param timeout: (deprecated) Timeout for the task. Default: - None
|
|
7386
|
+
:see: https://docs.aws.amazon.com/step-functions/latest/dg/bp-lambda-serviceexception.html
|
|
6781
7387
|
'''
|
|
6782
|
-
|
|
6783
|
-
|
|
6784
|
-
check_type(argname="argument scope", value=scope, expected_type=type_hints["scope"])
|
|
6785
|
-
check_type(argname="argument id", value=id, expected_type=type_hints["id"])
|
|
6786
|
-
props = CallAwsServiceProps(
|
|
6787
|
-
action=action,
|
|
6788
|
-
iam_resources=iam_resources,
|
|
6789
|
-
service=service,
|
|
6790
|
-
additional_iam_statements=additional_iam_statements,
|
|
6791
|
-
iam_action=iam_action,
|
|
6792
|
-
parameters=parameters,
|
|
6793
|
-
comment=comment,
|
|
6794
|
-
credentials=credentials,
|
|
6795
|
-
heartbeat=heartbeat,
|
|
6796
|
-
heartbeat_timeout=heartbeat_timeout,
|
|
6797
|
-
input_path=input_path,
|
|
6798
|
-
integration_pattern=integration_pattern,
|
|
6799
|
-
output_path=output_path,
|
|
6800
|
-
result_path=result_path,
|
|
6801
|
-
result_selector=result_selector,
|
|
6802
|
-
state_name=state_name,
|
|
6803
|
-
task_timeout=task_timeout,
|
|
6804
|
-
timeout=timeout,
|
|
6805
|
-
)
|
|
7388
|
+
result = self._values.get("retry_on_service_exceptions")
|
|
7389
|
+
return typing.cast(typing.Optional[builtins.bool], result)
|
|
6806
7390
|
|
|
6807
|
-
|
|
7391
|
+
def __eq__(self, rhs: typing.Any) -> builtins.bool:
|
|
7392
|
+
return isinstance(rhs, self.__class__) and rhs._values == self._values
|
|
6808
7393
|
|
|
6809
|
-
|
|
6810
|
-
|
|
6811
|
-
def _task_metrics(self) -> typing.Optional[_TaskMetricsConfig_32ea9403]:
|
|
6812
|
-
return typing.cast(typing.Optional[_TaskMetricsConfig_32ea9403], jsii.get(self, "taskMetrics"))
|
|
7394
|
+
def __ne__(self, rhs: typing.Any) -> builtins.bool:
|
|
7395
|
+
return not (rhs == self)
|
|
6813
7396
|
|
|
6814
|
-
|
|
6815
|
-
|
|
6816
|
-
|
|
6817
|
-
|
|
7397
|
+
def __repr__(self) -> str:
|
|
7398
|
+
return "CallAwsServiceCrossRegionProps(%s)" % ", ".join(
|
|
7399
|
+
k + "=" + repr(v) for k, v in self._values.items()
|
|
7400
|
+
)
|
|
6818
7401
|
|
|
6819
7402
|
|
|
6820
7403
|
@jsii.data_type(
|
|
@@ -33441,6 +34024,8 @@ __all__ = [
|
|
|
33441
34024
|
"CallApiGatewayRestApiEndpoint",
|
|
33442
34025
|
"CallApiGatewayRestApiEndpointProps",
|
|
33443
34026
|
"CallAwsService",
|
|
34027
|
+
"CallAwsServiceCrossRegion",
|
|
34028
|
+
"CallAwsServiceCrossRegionProps",
|
|
33444
34029
|
"CallAwsServiceProps",
|
|
33445
34030
|
"Channel",
|
|
33446
34031
|
"Classification",
|
|
@@ -34101,6 +34686,62 @@ def _typecheckingstub__e4534f8232f0840d6ef9dc3920130b2d24934f22c4483b9bd14a19e81
|
|
|
34101
34686
|
"""Type checking stubs"""
|
|
34102
34687
|
pass
|
|
34103
34688
|
|
|
34689
|
+
def _typecheckingstub__788d4ab0ebc83fedbcaa927c3a9c9a8e1a7299ac43edcd72cc49a907a5b183b1(
|
|
34690
|
+
scope: _constructs_77d1e7e8.Construct,
|
|
34691
|
+
id: builtins.str,
|
|
34692
|
+
*,
|
|
34693
|
+
action: builtins.str,
|
|
34694
|
+
iam_resources: typing.Sequence[builtins.str],
|
|
34695
|
+
region: builtins.str,
|
|
34696
|
+
service: builtins.str,
|
|
34697
|
+
additional_iam_statements: typing.Optional[typing.Sequence[_PolicyStatement_0fe33853]] = None,
|
|
34698
|
+
endpoint: typing.Optional[builtins.str] = None,
|
|
34699
|
+
iam_action: typing.Optional[builtins.str] = None,
|
|
34700
|
+
parameters: typing.Optional[typing.Mapping[builtins.str, typing.Any]] = None,
|
|
34701
|
+
retry_on_service_exceptions: typing.Optional[builtins.bool] = None,
|
|
34702
|
+
comment: typing.Optional[builtins.str] = None,
|
|
34703
|
+
credentials: typing.Optional[typing.Union[_Credentials_2cd64c6b, typing.Dict[builtins.str, typing.Any]]] = None,
|
|
34704
|
+
heartbeat: typing.Optional[_Duration_4839e8c3] = None,
|
|
34705
|
+
heartbeat_timeout: typing.Optional[_Timeout_d7c10551] = None,
|
|
34706
|
+
input_path: typing.Optional[builtins.str] = None,
|
|
34707
|
+
integration_pattern: typing.Optional[_IntegrationPattern_949291bc] = None,
|
|
34708
|
+
output_path: typing.Optional[builtins.str] = None,
|
|
34709
|
+
result_path: typing.Optional[builtins.str] = None,
|
|
34710
|
+
result_selector: typing.Optional[typing.Mapping[builtins.str, typing.Any]] = None,
|
|
34711
|
+
state_name: typing.Optional[builtins.str] = None,
|
|
34712
|
+
task_timeout: typing.Optional[_Timeout_d7c10551] = None,
|
|
34713
|
+
timeout: typing.Optional[_Duration_4839e8c3] = None,
|
|
34714
|
+
) -> None:
|
|
34715
|
+
"""Type checking stubs"""
|
|
34716
|
+
pass
|
|
34717
|
+
|
|
34718
|
+
def _typecheckingstub__992363fbcea98bcb2c2657a6b897b7392fc6dc4d41155241ad7622bdc9d61923(
|
|
34719
|
+
*,
|
|
34720
|
+
comment: typing.Optional[builtins.str] = None,
|
|
34721
|
+
credentials: typing.Optional[typing.Union[_Credentials_2cd64c6b, typing.Dict[builtins.str, typing.Any]]] = None,
|
|
34722
|
+
heartbeat: typing.Optional[_Duration_4839e8c3] = None,
|
|
34723
|
+
heartbeat_timeout: typing.Optional[_Timeout_d7c10551] = None,
|
|
34724
|
+
input_path: typing.Optional[builtins.str] = None,
|
|
34725
|
+
integration_pattern: typing.Optional[_IntegrationPattern_949291bc] = None,
|
|
34726
|
+
output_path: typing.Optional[builtins.str] = None,
|
|
34727
|
+
result_path: typing.Optional[builtins.str] = None,
|
|
34728
|
+
result_selector: typing.Optional[typing.Mapping[builtins.str, typing.Any]] = None,
|
|
34729
|
+
state_name: typing.Optional[builtins.str] = None,
|
|
34730
|
+
task_timeout: typing.Optional[_Timeout_d7c10551] = None,
|
|
34731
|
+
timeout: typing.Optional[_Duration_4839e8c3] = None,
|
|
34732
|
+
action: builtins.str,
|
|
34733
|
+
iam_resources: typing.Sequence[builtins.str],
|
|
34734
|
+
region: builtins.str,
|
|
34735
|
+
service: builtins.str,
|
|
34736
|
+
additional_iam_statements: typing.Optional[typing.Sequence[_PolicyStatement_0fe33853]] = None,
|
|
34737
|
+
endpoint: typing.Optional[builtins.str] = None,
|
|
34738
|
+
iam_action: typing.Optional[builtins.str] = None,
|
|
34739
|
+
parameters: typing.Optional[typing.Mapping[builtins.str, typing.Any]] = None,
|
|
34740
|
+
retry_on_service_exceptions: typing.Optional[builtins.bool] = None,
|
|
34741
|
+
) -> None:
|
|
34742
|
+
"""Type checking stubs"""
|
|
34743
|
+
pass
|
|
34744
|
+
|
|
34104
34745
|
def _typecheckingstub__63c577047b5ec17a682dc869c299af67611178c845f52baceb7e79927eee3db3(
|
|
34105
34746
|
*,
|
|
34106
34747
|
comment: typing.Optional[builtins.str] = None,
|