Retrieve query column data#
Description#
Returns a QueryColumnDataDto representing the column data for the given query text. If the query isn’t valid, returns a 400.
POST /api/v1/query/data
Required OAuth Scopes
No OAuth scopes are required to use this endpoint.
Parameters#
Parameter |
In |
Type |
Required |
Description |
|---|---|---|---|---|
body |
body |
true |
The query text to parse, up to 30000 characters; must not be null or empty |
Body parameter example#
{
"queryText": "string"
}
Code Samples#
curl -X POST https://h.app.wdesk.com/s/wdata/prep/api/v1/query/data \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer {access-token}'
http POST https://h.app.wdesk.com/s/wdata/prep/api/v1/query/data \
Content-Type:application/json \
Accept:application/json \
Authorization:"Bearer {access-token}"
wget --method=POST "https://h.app.wdesk.com/s/wdata/prep/api/v1/query/data" \
--output-document - \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--header 'Authorization: Bearer {access-token}'
import requests
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json',
'Authorization': 'Bearer {access-token}'
}
r = requests.post('https://h.app.wdesk.com/s/wdata/prep/api/v1/query/data', headers = headers)
print(r.json())
Returns#
200 - OK#
Returns a JSON object with a body property, which contains a QueryColumnDataDto object for the given query text.
Example Responses#
{
"body": {
"columns": [
{
"alias": "string",
"description": "string",
"metadata": {},
"mode": "string",
"name": "string",
"type": "string"
}
]
},
"code": "integer"
}