Quickstart
Add a resource, create an assistant and ask a first question, in the Lookio app and then over the REST API with curl.
You need a Lookio account. A new workspace comes with free welcome credits, which is enough for the questions below.
Add a resource
Open Resources and choose Add a resource. Pick Text, give it a title such as “Refund policy”, and paste a few paragraphs. Markdown headings (#) become the sections an answer cites.
The resource shows Indexing for a few seconds, then Ready.
Create an assistant
Open Assistants and choose Create an assistant. Name it, then open it and choose what it answers from: all resources, the ones you pick, or a tag. In the first case there is nothing else to set.
Ask a question
Open Chat, pick the assistant and ask something your text answers. The answer cites its sources as [1], [2]. Open a citation to read the passage it relies on.
The API answers at https://api.lookio.app/v1. Every call needs an API key. See Authentication for the details.
Create an API key
In the app, open Developer tools, then the API tab, and choose Create key. Pick the Editor preset: it can read, add and update resources and assistants, and ask questions. Copy the key now. Lookio shows it once.
export LOOKIO_API_KEY="sk_live_..."Check the key
curl https://api.lookio.app/v1/account \
-H "Authorization: Bearer $LOOKIO_API_KEY"The response lists the scopes this key holds.
Add a text
curl https://api.lookio.app/v1/resources \
-H "Authorization: Bearer $LOOKIO_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"type": "text",
"title": "Refund policy",
"text": "# Refunds\n\nYou can return any item within 30 days for a full refund."
}'The resource comes back with status set to queued. Note its data.id.
Wait until it is ready
curl https://api.lookio.app/v1/resources/RESOURCE_ID \
-H "Authorization: Bearer $LOOKIO_API_KEY"Repeat until data.status is ready. If it is failed, read data.status_detail.
Create an assistant
curl https://api.lookio.app/v1/assistants \
-H "Authorization: Bearer $LOOKIO_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "Support",
"context": "You are the support assistant of Acme. You answer customers who want a quick, accurate reply.",
"resource_ids": ["RESOURCE_ID"]
}'Note the assistant’s data.id.
Ask a question
curl https://api.lookio.app/v1/assistants/ASSISTANT_ID/query \
-H "Authorization: Bearer $LOOKIO_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: $(uuidgen)" \
-d '{ "question": "How long do I have to return an item?" }'data.answer holds the answer, data.citations the passages behind it, and data.credit_cost what it cost. The default mode is Flash, 30 credits.
Next steps
- Core concepts: the vocabulary, the four query modes and how credits work.
- Resources: what Lookio can read and how long it takes.
- Streaming: show an answer as it is written.
- Connect an AI client: let Claude or Cursor use your workspace.