Skip to content

Commit fa90fec

Browse files
Copilotpelikhan
andauthored
Clarify Copilot PAT docs (#43503)
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
1 parent 80c8b87 commit fa90fec

2 files changed

Lines changed: 6 additions & 2 deletions

File tree

.github/aw/instructions.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,3 +19,4 @@ Add your repository-specific standards here, for example:
1919
- Standard frontmatter defaults
2020
- Frontmatter ordering/style conventions
2121
- Security or policy constraints specific to this repository
22+
- When documenting or recommending Copilot authentication, state that `permissions: { copilot-requests: write }` uses `${{ github.token }}` for inference and does not require a PAT or `COPILOT_GITHUB_TOKEN` secret

docs/src/content/docs/reference/auth.mdx

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ This page describes authentication settings for GitHub Agentic Workflows.
1212

1313
## Which secret do I need?
1414

15-
Configure one GitHub Actions secret per engine before running your first workflow:
15+
Configure the authentication method your engine needs before running your first workflow. Some engines require a GitHub Actions secret, while Copilot can use `permissions: { copilot-requests: write }` with `${{ github.token }}` and no PAT:
1616

1717
### Copilot (default)
1818

@@ -60,6 +60,9 @@ Workflows using custom MCP tools or safe outputs may require additional authenti
6060

6161
You can add secrets manually in the GitHub UI or use the CLI for a streamlined experience.
6262

63+
> [!NOTE]
64+
> If your Copilot workflow uses `permissions: { copilot-requests: write }`, skip this section for Copilot authentication. gh-aw uses `${{ github.token }}` for inference in that mode, so no PAT or `COPILOT_GITHUB_TOKEN` secret is required.
65+
6366
### Adding secrets using the CLI
6467

6568
```bash
@@ -91,7 +94,7 @@ A reference for all GitHub Actions secrets used by GitHub Agentic Workflows for
9194

9295
### `copilot-requests: write` permission
9396

94-
The recommended way to authenticate Copilot inference is to grant the `copilot-requests: write` permission in your workflow. This uses the built-in GitHub Actions token — no PAT or repository secret is required. Billing is handled centrally through your organization's Copilot subscription.
97+
The recommended way to authenticate Copilot inference is to grant the `copilot-requests: write` permission in your workflow. This uses the built-in GitHub Actions token (`${{ github.token }}`) — no PAT or repository secret is required. Billing is handled centrally through your organization's Copilot subscription.
9598

9699
**Setup**:
97100

0 commit comments

Comments
 (0)