Skip to content

REST API

The web application talks to the server through a JSON REST API under /api. You can use it to automate anything the application does: import tests, start runs, collect results.

Base URL https://app.autotestx.com/api (or your server’s address)
Format JSON request and response bodies (content-type: application/json)
Authentication A session cookie (atx_session) from POST /api/auth/login, or an API token for CI (see below). Every route requires one except sign-in, registration and password reset.
Project List and create routes act on the project named in the x-project-id header. Routes for one record (/api/tests/:id) use that record’s own project.
Errors { "error": "message" }, with issues for validation errors and a stable code where the client can act on it. 401 not signed in, 402 not included in the organization’s plan, 403 not allowed, 404 not found, 409 conflict (e.g. a Ready test), 422 invalid, 429 too many sign-in attempts or too many suite runs in progress.
Permissions Exactly as in the app: see roles

The cookie is HttpOnly and SameSite=Strict, so use a cookie jar (as below) rather than reading it.

A pipeline cannot sign in with a password. A project Admin or Test Manager creates an API token under Project Members → API tokens for CI and the pipeline sends it on every request:

Terminal window
curl -H "Authorization: Bearer $ATX_TOKEN" https://app.autotestx.com/api/tokens/self
# → { "token": { "name": "GitHub Actions - main", "role": "tester", … }, "project": { "id": "prj_…", "name": "Web Portal" } }
  • A token belongs to one project, not to a person: it keeps working when its creator leaves, and the audit log and runs record the token (tok_…) as the actor. It needs no x-project-id header; naming another project is refused with 403.
  • Its role is Run tests (tester) or Read results only (viewer). It can never manage members, secrets, environments or other tokens.
  • It reaches only the endpoints a pipeline needs, marked CI below: reading tests, suites, environments and runs, and starting a run or a suite run. Any other endpoint answers 403 with code: "token_not_allowed".
  • The value (atx_pat_…) is shown once, when it is created. The server keeps only a SHA-256 digest. Tokens can be given an expiry of 1 to 365 days, or none.
  • A request with a bearer token is judged by the token alone. If the token is wrong it does not fall back to a cookie. Other schemes (e.g. a proxy’s Basic auth) are ignored.
Refusal Status code
Unknown or revoked token 401 invalid_token
Expired token 401 expired_token
Endpoint not open to tokens 403 token_not_allowed

How many tokens an organization may hold depends on its plan, counted across all its projects (expired tokens do not count): none on the proof of value, 2 on Team, unlimited on Business and Enterprise. Creating one more answers 402 with code: "plan_api_tokens" (not in this plan) or "plan_api_token_limit" (all in use).

A downgrade waits for the tokens: changing to a plan that allows fewer tokens than the organization holds is refused with 409 and code: "plan_api_tokens_in_use", saying how many to revoke. Until then every existing token keeps working, so the organization decides which pipelines to keep, not the server.

Worked example: import a test, run it, read the result

Section titled “Worked example: import a test, run it, read the result”
Terminal window
# 1. Sign in (stores the session cookie in cookies.txt)
curl -s -c cookies.txt -H "content-type: application/json" \
-d '{"email":"you@example.com","password":"…"}' \
https://app.autotestx.com/api/auth/login
# 2. Find your project and environment ids
curl -s -b cookies.txt https://app.autotestx.com/api/context
curl -s -b cookies.txt -H "x-project-id: prj_…" https://app.autotestx.com/api/environments
# 3. Import a test file
curl -s -b cookies.txt -H "content-type: application/json" -H "x-project-id: prj_…" \
--data @examples/create-purchase-order.json \
https://app.autotestx.com/api/tests/import
# → { "test": { "id": "tc_…", … }, "version": 1, … }
# 4. Start a run
curl -s -b cookies.txt -H "content-type: application/json" -H "x-project-id: prj_…" \
-d '{"testId":"tc_…","environmentId":"env_…"}' \
https://app.autotestx.com/api/runs
# → { "runId": "run_…" }
# 5. Get the result: 202 while running, 200 when finished
curl -s -b cookies.txt https://app.autotestx.com/api/runs/run_…
# → { "status": "passed", "passed": 18, "total": 18, "durationMs": 5025, "result": { "steps": [ … ] }, … }

For live progress, read the server-sent events stream GET /api/runs/:id/events instead of polling. Events are run.started, step.started, step.retry, step.finished, artifact, log and run.finished.

