Endpoints
This page describes the functional endpoint groups and what each route is responsible for.
Webhooks
POST /api/webhooks/githubReceives GitHub issue comment events and dispatches task creation.
Expected behavior:
- Valid signature + valid command -> create task.
- Invalid signature or unsupported payload -> reject request.
Tasks
GET /api/tasksPOST /api/tasksGET /api/tasks/:idDELETE /api/tasks/:idGET /api/tasks: list tasksPOST /api/tasks: create task (internal)GET /api/tasks/:id: fetch task statusDELETE /api/tasks/:id: cancel task
Recommended response model:
- Return consistent task identifiers and status enum values.
- Include timestamps for queued, started, and completed states.
- Include error payload on failure transitions.
Callback
POST /api/callbacks/completeReceives task completion signals from worker containers.
Expected callback payload fields typically include task id, status, and optional metadata such as PR URL.
Config
GET /api/configPUT /api/configGET /api/config: load user config from GistPUT /api/config: update user config in Gist
Error handling guidance
- Use
400for malformed request payloads. - Use
401/403for auth and permission failures. - Use
404when task or config target is missing. - Use
5xxonly for genuine server/runtime failures.