Skip to content

Commit bfa92e5

Browse files
committed
Add instructions for orgs
Organizations don't have models enabled by default, but they're needed for this to work
1 parent 8ccedc4 commit bfa92e5

File tree

1 file changed

+30
-0
lines changed

1 file changed

+30
-0
lines changed

README.md

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,36 @@ You can override the model with any model supported by the chosen provider.
102102
- Things to watch for
103103
4. Posts (or updates) the instructions as a PR comment, identified by a hidden HTML marker
104104

105+
## Troubleshooting
106+
107+
### GitHub Models returns 403 Forbidden
108+
109+
If you see a 403 error when using the `github-models` provider, GitHub Models may be disabled at the organization level. GitHub Models uses a hierarchical access control system:
110+
111+
1. **Enterprise level** — An enterprise owner must enable GitHub Models for the enterprise (if your organization is part of an enterprise)
112+
2. **Organization level** — An organization owner must enable GitHub Models for the organization
113+
3. **Workflow level** — Your workflow must declare `permissions: models: read` (already in the example above)
114+
115+
**To enable GitHub Models for your organization:**
116+
117+
An organization owner needs to:
118+
119+
1. Navigate to your organization's **Settings**
120+
2. Go to **Code, planning, and automation** → **Models** → **Development**
121+
3. Enable GitHub Models for the organization
122+
123+
**Alternative workaround:**
124+
125+
If you cannot enable GitHub Models at the organization level, switch to the Anthropic provider:
126+
127+
```yaml
128+
- uses: BadIdeaFactory/qa-instructions-action@v1
129+
with:
130+
github-token: ${{ secrets.GITHUB_TOKEN }}
131+
provider: anthropic
132+
anthropic-api-key: ${{ secrets.ANTHROPIC_API_KEY }}
133+
```
134+
105135
## Development
106136

107137
### Setup

0 commit comments

Comments
 (0)