Skip to main content

Retrieve cohort data

Retrieves cohort data for tracking user groups over time.

Endpoint and method

POST https://api-admin.adapty.io/api/v1/client-api/metrics/cohort/

Parameters

NameTypeRequiredDescription
filtersMetricsFilters objectAn object containing filtration parameters. See details below this table.
period_unitStringSpecify the time interval for aggregating analytics data, to view results grouped by selected periods, such as days, weeks, months, etc. Possible values are:
  • day
  • week
  • month
  • quarter
  • year
period_typeString

Analyze data by renewals or by days. For a detailed description, see Tracking by renewals or by days.

Possible values are:

  • renewals
  • days
value_typeStringSpecify how values are displayed. Possible values are:
  • absolute: as a percentage of the total
  • relative: as a percentage from the start, starting at 100% for renewal periods.
value_fieldStringSpecify the type of values displayed. Possible values are:
  • revenue
  • arppu
  • arpu
  • arpas
  • subscribers
  • subscriptions
accounting_typeStringThe accounting method used. Possible values are:
  • revenue
  • proceeds
  • net_revenue
renewal_daysArray of IntegersThis is a list of days since the app was installed for the cohort type period_type=days. Default:
  • 0
  • 3
  • 7
  • 14
  • 28
  • 31
  • 61
  • 92
  • 183
  • 336
  • 550
  • 731
formatStringSpecify the export file format. Available options are:
  • json
  • csv

MetricsFilters object

NameTypeRequiredDescription
datearray of String values(data)Enter the date or period for which you want to retrieve chart data.
storearray of String valuesFilter by the app store where the purchase was made. Possible values include app_store, play_store, stripe, and any custom store ID. If using a custom store, enter its ID as set in the Adapty Dashboard.
countryarray of String valuesFilter by the 2-letter country code where the purchase took place, using ISO 3166-1 standard codes.
store_product_idarray of String valuesUnique identifier of a product from the app store. You can see this ID in the Products section of the Adapty Dashboard.
durationarray of StringSpecify the subscription duration. Possible values are:
  • Weekly
  • Monthly
  • 2 months
  • 3 months
  • 6 months
  • Annual
  • Lifetime
  • Uncategorized
attribution_sourcearray of String valuesThe source integration for attribution. Possible options:
  • adjust
  • airbridge
  • apple_search_ads
  • appsflyer
  • branch
  • custom
attribution_statusarray of String valuesIndicates if the attribution is organic or non-organic. Possible values are:
  • organic
  • non-organic
  • unknown
attribution_channelarray of String valuesMarketing channel that led to the transaction.
attribution_campaignarray of String valuesMarketing campaign that brought the transaction.
attribution_adgrouparray of String valuesAttribution ad group that brought the transaction.
attribution_adsetarray of String valuesAttribution ad set that led to the transaction.
attribution_creativearray of String valuesSpecific visual or text elements in an ad or campaign tracked to measure effectiveness (e.g., clicks, conversions).
offer_categoryarray of String valuesSpecify the offer categories you want to retrieve data for. Possible values are:
  • introductory
  • promotional
  • winback
offer_typearray of String valuesSpecify the offer types you want to retrieve data for. Possible values are:
  • free_trial
  • pay_as_you_go
  • pay_up_front
.
offer_idarray of String valuesSpecify the specific offers you want to retrieve data for.

Request example

Example request (click to expand)

The example below shows how to track retention by cohort to spot drop-off points, revealing trends and key moments where engagement strategies could boost retention. Limited to App Store, a specific product, and the USA.

{
"filters": {
"date": [
"2024-04-01",
"2024-09-30"
],
"store": [
"app_store"
],
"country": [
"us"
],
"store_product_id": [
[
"monthly.premium.599"
]
],
},
"period_unit": "month",
"period_type": "renewals",
"value_type": "absolute",
"value_field": "subscriptions"
}