> For the complete documentation index, see [llms.txt](https://help.aximo.autify.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.aximo.autify.com/api-reference-ko/triggers-cases.md).

# Triggers – Cases

Trigger individual test case runs and poll their status.

## Trigger a case run

> Starts a new test session for the specified test case. The case must have\
> \*\*API access enabled\*\* in its settings.\
> \
> Returns a \`sessionId\` — poll \`GET /api/triggers/cases/{caseId}/sessions/{sessionId}\`\
> to track progress.<br>

```json
{"openapi":"3.0.3","info":{"title":"Aximo API","version":"1.0.0"},"tags":[{"name":"Triggers – Cases","description":"Trigger individual test case runs and poll their status."}],"servers":[{"url":"/","description":"Current environment"}],"security":[{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"x-api-key","description":"Organization API key generated from Settings → API Keys."}},"schemas":{"RunRequestError":{"type":"object","required":["error"],"properties":{"error":{"type":"string"},"availableModels":{"type":"array","items":{"type":"string"},"description":"Present when the request was rejected for its `model`: the models this\norganization can run, the same list `GET /api/models` returns.\n"}}},"Error":{"type":"object","required":["error"],"properties":{"error":{"type":"string"}}}},"responses":{"Unauthorized":{"description":"Missing or invalid API key.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"RateLimited":{"description":"Rate limit exceeded — e.g. the daily session limit was reached for the\norganization, or too many API requests were sent in a short window\n(retry after the number of seconds in the `Retry-After` header).\n","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"InternalError":{"description":"Unexpected server error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"paths":{"/api/triggers/cases/{caseId}/run":{"post":{"operationId":"triggerCaseRun","summary":"Trigger a case run","description":"Starts a new test session for the specified test case. The case must have\n**API access enabled** in its settings.\n\nReturns a `sessionId` — poll `GET /api/triggers/cases/{caseId}/sessions/{sessionId}`\nto track progress.\n","tags":["Triggers – Cases"],"parameters":[{"name":"caseId","in":"path","required":true,"schema":{"type":"string","format":"uuid"},"description":"UUID of the test case to run."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","properties":{"model":{"type":"string","enum":["default","haiku","sonnet","kimi","gpt-5.4","gpt-5.4-mini","gpt-5.5","auto"],"description":"Model to use for this run. Call `GET /api/models` for the values your\norganization can run — anything else is rejected with `400`, and the\nerror carries the usable list in `availableModels`. When omitted, the\n`defaultModel` from that endpoint applies.\n"},"hostnameOverrideIds":{"type":"array","items":{"type":"string","format":"uuid"},"description":"IDs of hostname overrides to apply for this run."},"userDeviceId":{"type":"string","format":"uuid","description":"Run on a registered local device (BYOD) from\n`GET /api/devices/user`; overrides the device bound on the\ncase. Desktop cases only — the device must be a desktop\nplatform (`windows`, `macos`, `linux`); phone-platform devices\nfail with `400`, and mobile cases cannot run on local devices\nvia this endpoint (use `POST /api/sessions`). Requires the\nBYOD feature to be enabled for your organization.\n"},"deviceArn":{"type":"string","description":"Encrypted device token from `GET /api/devices` (mobile only)."},"deviceName":{"type":"string","description":"Override the device name (mobile only)."},"platform":{"type":"string","enum":["ANDROID","IOS"],"description":"Override the mobile platform."},"uploadArn":{"type":"string","description":"Encrypted upload token from `GET /api/uploads/{id}` (mobile only)."},"uploadType":{"type":"string","enum":["own_app","existing","sample"],"description":"Override the upload type (mobile only)."},"appName":{"type":"string","description":"Override the app name (mobile only)."},"apps":{"type":"array","maxItems":3,"description":"Up to 3 apps to install for a mobile run. Takes precedence over the\nsingle-app fields (`uploadArn`/`uploadType`/`appName`); the first\nentry is the primary app.\n","items":{"type":"object","required":["uploadArn","uploadType","appName"],"properties":{"uploadArn":{"type":"string","description":"Encrypted upload token from `GET /api/uploads/{id}`."},"uploadType":{"type":"string","enum":["own_app","existing","sample"]},"appName":{"type":"string","nullable":true},"bundleId":{"type":"string"}}}}}}}}},"responses":{"201":{"description":"Case run triggered.","content":{"application/json":{"schema":{"type":"object","required":["success","sessionId"],"properties":{"success":{"type":"boolean"},"sessionId":{"type":"string","format":"uuid"}}}}}},"400":{"description":"Invalid request body — including a `model` this organization cannot run\n(the response then carries `availableModels`).\n","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunRequestError"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"description":"API access is not enabled for this case; a local device (BYOD) was\nrequested — via `userDeviceId` or the device bound on the case — while\nBYOD is not enabled for the organization; the organization has\ninsufficient credits; or the case is multi-device while that feature is\nnot enabled.\n","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Test case or user device not found.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/InternalError"}}}}}}
```

## Get case session status

> Returns the status and result of a session that was triggered for a specific test case.

```json
{"openapi":"3.0.3","info":{"title":"Aximo API","version":"1.0.0"},"tags":[{"name":"Triggers – Cases","description":"Trigger individual test case runs and poll their status."}],"servers":[{"url":"/","description":"Current environment"}],"security":[{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"x-api-key","description":"Organization API key generated from Settings → API Keys."}},"schemas":{"SessionStatus":{"type":"string","enum":["queued","created","preparing","running","succeeded","failed","terminated","error","archived"],"description":"Terminal statuses (stop polling): `succeeded`, `failed`, `terminated`, `error`, `archived`.\n"},"SessionResult":{"type":"string","nullable":true,"enum":["passed","failed","error"]},"Platform":{"type":"string","enum":["desktop","android","ios"]},"Error":{"type":"object","required":["error"],"properties":{"error":{"type":"string"}}}},"responses":{"Unauthorized":{"description":"Missing or invalid API key.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"RateLimited":{"description":"Rate limit exceeded — e.g. the daily session limit was reached for the\norganization, or too many API requests were sent in a short window\n(retry after the number of seconds in the `Retry-After` header).\n","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"InternalError":{"description":"Unexpected server error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"paths":{"/api/triggers/cases/{caseId}/sessions/{sessionId}":{"get":{"operationId":"getCaseSessionStatus","summary":"Get case session status","description":"Returns the status and result of a session that was triggered for a specific test case.","tags":["Triggers – Cases"],"parameters":[{"name":"caseId","in":"path","required":true,"schema":{"type":"string","format":"uuid"},"description":"UUID of the test case."},{"name":"sessionId","in":"path","required":true,"schema":{"type":"string","format":"uuid"},"description":"UUID of the session returned by the trigger endpoint."}],"responses":{"200":{"description":"Session status.","content":{"application/json":{"schema":{"type":"object","required":["id","status","platform","screenshotsCount"],"properties":{"id":{"type":"string","format":"uuid"},"status":{"$ref":"#/components/schemas/SessionStatus"},"result":{"$ref":"#/components/schemas/SessionResult"},"platform":{"$ref":"#/components/schemas/Platform"},"screenshotsCount":{"type":"integer"},"startedAt":{"type":"string","format":"date-time","nullable":true},"completedAt":{"type":"string","format":"date-time","nullable":true},"archivedAt":{"type":"string","format":"date-time","nullable":true,"description":"Set when the result was archived (soft-deleted); archived sessions stay readable here but are hidden from lists."}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"description":"Test case or session not found.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"$ref":"#/components/responses/RateLimited"},"500":{"$ref":"#/components/responses/InternalError"}}}}}}
```
