Interface ICallAwsServiceProps
Properties for calling an AWS service's API action from your state machine.
Inherited Members
Namespace: Amazon.CDK.AWS.StepFunctions.Tasks
Assembly: Amazon.CDK.AWS.StepFunctions.Tasks.dll
Syntax (csharp)
public interface ICallAwsServiceProps : ITaskStateBaseProps
Syntax (vb)
Public Interface ICallAwsServiceProps
Inherits ITaskStateBaseProps
Remarks
See: https://docs.aws.amazon.com/step-functions/latest/dg/supported-services-awssdk.html
ExampleMetadata: infused
Examples
Bucket myBucket;
var getObject = new CallAwsService(this, "GetObject", new CallAwsServiceProps {
Service = "s3",
Action = "getObject",
Parameters = new Dictionary<string, object> {
{ "Bucket", myBucket.BucketName },
{ "Key", JsonPath.StringAt("$.key") }
},
IamResources = new [] { myBucket.ArnForObjects("*") }
});
Synopsis
Properties
Action | The API action to call. |
IamAction | 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. |
IamResources | 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. |
Parameters | Parameters for the API action call. |
Service | The AWS service to call. |
Properties
Action
The API action to call.
string Action { get; }
Property Value
System.String
Remarks
Use camelCase.
IamAction
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.
virtual string IamAction { get; }
Property Value
System.String
Remarks
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
IamResources
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.
string[] IamResources { get; }
Property Value
System.String[]
Remarks
By default the action for this IAM statement will be service:action
.
Parameters
Parameters for the API action call.
virtual IDictionary<string, object> Parameters { get; }
Property Value
System.Collections.Generic.IDictionary<System.String, System.Object>
Remarks
Use PascalCase for the parameter names.
Default: - no parameters
Service
The AWS service to call.
string Service { get; }
Property Value
System.String