Skip to main content

Get template queries list

Description

Retrieves template queries list.

Request URL

Method: POST

https://example.com/api/v1.1/datatables/query_templates/list

Request parameters

ParameterTypeExampleRequiredDescription
tokenstring"abcdefghijklmnqrstuvwxyz"YesAPI token
formatstring"json"NoResponse data format.
By default – json
from_idint1NoFirst campaign in the list ID.
By default – 1
groups[]String[ "group1", "group2" ]NoList of access groups
groups_id[]int[ 0, 1 ]NoList of access groups IDs

Request example

{
"token": "abcdefghijklmnqrstuvwxyz"
}

Response example

{
"data": {
"id": 2,
"name": "QueryforextDB",
"shortname": "query",
"description": "External DB segment",
"sql": "SELECT * FROM table",
"connector_id": 1
},
"error": 0,
"error_text": "Successful operation",
}

Response parameters

ParameterTypeDescription
errorintError code
error_textstringError text
idintQuery ID
namestringQuery name
shortnamestringQuery shortname
descriptionstringQuery description
connector_idintExternal DB ID
sqlstringSQL query
groups_id[]intList of group IDs to search for
default – []