You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat: add allow_bot_actor parameter for automated workflows
- Add allow_bot_actor parameter to enable GitHub bots to trigger Claude Code Action
- Implement robust bot write permission validation
- Use repo.permissions for comprehensive access checks
- Handle both collaborator and installation permissions
- Add comprehensive test coverage for bot scenarios
- Update documentation with security considerations
This enables automated workflows like documentation updates, CI-triggered
code reviews, and scheduled maintenance while maintaining security through
explicit opt-in and proper permission validation.
Copy file name to clipboardExpand all lines: FAQ.md
+7-1Lines changed: 7 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -6,7 +6,13 @@ This FAQ addresses common questions and gotchas when using the Claude Code GitHu
6
6
7
7
### Why doesn't tagging @claude from my automated workflow work?
8
8
9
-
The `github-actions` user cannot trigger subsequent GitHub Actions workflows. This is a GitHub security feature to prevent infinite loops. To make this work, you need to use a Personal Access Token (PAT) instead, which will act as a regular user, or use a separate app token of your own. When posting a comment on an issue or PR from your workflow, use your PAT instead of the `GITHUB_TOKEN` generated in your workflow.
9
+
By default, bots cannot trigger Claude for security reasons. With `allow_bot_actor: true`, you can enable bot triggers, but there are important distinctions:
10
+
11
+
1.**GitHub Apps** (recommended): Create a GitHub App, use app tokens, and set `allow_bot_actor: true`. The app needs write permissions.
12
+
2.**Personal Access Tokens**: Use a PAT instead of `GITHUB_TOKEN` in your workflows with `allow_bot_actor: true`.
13
+
3.**github-actions[bot]**: Can trigger Claude with `allow_bot_actor: true`, BUT due to GitHub's security, responses won't trigger subsequent workflows.
14
+
15
+
**Important**: Even with `allow_bot_actor: true`, the `github-actions[bot]` using `GITHUB_TOKEN` cannot trigger subsequent workflows. This is a GitHub security feature to prevent infinite loops, not a limitation of this action.
10
16
11
17
### Why does Claude say I don't have permission to trigger it?
Copy file name to clipboardExpand all lines: README.md
+2-1Lines changed: 2 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -191,6 +191,7 @@ jobs:
191
191
|`branch_prefix`| The prefix to use for Claude branches (defaults to 'claude/', use 'claude-' for dash format) | No |`claude/`|
192
192
|`claude_env`| Custom environment variables to pass to Claude Code execution (YAML format) | No | "" |
193
193
|`settings`| Claude Code settings as JSON string or path to settings JSON file | No | "" |
194
+
|`allow_bot_actor`| Allow GitHub bots and automation accounts to trigger Claude (security: defaults to false, requires explicit opt-in) | No |`false`|
194
195
|`additional_permissions`| Additional permissions to enable. Currently supports 'actions: read' for viewing workflow results | No | "" |
195
196
|`experimental_allowed_domains`| Restrict network access to these domains only (newline-separated). | No | "" |
196
197
|`use_commit_signing`| Enable commit signing using GitHub's commit signature verification. When false, Claude uses standard git commands | No |`false`|
@@ -830,7 +831,7 @@ Both AWS Bedrock and GCP Vertex AI require OIDC authentication.
830
831
### Access Control
831
832
832
833
- **Repository Access**: The action can only be triggered by users with write access to the repository
833
-
- **No Bot Triggers**: GitHub Apps and bots cannot trigger this action
834
+
- **Bot Actor Control**: GitHub Apps and bots are blocked by default for security. Use `allow_bot_actor: true` to enable automated workflows (requires explicit opt-in)
834
835
- **Token Permissions**: The GitHub app receives only a short-lived token scoped specifically to the repository it's operating in
835
836
- **No Cross-Repository Access**: Each action invocation is limited to the repository where it was triggered
836
837
- **Limited Scope**: The token cannot access other repositories or perform actions beyond the configured permissions
Copy file name to clipboardExpand all lines: ROADMAP.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -10,7 +10,7 @@ Thank you for trying out the beta of our GitHub Action! This document outlines o
10
10
-**Support for workflow_dispatch and repository_dispatch events** - Dispatch Claude on events triggered via API from other workflows or from other services
11
11
-**Ability to disable commit signing** - Option to turn off GPG signing for environments where it's not required. This will enable Claude to use normal `git` bash commands for committing. This will likely become the default behavior once added.
12
12
-**Better code review behavior** - Support inline comments on specific lines, provide higher quality reviews with more actionable feedback
13
-
-**Support triggering @claude from bot users** - Allow automation and bot accounts to invoke Claude
13
+
-~**Support triggering @claude from bot users** - Allow automation and bot accounts to invoke Claude~
14
14
-**Customizable base prompts** - Full control over Claude's initial context with template variables like `$PR_COMMENTS`, `$PR_FILES`, etc. Users can replace our default prompt entirely while still accessing key contextual data
0 commit comments