Get customer retention metrics
Changed onThe Get customer retention metrics endpoint returns customer retention insights for a specific company's commerce connection over one or more periods of time.
This detail helps you assess a merchant's health and advise them on performance improvement strategies. It also provides you with key insights you need to assess the credit risk of a company.
Customer retention metrics
- Existing customers: the number of unique customers that have placed an order(s) in the specified period and any previous period.
- New customers: the number of unique customers that have placed an order(s) in the specified period and none in any previous period.
- Total customers: the total number of existing and new customers within the specified period.
- Retention rate: the ratio of existing customers within the specified period compared to the total customers at the end of the previous period represented as a percentage.
- Repeat rate: the ratio of existing customers to total customers over the specified period represented as a percentage.
Learn more about the formulas used to calculate customer retention metrics.
Response structure
The Customer retention report's dimensions and measures are:
| Index | Dimensions |
|---|---|
| index = 0 | Period |
| index = 1 | Customer retention metrics |
| Index | Measures |
|---|---|
| index = 0 | Count |
| index = 1 | Percentage |
The report data then combines multiple reporting dimensions and measures and outputs the value of each combination.
Request
- Base URLhttps://api.codat.io
- AuthAPI key in header Authorization
- TypeScriptA function with typed inputs. Its response is checked against the schema.
Query parameters
The date in which the report is created up to. Users must specify a specific date, however the response will be provided for the full month.
The number of months per period. E.g. 2 = 2 months per period.
The number of periods to return. There will be no pagination as a query parameter.
The period unit of time returned.
Shows the dimensionDisplayName and itemDisplayName in measures to make the report data human-readable.
Response
OK
Changes
- info
added the optional property
to the response with the status - info
added the optional property
to the response with the status - info
added the optional property
to the response with the status - info
added the optional property
to the response with the status - info
added the optional property
to the response with the status - info
added the optional property
to the response with the status - info
added the optional property
to the response with the status - info
added the optional property
to the response with the status
- info
- info
added the non-success response with the status
- info
added the non-success response with the status
- info
added the non-success response with the status
- info
added the non-success response with the status
- info
added the non-success response with the status
- info
added the non-success response with the status
- info