Skip to content

[Workers, R2] Add permissions access docs#31672

Draft
dinasaur404 wants to merge 3 commits into
productionfrom
workers-permissions-access
Draft

[Workers, R2] Add permissions access docs#31672
dinasaur404 wants to merge 3 commits into
productionfrom
workers-permissions-access

Conversation

@dinasaur404

Copy link
Copy Markdown
Contributor

Summary

Adds Developer Platform permissions documentation for the overview model, Workers role scopes, and R2 access options.

This is the first subset of authorization docs; additional product pages will be added in follow-up commits.

Screenshots (optional)

Documentation checklist

  • The change adheres to the documentation style guide.
  • If a larger change - such as adding a new page- an issue has been opened in relation to any incorrect or out of date information that this PR fixes.

@github-actions

Copy link
Copy Markdown
Contributor

This pull request requires reviews from CODEOWNERS as it changes files that match the following patterns:

Pattern Owners
/src/content/docs/workers/ @cloudflare/workers-docs, @GregBrimble, @irvinebroque, @mikenomitch, @korinne, @WalshyDev, @cloudflare/deploy-config, @cloudflare/product-owners, @cloudflare/wrangler, @MattieTK, @cloudflare/dev-plat-leads, @vy-ton

@ask-bonk ask-bonk Bot added documentation Documentation edits content:new Request for new/missing content labels Jun 24, 2026

@ask-bonk ask-bonk Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review summary

This PR adds three new pages under /workers/authorization/ that document Developer Platform permissions, Workers role scopes, and R2 access options. This is a solid first subset for authorization docs.

What changes:

  • Overview (index.mdx): Explains the three-level scope model (platform, product, resource) and the four role tiers.
  • Workers (workers.mdx): Details Workers-specific roles, scopes, Wrangler permission requirements, legacy permission mappings, Pages API token roles, bindings, and limitations.
  • R2 (r2.mdx): Covers R2 member roles, R2 API tokens, and account API token permission groups for storage, data catalog, and SQL.

Issues flagged:

  1. Broken link to a non-existent Durable Objects permissions page.
  2. Trailing slashes after URL anchors in three places on the Workers page.
  3. Descriptions on the R2 and Workers pages are shorter than the style guide recommends (50–160 characters).
  4. R2 page title could be more descriptive for consistency.

Please address the broken link and description lengths before merging. The trailing-slash and title items are quick fixes.

@@ -0,0 +1,128 @@
---
title: Workers permissions and access
description: Manage roles and scopes for Workers.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The description is 37 characters. The style guide recommends 50–160 characters for SEO and clarity. Consider expanding this to explain what actions the page covers (e.g., viewing, deploying, and managing Workers roles and scopes).

