amazonka-stepfunctions-2.0: Amazon Step Functions SDK.
Copyright(c) 2013-2023 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay
Stabilityauto-generated
Portabilitynon-portable (GHC extensions)
Safe HaskellSafe-Inferred
LanguageHaskell2010

Amazonka.StepFunctions.CreateStateMachine

Description

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. For more information, see Amazon States Language in the Step Functions User Guide.

This operation is eventually consistent. The results are best effort and may not reflect very recent updates and changes.

CreateStateMachine is an idempotent API. Subsequent requests won’t create a duplicate resource if it was already created. CreateStateMachine's idempotency check is based on the state machine name, definition, type, LoggingConfiguration and TracingConfiguration. If a following request has a different roleArn or tags, Step Functions will ignore these differences and treat it as an idempotent request of the previous. In this case, roleArn and tags will not be updated, even if they are different.

Synopsis

Creating a Request

data CreateStateMachine Source #

See: newCreateStateMachine smart constructor.

Constructors

CreateStateMachine' 

Fields

  • loggingConfiguration :: Maybe LoggingConfiguration

    Defines what execution history events are logged and where they are logged.

    By default, the level is set to OFF. For more information see Log Levels in the Step Functions User Guide.

  • tags :: Maybe [Tag]

    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 Amazon Web Services Billing and Cost Management User Guide, and Controlling Access Using IAM Tags.

    Tags may only contain Unicode letters, digits, white space, or these symbols: _ . : / = + - @.

  • tracingConfiguration :: Maybe TracingConfiguration

    Selects whether X-Ray tracing is enabled.

  • type' :: Maybe StateMachineType

    Determines whether a Standard or Express state machine is created. The default is STANDARD. You cannot update the type of a state machine once it has been created.

  • name :: Text

    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)

    To enable logging with CloudWatch Logs, the name should only contain 0-9, A-Z, a-z, - and _.

  • definition :: Sensitive Text

    The Amazon States Language definition of the state machine. See Amazon States Language.

  • roleArn :: Text

    The Amazon Resource Name (ARN) of the IAM role to use for this state machine.

Instances

Instances details
ToJSON CreateStateMachine Source # 
Instance details

Defined in Amazonka.StepFunctions.CreateStateMachine

ToHeaders CreateStateMachine Source # 
Instance details

Defined in Amazonka.StepFunctions.CreateStateMachine

ToPath CreateStateMachine Source # 
Instance details

Defined in Amazonka.StepFunctions.CreateStateMachine

ToQuery CreateStateMachine Source # 
Instance details

Defined in Amazonka.StepFunctions.CreateStateMachine

AWSRequest CreateStateMachine Source # 
Instance details

Defined in Amazonka.StepFunctions.CreateStateMachine

Associated Types

type AWSResponse CreateStateMachine #

Generic CreateStateMachine Source # 
Instance details

Defined in Amazonka.StepFunctions.CreateStateMachine

Associated Types

type Rep CreateStateMachine :: Type -> Type #

Show CreateStateMachine Source # 
Instance details

Defined in Amazonka.StepFunctions.CreateStateMachine

NFData CreateStateMachine Source # 
Instance details

Defined in Amazonka.StepFunctions.CreateStateMachine

Methods

rnf :: CreateStateMachine -> () #

Eq CreateStateMachine Source # 
Instance details

Defined in Amazonka.StepFunctions.CreateStateMachine

Hashable CreateStateMachine Source # 
Instance details

Defined in Amazonka.StepFunctions.CreateStateMachine

type AWSResponse CreateStateMachine Source # 
Instance details

Defined in Amazonka.StepFunctions.CreateStateMachine

type Rep CreateStateMachine Source # 
Instance details

Defined in Amazonka.StepFunctions.CreateStateMachine

newCreateStateMachine Source #

Create a value of CreateStateMachine with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

$sel:loggingConfiguration:CreateStateMachine', createStateMachine_loggingConfiguration - Defines what execution history events are logged and where they are logged.

By default, the level is set to OFF. For more information see Log Levels in the Step Functions User Guide.

$sel:tags:CreateStateMachine', createStateMachine_tags - 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 Amazon Web Services Billing and Cost Management User Guide, and Controlling Access Using IAM Tags.

