Skip to content

Retrieves table data for a user report.

Method getobj.report_table
Description Retrieves table data for a user report.
Who has access Agents and clients
Required components Data API for configuration
Request weight 1 point

Request parameters

Name Type Required Valid values Description
access_token string yes Authentication session key
user_id number no Unique user identifier of the agent client on behalf of which the request is made (Is required for the agent) To obtain a list of client users, you must use the method "get.customer_users"
limit number yes You cannot request more than 200 lines. Number of records to return. Default 50.
offset number yes Shift - determines from which record number to return limit records. Default 0.
report_type enum yes call_summary_uis summary_analytics User report type. Currently only works for report type call_summary_uis and summary_analytics. To get a list of user reports, you must use the "get.reports_list"
date_from iso8601 yes YYYY-MM-DD hh:mm:ss Start date and time of the reporting period. Maximum range: 366 days.
date_till iso8601 yes YYYY-MM-DD hh:mm:ss End date and time of the reporting period.
dimensions array yes Comma-separated list of dimension IDs. To retrieve available dimensions, use getobj.dimensions_tree. Their order determines the hierarchy of the returned tree.
columns array yes Comma-separated list of column IDs. To retrieve available columns, use getobj.columns_tree. Their order determines the order of fields in the response.
Filters used in the report
filters array yes An expression can contain both simple filters and a filter tree.
field string Field to filter by. The supported fields are predefined for this method.
operator enum Filtering operator. A list of all operators can be obtained in the section "Filtering operators"
value string Value for the filtering operator. Optional field; if it is missing, it is considered empty.
Filters applied to columns
filters array yes An expression can contain both simple filters and a filter tree.
field string Field to filter by. The supported fields are predefined for this method.
operator enum Filtering operator. A list of all operators can be obtained in the section "Filtering operators"
value string Value for the filtering operator. Optional field; if it is missing, it is considered empty.
Sorting used in the report
sort array no The sorting used in the report. The logic of construction is similar to "Sorting data"
Row expansion
parent_dimensions_value_ids array no ["N","M"] Select a report line for further expansion. Consists of a sequential list of dimension row identifiers. If not specified, level 1 is returned.

Response parameters

Name Type Valid values Filtering Sorting Default response Description
date_from iso8601 YYYY-MM-DD hh:mm:ss yes yes Start date and time of the reporting period.
date_till iso8601 YYYY-MM-DD hh:mm:ss yes yes End date and time of the reporting period.
Array of strings of the requested report
rows array yes Array of strings of the requested report
List of requested dimensions
dimension array yes List of values requested by dimensions
value string yes yes If there is no data in the requested dimension, Undefined Name of values requested dimensions
value_id string Unique ID of the value branch in the requested dimensions.
List of requested columns
columns array yes yes List of values of the requested columns in the dimension context
expandable boolean Is it possible to expand a dimension

Example request

{
"id": "number",
"jsonrpc": "2.0",
"method": "getobj.report_table",
"params": {
"access_token": "string",
"user_id": "number",
"limit": "number",
"offset": "number",
"report_type": "enum",
"date_from": "iso8601",
"date_till": "iso8601",
"dimensions": [
"dimension1",
"dimensionN"
],
"columns": [
"column1",
"columnN"
],
"parent_dimensions_value_ids": [
"N",
"M"
],
"filter":{
},
"columns_filter":{

},
"sort": [
{
"field": "string",
"order": "string"
}
]
}

}

Example request

{
"id": "number",
"jsonrpc": "2.0",
"method": "getobj.report_table",
"params": {
"access_token": "string",
"user_id": "number",
"limit": "number",
"offset": "number",
"report_type": "call_summary_uis",
"date_from": "2020-02-01 00:00:00",
"date_till": "2020-02-01 23:59:59",
"dimensions": [
"site",
"gr"
],
"columns": [
"cc_5"
],
"filter":{
"filters":[
{
"filters":[
{
"field":"tags",
"operator":"=",
"value":"Target"
},
{
"field":"tags",
"operator":"=",
"value":"Lead"
}
],
"condition":"or"
},
{
"filters":[
{
"field":"site_domain",
"operator":"=",
"value":"www.site1.ae"
},
{
"field":"site_domain",
"operator":"=",
"value":"www.site1.ae"
}
],
"condition":"or"
}
],
"condition":"and"
},
"columns_filter":{
"field":"cc_5",
"value":1,
"operator":">"
}
}
}

Example response

{
"jsonrpc": "2.0",
"id": "number",
"result": {
"data": {
"date_from": "iso8601",
"date_till": "iso8601",
"rows": [
{
"dimension": {
"value": "string",
"value_id": "string"
},
"columns": [
"float"
],
"expandable": "boolean"
}
]
}
}

}

Example response

{
"id": "1",
"jsonrpc": "2.0",
"result": {
"data": {
"date_from": "2020-02-19 00:00:00",
"date_till": "2020-02-20 23:59:59",
"rows": [
{
"columns": [
16.0,
25.0,
43.75
],
"dimension": {
"value": "Google Chrome",
"value_id": "6"
},
"expandable": false
},
{
"columns": [
11.0,
11.0,
36.36363636
],
"dimension": {
"value": "Yandex Browser",
"value_id": "70"
},
"expandable": true
}
]
}
}
}

Filter nestring examples

Minimum nestring level

{
"filter":{
"field":"tags",
"operator":"=",
"value":"Target"
}
}

Maximum nestring level (nestring depth: 2)

{
"filter":{
"filters":[
{
"filters":[
{
"field":"string",
"operator":"enum",
"value":"string"
}
],
"condition":"or"
},
{
"filters":[
{
"field":"string",
"operator":"enum",
"value":"string"
}
],
"condition":"or"
}
],
"condition":"and"
}
}

Possible errors

See the "Errors for getobj methods" section.