Docs
  • 0.57.0latest
  • 0.56.0
  • 0.55.0
  • 0.54.0
  • 0.53.0
  • 0.52.1
  • 0.52.0
  • 0.51.0
  • 0.48.0
  • 0.47.0
  • 0.46.0
  • 0.45.0
  • 0.44.0
  • 0.43.0
  • 0.42.0
  • 0.41.0
  • 0.40.0
  • 0.39.6
  • 0.39.5
  • 0.39.3
  • 0.39.2
  • 0.39.1
  • 0.39.0
  • 0.38.4
  • 0.38.2
  • 0.38.1
  • 0.37.1
  • 0.37.0
  • 0.36.2
  • 0.36.1
  • 0.36.0
  • 0.35.3
  • 0.35.2
  • 0.35.1
  • 0.35.0
  • 0.34.4
  • 0.34.3-beta
  • 0.34.2-beta
  • 0.34.1-beta
  • 0.34.0-beta
  • 0.33.4-beta
  • 0.33.3-beta
  • 0.33.2-beta
  • 0.33.1-beta
  • 0.33.0-beta
  • 0.32.0-beta

Records

CRUD over any table plus the list grammar — projections, filters, full text, nearest-vector, geo radius, ordering and cursor paging — every value bound, never spliced into a statement.

A table's records are the surface's core resource:

methodpathanswers
GET/v1/{ns}/{db}/tables/{t}/records{"records": [{"id", …fields}], "after"?: cursor}
POSTsame201 {"record": {…}} — the record as stored, defaults applied
GET…/records/{id}200 {"record": {…}} or 404
PATCH…/records/{id}merge — unnamed fields are kept; 200 {"record"}
PUT…/records/{id}replace — unnamed fields are dropped; 200 {"record"}
DELETE…/records/{id}200 {"deleted": true}

The PATCH/PUT split is the language's own merge-versus-replace rule wearing HTTP verbs. Reach for PATCH when your object is a patch; PUT when it is the whole record — a form that reposts three of a record's five fields with PUT deletes the other two.

A record id is checked as grammar (letters, digits, _ and -); anything else in a body or a query value is bound as a parameter after the statement is read, so a value that looks like syntax stays a string:

curl -H "Authorization: Bearer $TOKEN" \
  'http://127.0.0.1:8000/v1/app/main/tables/orders/records' \
  -X POST -H 'Content-Type: application/json' \
  -d '{"note": "a'"'"'; DROP TABLE orders; --"}'
# stored as one string; nothing runs

The list grammar

GET …/records takes the query as parameters, every value percent-encoded:

  • select=f1,f2 — a projection.
  • where=field:op:value — repeatable, conditions ANDed. Ops: eq ne gt gte lt lte like ilike in null not-null none not-none. A string value is a TessariQL string literal (single quotes, the lexer's escape set); a number is itself.
  • search=field:term — full text over an analysed field; the term is bound.
  • nearest=field:metric:[…] — the exact vector order, metric one of cosine euclidean. Conflicts with order and after (400): a nearest read is already ordered.
  • within=field:lat,lon,radius_m — a geo radius read.
  • order=field.asc / order=field.desc, limit=n (default 100, ceiling 1000), after=<cursor>.
curl -H "Authorization: Bearer $TOKEN" \
  'http://127.0.0.1:8000/v1/app/main/tables/orders/records?where=total:gte:5&where=tenant:eq:'"'"'a'"'"'&order=total.desc&limit=10'

A full page answers an after cursor — the bare id of the last record. Pass it back to continue; a counted offset does not exist here on purpose, because a counted page shifts under a concurrent insert and page 500 would do five hundred pages of work.

An unknown parameter or operator is a 400 naming it and the closed set — the grammar refuses rather than guesses, so a typo'd filter never quietly reads the whole table.

What the answers carry

A create answers the record as stored — defaults filled, server fields minted — so a client never has to guess what landed. Reads run through your session like everything else: a table your grants do not reach is a 404, and a row guard narrows the listing exactly as it narrows a SELECT.