Skip to content

Cloudflare Pages Webhook

Route & Auth

Property Value
Method POST
Path /webhooks/cloudflare/pages
Auth type secret
Header cf-webhook-auth
Secret CLOUDFLARE_PAGES_WEBHOOK_SECRET
Service account cloudflare-webhook@alan-eu-tools.iam.gserviceaccount.com
Response 200 OK
Idempotency @webhook_request_handler with checksum dedup

Payload

Field Type Description
text string Notification message text
account_id string Cloudflare account identifier
alert_type string Alert type (e.g. pages_event_alert)
data.project_name string Cloudflare Pages project name
data.deployment_id string Deployment identifier

Behavior

  1. Ignores test messages
  2. Validates account_id matches ALAN_ACCOUNT_ID
  3. For pages_event_alert events: syncs the Cloudflare deployment status
  4. For successful production-like deployments: posts GitHub PR comments with deployment info

Integrations

  • Cloudflare API: deployment status retrieval
  • GitHub API: PR comment posting

Code reference

{{ package_reference("apps.eu_tools.cloudflare_pages.webhook") }}

OpenAPI

Cloudflare Pages webhook on ReDoc ⧉