Skip to main content
POST

Authorizations

Authorization
string
header
required

Your API key (ta_live_…) from Settings → API keys, sent as Authorization: Bearer <key>. Keep it on a server: it can message every customer you have. A key is full, build or read-only; a request its level does not allow is refused with 403.

Headers

Thinnest-Workspace
string

Developers only: the customer workspace this request acts in — its org_… id from POST /customers. Leave it out to act in your own workspace.

Example:

"org_3fKq9TzQ1mN8vB2xR7cLpA"

Path Parameters

id
string
required

The agent's id (ag_…).

Body

application/json

Send url, or text with an optional title — not both.

url
string<uri>

A web page to fetch and index. Must start with http:// or https://.

text
string

Text to index, up to 200,000 characters. Trimmed.

Maximum string length: 200000
title
string

A title for text; cut to 200 characters. Left out, it is Pasted text. Ignored with url, whose title comes from the page.

Maximum string length: 200

Response

The document, indexed and ready to cite.

The document just added, with how many passages were indexed from it.

id
string
required

The document's id.

title
string
required

Its title: the one you sent, the page's own, or Pasted text.

type
enum<string>
required

Where it came from.

Available options:
url,
text
source
string
required

The address for a url, pasted for text.

status
enum<string>
required

Always ready on success.

Available options:
ready
error
null
required

Always null on success.

createdAt
string<date-time>
required

When it was added.

passages
integer
required

How many passages were indexed.

Required range: x >= 1