docs: add agent specific permission example (#3009)

pull/3014/head^2
Sai 2025-10-07 11:08:52 -04:00 committed by GitHub
parent 6c99b833e4
commit 1f725cc3ed
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 19 additions and 1 deletions

View File

@ -111,5 +111,23 @@ For example.
}
}
```
This configuration allows all commands by default (`"*": "allow"`) but requires approval for `git push` commands.
### Agents
Configure agent specific permissions
```json
{
"$schema": "https://opencode.ai/config.json",
"agent": {
"plan": {
"permission": {
"bash": {
"echo *": "allow"
}
}
}
}
}
```