Skip to content

Required permissions for /accounts/<account_id>/email/routing/rules/plan (blocks email addresses deploy) #36

Description

@ankagar

Question

What minimum API-token permissions authorize /accounts/<account_id>/email/routing/rules/plan?

I'm hitting Authentication error [code: 10000] on this call during wrangler deploy, with a build token that already grants all permissions the token UI exposes for Email Routing. Trying to figure out what's missing.

Context

wrangler.jsonc uses the top-level addresses field (Email Routing → "Send to a Worker"):

{
  "name": "<worker>",                                   
  "addresses": ["app1@example.com", "app2@example.com"] 
}                                                       

From the cloudflare/workers-sdk#14471 implementation, the addresses deploy step reads a plan and then applies via per-zone rule endpoints. The plan read is what fails for me:

✘ [ERROR] A request to the Cloudflare API
  (/accounts/<account_id>/email/routing/rules/plan) failed.
  Authentication error [code: 10000]

What works vs what doesn't

  • wrangler deploy locally (with super-admin account)
  • wrangler deploy from Workers Builds CI

Permissions of the API Token used in build

<account> (account scope) —
  Email Routing Addresses: Edit, Email Sending: Edit, ... 
All zones (zone scope) —
  Email Routing Rules: Edit, ... 

Environment

  • wrangler 4.115.0, Workers Builds CI (non-interactive), bun@1.3.11 / nodejs@24.18.0.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    product:emailRelating to Cloudflare Email Service: https://developers.cloudflare.com/email-service/

    Type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions