Skip to content

Workflows

Last updated View as MarkdownAgent setup

Manage and configure Workflows using Wrangler.

workflows list

List Workflows associated to account

npx wrangler workflows list
  • --localboolean

    Interact with local dev session

  • --portnumber default: 8787

    Port of the local dev session (default: 8787)

  • --pagenumber default: 1

    Show a sepecific page from the listing, can configure page size using "per-page"

  • --per-pagenumber

    Configure the maximum number of workflows to show per page

Global flags

  • --vboolean alias: --version

    Show version number

  • --cwdstring

    Run as if Wrangler was started in the specified directory instead of the current working directory

  • --configstring alias: --c

    Path to Wrangler configuration file

  • --envstring alias: --e

    Environment to use for operations, and for selecting .env and .dev.vars files

  • --env-filestring

    Path to an .env file to load - can be specified multiple times - values from earlier files are overridden by values in later files

  • --experimental-provisionboolean aliases: --x-provisiondefault: true

    Experimental: Enable automatic resource provisioning

  • --experimental-auto-createboolean alias: --x-auto-createdefault: true

    Automatically provision draft bindings with new resources

  • --install-skillsboolean default: false

    Install Cloudflare skills for detected AI coding agents before running the command

  • --profilestring

    Use a specific auth profile

workflows describe

Describe Workflow resource

npx wrangler workflows describe [NAME]
  • --localboolean

    Interact with local dev session

  • --portnumber default: 8787

    Port of the local dev session (default: 8787)

  • [NAME]string required

    Name of the workflow

Global flags

  • --vboolean alias: --version

    Show version number

  • --cwdstring

    Run as if Wrangler was started in the specified directory instead of the current working directory

  • --configstring alias: --c

    Path to Wrangler configuration file

  • --envstring alias: --e

    Environment to use for operations, and for selecting .env and .dev.vars files

  • --env-filestring

    Path to an .env file to load - can be specified multiple times - values from earlier files are overridden by values in later files

  • --experimental-provisionboolean aliases: --x-provisiondefault: true

    Experimental: Enable automatic resource provisioning

  • --experimental-auto-createboolean alias: --x-auto-createdefault: true

    Automatically provision draft bindings with new resources

  • --install-skillsboolean default: false

    Install Cloudflare skills for detected AI coding agents before running the command

  • --profilestring

    Use a specific auth profile

workflows delete

Delete workflow - when deleting a workflow, it will also delete it's own instances

npx wrangler workflows delete [NAME]
  • --localboolean

    Interact with local dev session

  • --portnumber default: 8787

    Port of the local dev session (default: 8787)

  • [NAME]string required

    Name of the workflow

Global flags

  • --vboolean alias: --version

    Show version number

  • --cwdstring

    Run as if Wrangler was started in the specified directory instead of the current working directory

  • --configstring alias: --c

    Path to Wrangler configuration file

  • --envstring alias: --e

    Environment to use for operations, and for selecting .env and .dev.vars files

  • --env-filestring

    Path to an .env file to load - can be specified multiple times - values from earlier files are overridden by values in later files

  • --experimental-provisionboolean aliases: --x-provisiondefault: true

    Experimental: Enable automatic resource provisioning

  • --experimental-auto-createboolean alias: --x-auto-createdefault: true

    Automatically provision draft bindings with new resources

  • --install-skillsboolean default: false

    Install Cloudflare skills for detected AI coding agents before running the command

  • --profilestring

    Use a specific auth profile

workflows trigger

Trigger a workflow, creating a new instance. Can optionally take a JSON string to pass a parameter into the workflow instance

npx wrangler workflows trigger [NAME] [PARAMS]
  • --localboolean

    Interact with local dev session

  • --portnumber default: 8787

    Port of the local dev session (default: 8787)

  • [NAME]string required

    Name of the workflow

  • [PARAMS]string default:

    Params for the workflow instance, encoded as a JSON string

  • --idstring

    Custom instance ID, if not provided it will default to a random UUIDv4

Global flags

  • --vboolean alias: --version

    Show version number

  • --cwdstring

    Run as if Wrangler was started in the specified directory instead of the current working directory

  • --configstring alias: --c

    Path to Wrangler configuration file

  • --envstring alias: --e

    Environment to use for operations, and for selecting .env and .dev.vars files

  • --env-filestring

    Path to an .env file to load - can be specified multiple times - values from earlier files are overridden by values in later files

  • --experimental-provisionboolean aliases: --x-provisiondefault: true

    Experimental: Enable automatic resource provisioning

  • --experimental-auto-createboolean alias: --x-auto-createdefault: true

    Automatically provision draft bindings with new resources

  • --install-skillsboolean default: false

    Install Cloudflare skills for detected AI coding agents before running the command

  • --profilestring

    Use a specific auth profile

