To assist resellers in analyzing their commercial activities, there is a Reporting and Data Export (RDE) service that, once installed on the platform, allows resellers to generate and download rated data reports about the accounts and related commercial resources (customers, subscriptions, invoices, and other) that changed during a specified period.
In this document:
The platform RDE service exposes its resources on the /reports endpoint.
To learn how to configure report generators, refer to the Reporting and Data Export documentation.
The API client can send a request for a set of rated data reports generated during a specified period. For this, a request contains the following query parameters:
from
: the first day of the requested period in ISO 8601 format.
to
: the last day of the requested period in ISO 8601 format.
format
(optional): requests the reports of the specified format only. The formats supported by RDE are:
json
, xml
, csv
, and xslx
.
Note
1. The pagination query parameters offset
and limit
are not parsed on this endpoint as the mentioned
above from
, to
, and format
query parameters define the limitation for the response.
In a response, offset
is always zero and limit
equals total
.
Use a request without the format
query parameter to receive the URLs of all reports for a specified period:
GET /reports?from=2019-11-05&to=2019-12-03 HTTP/1.1
Authorization: Bearer eyJwcm...0fQtrLk4RToj51HAmsRXO78
X-Subscription-Key: 066a6b...33b16
If successful, the response looks like this (the URLs are cut for brevity):
HTTP/1.1 200 OK
{
"data": [
{
"name": "withres2",
"format": "XLSX",
"creationDate": "2019-11-12T09:51:14Z",
"downloadUrl": "https://drrde3.blob.core.windows.net/rdecontainer/withres2.0fb84e60...-0f2cd36236ce.2019-11-12.10-51-15.216+0100.xlsx?sig=rb8TTt...iUY%3D&api-version=2016-05-31&st=2019-11-12T09%3A...%3A15Z&sv=2016-05-31&sp=rwd&sr=b"
},
{
"name": "daily-dr1",
"format": "JSON",
"creationDate": "2019-11-14T20:57:29Z",
"downloadUrl": "https://drrde3.blob.core.windows.net/rdecontainer/daily-dr1.1124976b...-ce8560b8626b.2019-11-14.21-57-30.014+0100.json.gz?sig=Ub2%2FU...%3D&api-version=2016-05-31&st=2019-11-14T20%3A47%3A...%3A30Z&sv=2016-05-31&sp=rwd&sr=b"
},
{
"name": "report",
"format": "XLSX",
"creationDate": "2019-11-05T12:15:18Z",
"downloadUrl": "https://drrde3.blob.core.windows.net/rdecontainer/report.12e9a7a4...-5d6515120ae1.2019-11-05.13-15-19.254+0100.xlsx?sig=bLUSOw%2BaSP...%3D&api-version=2016-05-31&st=2019-11-05T12%3A05%3A...%3A19Z&sv=2016-05-31&sp=rwd&sr=b"
},
{
"name": "dr-rep2",
"format": "XLSX",
"creationDate": "2019-11-05T12:59:32Z",
"downloadUrl": "https://drrde3.blob.core.windows.net/rdecontainer/dr-rep2.1c65e292...-a3d0a48c39b4.2019-11-05.13-59-32.900+0100.xlsx?sig=pJJRiB6Afp...%3D&api-version=2016-05-31&st=2019-11-05T12%3A49%3A...%3A33Z&sv=2016-05-31&sp=rwd&sr=b"
},
{
"name": "dr-rep1",
"format": "XLSX",
"creationDate": "2019-11-05T12:59:13Z",
"downloadUrl": "https://drrde3.blob.core.windows.net/rdecontainer/dr-rep1.39512e47...-be6c0b6d6bc9.2019-11-05.13-59-13.398+0100.xlsx?sig=CLah1V6%2B...%3D&api-version=2016-05-31&st=2019-11-05T12%3A49%3A...%3A13Z&sv=2016-05-31&sp=rwd&sr=b"
},
{
"name": "sample1",
"format": "JSON",
"creationDate": "2019-11-19T15:46:46Z",
"downloadUrl": "https://drrde3.blob.core.windows.net/rdecontainer/sample1.f162d420...-b261564255a4.2019-11-19.16-46-46.616+0100.json.gz?sig=UhvFMT...%3D&api-version=2016-05-31&st=2019-11-19T15%3A36%3A...%3A46Z&sv=2016-05-31&sp=rwd&sr=b"
},
{
"name": "daily-dr1",
"format": "JSON",
"creationDate": "2019-11-22T20:57:43Z",
"downloadUrl": "https://drrde3.blob.core.windows.net/rdecontainer/daily-dr1.fb548...-0bda2d322d76.2019-11-22.21-57-43.445+0100.json.gz?sig=FsjOYz...3D&api-version=2016-05-31&st=2019-11-22T20%3A47%3A...%3A43Z&sv=2016-05-31&sp=rwd&sr=b"
},
{
/* Other reports */
}
],
"pagination": {
"offset": 0,
"limit": 28,
"total": 28
}
}
Use a request with the format
query property to select all reports of the specified format, for example, JSON:
GET /reports?from=2019-11-05&to=2019-12-03&format=json HTTP/1.1
Authorization: Bearer eyJwcm...0fQtrLk4RToj51HAmsRXO78
X-Subscription-Key: 066a6b...33b16
If successful, the response looks like this (the URLs are cut for brevity):
HTTP/1.1 200 OK
{
"data": [
{
"name": "daily-dr1",
"format": "JSON",
"creationDate": "2019-11-14T20:57:29Z",
"downloadUrl": "https://drrde3.blob.core.windows.net/rdecontainer/daily-dr1.1124976b...-ce8560b8626b.2019-11-14.21-57-30.014+0100.json.gz?sig=Ub2%2FU...%3D&api-version=2016-05-31&st=2019-11-14T20%3A47%3A...%3A30Z&sv=2016-05-31&sp=rwd&sr=b"
},
{
"name": "sample1",
"format": "JSON",
"creationDate": "2019-11-19T15:46:46Z",
"downloadUrl": "https://drrde3.blob.core.windows.net/rdecontainer/sample1.f162d420...-b261564255a4.2019-11-19.16-46-46.616+0100.json.gz?sig=UhvFMT...%3D&api-version=2016-05-31&st=2019-11-19T15%3A36%3A...%3A46Z&sv=2016-05-31&sp=rwd&sr=b"
},
{
"name": "daily-dr1",
"format": "JSON",
"creationDate": "2019-11-22T20:57:43Z",
"downloadUrl": "https://drrde3.blob.core.windows.net/rdecontainer/daily-dr1.fb548...-0bda2d322d76.2019-11-22.21-57-43.445+0100.json.gz?sig=FsjOYz...3D&api-version=2016-05-31&st=2019-11-22T20%3A47%3A...%3A43Z&sv=2016-05-31&sp=rwd&sr=b"
},
{
/* Other reports */
}
],
"pagination": {
"offset": 0,
"limit": 17,
"total": 17
}
}
You can also schedule generation of a report for the specified dates using a request similar to this:
GET /reports?from=2019-11-05&to=2019-12-03&format=json HTTP/1.1
Authorization: Bearer eyJwcm...0fQtrLk4RToj51HAmsRXO78
X-Subscription-Key: 066a6b...33b16
{
"name": "Daily report",
"customizationName": "string",
"format": "json",
"startDate": "2019-11-07T17:02:59.000Z",
"endDate": "2019-12-07T17:02:59.000Z",
"downloadUrl": "https://report-storage1.blob.core.windows.net/rdecontainer/Customer1.e1...12d.2019-11-21.14-02-20.551+0100.json?sig=4JbyvWJAUwwN7R...3D&api-version=2016-05-31&st=2019-11-21T12%3A52%&se=202...0-02-19T12=2016-05-31&sp=rwd&sr=b"
}
If successful, the response looks like this (the URLs are cut for brevity):
HTTP/1.1 200 OK
{
"id": "f40c942d-ebec-41b9-b604-5ed9ffb6d4f2",
"name": "Daily report",
"customizationName": "string",
"status": "completed",
"type": "onetime",
"format": "json",
"creationDate": "2020-11-07T17:02:59.000Z",
"startDate": "2019-11-07T17:02:59.000Z",
"endDate": "2019-12-07T17:02:59.000Z",
"downloadUrl": "https://report-storage1.blob.core.windows.net/rdecontainer/Customer1.e1...12d.2019-11-21.14-02-20.551+0100.json?sig=4JbyvWJAUwwN7R...3D&api-version=2016-05-31&st=2019-11-21T12%3A52%&se=202...0-02-19T12=2016-05-31&sp=rwd&sr=b"
}
Refer to the Reporting and Data Export documentation for the complete list of parameters available in the reports. Conclusion ==========
This step completes the typical sales workflow. In the past steps, you learned how to use the CMP API to manage your customers, observe and select the required offers and products provided by them, order those products for your customers, manage the created subscriptions, and collect the rated data reports.
To understand how to sell common services in more detail, follow the Sales Scenarios.