Authentication

The Elai API uses bearer-token authentication.

Every request needs an Authorization header carrying the API token for your workspace:

Authorization: Bearer <API_TOKEN>

Find or generate the token in the Elai app under Settings → API.

A token is scoped to one workspace and authenticates as that workspace's admin user — it is not
tied to an individual person, and it carries admin rights inside that workspace. Rotating it through
POST /generateToken invalidates the previous one immediately.

❗️

A bare 401 has three possible causes

A missing, unknown or revoked token all return 401 with no response body, and so does a
workspace on the Unlimited plan — that plan cannot use the public API at all. Nothing in the
response distinguishes them. If a token you just generated returns 401 on every endpoint, check
the plan before debugging the token.