workflows instances list

Instance related commands (list, describe, terminate, pause, resume)

npx wrangler workflows instances list [NAME]
  • --localboolean

    Interact with local dev session

  • --portnumber default: 8787

    Port of the local dev session (default: 8787)

  • [NAME]string required

    Name of the workflow

  • --reverseboolean default: false

    Reverse order of the instances table

  • --statusstring

    Filters list by instance status (can be one of: queued, running, paused, errored, terminated, complete)

  • --pagenumber default: 1

    Show a sepecific page from the listing, can configure page size using "per-page"

  • --per-pagenumber

    Configure the maximum number of instances to show per page

Global flags

  • --vboolean alias: --version

    Show version number

  • --cwdstring

    Run as if Wrangler was started in the specified directory instead of the current working directory

  • --configstring alias: --c

    Path to Wrangler configuration file

  • --envstring alias: --e

    Environment to use for operations, and for selecting .env and .dev.vars files

  • --env-filestring

    Path to an .env file to load - can be specified multiple times - values from earlier files are overridden by values in later files

  • --experimental-provisionboolean aliases: --x-provisiondefault: true

    Experimental: Enable automatic resource provisioning

  • --experimental-auto-createboolean alias: --x-auto-createdefault: true

    Automatically provision draft bindings with new resources

  • --install-skillsboolean default: false

    Install Cloudflare skills for detected AI coding agents before running the command

  • --profilestring

    Use a specific auth profile

workflows instances describe

Describe a workflow instance - see its logs, retries and errors

npx wrangler workflows instances describe [NAME] [ID]
  • --localboolean

    Interact with local dev session

  • --portnumber default: 8787

    Port of the local dev session (default: 8787)

  • [NAME]string required

    Name of the workflow

  • [ID]string default: latest

    ID of the instance - instead of an UUID you can type 'latest' to get the latest instance and describe it

  • --step-outputboolean default: true

    Don't output the step output since it might clutter the terminal

  • --truncate-output-limitnumber default: 5000

    Truncate step output after x characters

Global flags

  • --vboolean alias: --version

    Show version number

  • --cwdstring

    Run as if Wrangler was started in the specified directory instead of the current working directory

  • --configstring alias: --c

    Path to Wrangler configuration file

  • --envstring alias: --e

    Environment to use for operations, and for selecting .env and .dev.vars files

  • --env-filestring

    Path to an .env file to load - can be specified multiple times - values from earlier files are overridden by values in later files

  • --experimental-provisionboolean aliases: --x-provisiondefault: true

    Experimental: Enable automatic resource provisioning

  • --experimental-auto-createboolean alias: --x-auto-createdefault: true

    Automatically provision draft bindings with new resources

  • --install-skillsboolean default: false

    Install Cloudflare skills for detected AI coding agents before running the command

  • --profilestring

    Use a specific auth profile

workflows instances send-event

Send an event to a workflow instance

npx wrangler workflows instances send-event [NAME] [ID]
  • --localboolean

    Interact with local dev session

  • --portnumber default: 8787

    Port of the local dev session (default: 8787)

  • [NAME]string required

    Name of the workflow

  • [ID]string required

    ID of the instance - instead of an UUID you can type 'latest' to get the latest instance and send an event to it

  • --typestring required

    Type of the workflow event

  • --payloadstring default: {}

    JSON string for the workflow event (e.g., '{"key": "value"}')

Global flags

  • --vboolean alias: --version

    Show version number

  • --cwdstring

    Run as if Wrangler was started in the specified directory instead of the current working directory

  • --configstring alias: --c

    Path to Wrangler configuration file

  • --envstring alias: --e

    Environment to use for operations, and for selecting .env and .dev.vars files

  • --env-filestring

    Path to an .env file to load - can be specified multiple times - values from earlier files are overridden by values in later files

  • --experimental-provisionboolean aliases: --x-provisiondefault: true

    Experimental: Enable automatic resource provisioning

  • --experimental-auto-createboolean alias: --x-auto-createdefault: true

    Automatically provision draft bindings with new resources

  • --install-skillsboolean default: false

    Install Cloudflare skills for detected AI coding agents before running the command

  • --profilestring

    Use a specific auth profile

workflows instances terminate

Terminate a workflow instance

npx wrangler workflows instances terminate [NAME] [ID]
  • --localboolean

    Interact with local dev session

  • --portnumber default: 8787

    Port of the local dev session (default: 8787)

  • [NAME]string required

    Name of the workflow

  • [ID]string required

    ID of the instance - instead of an UUID you can type 'latest' to get the latest instance and describe it

  • --rollbackboolean default: false

    Run registered rollback handlers before terminating

