docs(raw-api): document gitea_request, env vars and policy examples
Adds docs/raw-api.md (two-layer policy, sensitive denylist, env vars, write-mode warning), links it from index and api-reference, documents RAW_API_ENABLED / RAW_API_ALLOW_SENSITIVE in .env.example, and adds commented virtual-tool-name deny examples to policy.yaml. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
+12
-2
@@ -90,8 +90,18 @@ Scope requirements:
|
||||
- `create_milestone` (`owner`, `repo`, `title`, optional `description`, `due_on`)
|
||||
- `edit_issue_comment` (`owner`, `repo`, `comment_id`, `body`)
|
||||
|
||||
Not supported by design: merge, branch/label/release deletion, force push, repo/admin
|
||||
management.
|
||||
Not supported by the dedicated tools by design: merge, branch/label/release deletion,
|
||||
force push, repo/admin management. Endpoints not covered above are reachable through the
|
||||
generic `gitea_request` escape hatch (subject to policy, write-mode, and a sensitive-path
|
||||
denylist) — see [Raw API Dispatch](raw-api.md).
|
||||
|
||||
## Raw API Dispatch
|
||||
|
||||
- `gitea_request` (`method`, `path`, optional `query`, `body`)
|
||||
- Calls an arbitrary Gitea REST endpoint. `GET`/`HEAD` are reads; other methods are
|
||||
writes and require write-mode plus a whitelisted repository. Admin/credential
|
||||
endpoints are blocked unless `RAW_API_ALLOW_SENSITIVE=true`. See
|
||||
[Raw API Dispatch](raw-api.md) for the two-layer policy model and full details.
|
||||
|
||||
Note: `create_issue`, `add_labels`, and `remove_labels` accept label **names**; the
|
||||
server resolves them to Gitea label ids and returns a clear error for unknown labels.
|
||||
|
||||
Reference in New Issue
Block a user