AWS Step Functions

Serverless orchestration that runs multi-step workflows as visual state machines with built-in retries and error handling.

Verified against AWS documentation · 2026-08-24

Key facts

  1. 01Workflows are JSON state machines (Amazon States Language): Task, Choice, Parallel, Map, Wait, Pass, Succeed, Fail
  2. 02Standard: up to 1 year, exactly-once, billed per state transition, full visual execution history
  3. 03Express: up to 5 minutes, at-least-once, billed per request + duration, no .sync or callback patterns
  4. 04Retry, Catch, and Timeout are declarative — orchestration logic leaves your Lambda code
  5. 05Limits: 256 KB payload between states, 25,000 history events per Standard execution

Exam triggers

Phrases and scenarios that point here.

  • "Orchestrate", "coordinate", "multi-step process", "visual workflow", "state machine"
  • Lambda chained to Lambda with hand-rolled retry and error logic → replace with Step Functions
  • Process must run longer than Lambda's 15-minute ceiling → Standard workflow holds the state
  • A human approval or manual review sits in the middle of the flow → Standard + task token callback
  • High-volume, short-lived event processing where audit trail doesn't matter → Express, not Standard

Not this service

  • Producer and consumer just need decoupling, no steps to sequence → SQS
  • Rule-based event routing to targets with no workflow state to track → EventBridge
  • Existing Apache Airflow DAGs you don't want to rewrite → MWAA

Use cases

  1. 01Order sagas with compensating actions — charge card, reserve stock, book courier; if the courier call fails, Catch routes to a refund branch instead of leaving the customer charged with nothing shipped
  2. 02Refunds above a threshold pause on a task token until a manager clicks an approve link; the execution sits idle for days and costs nothing while waiting
  3. 03Wrapping jobs that outlive Lambda — .sync starts a Glue, Batch, or EMR job and the workflow blocks until it finishes, with no polling loop to build or maintain
  4. 04Distributed Map over an S3 inventory to re-tag or re-encrypt millions of objects, each batch running as its own child execution with its own 25,000-event budget
  5. 05Security response driven by EventBridge — a GuardDuty finding triggers isolate-instance, snapshot-volume, page-on-call as separately auditable steps rather than one opaque Lambda

How it's charged

  1. 01Standard bills per state transition — every retry, Choice evaluation, and Map iteration is another billable transition
  2. 02Express bills per request plus duration, rounded up to 100 ms and metered in 64 MB memory chunks; far cheaper per invocation at high volume
  3. 034,000 free Standard state transitions per month, permanent and not tied to the 12-month free tier
  4. 04Polling loops are the classic cost bug — a Wait-and-check loop bills every pass, while .sync or a callback bills two transitions total
  5. 05You pay only for orchestration; the Lambda, Glue, ECS, and data transfer costs of the actual work are billed by those services

Commonly confused with

References