| ------------------------------------- | ------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------- |
| Tail logs for a Worker | `wrangler tail` | `Metadata Read-Only` for that Worker |
| Deploy an existing Worker | `wrangler deploy` | `Editor` for that Worker |
| Deploy an existing Worker with routes | `wrangler deploy` | `Editor` for that Worker, plus [zone-level permissions](/fundamentals/manage-members/scope/#specific-domains/) for each zone referenced by routes |

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove the trailing slash after the anchor fragment. The correct format is /fundamentals/manage-members/scope/#specific-domains (trailing slash on the path, not after the fragment).

| Workers Observability Edit | `Editor` |
| Workers Observability Telemetry Edit | `Editor` |
| Workers Routes Read | `Metadata Read-Only` |
| Workers Routes Edit | `Editor`, plus [zone-level permission](/fundamentals/manage-members/scope/#specific-domains/) for each zone referenced by routes |

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove the trailing slash after the anchor fragment: /fundamentals/manage-members/scope/#specific-domains.

- Product-level Workers roles do not grant access to other Developer Platform products such as [R2](/r2/), [D1](/d1/), [KV](/kv/), [Queues](/queues/), [Vectorize](/vectorize/), or [Hyperdrive](/hyperdrive/).
- API tokens do not support platform-level Developer Platform permissions.
- Creating a new Worker requires Workers Admin because per-Worker permissions can only apply to Workers that already exist.
- Deploying a Worker with routes also requires [zone-level permissions](/fundamentals/manage-members/scope/#specific-domains/) for each zone referenced by those routes.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove the trailing slash after the anchor fragment: /fundamentals/manage-members/scope/#specific-domains.

## Related resources

- [Permissions and access overview](/workers/authorization/)
- [Durable Objects permissions and access](/workers/authorization/durable-objects/)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This links to /workers/authorization/durable-objects/, which does not exist yet. Since this PR is described as the "first subset" and follow-ups will add additional pages, this link will be broken. Consider removing this bullet or replacing it with plain text (e.g., "Durable Objects permissions and access — coming soon") until the page is added.

@@ -0,0 +1,74 @@
---
title: R2

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider a more descriptive title for consistency with the Workers page, such as R2 permissions and access.

@@ -0,0 +1,74 @@
---
title: R2
description: Review R2 access options.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The description is only 26 characters. The style guide recommends 50–160 characters. Consider expanding to describe what access models and token types the page covers.

@ask-bonk

ask-bonk Bot commented Jun 24, 2026

Copy link
Copy Markdown
Contributor

I've completed the review of PR #31672.

Labels applied

  • documentation
  • content:new

What the PR changes

This PR introduces three new pages under /workers/authorization/ as the first subset of Developer Platform authorization docs:

  • index.mdx — Overview of the three-level scope model (platform, product, resource) and four role tiers (Metadata Read-Only, Content Read-Only, Editor, Admin).
  • workers.mdx — Workers-specific roles, scopes, Wrangler command permissions, legacy permission mappings, Pages API token roles, bindings behavior, and limitations.
  • r2.mdx — R2 member/User Group roles, R2 API tokens, and account API token permission groups (Storage, Data Catalog, SQL).

Issues flagged

  • Broken linkworkers.mdx links to /workers/authorization/durable-objects/, which does not exist yet.
  • Trailing slashes after anchors — Three links in workers.mdx use /#specific-domains/ instead of /#specific-domains.
  • Short descriptionsr2.mdx (26 chars) and workers.mdx (37 chars) are below the recommended 50–160 character range.
  • Title consistencyr2.mdx title is just "R2"; should probably be "R2 permissions and access" to match the Workers page.

Review posted

A review with inline comments has been posted to PR #31672:

  • Overall review: View review
  • Inline comments: 7 specific line-level suggestions covering the issues above.

github run

@dinasaur404

Copy link
Copy Markdown
Contributor Author

/bonk can you make updates to address feedback?

Co-authored-by: dinasaur404 <dinasaur404@users.noreply.github.com>
@ask-bonk

ask-bonk Bot commented Jun 24, 2026

Copy link
Copy Markdown
Contributor

Done! I've addressed all the feedback from the review on PR #31672. Here's what was changed:

workers.mdx

  • Expanded description from 37 characters to ~96 characters.
  • Fixed three trailing slashes after anchor fragments on lines referencing #specific-domains.
  • Fixed two broken Durable Objects links:
    • In Limitations: removed the link to the non-existent page and kept it as plain text.
    • In Related resources: replaced the link with "Durable Objects permissions and access — coming soon".

r2.mdx

  • Updated title from "R2" to "R2 permissions and access" for consistency.
  • Expanded description from 26 characters to ~103 characters.

github run


## Legacy Workers permissions

These legacy permissions are being replaced by the new Workers roles. There is no deprecation date right now. Existing permissions continue to work, and customers will receive advance notice before any deprecation.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
These legacy permissions are being replaced by the new Workers roles. There is no deprecation date right now. Existing permissions continue to work, and customers will receive advance notice before any deprecation.
When granting access, you should use the new Workers roles above, and you should not use the legacy permissions below. While these legacy permissions continue to work, and they will be deprecated in the future. There is currently not a deprecation date, and customers will receive advance notice before any deprecation.

to be explicit re: "you should use"

@@ -0,0 +1,74 @@
---
title: R2 permissions and access

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should this be part of R2 docs instead? And if we need it to be discoverable, link to there?


## Workers roles

Workers roles can be assigned to members, User Groups, and API tokens.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

active voice

| Editor | Edit | Can read, update, and deploy existing Workers, including script content, settings, routes, schedules, versions, deployments, and observability. Cannot create, delete, or rename Workers. |
| Admin | Full manage | Full control over Workers, including creating, reading, updating, deploying, deleting, and renaming Workers when granted at the product scope. Per-Worker Admin applies only to the selected Worker. |

## Role scopes

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is there a title that more loudly and explicitly signals something like "How to grant access to only some Workers"


API tokens use the same Workers roles and scopes as members and User Groups, but they have their own permissions. A token can only perform actions allowed by the Workers role and scope assigned to that token.

## Wrangler

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should there be something in wrangler docs section about? or link to here?

@irvinebroque irvinebroque left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Deeplink to relevant part of dash will help people and agents here too

@irvinebroque irvinebroque left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How do I Terraform this? Can I do any of this via the API?

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

Labels

content:new Request for new/missing content documentation Documentation edits product:workers Related to Workers product size/m

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants