Skip to content

docs: add App Preview API key guide#898

Open
riderx wants to merge 4 commits into
mainfrom
codex/docs-app-preview-api-key
Open

docs: add App Preview API key guide#898
riderx wants to merge 4 commits into
mainfrom
codex/docs-app-preview-api-key

Conversation

@riderx

@riderx riderx commented Jul 15, 2026

Copy link
Copy Markdown
Member

Summary

  • Correct the App Preview API-key procedure for organization- and app-bound RBAC bindings.
  • Document the split between the app-level app_preview grant and the automatic, channel-scoped channel_preview grant created only when the key creates a channel.
  • Document per-key bundle ownership and the ownership-checked channel delete --delete-bundle cleanup flow, with an explicit availability gate until the companion release is deployed.
  • State the enforced mutation boundary: a preview key cannot manage an existing default/main channel, another preview key's channel, or another key's bundle.
  • Clarify that app_preview retains app-level read access, so the feature provides lifecycle/write isolation rather than strict channel-read isolation.

Dependency

Documents the companion implementation in Cap-go/capgo.app#2698. The special preview cleanup is explicitly marked unavailable until that implementation is released.

Validation

  • bunx prettier --write on the touched documentation files
  • bun run ci:verify:docs
  • Focused desktop and mobile visual comparison of /docs/webapp/api-keys/

Visual diff

Generated with bun run visual-diff:compare (2 screenshots, fuzz 1%).

Status Suite Route Viewport Diff (px)
changed docs /docs/webapp/api-keys/ desktop 3627290
changed docs /docs/webapp/api-keys/ mobile 1549810

Rendered App Preview dashboard documentation

Rendered App Preview public API documentation

@cursor

cursor Bot commented Jul 15, 2026

Copy link
Copy Markdown

Bugbot couldn't run - usage limit reached

Bugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit.

A user or team admin can review and increase usage limits in the Cursor dashboard.

(requestId: serverGenReqId_40a3753c-519b-460f-9a71-cf090be8847d)

@coderabbitai

coderabbitai Bot commented Jul 15, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

📝 Walkthrough

Walkthrough

The documentation defines the App Preview RBAC role, updates API key scoping and setup instructions, and clarifies preview channel and owned bundle deletion behavior.

Changes

App Preview RBAC guidance

Layer / File(s) Summary
App Preview permission contract
apps/docs/src/content/docs/docs/webapp/organization-roles.mdx, apps/docs/src/content/docs/docs/public-api/api-keys.mdx
Documents the app_preview and channel_preview roles, their permissions and exclusions, preview bindings, and organization provisioning requirements.
API key scope and setup
apps/docs/src/content/docs/docs/webapp/api-keys.mdx, apps/docs/src/content/docs/docs/public-api/api-keys.mdx
Explains organization-wide and selected-app scopes, App Preview assignment, secure key handling, and preview workflow setup.
Preview channel and bundle cleanup guidance
apps/docs/src/content/docs/docs/cli/reference/channel.mdx, apps/docs/src/content/docs/docs/webapp/channels.mdx, apps/docs/src/content/docs/docs/webapp/api-keys.mdx
Clarifies that App Preview keys can atomically delete their own preview channel and owned bundle with --delete-bundle, but cannot affect other channels or bundles.

Estimated code review effort: 2 (Simple) | ~15 minutes

Suggested reviewers: dalanir, wcaleniewolny

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly summarizes the main documentation addition: an App Preview API key guide.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch

Comment @coderabbitai help to get the list of available commands.

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Stale comment

Risk: low. Cursor Bugbot did not complete (skipped due to usage limit), so automated review is unavailable for this run. Leaving a non-blocking comment and assigning reviewers for human review of this documentation-only PR.

Open in Web View Automation 

Sent by Cursor Approval Agent: Pull Request Approver

@cursor cursor Bot requested review from Dalanir and WcaleNieWolny July 15, 2026 19:34
@riderx riderx force-pushed the codex/docs-app-preview-api-key branch from 4e6cb7d to a44ba35 Compare July 15, 2026 19:40
@cursor

cursor Bot commented Jul 15, 2026

Copy link
Copy Markdown

Bugbot couldn't run - usage limit reached

Bugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit.

A user or team admin can review and increase usage limits in the Cursor dashboard.

(requestId: serverGenReqId_b1b0555f-aceb-4375-b074-312da402bccc)

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Stale comment

Risk: low. Cursor Bugbot did not complete successfully (skipped due to usage limit), so automated review is unavailable for this run. Leaving a non-blocking comment; human reviewers are already assigned for this documentation-only PR.

Open in Web View Automation 

Sent by Cursor Approval Agent: Pull Request Approver

@coderabbitai coderabbitai 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.

Actionable comments posted: 2

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@apps/docs/src/content/docs/docs/webapp/api-keys.mdx`:
- Line 50: Update the App Developer role description in the API keys
documentation to remove the claim that it can manage app configuration; describe
only deployment and channel-settings access, or explicitly distinguish those
permissions from app settings, consistent with the organization roles
documentation.
- Around line 41-43: Update the organization-creation guidance in the API key
documentation to state that org.create requires an org-scoped org_admin or
org_super_admin binding, explicitly mapping the dashboard’s “Admin” role to the
appropriate binding when applicable. Preserve the existing permission and
automatic Super Admin assignment details.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: e4438429-294f-4d2e-b4d0-e673d9c10e17

📥 Commits

Reviewing files that changed from the base of the PR and between ffa58c6 and 4e6cb7d.

📒 Files selected for processing (6)
  • .github/pr-assets/app-preview-api-key-docs.webp
  • apps/docs/src/content/docs/docs/cli/reference/channel.mdx
  • apps/docs/src/content/docs/docs/public-api/api-keys.mdx
  • apps/docs/src/content/docs/docs/webapp/api-keys.mdx
  • apps/docs/src/content/docs/docs/webapp/channels.mdx
  • apps/docs/src/content/docs/docs/webapp/organization-roles.mdx
🔗 Linked repositories identified

CodeRabbit considers these linked repositories for cross-repo context during reviews:

  • Cap-go/capacitor-updater (manual)

Comment thread apps/docs/src/content/docs/docs/webapp/api-keys.mdx Outdated
Comment thread apps/docs/src/content/docs/docs/webapp/api-keys.mdx Outdated
@riderx riderx force-pushed the codex/docs-app-preview-api-key branch from a44ba35 to a4e19cd Compare July 15, 2026 19:45
@cursor

cursor Bot commented Jul 15, 2026

Copy link
Copy Markdown

Bugbot couldn't run - usage limit reached

Bugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit.

A user or team admin can review and increase usage limits in the Cursor dashboard.

(requestId: serverGenReqId_a8882765-92a9-4769-b87c-40006285962a)

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Stale comment

Risk: low. Cursor Bugbot did not complete successfully (skipped due to usage limit), so automated review is unavailable for this run. Leaving a non-blocking comment; human reviewers are already assigned for this documentation-only PR.

Open in Web View Automation 

Sent by Cursor Approval Agent: Pull Request Approver

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Stale comment

Risk: low. Not approving because Cursor Bugbot did not complete successfully (skipped due to usage limit). Human review is needed for this documentation-only PR.

Open in Web View Automation 

Sent by Cursor Approval Agent: Pull Request Approver External

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Stale comment

Risk: low. Cursor Bugbot did not complete successfully (skipped due to usage limit), so automated review is unavailable for this run. Leaving a non-blocking comment; human reviewers are already assigned for this documentation-only PR.

Open in Web View Automation 

Sent by Cursor Approval Agent: Pull Request Approver External

@cursor

cursor Bot commented Jul 15, 2026

Copy link
Copy Markdown

Bugbot couldn't run - usage limit reached

Bugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit.

A user or team admin can review and increase usage limits in the Cursor dashboard.

(requestId: serverGenReqId_94d598e4-6d5d-46f5-a74e-3eb20ee4010e)

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Stale comment

Risk: low. Cursor Bugbot did not complete successfully (skipped due to usage limit), so automated review is unavailable for this run. Leaving a non-blocking comment; human reviewers are already assigned for this documentation-only PR.

Open in Web View Automation 

Sent by Cursor Approval Agent: Pull Request Approver

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Stale comment

Risk: low. Cursor Bugbot did not complete successfully (skipped due to usage limit), so automated review is unavailable for this run. Leaving a non-blocking comment; human reviewers are already assigned for this documentation-only PR.

Open in Web View Automation 

Sent by Cursor Approval Agent: Pull Request Approver External

@cursor

cursor Bot commented Jul 15, 2026

Copy link
Copy Markdown

Bugbot couldn't run - usage limit reached

Bugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit.

A user or team admin can review and increase usage limits in the Cursor dashboard.

(requestId: serverGenReqId_4f07dceb-51f9-4422-b54c-fd9f4b3590c8)

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Stale comment

Risk: low. Cursor Bugbot did not complete successfully (skipped due to usage limit), so automated review is unavailable for this run. Leaving a non-blocking comment; human reviewers are already assigned.

Open in Web View Automation 

Sent by Cursor Approval Agent: Pull Request Approver External

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Stale comment

Risk: low. Cursor Bugbot did not complete successfully (skipped due to usage limit), so automated review is unavailable for this run. Leaving a non-blocking comment; human reviewers are already assigned for this documentation-only PR.

Open in Web View Automation 

Sent by Cursor Approval Agent: Pull Request Approver

@coderabbitai coderabbitai 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.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@apps/docs/src/content/docs/docs/cli/reference/channel.mdx`:
- Around line 59-65: Remove or clearly mark the unsupported --delete-bundle App
Preview cleanup flow in
apps/docs/src/content/docs/docs/cli/reference/channel.mdx lines 59-65,
apps/docs/src/content/docs/docs/webapp/organization-roles.mdx line 117,
apps/docs/src/content/docs/docs/public-api/api-keys.mdx lines 53 and 126,
apps/docs/src/content/docs/docs/webapp/api-keys.mdx lines 65-91, and
apps/docs/src/content/docs/docs/webapp/channels.mdx line 91; do not present it
as available until the companion implementation is released.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: 952480ab-8661-4249-9e3f-035b2656badc

