Automation
REST API
Endpoints, authentication, errors, idempotency and waiting.
All documentation
The REST API is versioned under https://abackinspect.com/api/v1 and described by an OpenAPI 3.1 document at /api/v1/openapi.json. It is part of the Pro and Team plans.
Authentication
Send an API key as Authorization: Bearer aik_.... Keys belong to a workspace and carry scopes: read, run and write. A request outside a key's scopes answers 403 with INSUFFICIENT_SCOPE.
Common endpoints
| Request | Purpose |
|---|---|
GET /projects | Projects with environments and test health |
POST /projects/:id/tests | Create a test from a definition |
POST /tests/validate | Validate a definition without saving |
PATCH /tests/:id | Update a test; a changed definition creates a version |
POST /tests/:id/runs?wait=120 | Run one test, optionally waiting for the result |
POST /projects/:id/runs?wait=300 | Run all enabled tests, a tag, or a list of tests |
GET /runs/:id | A run with steps, logs and artifacts |
GET /runs/:id/status | A run's status only, for polling |
POST /runs/:id/cancel | Cancel a queued or running run |
GET /batches/:id/junit | JUnit XML for a suite run |
GET /artifacts/:id | A screenshot, diff or trace |
GET /usage | Runs used this month and plan limits |
Starting runs
{
"environmentId": "env_...",
"baseUrl": "https://pr-12.preview.example.com",
"label": "PR 12",
"metadata": {
"commit": "9f2c1e7",
"branch": "feature/reset",
"pullRequest": "12",
"source": "github-actions"
}
}environmentIddefaults to the project's default environment.baseUrlmust be on a host in that environment's allow list.?wait=Nholds the response up to N seconds (at most 300) until the runs finish.Idempotency-Key(up to 100 characters) makes a retried request return the original runs with status 200.
Errors
Errors have a stable code, a message and a request id:
{
"error": {
"code": "QUOTA_EXCEEDED",
"message": "This workspace has used 3000 of 3000 runs this month. Usage resets on 01 Dec 2026.",
"requestId": "req_..."
}
}Codes include VALIDATION_ERROR, TEST_DEFINITION_INVALID, TARGET_NOT_ALLOWED, UNSAFE_TARGET, QUOTA_EXCEEDED, RATE_LIMITED, BILLING_REQUIRED, NOT_FOUND and FORBIDDEN. Identifiers from another workspace answer 404.
Rate limits
About 120 requests a minute per key and 30 run requests a minute per workspace. A limited request answers 429 with a retry-after header. Pagination uses nextCursor from list responses.