Skip to main content
POST
Run a SQL statement, streamed

Authorizations

Authorization
string
header
required

Organization API key (sl_…).

Headers

x-tenant-id
string
required

The organization ID the request is scoped to.

Body

application/json

A SQL statement to run on a connection, saving nothing.

sql
string
required

The statement to run, in the form a custom SQL section's custom_sql_query takes. References to the previous run render empty.

Minimum string length: 1
connection_id
string | null

The connection to run the statement on, as connection_id on /v2/snowflake-accounts and /v2/databricks-connections. Required unless snowflake_account_id names the account.

snowflake_account_id
string | null
deprecated

Deprecated: send connection_id instead. The Snowflake account to run the statement against. When both are sent they must name the same connection.

Response

A stream of Server-Sent Events.

The statement is still running in Snowflake.

elapsed
string<duration>
required

How long the statement has run so far.

event
string
default:running
Allowed value: "running"