Skip to content

Commit 3e6458f

Browse files
authored
ci(claude): switch Claude Code actions to ANTHROPIC_API_KEY (#3532)
## Summary Both Claude Code workflows (`claude.yml` and `claude-md-audit.yml`) authenticated via `CLAUDE_CODE_OAUTH_TOKEN`, which broke when the org disabled Claude subscription access for Claude Code: > Your organization has disabled Claude subscription access for Claude Code · Use an Anthropic API key instead, or ask your admin to enable access This switches both workflows to `anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }}` (secret already added to the repo). ## Test plan - [ ] Confirm `📝 CLAUDE.md Audit` runs to completion on this PR - [ ] Confirm `@claude` mention in a PR comment still triggers the `Claude Code` workflow successfully
1 parent 62e0066 commit 3e6458f

2 files changed

Lines changed: 5 additions & 5 deletions

File tree

.github/workflows/claude-md-audit.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ jobs:
3636
id: claude
3737
uses: anthropics/claude-code-action@fefa07e9c665b7320f08c3b525980457f22f58aa # v1.0.111
3838
with:
39-
claude_code_oauth_token: ${{ secrets.CLAUDE_CODE_OAUTH_TOKEN }}
39+
anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }}
4040
use_sticky_comment: true
4141
allowed_bots: "devin-ai-integration[bot]"
4242

.github/workflows/claude.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,9 @@ jobs:
1919
(github.event_name == 'issues' && (contains(github.event.issue.body, '@claude') || contains(github.event.issue.title, '@claude')))
2020
runs-on: ubuntu-latest
2121
permissions:
22-
contents: read
23-
pull-requests: read
24-
issues: read
22+
contents: write
23+
pull-requests: write
24+
issues: write
2525
id-token: write
2626
actions: read # Required for Claude to read CI results on PRs
2727
steps:
@@ -52,7 +52,7 @@ jobs:
5252
id: claude
5353
uses: anthropics/claude-code-action@fefa07e9c665b7320f08c3b525980457f22f58aa # v1.0.111
5454
with:
55-
claude_code_oauth_token: ${{ secrets.CLAUDE_CODE_OAUTH_TOKEN }}
55+
anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }}
5656

5757
# This is an optional setting that allows Claude to read CI results on PRs
5858
additional_permissions: |

0 commit comments

Comments
 (0)