Global flags

  • --vboolean alias: --version

    Show version number

  • --cwdstring

    Run as if Wrangler was started in the specified directory instead of the current working directory

  • --configstring alias: --c

    Path to Wrangler configuration file

  • --envstring alias: --e

    Environment to use for operations, and for selecting .env and .dev.vars files

  • --env-filestring

    Path to an .env file to load - can be specified multiple times - values from earlier files are overridden by values in later files

  • --experimental-provisionboolean aliases: --x-provisiondefault: true

    Experimental: Enable automatic resource provisioning

  • --experimental-auto-createboolean alias: --x-auto-createdefault: true

    Automatically provision draft bindings with new resources

  • --install-skillsboolean default: false

    Install Cloudflare skills for detected AI coding agents before running the command

  • --profilestring

    Use a specific auth profile

workflows instances restart

Restart a workflow instance

npx wrangler workflows instances restart [NAME] [ID]
  • --localboolean

    Interact with local dev session

  • --portnumber default: 8787

    Port of the local dev session (default: 8787)

  • [NAME]string required

    Name of the workflow

  • [ID]string required

    ID of the instance - instead of an UUID you can type 'latest' to get the latest instance and describe it

  • --from-step-namestring

    Name of the step to restart from

  • --from-step-countnumber

    1-based occurrence of the step name/type to restart from (defaults to 1)

  • --from-step-typestring

    Step type to restart from, used when the same name is shared across step types (defaults to do)

Global flags

  • --vboolean alias: --version

    Show version number

  • --cwdstring

    Run as if Wrangler was started in the specified directory instead of the current working directory

  • --configstring alias: --c

    Path to Wrangler configuration file

  • --envstring alias: --e

    Environment to use for operations, and for selecting .env and .dev.vars files

  • --env-filestring

    Path to an .env file to load - can be specified multiple times - values from earlier files are overridden by values in later files

  • --experimental-provisionboolean aliases: --x-provisiondefault: true

    Experimental: Enable automatic resource provisioning

  • --experimental-auto-createboolean alias: --x-auto-createdefault: true

    Automatically provision draft bindings with new resources

  • --install-skillsboolean default: false

    Install Cloudflare skills for detected AI coding agents before running the command

  • --profilestring

    Use a specific auth profile

workflows instances pause

Pause a workflow instance

npx wrangler workflows instances pause [NAME] [ID]
  • --localboolean

    Interact with local dev session

  • --portnumber default: 8787

    Port of the local dev session (default: 8787)

  • [NAME]string required

    Name of the workflow

  • [ID]string required

    ID of the instance - instead of an UUID you can type 'latest' to get the latest instance and pause it

Global flags

  • --vboolean alias: --version

    Show version number

  • --cwdstring

    Run as if Wrangler was started in the specified directory instead of the current working directory

  • --configstring alias: --c

    Path to Wrangler configuration file

  • --envstring alias: --e

    Environment to use for operations, and for selecting .env and .dev.vars files

  • --env-filestring

    Path to an .env file to load - can be specified multiple times - values from earlier files are overridden by values in later files

  • --experimental-provisionboolean aliases: --x-provisiondefault: true

    Experimental: Enable automatic resource provisioning

  • --experimental-auto-createboolean alias: --x-auto-createdefault: true

    Automatically provision draft bindings with new resources

  • --install-skillsboolean default: false

    Install Cloudflare skills for detected AI coding agents before running the command

  • --profilestring

    Use a specific auth profile

workflows instances resume

Resume a workflow instance

npx wrangler workflows instances resume [NAME] [ID]
  • --localboolean

    Interact with local dev session

  • --portnumber default: 8787

    Port of the local dev session (default: 8787)

  • [NAME]string required

    Name of the workflow

  • [ID]string required

    ID of the instance - instead of an UUID you can type 'latest' to get the latest instance and resume it

Global flags

  • --vboolean alias: --version

    Show version number

  • --cwdstring

    Run as if Wrangler was started in the specified directory instead of the current working directory

  • --configstring alias: --c

    Path to Wrangler configuration file

  • --envstring alias: --e

    Environment to use for operations, and for selecting .env and .dev.vars files

  • --env-filestring

    Path to an .env file to load - can be specified multiple times - values from earlier files are overridden by values in later files

  • --experimental-provisionboolean aliases: --x-provisiondefault: true

    Experimental: Enable automatic resource provisioning

  • --experimental-auto-createboolean alias: --x-auto-createdefault: true

    Automatically provision draft bindings with new resources

  • --install-skillsboolean default: false

    Install Cloudflare skills for detected AI coding agents before running the command

  • --profilestring

    Use a specific auth profile

Was this helpful?