API conventions
The rules every route of the automation API keeps: addresses, errors, limits, pages, safe retries and versions. The same rules hold for the portal’s own routes unless their reference says otherwise.
Addresses and formats
Section titled “Addresses and formats”- Base address: each installation has its own API host, for example
https://api.academy.example.com. Every route starts with/v1/, except a few that standards fix:/.well-known/…,/scim/v2/…and the content host’s/scorm/…. - JSON in and out (
Content-Type: application/json), UTF-8. The automation API refuses a body with a field the route doesn’t know (400 validation_failed), so a typo never goes unnoticed. The OAuth token endpoints takeapplication/x-www-form-urlencoded, SCIM takesapplication/scim+json. - Ids are UUIDs. Times are ISO 8601 in UTC (
2026-11-20T08:43:46.514Z); dates without a time areYYYY-MM-DD. - Cells: an installation can run several regional cells. Every answer carries
x-academy-cell; a token of another cell gets421 wrong_cellwith the right cell. - Health:
GET /healthzanswers{"status":"ok"}while the process runs;GET /readyzanswers{"status":"ready","cell":"…","region":"…","release":{"commit":"…","builtAt":"…","ciRun":"…"}}when it can serve, with the running release (nullwhen run from a checkout)./readyzis the operator’s check, not a public one: behind nginx only loopback and the admin console’s addresses reach it (deploy);/healthzis open.
Errors
Section titled “Errors”An error answers with an HTTP status and a JSON body:
{ "error": "insufficient_scope", "message": "courses:read" }erroris a stable code for your flow to branch on;messageis for people and may change. Some errors add fields (for examplecellwithwrong_cell).- Validation errors are
400 validation_failed, with every problem in the message:"email: Invalid email address; body: Unrecognized key: \"foo\"". - Unexpected errors are
500 {"error": "internal", "message": "internal error"}; nothing about the cause leaves the server. Retry later with the sameIdempotency-Key. - An unknown route is
404with"error": "Not Found". - The OAuth token endpoints answer as RFC 6749 says:
{"error": "invalid_client"}, and for agents alsoerror_description.
| Status | Code | Meaning |
|---|---|---|
| 400 | validation_failed |
the request doesn’t fit the route’s schema |
| 400 | invalid_idempotency_key |
the Idempotency-Key isn’t 1 to 255 visible ASCII characters |
| 400 | invalid_manager |
the manager isn’t a person of the organisation |
| 401 | unauthenticated |
no token, or not a valid one |
| 401 | invalid_token |
the machine token is unknown or expired: get a new one |
| 402 | payment_required |
the live session is paid and has to be booked first |
| 403 | insufficient_scope |
the token lacks the scope named in message |
| 403 | forbidden |
the person behind the token isn’t (or is no longer) allowed to do this |
| 403 | read_only |
the personal access token may only read |
| 403 | two_factor_required |
the administrator must set up their second sign-in step first |
| 403 | contract_ended |
the organisation’s contract has ended: machine and agent access stopped; its global administrator can still export the data |
| 403 | course_access |
the person may not take the live session’s course |
| 404 | not_found |
no such object in this organisation |
| 409 | field_owned_by_hr |
the HR connector leads this field; leave it out (HR systems) |
| 409 | person_external |
the address belongs to an external learner, not a member |
| 409 | person_is_admin |
people with administrative roles are changed in the portal |
| 409 | user_exists |
a person with that email was added at the same moment: retry |
| 409 | team_synced |
the team’s members come from a directory (SCIM, Entra, Google, HR) |
| 409 | team_grants_role |
the team’s members receive a role; change them in the portal |
| 409 | already_joined, full, cancelled, ended |
the live session can’t take this registration |
| 409 | session_private |
the live session has its own invitation list |
| 409 | not_a_mentor |
the person isn’t a mentor |
| 409 | not_a_trainer, trainer_gone, above_budget, run_finished, run_not_done |
course factory runs (automation API) |
| 409 | integration_limit, webhook_limit |
at most 25 machine clients, 20 webhooks |
| 409 | idempotency_in_progress |
a request with this key is still running: wait and retry |
| 422 | idempotency_key_reused |
this key was used for another request |
| 429 | rate_limited |
too many calls this minute |
| 429 | invite_quota |
a new organisation may send only a few invitations a day (remaining says how many are left) |
| 500 | internal |
an error on the server’s side |
Codes are only ever added. Treat a code you don’t know by its status.
Rate limits
Section titled “Rate limits”| Who | Limit |
|---|---|
| Each machine client on the automation API | 300 requests a minute |
Machine token endpoint /v1/integration-oauth/token |
30 a minute per IP address |
| MCP, per person | 600 requests a minute |
| OAuth token endpoint for agents | 120 a minute per IP address |
| OAuth client registration | 20 an hour per IP address |
| Knowledge connectors | 1,200 requests a minute per connector |
The windows are fixed minutes. Above a limit the API answers 429 (rate_limited on the automation API, too_many_attempts elsewhere) without a Retry-After header: wait until the next minute starts, then go on. Spread bulk jobs over time and reuse tokens instead of asking for one per call.
Pagination
Section titled “Pagination”Lists of the automation API come in pages, ordered by id:
GET /v1/integration-api/people?limit=100&after=870560e9-…{ "items": [ … ], "next": "9a1f…" }limit: 1 to 100, default 50.after: thenextof the previous page.nextisnullon the last page.- A full read is not a snapshot: what changes while you read may or may not be in it. For changes, subscribe to webhooks instead of reading everything again.
- Filters: people by
emailoremployeeNumber, courses bytitle, requirements byteamId, live sessions byfrom(an ISO time). - The list of subscriptions is short and comes whole, as
{ "items": [ … ] }.
Idempotency
Section titled “Idempotency”Send an Idempotency-Key with every POST, PUT, PATCH and DELETE of the automation API (/v1/integration-api/…):
Idempotency-Key: onboarding-E-1042-team- 1 to 255 visible ASCII characters. Use something that is the same when your tool repeats a step and different for another step, such as the step’s run id plus the person’s email.
- The same key with the same request (method, address with query, body) gets the first answer again, with
idempotent-replayed: true; nothing happens twice. Answers are kept for 24 hours. - While the first request still runs, a repeat is
409 idempotency_in_progress; retry a moment later. - The same key with another request is
422 idempotency_key_reused. - Answers that say nothing about the change (
401,403,429,5xx) aren’t kept, so a retry after them really runs again. - Keys belong to the caller: a machine client’s keys are its own across its tokens.
Some writes are idempotent by themselves: PUT /v1/integration-api/people finds a person by email and PUT /v1/integration-api/courses a course by title; both answer created: true|false (201 or 200). The PUT …/members/{personId} routes add someone once, however often they are called, and answer changed: true|false.
Versions and deprecation
Section titled “Versions and deprecation”The automation API is version 1, in the path (/v1/). Its promise:
- Routes, fields, scopes, error codes and webhook event types are only ever added.
- A field is never removed or renamed, and never changes its meaning or type. An error code stays what it is.
- A change that would break this comes as a new version (
/v2) beside v1, announced at least 12 months before v1 ends. - Your code must ignore fields and event types it doesn’t know; that is how additions stay harmless.
The same promise holds for webhook payloads and for the MCP tools marked ★ (MCP). Routes outside the automation API belong to the portal and follow it; build integrations on the automation API, MCP and webhooks.
Nothing is deprecated today, so the API sends no Deprecation or Sunset headers yet. Every change to an interface, and every deprecation with its date, is in the changelog.
The reference
Section titled “The reference”- On the docs site: the API reference, generated from
docs/integrations/openapi-v1.jsonwith an example for every route. Each example is checked against the route’s schemas when the API starts, and a test keeps the file current. - On every installation, for someone signed in to its portal:
/v1/integration-api/docs(readable) and/v1/integration-api/openapi.json(OpenAPI 3.1 of the automation API),/v1/api-docsand/v1/openapi.json(every route, portal routes with their own sign-in rules). They need a browser session; tokens can’t fetch them (ADR 0337).
Import the OpenAPI document into Postman, Insomnia or a code generator; Make and Power Automate build a custom connector from it.
Browsers and CORS
Section titled “Browsers and CORS”The API is for servers. It answers cross-origin browser requests only from the portal’s own addresses (CORS_ORIGINS and the organisations’ portal domains), and /v1/mcp refuses any other Origin. Requests without an Origin header (servers, scripts, automation tools) aren’t affected.