Browse docs

Make requests to the API

How to call the Telltail REST API once you have a token: the address, the header, how lists page, what errors look like, and the limits.

The basics

  • Address. Every route is under https://app.telltailhq.com/api/v1.
  • Token. Send Authorization: Bearer followed by a personal access token (tt_pat_…) or an app’s access token (tt_at_…).
  • Format. Answers are JSON. The few routes that take a body take JSON too.
curl "https://app.telltailhq.com/api/v1/customers?q=rivera&limit=10" \
  -H "Authorization: Bearer tt_pat_your_token"

Find the route you need

The API reference lists every route a token can call, with its parameters. /api/v1/spec.json is the same list as an OpenAPI document, for tools that generate a client. The reference describes what you send. To see what a route answers, call the route.

Lists

A list takes limit, and answers its rows with the total and the address of the next page:

{
  "rows": [ { "id": "CU_…", "firstName": "Ana", … } ],
  "total": 412,
  "limit": 10,
  "next": "https://app.telltailhq.com/api/v1/customers?limit=10&cursor=…"
}

Request next as it is for the next page, and stop when next is null. The same address is in the Link header, as rel="next". This loop reads every customer:

url="https://app.telltailhq.com/api/v1/customers?limit=200"
while [ "$url" != "null" ]; do
  page=$(curl -s "$url" -H "Authorization: Bearer tt_pat_your_token")
  echo "$page" | jq -c '.rows[]'
  url=$(echo "$page" | jq -r '.next')
done

The cursor inside next belongs to that request: a cursor sent with another filter, another sort or another route answers 400. To change a filter or the sort, start again without a cursor. limit can change between pages. Lists don’t take an offset.

Many lists also take q to search, and sort with dir. A few feeds page another way, with page or before; the reference shows which parameters each route takes.

What the values mean

  • Ids are opaque strings with a prefix, such as CU_… for a customer and SA_… for a sale. Pass them back as they are.
  • Money is a whole number of the currency’s smallest unit: 12995 is $129.95 in a shop that uses dollars. The shop’s currency is on GET /company.
  • Times are ISO 8601 in UTC, such as 2026-11-20T18:42:35.790Z.
  • Days, such as a report’s from and to, are YYYY-MM-DD and mean the shop’s own calendar day. The shop’s time zone is on GET /company.

Errors

An error answers JSON. Read its code, status and message:

{ "defined": false, "code": "NOT_FOUND", "status": 404, "message": "Sale not found" }
401
No token, or one that is expired, revoked or no longer allowed. Get a new token.
403, This connection is read-only.
The route writes. Tokens can only read.
403, Missing permission: …
The person the token belongs to doesn’t have that permission in the shop.
404
No such record in this shop, or no such route.
429
Too many requests. Wait the number of seconds in the Retry-After header.

Limits

A personal access token may make 120 requests a minute, and so may each person’s connection to an app. Past that, requests answer 429 with a Retry-After header until the minute is up.

Reports

Reports run through the API too, for a person with the Run shop reports permission. POST /reports/run takes the report’s name and its parameters:

curl https://app.telltailhq.com/api/v1/reports/run \
  -H "Authorization: Bearer tt_pat_your_token" \
  -H "Content-Type: application/json" \
  -d '{"report":"sales.summary","params":{"from":"2026-11-01","to":"2026-11-07"}}'

Q&A

Which shop does a request read?

The one the token was made for. A token never reaches a second shop.

Can an AI assistant use the same token?

Yes. The same token works on the MCP server at https://app.telltailhq.com/mcp. See Ask Claude about your shop.

NextExamples: what to build with the API