Skip to main content
GET
Run a SQL SELECT from DuckDB, result as CSV

Authorizations

Authorization
string
header
required

A Dataville API key, sent as Authorization: Bearer dataville_.... Clients that cannot set headers may pass the same key as ?token=.

Query Parameters

sql
string
required

A single SELECT statement, URL-encoded (max 10,000 characters).

Example:

"SELECT title, url FROM wiki LIMIT 10"

datasets
string

Comma-separated ids of the caller's connected sheets to make available, as datasetIds in POST /api/v1/query.

token
string

API key as a query parameter, for clients that cannot set an Authorization header (DuckDB WASM, the DuckDB CLI). Prefer the header wherever possible — query strings end up in logs.

Response

The query result as CSV with a header row. Same headers as the Parquet form.

The response is of type string.