Retrieve a retention percentage report.
aggregationField required | string Report aggregation field. |
aggregationPeriod required | string Report aggregation period. |
periodStart required | string Report start date. |
periodEnd required | string Report end date. |
includeSwitchedSubscriptions | string If to include switched subscriptions. |
limit | integer [ 0 .. 1000 ] The collection items limit. |
offset | integer >= 0 The collection items offset. |
filter | string The collection items filter requires a special format. Use "," for multiple allowed values. Use ";" for multiple fields. See the filter guide for more options and examples about this format. |
criteria | string Criteria parameter for requesting a collection. |
Report was retrieved successfully.
Pagination-Total | integer Total items count. Example: 332 |
Pagination-Limit | integer Items per page limit. Example: 100 |
Pagination-Offset | integer Pagination offset. Example: 2 |
Unauthorized access, invalid credentials were used.
Access forbidden.
const params = { aggregationField: 'month', aggregationPeriod: 'month', periodStart: '2016-09-01T00:00:00Z', periodEnd: '2017-09-01T00:00:00Z', includeSwitchedSubscriptions: false, limit: 20, offset: 0, tz: 0 }; const report = await api.reports.getRetentionPercentage(params);
{- "data": [
- {
- "aggregationValue": "string",
- "subscriptionsCount": 0,
- "periods": [
- {
- "period": 0,
- "retentionRatio": 0,
- "canceledSubscriptionsCount": 0
}
]
}
]
}