Method Path Body / notes
POST /api/auth/login { email, password }. Sets the session cookie. Public.
POST /api/auth/logout Ends the session
GET /api/auth/session The signed-in user, or null. Public.
POST /api/auth/register { name, email, password }. Self-registration. Public.
POST /api/auth/forgot { email }. Sends (prints) a reset link. Public.
POST /api/auth/reset { token, password }. Public.
POST /api/auth/password { currentPassword, newPassword }. Change own password; signs out your other sessions.
GET /api/context Signed-in user, organizations and projects with your role in each
GET /api/profile Your profile and recent runs
GET /api/roles CI. The role → permission matrix
Method Path Notes
GET /api/tests CI. Tests you can see in the project
POST /api/tests Create from a test document
POST /api/tests/import Import a DSL document: migrated, validated, new id, shared, owned by you. 422 with issues if it is not a JSON object, has no dslVersion, is newer than this build, or is otherwise invalid. Its status is kept only if your role can approve tests (Test Manager, Admin); otherwise a ready or deprecated document is imported as draft. 409 if it carries unsaved AI-written steps with a status other than draft
GET /api/tests/:id CI. Current version, with owner, visibility and what you can do (can)
PUT /api/tests/:id Save. A Draft is saved over its current version; 422 with issues if invalid; 409 for a Ready or Deprecated test, or with stepIds when a save that adds AI-written steps is not a draft.
DELETE /api/tests/:id Delete the test and all versions
POST /api/tests/:id/validate Validate a document without saving
POST /api/tests/:id/revisions Start a new Draft revision of a Ready test
POST /api/tests/:id/duplicate Copy into a new Draft you own
PUT /api/tests/:id/sharing { visibility?, ownerId? }
GET /api/tests/:id/versions CI. Version history. Each entry carries provenance (who opened the revision and why), lastChange and changes (every write, consecutive editor saves by one person kept as one). A write that first saved steps the AI step writer produced has assisted: "ai". Authors show their current name; a member or token that is gone keeps its old name with removed: true. ?trigger=heal-auto,heal-approve and ?author=<member or token id> keep the revisions with a matching write; an unknown trigger is 422. Every field and trigger: Version provenance. Entries written before provenance carry none and match no filter.
GET /api/tests/:id/versions/:version CI. One version, with the provenance of its latest write
POST /api/tests/:id/versions/:version/restore Restore as a new version
POST /api/script The readable Script rendering of a test document
POST /api/scripts/try Try a custom code snippet (editor’s Run code)
GET /api/registry CI. Step types and their parameters
Method Path Notes
GET /api/runs CI. Runs in the project
POST /api/runs CI (Run tests tokens). { testId, environmentId?, headed?, screenshots? } → { runId }. screenshots defaults to every step; false limits to failures.
GET /api/runs/:id CI. The result. 202 while running. produced lists the test revisions and component versions the run’s self-healing fixes were written into: { of, id, name, version, trigger } (details).
GET /api/runs/:id/events CI. Server-sent events, live
GET /api/runs/:id/report.junit.xml CI. The run as JUnit XML: one test case, or one per data row. 409 while running.
GET /api/runs/:id/export.json CI. The run in the export envelope (autotestx.run/1). 409 while running.
GET /api/runs/:id/artifacts/:name CI. A screenshot or other artifact
GET /api/runs/:id/rows/:row CI. One row’s full result in a data-driven run
GET /api/runs/:id/rows/:row/artifacts/:name CI. A row’s artifact
GET /api/runs/:id/failure-context CI. Why a run failed, in one document: the failing step with expected vs actual and its screenshot link, the 3 steps before it, self-heals (and whether they came before the failure), degraded locators, the first failing data row, the test’s recent results on the same environment (lastPassedAt, failingSince, failuresInARow, flaky), a one-line summary, rule-based hints and the run’s failure classification. 202 while running. What the MCP tool explain_failure returns.
GET /api/dashboard Dashboard figures. healing holds autoAppliedThisWeek, revertedThisWeek, pending and pausedRules.

A suite execution runs every shared test of a suite against one environment and rolls the results up into one answer. It is what Run on the Test Suites page, a schedule, atx run --suite and a deploy pipeline use. See Run after deployment for pipeline examples.

