All docs pages
The Roastd API
Everything you can see and do in Roastd, from your own scripts: your numbers, fixes and reports, and approving, declining or undoing fixes. Every address follows the same rules as the dashboard, and anything only you may do still waits for you on roastd.io.
Updated
Start
Step 1: Make an API key
In Roastd, open Settings, Connections, and press Make an API key. Name it, choose Read only or Read and act, and copy the key. It is shown this one time only, and you can revoke it there at any time.Step 2: Send it with every request
As the headerAuthorization: Bearer <your key>. The API answers JSON athttps://roastd.io/api/v1.
curl https://roastd.io/api/v1/me \
-H "Authorization: Bearer roastd_your_key"curl "https://roastd.io/api/v1/sites/acme-invoicing.com/fixes?show=needs_yes" \
-H "Authorization: Bearer roastd_your_key"curl -X POST https://roastd.io/api/v1/fixes/fix_456/approve \
-H "Authorization: Bearer roastd_your_key" \
-H "Idempotency-Key: 6f1c2a90-0b7e-4f7e-9a1d-2c4b8e1f0a33"The description for your tools
/api/v1/openapi.json, from the same definitions the API checks with.Reading
Any key. {site} is the site's domain, such as acme-invoicing.com, or its id.
| Address | What it gives |
|---|---|
GET /me | Who is connected |
GET /sites/ | How a site is doing Query |
GET /sites/ | Searches on Google Query |
GET /sites/ | Pages on Google Query |
GET /sites/ | AI answers Query |
GET /sites/ | Rivals |
GET /sites/ | The change log Query |
GET /fixes/ | Read one fix |
GET /sites/ | Fixes to make in the code |
GET /sites/ | Monday emails and reviews |
GET /sites/ | One report in full |
GET /sites/ | A site's settings |
GET /sites/ | The site's facts |
GET /sites/ | The questions asked of AI answers |
GET /sites/ | A site's plan |
GET /free-reports/ | Read a free report |
POST /links | Link to a step on roastd.io Body |
Reporting fixes your code makes
Any key, read only too: a script or tool that makes an approved fix in your code says so here, and the fix shows as live and is measured from that day.
| Address | What it does |
|---|---|
POST /fixes/ | Report a fix made Body |
POST /fixes/ | Say the old version is in place again |
POST /fixes/ | Report a fix you could not make Body |
Acting
Keys that may act. A new page, a redirect, removing a page from Google, or a claim about price, law, health, money or a rival answers needs_person with the roastd.io link instead, and paying, switching Autopilot on, loosening a rule and team changes are not in the API at all.
A body is one JSON object with the fields listed. Any other field is left out, and the parts of the address always win.
| Address | What it does |
|---|---|
POST /fixes/ | Approve a fix |
POST /fixes/ | Decline a fix |
POST /fixes/ | Stop a fix in its wait |
POST /fixes/ | Undo a live fix |
POST /fixes/ | Answer a new page's questions Body |
POST /sites/ | Track searches Body |
DELETE /sites/ | Stop tracking a search |
POST /sites/ | Add a rival Body |
DELETE /sites/ | Remove a rival |
POST /sites/ | Add a fact Body |
PATCH /sites/ | Edit a fact Body |
DELETE /sites/ | Delete a fact |
POST /sites/ | Add a question Body |
PATCH /sites/ | Change, take out, put back or reset a question Body |
POST /sites/ | Leave a page alone Body |
PATCH /sites/ | Make a rule stricter Body |
POST /sites/ | Switch Autopilot off |
PUT /sites/ | Set the time zone Body |
POST /free-reports | Start a free report Body |
Sending a request again
Send an Idempotency-Key header (any unique string, such as a UUID) with any request that acts. If the same key and request come again within 24 hours, the API answers the first answer again, with Idempotent-Replayed: true, and nothing happens twice. The same key with a different request is refused.
Some answers are not kept, so the same key runs the request again: a limit (429) or a fault on our side (5xx), where waiting helps, and a refusal about the key or the plan (402, 403), which can change once a trial starts or a key that may act is used.
Lists, a page at a time
Lists take limit (up to 100) and cursor. When there is more, the answer has nextCursor: send it as cursor for the next page. Field names are the same as in the connector's answers.
Limits
60 requests a minute and 5,000 a day for each key, and 300 changes a day for each person across every key and connected app. Past one, the answer is 429 with Retry-After.
Errors
Every error is application/problem+json: a code your program can act on, the plain sentence to show a person in detail, and, for a step only the person may take, next with the roastd.io link.
{
"type": "https://roastd.io/docs/api#needs-person",
"title": "Only the person may do this",
"status": 403,
"detail": "A new page always waits for your own yes on roastd.io.",
"code": "needs_person",
"next": {
"purpose": "approve_fix",
"url": "https://roastd.io/open?to=approve_fix&site=site_123&fix=fix_456",
"what": "Open it on roastd.io, read the exact text, and approve it there."
}
}- 400 invalid
- Something sent does not fit. The sentence names the field.
- 400 which_site
- You have several sites: name one in the address.
- 400 bad_json
- The body is not one JSON object.
- 402 needs_plan
- The fix needs a trial or a plan first. For an owner, next opens Billing; for a member, detail names the owner who can start one.
- 403 read_only
- This key may only read. Make one that may act.
- 403 owner_only
- Only an owner of the site may do this.
- 403 needs_person
- Only the person may do this, on roastd.io. next has the link that opens it.
- 404 not_found
- No such site, fix or report among your own.
- 404 no_route
- No such address in the API.
- 405 method
- The address takes other methods. Allow lists them.
- 409 conflict
- The fix moved on: a teammate or the agent changed it first.
- 409 idempotency_running
- The first request with this Idempotency-Key is still running. Retry-After says when to ask again: 5 seconds.
- 413 too_large
- The body is over 100,000 characters.
- 415 unsupported_media
- Send the body as JSON.
- 422 idempotency_mismatch
- This Idempotency-Key was used for another request in the last 24 hours.
- 429 limit
- Too many requests. Retry-After says when to try again.
Versions
/v1 only grows: new addresses and new fields, never a field taken away or a meaning changed. If something must go, it is announced in the changelog and with Deprecation and Sunset headers on the address.
Using an AI tool instead of a script? Add Roastd to it with the connector. What a key can reach is also on the security page.
Related pages
- Your own Claude or CursorThe connector: your AI makes each approved fix in your code, and tells us when.Read it
- SecurityEvery permission we ask for, what we keep and for how long, and how to reach us.Read it
- What each fix changesEvery kind of fix, what it changes on your site, and whether it asks first.Read it