Skip to content
Proud to collaborate with Microsoft for Startups

cloudflare.workers.deploy_script ​

Deploy a Cloudflare Worker to production

Deploys a Cloudflare Worker script to production.

The worker must already exist (created via cloudflare.workers.create_script). This operation makes the latest script code live.

Inputs:

  • script_name: Name of the worker script (required).
  • environment: Target environment (optional, default: production).
  • connection_uuid: Cloud connection UUID for Cloudflare credentials (required).

Outputs (terminal state_data):

  • script_name: str — confirmed script name
  • deployment_id: str — deployment ID
  • worker_url: str — URL to access the deployed worker

Compensation: Not directly reversible — deploy a previous version. Plugin required: context.get_plugin("cloudflare")

Overview ​

PropertyValue
Workflow typeAtomic
LibraryApp-cloudflare
Version1.0

Input Schema ​

FieldTypeRequiredDefaultDescription
script_namestringYes—Name of the worker script
environmentstringNo—Target environment (default: production)
connection_uuiduuidYes—Cloud connection UUID for Cloudflare credentials

Output Schema ​

FieldTypeRequiredDefaultDescription
deployment_idstringNo——
script_namestringNo——
worker_urlstringNo——
connection_uuiduuidNo——
environmentstringNo——
failure_reasonstringNo——
failure_typestringNo——
failed_actionstringNo——
failed_at_statestringNo——
failed_stepstringNo——
failed_layerstringNo——
errorstringNo——
error_typestringNo——

States ​

StateInitialTerminalSuccessAuto-advanceDescription
pendingYesNo—executeDeploy-script request accepted
completedNoYesYes—Worker deployed
failedNoYesNo—Worker deploy failed

State Diagram ​

Transitions ​

FromActionToDescription
pendingexecutecompletedDeploy worker script
* (any state)failfailedMark workflow failed

API Usage ​

bash
POST /api/workflows/start
Content-Type: application/json

{
  "workflow_type": "cloudflare.workers.deploy_script",
  "initial_data": {
    "script_name": "value",
    "connection_uuid": "value"
  }
}