Skip to main content

Token - Token List

Endpoint

/o/token/list

Overview

Returns all tokens owned by the authenticated user.

Authentication

  • 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

  • Any authenticated dashboard user.

Request Parameters

ParameterTypeRequiredDescription
api_keyStringYes (or use auth_token)Dashboard API key.
auth_tokenStringYes (or use api_key)Dashboard auth token.

Response

Success Response

{
"result": [
{
"_id": "884803f9e9eda51f5dbbb45ba91fa7e2b1dbbf4b",
"ttl": 3600,
"ends": 1771238910,
"multi": false,
"owner": "67b1d21f1c8b2b714d99e001",
"app": ["6991c75b024cb89cdc04efd2"],
"endpoint": ["^/o/apps"],
"purpose": "Read Apps",
"temporary": false
}
]
}

Response Fields

FieldTypeDescription
resultArrayList of tokens owned by authenticated user.
result[]._idStringToken ID.
result[].ttlNumberToken TTL in seconds (0 means non-expiring).
result[].endsNumberExpiration Unix timestamp (seconds).
result[].multiBooleanReuse flag.
result[].ownerStringToken owner ID.
result[].appString or ArrayApp restrictions.
result[].endpointString or ArrayEndpoint restrictions.
result[].purposeStringToken purpose text.
result[].temporaryBooleanTemporary-token flag.

Error Responses

Status Code: 400 Bad Request

{
"result": "Missing parameter \"api_key\" or \"auth_token\""
}

Status Code: 404 Not Found

{
"result": "Database error message"
}

Behavior/Processing

Behavior Modes

ModeTriggerProcessing PathResponse Shape
Token list modeAuthenticated requestReads all auth_tokens documents where owner matches caller ID.Wrapped token array in result.

Database Collections

CollectionUsed forData touched by this endpoint
countly.membersAuth validationResolves authenticated member.
countly.auth_tokensToken list sourceReads tokens where owner equals caller id.

Examples

Example 1: List my tokens

/o/token/list?api_key=YOUR_API_KEY

Last Updated

2026-02-17