SingleStateOptions

class aws_cdk.aws_stepfunctions.SingleStateOptions(*, comment=None, input_path=None, output_path=None, result_path=None, result_selector=None, prefix_states=None, state_id=None)

Bases: ParallelProps

Options for creating a single state.

Parameters:
  • comment (Optional[str]) – An optional description for this state. Default: No comment

  • input_path (Optional[str]) – JSONPath expression to select part of the state to be the input to this state. May also be the special value JsonPath.DISCARD, which will cause the effective input to be the empty object {}. Default: $

  • output_path (Optional[str]) – JSONPath expression to select part of the state to be the output to this state. May also be the special value JsonPath.DISCARD, which will cause the effective output to be the empty object {}. Default: $

  • result_path (Optional[str]) – JSONPath expression to indicate where to inject the state’s output. May also be the special value JsonPath.DISCARD, which will cause the state’s input to become its output. Default: $

  • result_selector (Optional[Mapping[str, Any]]) – The JSON that will replace the state’s raw result and become the effective result before ResultPath is applied. You can use ResultSelector to create a payload with values that are static or selected from the state’s raw result. Default: - None

  • prefix_states (Optional[str]) – String to prefix all stateIds in the state machine with. Default: stateId

  • state_id (Optional[str]) – ID of newly created containing state. Default: Construct ID of the StateMachineFragment

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
import aws_cdk.aws_stepfunctions as stepfunctions

# result_selector: Any

single_state_options = stepfunctions.SingleStateOptions(
    comment="comment",
    input_path="inputPath",
    output_path="outputPath",
    prefix_states="prefixStates",
    result_path="resultPath",
    result_selector={
        "result_selector_key": result_selector
    },
    state_id="stateId"
)

Attributes

comment

An optional description for this state.

Default:

No comment

input_path

JSONPath expression to select part of the state to be the input to this state.

May also be the special value JsonPath.DISCARD, which will cause the effective input to be the empty object {}.

Default:

$

output_path

JSONPath expression to select part of the state to be the output to this state.

May also be the special value JsonPath.DISCARD, which will cause the effective output to be the empty object {}.

Default:

$

prefix_states

String to prefix all stateIds in the state machine with.

Default:

stateId

result_path

JSONPath expression to indicate where to inject the state’s output.

May also be the special value JsonPath.DISCARD, which will cause the state’s input to become its output.

Default:

$

result_selector

The JSON that will replace the state’s raw result and become the effective result before ResultPath is applied.

You can use ResultSelector to create a payload with values that are static or selected from the state’s raw result.

Default:
  • None

See:

https://docs.aws.amazon.com/step-functions/latest/dg/input-output-inputpath-params.html#input-output-resultselector

state_id

ID of newly created containing state.

Default:

Construct ID of the StateMachineFragment