Public API
Start runs and read guides, reviews and events from your own scripts.
The REST API lets a script find a pull request, generate a guide, and read the guide and its review. A request acts as you, narrowed by its token's scopes, so it never reaches a repository you can't open. How Theseus works explains guides and changes.
| API name | What it is |
|---|---|
changeset | The pull request or branch a guide describes |
run | One attempt to generate a guide |
guide | What a successful run produces |
claim | One change in a guide; the API's name for a change |
Resolve a PR, start a run, and read its guide.
Create a personal token with the access you need.
Base URL
Link to this sectionhttps://app.theseus.dev/api/v1Send every request over HTTPS with an Authorization: Bearer header.
Rate limit
Link to this sectionEach person gets 300 requests a minute, shared between the API and MCP. Past that, requests fail with 429 rate_limited and a Retry-After header giving the seconds to wait.
Pagination
Link to this sectionMost list operations take limit (1 to 100, default 50) and return data, next_cursor and has_more. Pass next_cursor back as cursor with the same filters; with different filters it fails with invalid_request. Search has its own limits. Session notes use this pagination for one repository and branch, oldest first.
Errors
Link to this sectionFailures are RFC 9457 problem details (application/problem+json). Branch on code, not title; treat a code you don't know by its HTTP status. Quote request_id when you report a problem.
code | Status | Means |
|---|---|---|
invalid_request | 400 | errors lists each bad field |
unauthenticated | 401 | Missing, expired or revoked token |
not_in_plan | 402 | The plan doesn't cover it; detail says why |
insufficient_scope | 403 | The token lacks required_scope, or the operation needs a sign-in |
admission_required | 403 | Theseus hasn't admitted you yet, or no longer does |
not_found | 404 | Missing, or you can't access it |
ambiguous | 409 | Pick one of candidates, or specify a workspace for notes |
conflict | 409 | Clashes with the resource's current state |
rate_limited | 429 | Wait for Retry-After |
internal_error | 500 | Retrying won't help; report it |
unavailable | 503 | Retry the same request |
Resources
Link to this sectionChangesets
Link to this sectionFind a pull request or branch already known to Theseus.
Guides
Link to this sectionGenerate a guide, read it, and inspect its claims.
Reviews
Link to this sectionRead a recorded review decision action.
Session notes
Link to this sectionSend notes from an agent and read the notes you sent for a repository and branch.
Integrations
Link to this sectionConfigure event delivery and inspect delivery attempts.
- List integrations
- Create integration
- Available repositories
- Get integration
- Update integration
- Delete integration
- Grant repository
- Revoke repository
- List deliveries
- Send test event
- Rotate signing secret
- Enable integration
- Resend delivery
Events
Link to this sectionRead recorded events and recover missed work.
Account
Link to this sectionIdentify your account and manage personal tokens.