Method Path Notes
POST /api/executions CI (Run tests tokens). Start a suite. Body below. → 202 { executionId, tests, status, url, statusUrl }
GET /api/executions CI. The project’s last 100 suite runs, newest first, without children. ?suite=Asset for one suite, ?release=v2.14.0 for one release, ?commit=a1b2c3d (7+ characters) for one commit; they combine.
GET /api/executions/:id CI. One suite run with every test (children). ?wait=N holds the request up to N seconds (max 120) until it finishes.
GET /api/executions/:id/investigation CI. The failure investigation of a suite run. entries: one per failed test, with its rule-based class (maximo, server-error, auth, test-data, environment, timeout, locator, assertion, unknown), confidence (0 to 1), the matching rule, endpoint (METHOD host/path), tier (healing tier of a locator failure), bmxaa codes, alternatives, failedStep, artifacts (report, screenshot, video, trace, console and network logs) and analysis. groups: the failures by class and endpoint, largest first. complete is false while tests are still running. An unknown entry may carry aiDiagnosis (an AI suggestion: cause, category, confidence, evidence, nextSteps; or { skipped } saying why there is none) and aiDiagnosisPending: true while it is being made, and aiFeedback (helpful, wrong, and the caller’s own vote as mine); an unknown group may carry aiCause, never from a suggestion more people marked wrong than helpful. Neither changes class. What the MCP tool investigate_failures returns.
GET /api/releases/:release/report CI. The release evidence report. ?environment=Staging (name or id) narrows it to one environment. recommendation: decision (go, go-with-risks, no-go, insufficient), label, headline, blockers, risks. suites: the latest run of each suite and environment, with attempts, passedOnRerun and previousRelease. failures: each failing test with change (regression, new, known) and its class. fixed, notRun, causes, totals, previousRelease. complete is false while a run is in progress. A release nothing ran against answers 200 with insufficient. What the MCP tool release_report returns.
GET /api/executions/:id/report.junit.xml CI. The suite run as JUnit XML. 409 while it is still running.
GET /api/executions/:id/export.json CI. The suite run and every run it started, in the export envelope (autotestx.execution/1). 409 while running.
GET /api/releases/:release/export.json CI. The release evidence report in the export envelope (autotestx.release-report/1). ?environment= as above.
GET /api/runs/:id/report.pdf CI. The run report as a PDF, every step with its screenshot. ?tz= for the times. 409 while running.
GET /api/executions/:id/report.pdf CI. The suite run report as a PDF. 409 while running.
GET /api/releases/:release/report.pdf CI. The release evidence report as a PDF. ?environment= as above.
PUT /api/environments/:ref/deployed CI (Run tests tokens). Record what was deployed to the environment (:ref is its id or name). Body: a deployment object with at least release or commit. Suite runs there that send no deployment are labelled with it and carry deploymentFrom: { source: "environment", deployedAt }. A POST /api/executions from a pipeline token with deployment and an environment records it too. → 200 { environmentId, deployed }
DELETE /api/environments/:ref/deployed CI (Run tests tokens). Forget it. → 200 { environmentId, deployed: null }
POST /api/executions/:id/cancel CI (Run tests tokens). Cancel tests not yet started; running ones finish, then the run ends cancelled. 409 once finished. Send Content-Type: application/json with an empty {} body: every POST must be JSON, or it is refused with 403.

Start body

Field Required Meaning
suite yes The suite’s name. Case and extra spaces do not matter.
environment / environmentId no The environment by name ("staging") or id. Without one, tests run with no environment.
scope no "all" (default) or "ready": Ready tests only, the others listed as skipped.
deployment no The deploy being tested: { release?, source?, commit?, branch?, deployId?, url?, note? } (build is accepted for deployId). Short text (300 characters each); url must be http(s). Shown on the suite run and in failure emails, and release and commit can filter GET /api/executions; otherwise never interpreted.

The result. status is running until every test has settled, then passed, failed, error or cancelled. A failure outranks an error, and a suite where nothing ran is an error. counts has total, passed, failed, error, skipped, cancelled; each entry in children has testName, status, runId (open it with GET /api/runs/:id) and, when it did not run, a reason.

Waiting. Rather than polling every few seconds, a pipeline can call GET /api/executions/:id?wait=60 in a loop: each call returns as soon as the suite finishes, or after 60 seconds with status: "running".

Limits. One API token may have 5 suite runs in progress at once (ATX_MAX_RUNNING_PER_TOKEN). One more answers 429 with code: "too_many_running". How many tests run at the same time is set by the organization’s plan.

