Query

Get a query result by ID

Changed on

Retrieve a stored query run by its ID, including its result rows. Results larger than the inline storage cap are replayed truncated (truncated: true).

get/query/{id}

Request

  • Base URL
    https://api.cloudglue.dev/v1
  • Auth
    HTTP bearer

Path parameters

idstring uuid required

The ID of the query result to retrieve

Response

Query result details

idstring uuid

Query result ID

object'query_result'

Object type identifier

status'completed' | 'failed' | 'in_progress' | 'cancelled'

Current status of the query. Synchronous queries return 'completed' or 'failed'.

created_atnumber

Unix timestamp of when the query was created

collectionsstring[]

Collection IDs the query ran over

sqlstring nullable

The effective SQL that was executed (echoes the request's sql)

rowsobject[] nullable

Result rows as objects keyed by column name

row_countinteger

Number of rows returned

truncatedboolean

Whether the result was truncated by max_rows or the stored-result size cap

dry_runboolean

True when the query was only validated/compiled (dry_run request): columns holds the output schema and rows is null.

format'json' | 'csv' | 'jsonl' nullable

The result format ('csv'/'jsonl' for background exports)

download_urlstring nullable

Signed URL to download a completed background export. Valid for 24 hours and not refreshed on read (re-run the export if it expires); null for synchronous runs and until a background export completes

download_expires_atnumber nullable

Unix timestamp (ms) when download_url expires

output_bytesinteger nullable

Compressed size of a completed background export, in bytes

Changes