2019/12/04 - AWS Step Functions - 4 updated api methods
Changes Update stepfunctions client to latest version
{'loggingConfiguration': {'destinations': [{'cloudWatchLogsLogGroup': {'logGroupArn': 'string'}}], 'includeExecutionData': 'boolean', 'level': 'ALL | ERROR | FATAL | OFF'}, 'type': 'STANDARD | EXPRESS'}
Creates a state machine. A state machine consists of a collection of states that can do work ( Task states), determine to which states to transition next ( Choice states), stop an execution with an error ( Fail states), and so on. State machines are specified using a JSON-based, structured language.
See also: AWS API Documentation
Request Syntax
client.create_state_machine( name='string', definition='string', roleArn='string', type='STANDARD'|'EXPRESS', loggingConfiguration={ 'level': 'ALL'|'ERROR'|'FATAL'|'OFF', 'includeExecutionData': True|False, 'destinations': [ { 'cloudWatchLogsLogGroup': { 'logGroupArn': 'string' } }, ] }, tags=[ { 'key': 'string', 'value': 'string' }, ] )
string
[REQUIRED]
The name of the state machine.
A name must not contain:
white space
brackets < > { } [ ]
wildcard characters ? *
special characters " # % \ ^ | ~ ` $ & , ; : /
control characters ( U+0000-001F, U+007F-009F)
string
[REQUIRED]
The Amazon States Language definition of the state machine. See Amazon States Language.
string
[REQUIRED]
The Amazon Resource Name (ARN) of the IAM role to use for this state machine.
string
Determines whether a Standard or Express state machine is created. If not set, Standard is created.
dict
Defines what execution history events are logged and where they are logged.
level (string) --
Defines which category of execution history events are logged.
includeExecutionData (boolean) --
Determines whether execution history data is included in your log. When set to FALSE, data is excluded.
destinations (list) --
An object that describes where your execution history events will be logged. Limited to size 1. Required, if your log level is not set to OFF.
(dict) --
cloudWatchLogsLogGroup (dict) --
An object describing a CloudWatch log group. For more information, see AWS::Logs::LogGroup in the AWS CloudFormation User Guide.
logGroupArn (string) --
The ARN of the the CloudWatch log group to which you want your logs emitted to. The ARN must end with :*
list
Tags to be added when creating a state machine.
An array of key-value pairs. For more information, see Using Cost Allocation Tags in the AWS Billing and Cost Management User Guide, and Controlling Access Using IAM Tags.
Tags may only contain Unicode letters, digits, white space, or these symbols: _ . : / = + - @.
(dict) --
Tags are key-value pairs that can be associated with Step Functions state machines and activities.
An array of key-value pairs. For more information, see Using Cost Allocation Tags in the AWS Billing and Cost Management User Guide, and Controlling Access Using IAM Tags.
Tags may only contain Unicode letters, digits, white space, or these symbols: _ . : / = + - @.
key (string) --
The key of a tag.
value (string) --
The value of a tag.
dict
Response Syntax
{ 'stateMachineArn': 'string', 'creationDate': datetime(2015, 1, 1) }
Response Structure
(dict) --
stateMachineArn (string) --
The Amazon Resource Name (ARN) that identifies the created state machine.
creationDate (datetime) --
The date the state machine is created.
{'loggingConfiguration': {'destinations': [{'cloudWatchLogsLogGroup': {'logGroupArn': 'string'}}], 'includeExecutionData': 'boolean', 'level': 'ALL | ERROR | FATAL | OFF'}, 'type': 'STANDARD | EXPRESS'}
Describes a state machine.
See also: AWS API Documentation
Request Syntax
client.describe_state_machine( stateMachineArn='string' )
string
[REQUIRED]
The Amazon Resource Name (ARN) of the state machine to describe.
dict
Response Syntax
{ 'stateMachineArn': 'string', 'name': 'string', 'status': 'ACTIVE'|'DELETING', 'definition': 'string', 'roleArn': 'string', 'type': 'STANDARD'|'EXPRESS', 'creationDate': datetime(2015, 1, 1), 'loggingConfiguration': { 'level': 'ALL'|'ERROR'|'FATAL'|'OFF', 'includeExecutionData': True|False, 'destinations': [ { 'cloudWatchLogsLogGroup': { 'logGroupArn': 'string' } }, ] } }
Response Structure
(dict) --
stateMachineArn (string) --
The Amazon Resource Name (ARN) that identifies the state machine.
name (string) --
The name of the state machine.
A name must not contain:
white space
brackets < > { } [ ]
wildcard characters ? *
special characters " # % \ ^ | ~ ` $ & , ; : /
control characters ( U+0000-001F, U+007F-009F)
status (string) --
The current status of the state machine.
definition (string) --
The Amazon States Language definition of the state machine. See Amazon States Language.
roleArn (string) --
The Amazon Resource Name (ARN) of the IAM role used when creating this state machine. (The IAM role maintains security by granting Step Functions access to AWS resources.)
type (string) --
creationDate (datetime) --
The date the state machine is created.
loggingConfiguration (dict) --
level (string) --
Defines which category of execution history events are logged.
includeExecutionData (boolean) --
Determines whether execution history data is included in your log. When set to FALSE, data is excluded.
destinations (list) --
An object that describes where your execution history events will be logged. Limited to size 1. Required, if your log level is not set to OFF.
(dict) --
cloudWatchLogsLogGroup (dict) --
An object describing a CloudWatch log group. For more information, see AWS::Logs::LogGroup in the AWS CloudFormation User Guide.
logGroupArn (string) --
The ARN of the the CloudWatch log group to which you want your logs emitted to. The ARN must end with :*
{'stateMachines': {'type': 'STANDARD | EXPRESS'}}
Lists the existing state machines.
If nextToken is returned, there are more results available. The value of nextToken is a unique pagination token for each page. Make the call again using the returned token to retrieve the next page. Keep all other arguments unchanged. Each pagination token expires after 24 hours. Using an expired pagination token will return an HTTP 400 InvalidToken error.
See also: AWS API Documentation
Request Syntax
client.list_state_machines( maxResults=123, nextToken='string' )
integer
The maximum number of results that are returned per call. You can use nextToken to obtain further pages of results. The default is 100 and the maximum allowed page size is 1000. A value of 0 uses the default.
This is only an upper limit. The actual number of results returned per call might be fewer than the specified maximum.
string
If nextToken is returned, there are more results available. The value of nextToken is a unique pagination token for each page. Make the call again using the returned token to retrieve the next page. Keep all other arguments unchanged. Each pagination token expires after 24 hours. Using an expired pagination token will return an HTTP 400 InvalidToken error.
dict
Response Syntax
{ 'stateMachines': [ { 'stateMachineArn': 'string', 'name': 'string', 'type': 'STANDARD'|'EXPRESS', 'creationDate': datetime(2015, 1, 1) }, ], 'nextToken': 'string' }
Response Structure
(dict) --
stateMachines (list) --
(dict) --
Contains details about the state machine.
stateMachineArn (string) --
The Amazon Resource Name (ARN) that identifies the state machine.
name (string) --
The name of the state machine.
A name must not contain:
white space
brackets < > { } [ ]
wildcard characters ? *
special characters " # % \ ^ | ~ ` $ & , ; : /
control characters ( U+0000-001F, U+007F-009F)
type (string) --
creationDate (datetime) --
The date the state machine is created.
nextToken (string) --
If nextToken is returned, there are more results available. The value of nextToken is a unique pagination token for each page. Make the call again using the returned token to retrieve the next page. Keep all other arguments unchanged. Each pagination token expires after 24 hours. Using an expired pagination token will return an HTTP 400 InvalidToken error.
{'loggingConfiguration': {'destinations': [{'cloudWatchLogsLogGroup': {'logGroupArn': 'string'}}], 'includeExecutionData': 'boolean', 'level': 'ALL | ERROR | FATAL | OFF'}}
Updates an existing state machine by modifying its definition and/or roleArn. Running executions will continue to use the previous definition and roleArn. You must include at least one of definition or roleArn or you will receive a MissingRequiredParameter error.
See also: AWS API Documentation
Request Syntax
client.update_state_machine( stateMachineArn='string', definition='string', roleArn='string', loggingConfiguration={ 'level': 'ALL'|'ERROR'|'FATAL'|'OFF', 'includeExecutionData': True|False, 'destinations': [ { 'cloudWatchLogsLogGroup': { 'logGroupArn': 'string' } }, ] } )
string
[REQUIRED]
The Amazon Resource Name (ARN) of the state machine.
string
The Amazon States Language definition of the state machine. See Amazon States Language.
string
The Amazon Resource Name (ARN) of the IAM role of the state machine.
dict
level (string) --
Defines which category of execution history events are logged.
includeExecutionData (boolean) --
Determines whether execution history data is included in your log. When set to FALSE, data is excluded.
destinations (list) --
An object that describes where your execution history events will be logged. Limited to size 1. Required, if your log level is not set to OFF.
(dict) --
cloudWatchLogsLogGroup (dict) --
An object describing a CloudWatch log group. For more information, see AWS::Logs::LogGroup in the AWS CloudFormation User Guide.
logGroupArn (string) --
The ARN of the the CloudWatch log group to which you want your logs emitted to. The ARN must end with :*
dict
Response Syntax
{ 'updateDate': datetime(2015, 1, 1) }
Response Structure
(dict) --
updateDate (datetime) --
The date and time the state machine was updated.