Skip to main content
GET
A saved query is lake SQL you store on an instance so you can rerun it later. It is not a query run. This endpoint returns one saved query by query_id, including the SQL, how Cloud picks the date range, and the schedule when one is set.

Authorization

Blnk Cloud APIs support any one of the following authentication methods. All of them work with your CLOUD_API_KEY or OAUTH_ACCESS_TOKEN.
Pass Authorization: Bearer CLOUD_API_KEY or Authorization: Bearer OAUTH_ACCESS_TOKEN.
string
required
Cloud API key or OAuth access token. Create credentials in API keys or OAuth.

Path

string
required
Unique id of the saved query (lake_query_...). Get it from List saved queries or Create saved query.

Response

string
Unique id of this saved query (lake_query_...). Pass it as saved_query_id on Create new query.
string
Unique id of the instance (instance_...) this query is bound to.
string
User who created the query. Anyone in the workspace can run it. Only this owner or an admin can update, delete, or schedule it.
string
Label shown in Insights and copied onto query runs that come from this query.
string
Optional note about what the query returns. Empty string when none was set.
string
Read-only DuckDB SELECT or WITH Cloud runs each time you execute this query.
string
How Cloud picks the lake date range when the query runs. fixed uses the stored start_date and end_date. rolling uses the last rolling_days days, resolved at run time.
timestamp
First day of lake history for a fixed query. Omitted when range_mode is rolling.
timestamp
Last day of lake history for a fixed query. Omitted when range_mode is rolling.
integer
Number of days of lake history to open when range_mode is rolling (1 to 3650). 0 when the query is fixed.
object
Cron schedule Cloud uses to run this query automatically. Present only after you set a schedule.
timestamp
When the saved query was first created.
timestamp
When the saved SQL, name, description, or date range was last changed.

Need help?

We are very happy to help you make the most of Blnk, regardless of whether it is your first time or you are switching from another tool. To ask questions or discuss issues, please contact us or join our Discord community.