No Translation available yet
You have Slovak selected as language but this page has not been translated yet. Translate the page or view the content in the default space language below.
Display default
/api/reports/views/:id/table/data
This method returns table data in HTML format.
Request Parameters
Parameters | Detail | Example |
---|
id
| ID of the table. This ID is part of the /api/reports/:id response. | 123 |
filter
| (Optional) Filter applied to the table, with following structure: | |
---|
drilldown | Drilldown defined with attribute code and following structure: | |
---|
op | Filter operation type - please see list of supported values. | value/values | (Optional) Depends on selected "op". Contains value or values for filter. | countOp | (Optional) Used with COUNT operation. Specifies the second operation used together with count. Supported values: EQ, NEQ, GT, GTE, LT, LTE |
In order to join multiple filters or apply two filters on the same parameter, attribute drilldown can be an array. "conditionType" attribute outside "drilldown" defines condition between drilldown array members and "conditionType" attribute inside drilldown member defines condition between attributes in the drilldown. |
|
{
"drilldown": {
"L_COUNTRY_OR_AREA": {
"op": "EQ",
"value": "Slovakia"
},
"L_TYPE": {
"op": "IN",
"values": [ "Type 1", "Type 2", "Type 3" ]
},
"L_DATE": {
"op": "NOT_NULL"
},
"L_PRODUCT":{
"op":"COUNT",
"countOp":"LTE",
"value":"816"
}
}
}
Example of a between filter:
{"drilldown":[{"L_ID":{"op":"GT","value":"10"}},{"L_ID":{"op":"LT","value":"20"}}]}
|
rowsFrom
| (Optional) Rows from. | 0 |
rowsTo
| (Optional) Rows to. | 10 |
columnsFrom
| (Optional) Columns from. | 0 |
columnsTo
| (Optional) Columns to. | 20 |
drilldownConfig | (Optional) Replaces the table drill-down with custom configuration. Both horizontal and vertical drill-down configuration can be replaced. Each configuration is an array with the following elements: Name | Description |
---|
dataSetDrilldownAttribute | Code of the attribute (e.g. L_CITY) | dataSetDrilldownAttributeSubset | (Optional) ID of the used subset |
If only one drilldown is specified (horizontal/vertical) the other one is left as currently in configuration for the request. |
{
"horizontal":[
{
"dataSetDrilldownAttribute":"L_PRODUCT_TYPE"
},
{
"dataSetDrilldownAttribute":"L_PRODUCT"
}
],
"vertical":[
{
"dataSetDrilldownAttribute":"L_DATE",
"dataSetDrilldownAttributeSubset":"0EE39yrVHY"
}
]
}
|
Sample request/response
Using curl
:
curl -H "Authorization: OAuth realm=\"https://service.belladati.com/\", oauth_consumer_key=\"myConsumer\", oauth_token=\"mh7an9dkrg59\", oauth_timestamp=\"135131231\", oauth_nonce=\"randomString\"" https://service.belladati.com/api/reports/views/1234/table/data
The JSON format response:
{
"content" : "<tr><td data-column=\"0\" data-row=\"0\" style=\" color:rgb(77, 77, 77) !important ; background-color:rgb(237, 237, 237); \">1,033,054,533,155<\/td><\/tr>"
}
Next steps