Refusal Status code
No suite, bad scope, bad deployment 400
Viewer token or role without Run tests 403
Unknown suite, suite with no shared tests, unknown environment 404
Too many suite runs in progress for this token 429 too_many_running
Method Path Notes
POST /api/mcp CI (any token). The MCP endpoint: Streamable HTTP, stateless, JSON responses. Tools list_suites, run_suite, get_result, explain_failure, investigate_failures, release_report, component_maintenance. Requires Authorization: Bearer atx_pat_…; a browser session gets 401.
GET, DELETE /api/mcp 405: no event stream and no sessions to end

The tools call the endpoints above with the same token, so a token’s role limits an assistant exactly as it limits a pipeline. Suite runs an assistant starts have trigger: "mcp".

Who the project emails about suite runs a deploy pipeline started, and about self-healing fixes awaiting review. See Notifications.

Method Path Notes
GET /api/notifications { pipeline, healReview, healDigestMinutes }. Each list is { people: [{ id, name }], isDefault }: isDefault is true when no list was set and the role-based default applies.
PUT /api/notifications { pipeline?: string[] | null, healReview?: string[] | null }: member ids, [] for nobody, null to go back to the default. Admin / Test Manager (Manage scheduled runs). 422 unknown_member if anyone is not in the project; nothing is saved then.
Method Path Notes
GET /api/healing Suggestions in the project, newest first, with counts per status. Filters: ?status=pending|approved|rejected|stale|superseded|reverted, ?testId=, ?auto=1 (only what a rule decided). Each has can.review and can.revert; one a rule decided also has autoApplied, ruleId, ruleVersion, ruleName and auto (the outcome and its reasons). base is the revision its run executed: { of: 'test'|'component', version, updatedAt?, stepHash, step? } (version: null for content never saved; absent on older suggestions). A pending one also has owner, the test or component as it is now: { of, version, updatedAt?, by?, tag, check }, where check is current, rebased (written since, this step unchanged) or conflict (this step edited around its locator since; owner.step is then the step as it is now).
POST /api/healing/:id/approve { target?, note?, acceptConflict?, confirmEditing? }, optional If-Match: "<owner.tag>". Applies the proposal, or target when given, to the test as it is at that moment. Returns { suggestion, result, versions, check, sourceTest? }. 409 when the step’s target changed since (the suggestion becomes stale) or it is no longer pending. 409 heal-conflict when the step was edited around its locator since the run: nothing is written, the suggestion stays pending, and view holds { found, now, proposed, owner }. Send acceptConflict: true with the If-Match you were shown to apply it anyway; if the step changed again, the answer is a fresh 409. Without If-Match, acceptConflict takes the conflict as it stands. 409 being-edited (with editing: { userName, since, lastEditAt }) when someone else holds the test’s edit lock; send confirmEditing: true to go ahead.
POST /api/healing/:id/reject { note? }. The same proposal is not suggested again for that step.
POST /api/healing/:id/revert { note?, pauseRule? }. Puts back the target an applied fix replaced, as a new revision, and sets the suggestion to reverted (it is not suggested again). For a rule’s fix it also pauses that rule for that step unless pauseRule: false; the response then includes pausedRule. 409 when the suggestion is not approved, or the step has changed since the fix. 422 when pauseRule is not a boolean.
GET /api/healing/breakers Rules paused for a test: cause is broke (a fix failed again; paused for the test) or reverted (paused for one step). Returns { breakers, canReset }.
DELETE /api/healing/breakers/:id Lifts a pause, so the rule may fix that test or step again

Approving, rejecting and reverting need the Approve or reject self-healing suggestions permission (tests.heal), and a fix inside a component also components.manage.

When the rules act. After a run finishes, the server stores the result (GET /api/runs/:id then answers 200), files its suggestions, and only then runs the project’s rules. The run.finished event is sent after all three. A client that needs to see what the rules did should wait for run.finished, or poll the audit trail, not the run.

