Skip to main content

User Profiles - History

Endpoint

/o?method=user_details&calculate=history

Enterprise Only
This API is available exclusively in Countly Enterprise.

Overview

Returns single-user profile object enriched with historical property changes.

Authentication

Authentication methods:

  • API Key (parameter): api_key=YOUR_API_KEY
  • Auth Token (parameter): auth_token=YOUR_AUTH_TOKEN
  • Auth Token (header): countly-token: YOUR_AUTH_TOKEN

Permissions

  • User Profiles: Read permission.

Request Parameters

ParameterTypeRequiredDescription
api_keyStringYes (or auth_token)API key authentication
auth_tokenStringYes (or api_key)Auth token authentication
app_idStringYesApp ID
methodStringYesMust be user_details
calculateStringYesMust be history
uidStringNoUser ID
didStringNoDevice ID alternative
periodStringNoRequested period
periodOffsetNumberNoOffset in minutes

Configuration Impact

SettingDefaultAffectsUser-visible impact
users.*User profile feature defaultsUser-details retrieval behavior in profile endpoints.Changes to user feature settings can affect which profile-related fields/aggregations are returned.

Response

Success Response

{
"_id": "d8f4d8f91ac1f1f5a8e6f0d9d3f4c0a71b2e3d4f",
"uid": "u_102",
"name": "Jane Doe",
"history": {
"cc": {
"US": true,
"DE": true
},
"p": {
"iOS": {
"17.2": true
}
}
}
}

Response Fields

FieldTypeDescription
_idStringUser document ID
uidStringUser ID
historyObjectHistorical property values map

Error Responses

  • HTTP 400 - Missing user identifier:
{
"result": "Missing parameter \"uid\" or \"did\""
}
  • HTTP 400 - User not found:
{
"result": "User not found"
}

Behavior/Processing

  • Loads base user profile from app users collection.
  • Fetches historical values from query layer and adds them under history.
  • Returns raw user object.

Database Collections

CollectionUsed forData touched by this endpoint
countly.app_users{appId}Per-app user profilesStores user-level properties and profile fields affected by this endpoint.
countly_drill.drill_eventsDrill event recordsStores granular event rows queried or updated by this endpoint.

Examples

/o?api_key=YOUR_API_KEY&app_id=YOUR_APP_ID&method=user_details&calculate=history&uid=u_102&period=30days

Ⓔ Enterprise

This feature is part of Countly Enterprise.

Get Access:

Already a Customer? Use support portal if you have any questions.


Last Updated

2026-02-16