ReadonlybaseWhere the engine is served, without a trailing slash.
ReadonlytimeoutMilliseconds any single call waits before giving up.
ReadonlyuserSent on every request. The engine's audit log records it.
Read the decisions the engine recently made, newest first.
Not served unless an operator started the engine with -audit-readers
naming who may read it, because the record contains every caller's
activity. An engine with nobody named answers 404 and a caller who is
authenticated but not named gets 403, so handle both: this is one of the
few calls that can fail for reasons that are nothing to do with the
request.
It is a bounded window rather than the whole record. An engine writing an audit file keeps everything there.
Optionaldecision?: AuditDecisionReturn only this decision. refused is the useful one.
Optionallimit?: numberMost recent decisions to return, up to 200.
Return the SQL a request compiles to, without running it.
A dry run is still governed: a request you may not run returns a refusal and no SQL, and the inspection is audited. It is a way to see what a query would do, not a way around the gate.
Whether the last model reload moved a number.
This compares the model being served against the one served before it, which is the comparison nobody can make from outside the process. An engine that has served only one model answers 404 as Refused, because that is a different answer from nothing having changed and only one of them is reassuring.
Dimensions available for grouping and filtering.
Optionalmetric: string
Restrict to dimensions valid for this metric, which is almost always what you want.
Ask the warehouse whether the model is still true.
Everything else validates the model against itself: the YAML parses, the joins resolve, the expressions compile. None of that notices that somebody dropped a column last Tuesday, and the first sign of that is usually a caller getting an error, which is the most expensive place to find it.
Reports rather than refuses, so a rejection here means the check could not
run. Read ok for the verdict and skipped for the case where nothing
could be checked at all.
What the scheduled warehouse check has seen, oldest first.
Drift is found by looking regularly, not by looking once, which is how
"when did this start" stays answerable. An engine started without
-doctor-every has nothing scheduled and answers 404 as Refused.
What you may read of a metric, and why.
Answers "why can I not group by that column" without running a query and being denied. For the calling identity only, which is a security property rather than a limitation: an endpoint that reported another identity's access would publish the policy it was configured to enforce.
The qualified name, as metrics reports it.
What this deployment enforces, including what it does not.
Worth reading before trusting the layer with anything sensitive:
enforcementNotes states the gaps in plain language.
Poll a job and read one page of its rows.
One metric's definition and the dimensions legal for it.
Qualified as namespace.metric, or bare when unambiguous.
The workspace digest currently served.
Every query result carries this too. Two results with the same digest were produced by exactly the same definitions.
The namespaces in the workspace, their owners and availability.
What this engine enforces, and what it does not.
Says nothing about who is allowed what. For that, and only about yourself, use explainPolicy.
Answer a question and return rows.
Use run instead when the warehouse might be slow: this call holds the connection open for the whole query.
Tell the engine to re-read its model source.
Resolves to reading or already running. Both mean the caller got what
they asked for; treating the second as a failure would retry a sync that
is already under way.
It carries no model, deliberately: this means "look now", not "install this". The engine already follows git, so the only thing this changes is the wait. A method that accepted a model would be a second way into production, one that skips the pull request, the checks and the diff that reports which numbers move.
Needs the deploy:model scope, which read:model and run:query never
imply.
Resolving does not mean the new model is serving. A sync is not instant,
and reporting a commit before the swap happened would be a claim a
pipeline then asserts as fact. Poll health and read
origin.commit to know when the new model is the one answering.
An engine reading from a path has nothing to re-read and answers 404. A model that fails to load is not a failure of this call either: the engine keeps serving the previous one and says so in a 502. Both are Refused.
Run a query that may take longer than an HTTP request should.
Submits the query, polls until it finishes, collects every page and returns one result. A large BigQuery scan routinely outlives the default timeout of an agent framework, and a synchronous call that times out leaves the query running and billable with nobody reading it.
The governance gate runs during submission, so a request this identity may not make throws immediately rather than after a wait.
Assert what this model answers.
validate says the model holds together and diff says a number
changed. Neither says a number was ever right.
Check withheld as well as ok. A credential without run:query cannot
cause warehouse execution, so cases that would are withheld and counted
rather than run or silently dropped, and a caller reading only ok would
conclude a suite passed when half of it never ran.
Start a query in the background and return immediately.
The returned job already carries compiledSql, because compilation happened
synchronously. A job coming back at all means the query was authorized, not
merely accepted.
Prefer run unless you need to do something else while it runs.
Poll until a job reaches a terminal state.
Backs off from a fast first poll to a two second ceiling, so a query that finishes quickly is not delayed and a slow one is not hammered.
On expiry the job is cancelled before throwing, so giving up here also stops the warehouse work.
StaticfromBuild a client from environment variables.
Keeps the token out of source and out of the process list, which is where a token passed as a command-line flag ends up.
A connection to one truegrain engine.