Interface ICallAwsServiceJsonataProps
Properties for calling an AWS service's API action using JSONata from your state machine.
Inherited Members
Namespace: Amazon.CDK.AWS.StepFunctions.Tasks
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public interface ICallAwsServiceJsonataProps : ITaskStateJsonataBaseProps, IStateBaseProps, ITaskStateBaseOptions, IAssignableStateOptions, IJsonataCommonOptions
Syntax (vb)
Public Interface ICallAwsServiceJsonataProps Inherits ITaskStateJsonataBaseProps, IStateBaseProps, ITaskStateBaseOptions, IAssignableStateOptions, IJsonataCommonOptions
Remarks
See: https://docs.aws.amazon.com/step-functions/latest/dg/supported-services-awssdk.html
ExampleMetadata: fixture=_generated
Examples
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK;
using Amazon.CDK.AWS.IAM;
using Amazon.CDK.AWS.StepFunctions;
using Amazon.CDK.AWS.StepFunctions.Tasks;
var assign;
var outputs;
var parameters;
PolicyStatement policyStatement;
TaskRole taskRole;
Timeout timeout;
var callAwsServiceJsonataProps = new CallAwsServiceJsonataProps {
Action = "action",
IamResources = new [] { "iamResources" },
Service = "service",
// the properties below are optional
AdditionalIamStatements = new [] { policyStatement },
Assign = new Dictionary<string, object> {
{ "assignKey", assign }
},
Comment = "comment",
Credentials = new Credentials {
Role = taskRole
},
Heartbeat = Duration.Minutes(30),
HeartbeatTimeout = timeout,
IamAction = "iamAction",
IntegrationPattern = IntegrationPattern.REQUEST_RESPONSE,
Outputs = outputs,
Parameters = new Dictionary<string, object> {
{ "parametersKey", parameters }
},
QueryLanguage = QueryLanguage.JSON_PATH,
StateName = "stateName",
TaskTimeout = timeout,
Timeout = Duration.Minutes(30)
};
Synopsis
Properties
| Action | The API action to call. |
| AdditionalIamStatements | Additional IAM statements that will be added to the state machine role's policy. |
| 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
AdditionalIamStatements
Additional IAM statements that will be added to the state machine role's policy.
PolicyStatement[]? AdditionalIamStatements { get; }
Property Value
Remarks
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
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.
string? IamAction { get; }
Property Value
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
string[]
Remarks
By default the action for this IAM statement will be service:action.
Parameters
Parameters for the API action call.
IDictionary<string, object>? Parameters { get; }
Property Value
Remarks
Use PascalCase for the parameter names.
Default: - no parameters
Service
The AWS service to call.
string Service { get; }