📥 Commits

Reviewing files that changed from the base of the PR and between 4e6cb7d and 012e0bb.

📒 Files selected for processing (7)
  • .github/pr-assets/app-preview-api-key-docs.webp
  • .github/pr-assets/app-preview-api-key-public-api-docs.webp
  • apps/docs/src/content/docs/docs/cli/reference/channel.mdx
  • apps/docs/src/content/docs/docs/public-api/api-keys.mdx
  • apps/docs/src/content/docs/docs/webapp/api-keys.mdx
  • apps/docs/src/content/docs/docs/webapp/channels.mdx
  • apps/docs/src/content/docs/docs/webapp/organization-roles.mdx
🔗 Linked repositories identified

CodeRabbit considers these linked repositories for cross-repo context during reviews:

  • Cap-go/capacitor-updater (manual)

Comment thread apps/docs/src/content/docs/docs/cli/reference/channel.mdx Outdated
@cursor

cursor Bot commented Jul 15, 2026

Copy link
Copy Markdown

Bugbot couldn't run - usage limit reached

Bugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit.

A user or team admin can review and increase usage limits in the Cursor dashboard.

(requestId: serverGenReqId_4d92fcd5-b2fe-4e63-8246-4601ef5e27c9)

@sonarqubecloud

Copy link
Copy Markdown

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Risk: low. Cursor Bugbot did not complete successfully (skipped due to usage limit), so automated review is unavailable for this run. Leaving a non-blocking comment; human reviewers are already assigned.

Open in Web View Automation 

Sent by Cursor Approval Agent: Pull Request Approver

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Risk: low. Cursor Bugbot did not complete successfully (skipped), so automated review is unavailable for this run. Leaving a non-blocking comment; human reviewers are already assigned.

Open in Web View Automation 

Sent by Cursor Approval Agent: Pull Request Approver External

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant