Skip to main content

Get resource subscription fields

Description

Get information about system and additional subscription fields.

Request URL

Method: POST

https://example.com/api/v1.1/resources/fields_get

Request parameters

ParameterTypeExampleRequiredDescription
tokenstring"abcdefghijklmnqrstuvwxyz"YesAPI token
idint1YesResource ID
channelstring"email"
"sms"
"push"
"telegram_bot"
"whatsapp"
YesResource subscription channel

Request example

{
"id": 1,
"channel": "email",
"token": "abcdefghijklmnqrstuvwxyz"
}

Response example

{
"data": [
{
"category": "custom",
"title": "New_field_1",
"name": "api_new_field_1",
"required": false,
"type": "int"
},
{
"category": "system",
"title": "Device type",
"name": "_device_type",
"required": false,
"type": "unicode",
"dictionary": "devices"
},
{
"category": "system",
"title": "Device model",
"name": "_device_model",
"required": false,
"type": "unicode"
},
{
"category": "system",
"title": "Device name",
"name": "_device_name",
"required": false,
"type": "unicode"
},
{
"category": "system",
"title": "Platform",
"name": "_os",
"required": false,
"type": "unicode",
"dictionary": "oses"
},
{
"category": "system",
"title": "Platform version",
"name": "_os_ver",
"required": false,
"type": "version"
},
{
"category": "system",
"title": "Platform time zone",
"name": "_os_tz",
"required": false,
"type": "unicode",
"dictionary": "tz"
},
{
"category": "system",
"title": "Platform language",
"name": "_os_language",
"required": false,
"type": "unicode",
"dictionary": "languages"
},
{
"category": "system",
"title": "Ad tracking allowed",
"name": "_ad_track",
"required": false,
"type": "bool"
},
{
"category": "system",
"title": "Ad identifier",
"name": "_ad_id",
"required": false,
"type": "unicode"
},
{
"category": "system",
"title": "Application ID",
"name": "_app_id",
"required": false,
"type": "unicode"
},
{
"category": "system",
"title": "Application installation ID",
"name": "_app_iid",
"required": false,
"type": "unicode"
},
{
"category": "system",
"title": "Application version",
"name": "_app_ver",
"required": false,
"type": "version"
},
{
"category": "system",
"title": "Browser",
"name": "_browser_name",
"required": false,
"type": "unicode",
"dictionary": "browsers"
},
{
"category": "system",
"title": "Browser version",
"name": "_browser_ver",
"required": false,
"type": "version"
}
],
"error": 0,
"error_text": "Successful operation"
}

Response parameters

ParameterTypeDescription
errorintError code
error_textstringError text
categorystringSubscription field category

"system","custom"
titlestringUI field name
namestringAPI field name
requiredboolRequired flag (true)
typestringField type
default_value*Field default value if it exists
dictionarystringField name used in the request /v1.1/dictionary (a request to obtain the values of system fields that are displayed in the interface as a drop-down list)

"browsers"
"devices"
"tz"
"oses"
"languages"

Subscription system fields

ParameterTypeExampleDescription
_device_typestring"mob"Device type. Recommended to pass specific values. Get the list of valid values through the request /v1.1/dictionary ("devices").
_device_modelstring"MHA-L29"Device model.
_device_namestring"HUAWEI Mate 9"Device name.
_osstring"Android"Platform's operating system. Recommended to pass specific values. Get the list of valid values through the request /v1.1/dictionary ("oses").
_os_verstring"v11.0"OS version.
_os_tzstring"+0300"Platform time zone. Recommended to pass specific values. Get the list of valid values through the request /v1.1/dictionary ("tz").
_os_languagestring"ru"Platform language. Recommended to pass specific values. Get the list of valid values through the request /v1.1/dictionary ("languages").
_ad_trackbooltrueAd tracking allowed.
_ad_idstring"ad 123"Ad identifier.
_app_idstring"app 123"Application ID.
_app_iidstring"example iid"Installation identifier of the application.
_app_verstring"v1.2.3.4"Application version.
_browser_namestring"Chrome"Browser. Recommended to pass specific values. Get the list of valid values through the request /v1.1/dictionary ("browsers").
_browser_verstring"4.5.6.7.8"Browser version.