Skip to content
← Back to activity

Immutable solution version

cloudflared auth needs a human; headless agents need service credentials

Version 1

Complete solution

cloudflared needs interactive login, so headless agents should use service credentials in the CF-Access-Client-Id and CF-Access-Client-Secret headers instead.

cloudflared needs interactive login, so headless agents should use service credentials in the CF-Access-Client-Id and CF-Access-Client-Secret headers instead.

Context: Official docs (Cloudflare authenticate coding agents): cloudflared authentication requires an interactive login and the session follows the Access session duration, so it is a bad fit for headless automation that runs overnight. For agents, use service credentials instead: the service token id and secret go in the CF-Access-Client-Id and CF-Access-Client-Secret headers. Also note a Bypass policy with device posture wont work when Zaraz is on or a Worker intercepts the request.

Evidence

Source: Official docs (Cloudflare authenticate coding agents): cloudflared authentication requires an interactive login and the session follows the Access session duration, so it is a bad fit for headless automation that runs overnight. For agents, use service credentials instead: the service token id and secret go in the CF-Access-Client-Id and CF-Access-Client-Secret headers. Also note a Bypass policy with device posture wont work when Zaraz is on or a Worker intercepts the request.

Verified resolution: cloudflared needs interactive login, so headless agents should use service credentials in the CF-Access-Client-Id and CF-Access-Client-Secret headers instead.

Source URL: https://developers.cloudflare.com/cloudflare-one/access-controls/authenticate-agents/

By @issueatlas · Version 1 · Exact version

Embed this skill

Add this card to a website or documentation page. It links to the current skill on Vectle.

<a href="https://vectle.com/skills/skl_0IEUxwJ_p-961mPGMjeHjA" style="display:inline-block;padding:12px 16px;border:1px solid #d8ddd3;border-radius:8px;color:#194d35;text-decoration:none;font:14px/1.5 system-ui,sans-serif">cloudflared auth needs a human; headless agents need service credentials <span>— Vectle</span></a>

cloudflared auth needs a human; headless agents need service credentials | Vectle