Skip to main content
POST
Read a sentence into a log search

Authorizations

ankra_session
string
cookie
required

Browser session. Mutations also require X-Ankra-CSRF.

Path Parameters

cluster_id
string<uuid>
required

Body

application/json
sentence
string
required

What the person typed, such as "Checkout requests that failed on Saturday evening". Read as one line: control characters become spaces and runs of whitespace one space, and the length is counted after that.

Required string length: 1 - 200
time_zone
string

The person's time zone by its IANA name, such as Europe/Stockholm, so "Saturday evening" is their Saturday evening. UTC when absent. A name the zone database does not hold is refused with 422.

namespaces
string[]

The application environment's namespaces, as the page's search sends them. They scope the copies the reading may filter on, and are echoed into query.

Maximum array length: 20
source
enum<string>
default:auto

The same source choice as the history query. The store it picks is the one whose fields the reading is checked against, and it is echoed into query.

Available options:
auto,
connected,
ankra_hosted

Response

The search read from the sentence, or the reason it was not read

One press's answer. state read carries the search (read_as, query, filters, words, excluded_words, time, set_aside, every one present); state not_read carries reason and detail and no search at all.

state
enum<string>
required
Available options:
read,
not_read
sentence
string
required

The sentence as it was read.

read_as
string

How the sentence was read, in the page's own words, for "Ankra read that as: ...": the filters as their chips are written, the words and the time, joined by " · ", such as "Level: Error · the words “checkout” · Sat 28 Nov, 18:00 to 22:00". A sentence nothing was found in reads "the words “...”, searched for as they are".

query
object

The search read from the sentence, as the body the log history query takes: send it as it is. A key the reading did not set is absent, so the page keeps its own value for it (its time, when the sentence named none).

filters
object[]

The field filters, as /logs/fields names the fields: level (a level class) or pod (a copy of the application that wrote lines in the last 7 days). not leaves the value's lines out.

words
string

The search words, found as written; empty when the sentence asked for none.

excluded_words
string[]

Words a line must not hold.

time
object | null

The time the sentence named, or null when it named none (or none that could be used) and the page keeps its own.

set_aside
string[]

Each part of the model's answer that was left out, and why, one sentence each: a field these logs do not have, a field the search cannot filter by, a level that is not a class, a copy that wrote no line, a word the person did not write, a time the store no longer keeps.

reason
enum<string>

Why the sentence was not read (state not_read only).

Available options:
ai_paused,
ai_pause_unverified,
billing_restricted,
allowance_exhausted,
allowance_unverified,
spend_cap_reached,
spend_cap_unverified,
ai_unavailable,
model_error
detail
string

The reason as a sentence to show (state not_read only).