HSX_E_ROLLBACK_CLOUDFLARE_CREDENTIALS

Rollback needs a Cloudflare API token.

What this error means

Rollback restores live Cloudflare traffic to a prior Worker version, which requires a Cloudflare API token. None was available, so nothing was changed (metadata-only rollback that does not touch traffic is retired).

When this error stops a command, hs-x exits with code 1. With --json, the failure is reported as a structured error whose code field is HSX_E_ROLLBACK_CLOUDFLARE_CREDENTIALS — stable to match on in scripts and agents.

Likely causes

  • Neither HSX_CLOUDFLARE_API_TOKEN nor CLOUDFLARE_API_TOKEN is set in the environment

How to fix it

  • Set HSX_CLOUDFLARE_API_TOKEN (or CLOUDFLARE_API_TOKEN) to a token that can manage the Worker, then re-run

Still stuck? Re-run the command with --debug for the wire-level detail, or hs-x doctor to check accounts, link state, and connectivity in one pass.