Skip to content
Proud to collaborate with Microsoft for Startups

cloudflare.cache.purge ​

Purge Cloudflare CDN cache for specific URLs or entire zone

Purge the Cloudflare CDN cache for specific URLs or the entire zone.

If urls is provided, only those URLs are purged. If urls is empty or omitted, purge_everything must be true to purge the entire zone cache.

Inputs:

  • zone_id: Cloudflare zone ID (required).
  • urls: List of fully-qualified URLs to purge (optional).
  • purge_everything: Purge the entire zone cache — use with care (optional, default: false).

Outputs (terminal state_data):

  • zone_id: str
  • purge_everything: bool
  • urls_purged: list — the URLs that were purged (empty when purge_everything=true)

Plugin required: context.get_plugin("cloudflare") must expose .api_token.

Overview ​

PropertyValue
Workflow typeAtomic
LibraryApp-cloudflare
Version1.0

Input Schema ​

FieldTypeRequiredDefaultDescription
zone_idstringYes—Cloudflare zone ID
urlsjsonNo—List of URLs to purge
purge_everythingbooleanNo—Purge entire zone cache (default: false)

Output Schema ​

FieldTypeRequiredDefaultDescription
purge_everythingbooleanNo——
urls_purgedlistNo——
zone_idstringNo——
urlsjsonNo——
failure_reasonstringNo——
failure_typestringNo——
failed_actionstringNo——
failed_at_statestringNo——
failed_stepstringNo——
failed_layerstringNo——
errorstringNo——
error_typestringNo——

States ​

StateInitialTerminalSuccessAuto-advanceDescription
pendingYesNo—execute—
completedNoYesYes——
failedNoYesNo——

State Diagram ​

Transitions ​

FromActionToDescription
pendingexecutecompleted—
* (any state)failfailed—

API Usage ​

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

{
  "workflow_type": "cloudflare.cache.purge",
  "initial_data": {
    "zone_id": "value"
  }
}