API overview
The Lookio REST API at api.lookio.app/v1 lets you add resources, manage assistants and ask questions from your own code, with JSON, scopes and safe retries.
The REST API does everything the app does: add resources, build assistants, ask questions and manage the workspace. The CLI and MCP tools are built on the same service layer, so a rule enforced in the app is enforced here too.
Base URL
https://api.lookio.app/v1Every endpoint lives under /v1. Responses are JSON, except a streamed answer, which is a server-sent event stream.
Start with GET /v1/account
GET /v1/account tells you which workspace a credential belongs to and which scopes it holds. Call it first: it verifies the credential and shows what you can do before you try.
curl https://api.lookio.app/v1/account \
-H "Authorization: Bearer $LOOKIO_API_KEY"What the API covers
| Area | What you do | Reference |
|---|---|---|
| Account and usage | Read the workspace, the credit balance and the usage over time. | Get account |
| Resources | Add texts, files, web pages and sites, read their status, re-index and delete them. | List resources |
| Sites | Preview a site and tune the rules of an imported one. | Preview a site |
| Tags | List, rename and delete tags. | List tags |
| Assistants | Create, change and delete assistants, and ask them questions. | Ask an assistant |
| Conversations | Continue a conversation, list, read, rename and delete yours, and forward your users’ thumbs on an answer. | List conversations |
| Logs | Read the workspace’s four logs: what people asked, every answer and its cost, every indexing, and who changed what. | List the workspace’s conversation logs |
| Widgets | Put an assistant on a website, and read what visitors asked. | List widgets |
| Members | List members and change their permissions. | List members |
| Feedback | Tell Lookio what did not work as expected. | Submit feedback |
The rules in short
- JSON in, JSON out, with
snake_casefield names. See Conventions. - Bearer authentication with an API key or an OAuth token. See Authentication.
- Only asking a question spends credits. The
queryscope gates it. - Every POST accepts an
Idempotency-Key, so a retried request is not run twice. - One error format with stable codes. See Errors.
- Rate limits per credential. See Rate limits.
The machine-readable description
The API is described by an OpenAPI 3.1 document. It is the source of every request and response shape in this reference.
- On this site:
/docs/openapi.json. - Served by the API itself:
https://api.lookio.app/openapi.json. - For AI agents:
https://api.lookio.app/llms.txtand/docs/llms.txt.
Where a guide and the reference disagree, the reference wins.
Other ways in
- The CLI wraps this API for terminals and CI.
- The MCP server lets AI clients call it as tools.
- A TypeScript SDK wraps this API: see SDK.