AWS CLI version 2, the latest major version of AWS CLI, is now stable and recommended for general use. To view this page for the AWS CLI version 2, click here. For more information see the AWS CLI version 2 installation instructions and migration guide.
[ aws . stepfunctions ]
Starts a state machine execution.
A qualified state machine ARN can either refer to a Distributed Map state defined within a state machine, a version ARN, or an alias ARN.
The following are some examples of qualified and unqualified state machine ARNs:
mapStateLabel
in a state machine named myStateMachine
. arn:partition:states:region:account-id:stateMachine:myStateMachine/mapStateLabel
ValidationException
.PROD
. arn:<partition>:states:<region>:<account-id>:stateMachine:<myStateMachine:PROD>
myStateMachine
. arn:<partition>:states:<region>:<account-id>:stateMachine:<myStateMachine>
If you start an execution with an unqualified state machine ARN, Step Functions uses the latest revision of the state machine for the execution.
To start executions of a state machine version , call StartExecution
and provide the version ARN or the ARN of an alias that points to the version.
StartExecution
is idempotent for STANDARD
workflows. For a STANDARD
workflow, if you call StartExecution
with the same name and input as a running execution, the call succeeds and return the same response as the original request. If the execution is closed or if the input is different, it returns a 400 ExecutionAlreadyExists
error. You can reuse names after 90 days.
StartExecution
isn't idempotent for EXPRESS
workflows.
See also: AWS API Documentation
start-execution
--state-machine-arn <value>
[--name <value>]
[--input <value>]
[--trace-header <value>]
[--cli-input-json <value>]
[--generate-cli-skeleton <value>]
[--debug]
[--endpoint-url <value>]
[--no-verify-ssl]
[--no-paginate]
[--output <value>]
[--query <value>]
[--profile <value>]
[--region <value>]
[--version <value>]
[--color <value>]
[--no-sign-request]
[--ca-bundle <value>]
[--cli-read-timeout <value>]
[--cli-connect-timeout <value>]
--state-machine-arn
(string)
The Amazon Resource Name (ARN) of the state machine to execute.
The
stateMachineArn
parameter accepts one of the following inputs:
- An unqualified state machine ARN – Refers to a state machine ARN that isn't qualified with a version or alias ARN. The following is an example of an unqualified state machine ARN.
arn:<partition>:states:<region>:<account-id>:stateMachine:<myStateMachine>
Step Functions doesn't associate state machine executions that you start with an unqualified ARN with a version. This is true even if that version uses the same revision that the execution used.- A state machine version ARN – Refers to a version ARN, which is a combination of state machine ARN and the version number separated by a colon (:). The following is an example of the ARN for version 10.
arn:<partition>:states:<region>:<account-id>:stateMachine:<myStateMachine>:10
Step Functions doesn't associate executions that you start with a version ARN with any aliases that point to that version.- A state machine alias ARN – Refers to an alias ARN, which is a combination of state machine ARN and the alias name separated by a colon (:). The following is an example of the ARN for an alias named
PROD
.arn:<partition>:states:<region>:<account-id>:stateMachine:<myStateMachine:PROD>
Step Functions associates executions that you start with an alias ARN with that alias and the state machine version used for that execution.
--name
(string)
Optional name of the execution. This name must be unique for your Amazon Web Services account, Region, and state machine for 90 days. For more information, see Limits Related to State Machine Executions in the Step Functions Developer Guide .
If you don't provide a name for the execution, Step Functions automatically generates a universally unique identifier (UUID) as the execution name.
A name must not contain:
- white space
- brackets
< > { } [ ]
- wildcard characters
? *
- special characters
" # % \ ^ | ~ ` $ & , ; : /
- control characters (
U+0000-001F
,U+007F-009F
)To enable logging with CloudWatch Logs, the name should only contain 0-9, A-Z, a-z, - and _.
--input
(string)
The string that contains the JSON input data for the execution, for example:
"input": "{\"first_name\" : \"test\"}"
Note
If you don't include any JSON input data, you still must include the two braces, for example:"input": "{}"
Length constraints apply to the payload size, and are expressed as bytes in UTF-8 encoding.
--trace-header
(string)
Passes the X-Ray trace header. The trace header can also be passed in the request payload.
--cli-input-json
(string)
Performs service operation based on the JSON string provided. The JSON string follows the format provided by --generate-cli-skeleton
. If other arguments are provided on the command line, the CLI values will override the JSON-provided values. It is not possible to pass arbitrary binary values using a JSON-provided value as the string will be taken literally.
--generate-cli-skeleton
(string)
Prints a JSON skeleton to standard output without sending an API request. If provided with no value or the value input
, prints a sample input JSON that can be used as an argument for --cli-input-json
. If provided with the value output
, it validates the command inputs and returns a sample output JSON for that command.
--debug
(boolean)
Turn on debug logging.
--endpoint-url
(string)
Override command's default URL with the given URL.
--no-verify-ssl
(boolean)
By default, the AWS CLI uses SSL when communicating with AWS services. For each SSL connection, the AWS CLI will verify SSL certificates. This option overrides the default behavior of verifying SSL certificates.
--no-paginate
(boolean)
Disable automatic pagination. If automatic pagination is disabled, the AWS CLI will only make one call, for the first page of results.
--output
(string)
The formatting style for command output.
--query
(string)
A JMESPath query to use in filtering the response data.
--profile
(string)
Use a specific profile from your credential file.
--region
(string)
The region to use. Overrides config/env settings.
--version
(string)
Display the version of this tool.
--color
(string)
Turn on/off color output.
--no-sign-request
(boolean)
Do not sign requests. Credentials will not be loaded if this argument is provided.
--ca-bundle
(string)
The CA certificate bundle to use when verifying SSL certificates. Overrides config/env settings.
--cli-read-timeout
(int)
The maximum socket read time in seconds. If the value is set to 0, the socket read will be blocking and not timeout. The default value is 60 seconds.
--cli-connect-timeout
(int)
The maximum socket connect time in seconds. If the value is set to 0, the socket connect will be blocking and not timeout. The default value is 60 seconds.
executionArn -> (string)
The Amazon Resource Name (ARN) that identifies the execution.
startDate -> (timestamp)
The date the execution is started.