> ## Documentation Index
> Fetch the complete documentation index at: https://docs.lusor.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# API reference

> Every Lusor API endpoint, with an interactive playground.

The reference is generated from the Lusor OpenAPI specification. You can download it as [openapi.yaml](https://docs.lusor.ai/api-reference/openapi.yaml).

## Base URL

```
https://api.lusor.ai
```

## Authentication

Send your API key in the `X-Api-Key` header, or as `Authorization: Bearer lusor_...`. See [Authentication](https://docs.lusor.ai/authentication.md).

To try an endpoint in the playground, paste your key into its authorization field. Requests from the playground act on your real workspace and phones. Direct-control requests on a Lusor Phone use Lusor Phone minutes.

## Errors

Errors are JSON:

```json theme={null}
{ "error": "not_found", "message": "Agent '…' not found" }
```

A request that fails validation returns `400` in one of two shapes, depending on the endpoint:

* `{ "error": "validation_error", "details": { … } }`, with per-field details. Direct phone control actions, for example, use this shape.
* `{ "error": "bad_request", "message": "…" }`, with one message. Agent endpoints, for example, use this shape: a turn with an empty `prompt` returns it.

Handle both: branch on `error`, then read `details` or `message`. A resource in another workspace returns the same `404` as one that does not exist.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.