Skip to main content

Read event segment metadata

Enterprise Only
This API is available exclusively in Countly Enterprise.

Endpoint

/o/data-manager/event-segment

Overview

Returns segment metadata per event, including status/required/description and latest audit info.

Authentication

Countly API supports three authentication methods:

  1. API key query parameter: api_key=YOUR_API_KEY
  2. Auth token query parameter: auth_token=YOUR_AUTH_TOKEN
  3. Auth token header: countly-token: YOUR_AUTH_TOKEN

Permissions

Requires data_manager Read permission.

Request Parameters

ParameterTypeRequiredDescription
app_idStringYesTarget app ID.
api_keyStringConditionalRequired if auth_token is not provided.
auth_tokenStringConditionalRequired if api_key is not provided.

Response

Success Response

[
{
"_id": "purchase",
"sg": [
{
"name": "country",
"type": "s",
"status": "approved",
"required": false,
"description": "Country code"
}
]
}
]

Response Fields

FieldTypeDescription
[]ArrayArray of events with grouped segment metadata (sg).
[].sg[].nameStringSegment key.
[].sg[].typeStringSegment type.
[].sg[].statusStringSegment status when present.
[].sg[].requiredBooleanSegment required flag when present.
[].sg[].descriptionStringSegment description when present.
[].sg[].auditObjectLatest audit info (if found).

Error Responses

  • 500
{
"result": "Error"
}

Behavior/Processing

  • Aggregates event segment metadata from countly_drill.drill_meta.
  • Enriches segments with audit info from countly.systemlogs and countly.members.
  • Adds masking metadata from app masking config when present.

Audit & System Logs

  • This endpoint does not emit /systemlogs actions.

Database Collections

CollectionUsed forData touched by this endpoint
countly_drill.drill_metaPrimary source for event segment metadataReads event and segment definitions, including status/type/required fields.
countly.systemlogsAudit enrichment sourceReads latest segment/event-related system log entries to attach audit metadata.
countly.membersUser-name enrichment sourceReads member names for user_id values found in audit logs.
countly.appsMasking enrichment sourceReads app masking configuration to annotate masked segments in the response.

Examples

/o/data-manager/event-segment?
app_id=64f5c0d8f4f7ac0012ab3456


Last Updated

2026-02-16