Cohort retention: daily, weekly or monthly, with optional entry and return events and an entry-event breakdown
AuthorizationBearer <token>
Session token issued by the accounts service (or the legacy /v1/auth routes).
In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/v1/analytics/retention" \ -H "Content-Type: application/json" \ -d '{ "end": "2026-09-13T12:30:45Z", "periods": 8, "start": "2026-07-01T00:00:00Z" }'{ "retention": { "cohorts": [ { "cells": [ "complete", "complete", "partial", "future" ], "cohort": "2026-07-06T00:00:00Z", "complete": true, "rates": [ 100, 66.7, 50.8, null ], "retained": [ 120, 80, 61, null ], "size": 120 } ], "interval": "week", "observed_until": "2026-09-13T12:30:45Z", "periods": 3 }}