Data -- Queries

Read Query

Returns a single query by its ID. Includes path and folderId if the query is placed in a folder.

get/data/projects/{projectId}/queries/{queryId}

Request

  • Base URL: https://partner.peaka.studio/api/v1
  • URL: https://partner.peaka.studio/api/v1/data/projects/{projectId}/queries/{queryId}
  • Auth: HTTP bearer

Path parameters

projectIdstring required

ID of the Project

queryIdstring required

ID of the Query

Response

Read Query

idstring

The ID of the query.

displayNamestring

The display name of the query.

namestring

The name of the query used in SQL, e.g. SELECT * FROM "peaka"."query"."<name>". For a MATERIALIZED query the materialized result is queryable as "peaka"."mtquery"."<name>".

inputQuerystring

The SQL query. For a materialized query created from an existing query (via inputQueryRefId), this holds the snapshot of the source query's SQL resolved when the query was created or last updated with the reference.

queryType'PLAIN' | 'MATERIALIZED'

The type of the query.

pathstring nullable

The folder path of the query (e.g. "/analytics/dashboards"). Null if not in any folder.

folderIdstring nullable

The ID of the folder containing this query. Null if not in any folder.

Example response

{
  "schedule": {
    "type": "cron",
    "cronExpression": "0 0 * * *",
    "timezone": "UTC"
  }
}

Changes

No recorded changes to this operation across all 1 revision of this API.