List the output columns of a query

List the output columns of a query#

Description#

List the output columns of a query, including the column name (or alias), catalog, schema, table, type, type size in bytes, and a boolean indicating if the column is aliased.

POST /api/v1/query/{queryId}/describe

Required OAuth Scopes

No OAuth scopes are required to use this endpoint.

Parameters#

Parameter

In

Type

Required

Description

queryId

path

string

true

The unique identifier of the query

Code Samples#

curl -X POST https://h.app.wdesk.com/s/wdata/prep/api/v1/query/{queryId}/describe \
    -H 'Accept: application/json' \
    -H 'Authorization: Bearer {access-token}'
http POST https://h.app.wdesk.com/s/wdata/prep/api/v1/query/{queryId}/describe \
    Accept:application/json \
    Authorization:"Bearer {access-token}"
wget --method=POST "https://h.app.wdesk.com/s/wdata/prep/api/v1/query/{queryId}/describe" \
    --output-document -  \ 
    --header 'Accept: application/json' \ 
    --header 'Authorization: Bearer {access-token}'
import requests

headers = {
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.post('https://h.app.wdesk.com/s/wdata/prep/api/v1/query/{queryId}/describe', headers = headers)

print(r.json())

Returns#

200 - OK#

undefined

Example Responses#

{
  "body": {
    "columns": [
      {
        "catalog": "string",
        "catalogColumnName": "string",
        "name": "string",
        "schema": "string",
        "table": "string",
        "type": "string"
      }
    ]
  },
  "code": "integer"
}