Tags may only contain Unicode letters, digits, white space, or these symbols: _ . : / = + - @.

$sel:tracingConfiguration:CreateStateMachine', createStateMachine_tracingConfiguration - Selects whether X-Ray tracing is enabled.

CreateStateMachine, createStateMachine_type - Determines whether a Standard or Express state machine is created. The default is STANDARD. You cannot update the type of a state machine once it has been created.

CreateStateMachine, createStateMachine_name - 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)

To enable logging with CloudWatch Logs, the name should only contain 0-9, A-Z, a-z, - and _.

$sel:definition:CreateStateMachine', createStateMachine_definition - The Amazon States Language definition of the state machine. See Amazon States Language.

CreateStateMachine, createStateMachine_roleArn - The Amazon Resource Name (ARN) of the IAM role to use for this state machine.

Request Lenses

createStateMachine_loggingConfiguration :: Lens' CreateStateMachine (Maybe LoggingConfiguration) Source #

Defines what execution history events are logged and where they are logged.

By default, the level is set to OFF. For more information see Log Levels in the Step Functions User Guide.

createStateMachine_tags :: Lens' CreateStateMachine (Maybe [Tag]) Source #

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 Amazon Web Services Billing and Cost Management User Guide, and Controlling Access Using IAM Tags.

Tags may only contain Unicode letters, digits, white space, or these symbols: _ . : / = + - @.

createStateMachine_type :: Lens' CreateStateMachine (Maybe StateMachineType) Source #

Determines whether a Standard or Express state machine is created. The default is STANDARD. You cannot update the type of a state machine once it has been created.

createStateMachine_name :: Lens' CreateStateMachine Text Source #

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)

To enable logging with CloudWatch Logs, the name should only contain 0-9, A-Z, a-z, - and _.

createStateMachine_definition :: Lens' CreateStateMachine Text Source #

The Amazon States Language definition of the state machine. See Amazon States Language.

createStateMachine_roleArn :: Lens' CreateStateMachine Text Source #

The Amazon Resource Name (ARN) of the IAM role to use for this state machine.

Destructuring the Response

data CreateStateMachineResponse Source #

See: newCreateStateMachineResponse smart constructor.

Constructors

CreateStateMachineResponse' 

Fields

Instances

Instances details
Generic CreateStateMachineResponse Source # 
Instance details

Defined in Amazonka.StepFunctions.CreateStateMachine

Associated Types

type Rep CreateStateMachineResponse :: Type -> Type #

Read CreateStateMachineResponse Source # 
Instance details

Defined in Amazonka.StepFunctions.CreateStateMachine

Show CreateStateMachineResponse Source # 
Instance details

Defined in Amazonka.StepFunctions.CreateStateMachine

NFData CreateStateMachineResponse Source # 
Instance details

Defined in Amazonka.StepFunctions.CreateStateMachine

Eq CreateStateMachineResponse Source # 
Instance details

Defined in Amazonka.StepFunctions.CreateStateMachine

type Rep CreateStateMachineResponse Source # 
Instance details

Defined in Amazonka.StepFunctions.CreateStateMachine

type Rep CreateStateMachineResponse = D1 ('MetaData "CreateStateMachineResponse" "Amazonka.StepFunctions.CreateStateMachine" "amazonka-stepfunctions-2.0-K6z2kqboJVbL1MZX8DUt0f" 'False) (C1 ('MetaCons "CreateStateMachineResponse'" 'PrefixI 'True) (S1 ('MetaSel ('Just "httpStatus") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Int) :*: (S1 ('MetaSel ('Just "stateMachineArn") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Text) :*: S1 ('MetaSel ('Just "creationDate") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 POSIX))))

newCreateStateMachineResponse Source #

Create a value of CreateStateMachineResponse with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

$sel:httpStatus:CreateStateMachineResponse', createStateMachineResponse_httpStatus - The response's http status code.

CreateStateMachineResponse, createStateMachineResponse_stateMachineArn - The Amazon Resource Name (ARN) that identifies the created state machine.

CreateStateMachineResponse, createStateMachineResponse_creationDate - The date the state machine is created.

Response Lenses

createStateMachineResponse_stateMachineArn :: Lens' CreateStateMachineResponse Text Source #

The Amazon Resource Name (ARN) that identifies the created state machine.