Method Path Notes
GET /api/healing/rules { rules, canManage }, in priority order
POST /api/healing/rules Creates a rule (below). 201 { rule } with version: 1.
PUT /api/healing/rules/:id Replaces a rule’s fields; version goes up by one. Send the version you edited to make the write conditional: 409 (version-conflict) if someone else saved first.
DELETE /api/healing/rules/:id ?version= optional, as for PUT. Fixes the rule already made stay.
GET /api/healing/rules/:id/history Every version of the rule, deleted ones included
POST /api/healing/rules/preview { rule?, days? }. What the saved rules (and the unsaved draft rule, if given; with its id it stands in for that saved rule) would have done to the last days (default 30, up to 365) days of suggestions. Read-only.
GET /api/healing/limit The daily limit on automatic fixes this project’s runs use: limit, source (system, organization or project), capped, the organization’s default and maximum, and whether the caller may change it
PUT /api/healing/limit { dailyFixLimit }: the project’s own limit, 0 to the organization’s maximum; null goes back to the organization’s default. Needs healing.rules.manage
GET /api/orgs/:id/healing The organization’s default and maximum, and each project’s limit
PUT /api/orgs/:id/healing { dailyFixLimit?, maxDailyFixLimit? }, 0 to 50, default not above maximum; a field left out goes back to the system value. Organization administrators only
GET /api/ai/diagnosis The project’s AI diagnosis of unclassified failures: enabled, dailyLimit, source (system, organization or project), text, orgAllows, and whether the caller may change it (canManage) or use Diagnose with AI (canDiagnose)
PUT /api/ai/diagnosis { diagnoseUnclassified?, diagnosisDailyLimit? }: on or off, and new diagnoses a day, 0 to 100; null goes back to the default (off, 20). Needs ai.diagnosis.manage; refused while the organization has it off
POST /api/runs/:id/diagnosis Token. Diagnose with AI: one Unclassified run, charged to the caller. Needs tests.ai. → 200 the suggestion, or { skipped } saying why there is none; 422 for a run the rules classified; 403 while the organization has it off; 429 when the AI allowance is used up; 503 when the AI service is not connected
POST /api/runs/:id/diagnosis/feedback Token. { vote }: helpful, wrong, or null to take the caller’s vote back. One vote per person; wrong also stops the answer being reused for failures that look the same. Needs tests.run. → { helpful, wrong, mine? }; 422 when the run has no AI suggestion
GET /api/ai/diagnosis/causes ?days=30 (1 to 90). The project’s Unclassified failures in the period: unclassified, diagnosed, notDiagnosed by reason (pending when none was recorded), rejected, withoutRule, votes, and rules: each suggested rule with category, failures, answers, tests, causes, helpful, wrong and lastSeen, most failures first. Rejected suggestions are never listed. Needs ai.diagnosis.manage
GET /api/orgs/:id/ai Whether the organization’s projects may diagnose with AI (allowed), and each project’s setting
PUT /api/orgs/:id/ai { runDiagnosis }: allowed or off. Organization administrators only
{
"name": "Trust strong click fixes",
"enabled": true,
"priority": 100,
"scope": { "allTests": false, "testIds": [], "tags": ["smoke"], "suites": [], "componentIds": [] },
"conditions": {
"maxTier": 1,
"minConfidence": 0.85,
"minMargin": 0.15,
"allowedRisk": ["low"],
"stepTypes": ["click"],
"minOccurrences": 2,
"decisionWas": "applied"
},
"action": "auto-approve",
"mode": "dry-run",
"readyTests": "draft"
}

action is auto-approve, require-review or auto-reject; mode is active or dry-run; readyTests is draft (default) or keep-ready. minMargin and decisionWas are optional. Defaults: priority 100, maxTier 1, allowedRisk ["low"], minOccurrences 1, mode active.

A rule is refused with 422 when it is malformed, names a test or component the caller cannot see, or, for auto-approve, crosses a guardrail: high in allowedRisk, maxTier 2, or minConfidence below the runner’s own threshold for the risks it allows (0.70 low, 0.78 medium). See Limits no rule can lift.

Reading rules and previewing is open to every member. Creating, changing and deleting rules, and lifting a pause, need Manage self-healing rules (healing.rules.manage).

Method Path Notes
GET /api/healing/audit Entries, newest first, paged: { entries, total, nextOffset? }. Filters: ?testId=, ?actor= (a person’s name or user id, rule:<id> for every version of a rule, rule:<id>@v2 for one), ?event= (comma-separated names, or a family such as auto), ?from= / ?to= (ISO time or YYYY-MM-DD, inclusive), ?limit= (default 50, max 500), ?offset=.
GET /api/healing/audit/export.csv The same filters, as CSV
GET /api/healing/audit/verify Walks the project’s hash chain: { ok: true, entries }, or { ok: false, entries, brokenAt, why } with the 1-based number of the first entry that does not fit

