RealTimeX
Start For Free

RealTimeX

API Documentation

IntroductionAuthenticationBase URLHeadersError codes
Sample requestsSample responsesStatus codesAppendixChangelog

API Reference

Appendix

Shared variables, glossary, pagination shape, and conventions used across the RealtimeX API docs.

Overview

This appendix collects cross-cutting reference material that does not belong to a single endpoint: Postman/collection variables, product glossary, pagination shape, and how Platform admin APIs differ from chat SDK APIs.

Use it when wiring environments, naming things in your integration, or checking whether a call should use a client token or a chat user token.

Collection variables

These reusable variables appear throughout this documentation and the underlying Postman collection. Prefer setting them once per environment instead of hardcoding values in every request.

VariableDefault / ExampleDescription
baseUrlhttp://localhost:5000Server origin. Production example: https://realtimex.softwareco.com
apiVersionv1API version prefix (v1 or v2). Changing this re-points every request path.
URL{{baseUrl}}/api/{{apiVersion}}Composed base URL used by all requests. Prefer editing baseUrl / apiVersion instead of hardcoding.
accessToken(secret — not shown)Client (Platform) access token. Set by Auth → Login / Register Client.
refreshToken(secret — not shown)Client refresh token. Used with Auth → Refresh token to mint a new access token.
userAccessToken(secret — not shown)Chat user access token. Set by User → Login. Used by Conversation / Messages / Uploads chat SDK calls.
clientId-Tenant (client) _id. Required with is-tenant: true as x-client-id.
clientEmailclientpro1@yopmail.comClient credentials used by Auth → Login Client.
clientPassword(secret — not shown)Client credentials used by Auth → Login Client.
conversationId-Conversation _id used by conversation and message requests.
messageId-Message _id used by message and moderation report flows.
roleId-Custom role _id used by Custom Roles get / update / delete.
userId-User _id used by user, mute/ban, and Platform user admin requests.
reportId-Moderation report _id from List Reports, used by Resolve Reports.

After Auth → Login Client, scripts typically populate accessToken, refreshToken, and clientId. After User → Login, they populate userAccessToken.

Glossary

TermDefinition
ClientA tenant / organization account. Owns users, conversations, settings, and custom roles. Authenticates with a client access token for Platform APIs.
Tenant DBThe isolated data space for a single Client, selected via is-tenant: true and x-client-id.
User (chat user)An end participant in a Client's tenant. Authenticates with a user access token for chat SDK endpoints (conversations, messages, uploads).
PlatformAdmin-facing APIs under /client/... and related modules (dashboard, analytics, settings, moderation) used by the tenant console.
ConversationA DM or group chat thread that contains messages, participants, and optional group permissions.
Pinned / Starred messageA message flagged for quick reference (conversation pin) or personal bookmark (star).
Pre-signed URLA time-limited S3 URL that allows direct client-side upload without proxying the file through the API server.
Effective settingsResolved runtime settings (feature gates, limits, timers) without admin document fields or secret tokens such as videoSdkToken.
Moderation reportA user-flagged message awaiting Platform review (pending → resolved / dismissed).
Audit logAn append-only record of tenant actions (ban, mute, resolve, settings changes) for compliance and debugging.

Pagination convention

Modern list endpoints return items under data.list plus a data.pagination object. Query parameters such as page and limit are documented per endpoint when supported; some moderation/settings lists use server defaults with no required query string.

json
{
  "list": [],
  "pagination": {
    "currentPage": 1,
    "totalCount": 42,
    "hasNextPage": true,
    "hasPreviousPage": false,
    "pageSize": 10
  }
}
  • currentPage is 1-based.
  • Use hasNextPage / hasPreviousPage to drive pager UI without recomputing totals locally.
  • pageSize reflects the page that was returned (may differ from your requested limit if capped).

IDs & timestamps

  • Resource ids are MongoDB ObjectIds (24 hex characters) exposed as _id strings.
  • Timestamps are ISO-8601 UTC strings (createdAt, updatedAt, mutedUntil, etc.).
  • Treat mute as active only while mutedUntil is in the future.
  • Nullables such as resolutionNote or groupImage may be null when unset — do not assume empty string.

Platform vs chat SDK

AspectPlatform (client)Chat SDK (user)
TokenaccessToken from Auth Login / Register ClientuserAccessToken from User Login
Typical paths/client/..., dashboard, analytics, settings, moderation/user/..., conversation, messages, uploads
AudienceTenant admins and console toolingEnd-user chat applications and SDKs
Tenant headersUsually is-tenant: true + x-client-idSame tenant headers for tenant-scoped chat data

Mixing tokens is a common cause of 401/403. If a Platform call fails auth, confirm you are not accidentally sending the chat user token.

Related pages

  • Authentication — token types and login flow.
  • Headers — Authorization, Content-Type, tenant headers.
  • Sample requests / responses — request style and envelope parsing.
  • Error codes / Status codes — failure handling.
PreviousStatus codesNextChangelog

On this page

OverviewCollection variablesGlossaryPagination conventionIDs & timestampsPlatform vs chat SDKRelated pages