Events: suggestion.created, suggestion.updated, rule.evaluated, auto.applied, auto.rejected, auto.skipped, manual.approved, manual.rejected, heal.reverted, rule.created, rule.updated, rule.deleted. Entries about a suggestion carry its base (the revision its run executed); manual.approved and auto.applied also carry check (current, rebased, or conflict when a person took a fix for a changed step) next to versions. An auto.skipped entry with reason: 'conflict' is a fix a rule held back because the step was edited around its locator. Every member can read the trail, minus entries about other people’s private tests. See Self-healing audit trail.

Method Path Notes
GET / POST /api/environments CI (GET only). List; create or update ({ id?, name, variables, secrets, applicationId? })
DELETE /api/environments/:id
GET / POST /api/secrets Secret inventory; set a secret: { environmentId, name, value }
GET / POST /api/applications List; create or update
DELETE /api/applications/:id

Secret values are write-only: no endpoint returns them.

Method Path Notes
GET / POST /api/suites CI (GET only). List; add
PUT / DELETE /api/suites/:name Rename (moves its tests); delete (only when empty)
GET / POST /api/components List; create from a source test
GET / PUT / DELETE /api/components/:id Detail with versions and usages; update name/description; delete
POST /api/components/:id/versions Publish a new version
GET /api/components/:id/versions/:version One version
GET /api/components/:id/impact What upgrading each caller would change
POST /api/components/:id/upgrade Upgrade chosen callers
GET /api/component-maintenance CI. The maintenance queue: findings most urgent first, each with kind, priority (0–100), summary, recommendation { action, text }, the visible tests and a hiddenTests count
GET / POST /api/test-data Data sets: list; create or update
GET / DELETE /api/test-data/:id
GET / POST /api/data-pools Pools: list; create or update
GET / DELETE /api/data-pools/:id
POST /api/data-pools/:id/reset Release leases or restore consumed records
Method Path Notes
POST /api/record/start Start a recording session
GET /api/record/:id Captured steps so far
POST /api/record/:id/stop Stop
GET /api/record/:id/preview Screenshot where recording ended
POST /api/pick/start, /api/pick/:id/mode, /api/pick/:id/close Element picker session
GET /api/pick/:id Picked element and its locators
POST /api/language/generate { text, testId?, environmentId? } → draft steps (needs ANTHROPIC_API_KEY)
GET / POST / DELETE /api/language/examples The project’s learned examples
Method Path Notes
GET /api/tokens The selected project’s tokens (never their values) and allowance: { used, limit } for the organization. Admin / Test Manager.
POST /api/tokens { name, role: "tester" | "viewer", expiresInDays?: 1-365 | null } → 201 { value, token }. The only response that contains value.
DELETE /api/tokens/:id Revoke at once
GET /api/tokens/self CI. The calling token and its project, for a pipeline’s first step
Method Path Notes
GET / POST /api/members Sign-in accounts (platform administrators)
DELETE /api/members/:id
POST /api/orgs Create an organization
PUT / DELETE /api/orgs/:id Rename / delete
GET / POST /api/orgs/:id/members List / invite
PUT / DELETE /api/orgs/:id/members/:userId Change organization role / remove
GET / POST /api/orgs/:id/projects List / create projects
PUT / DELETE /api/projects/:id Rename / delete a project
GET /api/projects/:id/members Project members
PUT / DELETE /api/projects/:id/members/:userId Set / remove a project role
GET / POST /api/settings The project’s suite list: { modules: [...] }
Method Path Notes
GET /api/agent Your paired computers and whether an agent is needed
DELETE /api/agent/:id Disconnect a computer
GET /api/agent/download The Windows agent installer
GET /api/agent/install-mac.sh The Mac install script (no sign-in: Terminal fetches it with curl)
GET /api/agent/download/mac-:arch The Mac agent for arm64 or x64 (no sign-in)
GET / POST /api/agent/pair/:code Pairing approval
WebSocket /api/agent/connect The agent’s own connection (authenticated in its first message)
  • Every route requires a session unless it is explicitly public. The check is central, so a new route cannot accidentally be left open.
  • A record from another project is refused even with a valid id, and the attempt is written to the audit log (audit.log in the data folder).
  • Passwords are stored as scrypt hashes; session, reset and API tokens only as SHA-256 digests.
  • API tokens reach only endpoints explicitly opened to them, by the same central check: a new endpoint is closed to CI until it is marked otherwise.