specification: API Commons Data Model specificationVersion: '0.1' provider: Ant Media providerId: ant-media generated: '2026-09-02' method: derived source: >- Derived from the component schemas and $ref graph of the six OpenAPI documents in openapi/ (Ant Media Server 3.1.0 specs), cross-checked against https://docs.antmedia.io/guides/developer-sdk-and-api/rest-api-guide/. description: >- The entity graph behind the Ant Media Server REST API. Broadcast is the hub: almost every other entity hangs off a streamId. There are no opaque prefixed ids in this API — a streamId is a caller-chosen string, which is what makes createBroadcast retry-safe and what makes collisions the documented 400. id_conventions: style: caller-supplied plain strings detail: >- streamId is chosen by the client on createBroadcast (or generated by the server when omitted); there are no prefixed, typed or opaque ids anywhere in the model. The only structured id is ObjectId (MongoDB) on TensorFlowObject.dbId, which leaks the datastore. collision: >- Reusing an existing streamId on createBroadcast returns HTTP 400 — "If stream id is already used in the data store, it returns error". entities: - name: Broadcast description: >- The central object — a live stream or stream source, with ~60 fields covering identity, state, protocol endpoints, viewer counts, recording flags, geo, conference role and the per-stream webhook URL (listenerHookURL). key: streamId operations: [createBroadcast, getBroadcast, updateBroadcast, deleteBroadcast, deleteBroadcastsBulk, getBroadcastList, startStreamSourceV2, stopStreamingV2, enableRecording] relationships: - has_many: Endpoint via: endPointList - has_many: PlayListItem via: playListItemList - has_one: HLSParameters via: hlsParameters - has_many: EncoderSettings via: encoderSettingsList - belongs_to: Broadcast via: mainTrackStreamId note: Self-reference — a subtrack points at its main track. In conferencing the main track is the room. - has_many: Broadcast via: subTrackStreamIds note: Inverse of mainTrackStreamId. - has_many: Subscriber via: streamId - has_many: Token via: streamId - has_many: ConnectionEvent via: streamId - has_many: VoD via: streamId - name: BroadcastUpdate description: The partial-update projection of Broadcast used by updateBroadcast. Same relationship graph. operations: [updateBroadcast] - name: Endpoint description: A third-party RTMP republish target attached to a broadcast, optionally per adaptive resolution. key: endpointServiceId operations: [addEndpointV3, removeEndpointV2] relationships: - belongs_to: Broadcast via: endPointList - name: PlayListItem description: An entry in a linear playlist broadcast. operations: [playNextItem, updateSeekTime] relationships: - belongs_to: Broadcast via: playListItemList - name: HLSParameters description: Per-broadcast HLS packaging parameters. relationships: - belongs_to: Broadcast via: hlsParameters - name: EncoderSettings description: A rung in the adaptive-bitrate ladder — resolution, bitrate, codec settings. relationships: - belongs_to: Broadcast via: encoderSettingsList - belongs_to: AppSettings via: encoderSettings - name: Subscriber description: >- A named participant with publish or play rights on a stream, optionally with a base32 TOTP secret (b32Secret) whose length must be a multiple of 8. key: subscriberId operations: [addSubscriber, deleteSubscriber, revokeSubscribers, blockSubscriber, listSubscriberV2, getTOTP] relationships: - belongs_to: Broadcast via: streamId - has_one: SubscriberStats via: subscriberId - name: SubscriberStats description: Per-subscriber connection statistics. operations: [listSubscriberStatsV2] relationships: - belongs_to: Subscriber via: subscriberId - belongs_to: Broadcast via: streamId - has_many: ConnectionEvent via: connectionEvents - name: ConnectionEvent description: A single connect/disconnect event for a subscriber on a stream. operations: [getConnectionEvents] relationships: - belongs_to: Broadcast via: streamId - belongs_to: Subscriber via: subscriberId - name: Token description: A one-time or time-limited publish/play token, optionally scoped to a conference room. key: tokenId operations: [getTokenV2, getJwtTokenV2, validateTokenV2, listTokensV2, revokeTokensV2] relationships: - belongs_to: Broadcast via: streamId - belongs_to: Room via: roomId - name: VoD description: A recorded or imported video-on-demand asset. key: vodId operations: [getVoD, getVodList, deleteVoD, deleteVoDsBulk, uploadVoDFile, importVoDs, unlinksVoD, importVoDsToStalker] relationships: - belongs_to: Broadcast via: streamId note: Set when the VoD was produced by recording a live stream; the vodReady webhook carries both ids. - name: FilterConfiguration description: A media-processing or MCU filter applied to a stream or conference room. key: filterId operations: [create, delete, getFilters, createMCU, deleteMCU, setCustomMCUFilter, resetMCUFilter, setPluginType] - name: BroadcastStatistics description: Aggregate viewer and bitrate statistics for a broadcast. operations: [getBroadcastStatistics, getBroadcastTotalStatistics] relationships: - belongs_to: Broadcast via: streamId - name: WebRTCClientStats description: Per-WebRTC-client statistics, composed of audio and video send/receive stat objects. key: clientId operations: [getWebRTCClientStatsListV2, getWebRTCLowLevelSendStats, getWebRTCLowLevelReceiveStats] relationships: - has_one: WebRTCVideoSendStats via: videoSentStats - has_one: WebRTCAudioSendStats via: audioSentStats - name: TensorFlowObject description: An object-detection result produced by the AI/vision plugins. operations: [getDetectionListV2, getObjectDetectedTotal] relationships: - belongs_to: Broadcast via: imageId - has_one: ObjectId via: dbId note: A MongoDB ObjectId — the only place the datastore leaks into the contract. - name: RTMPToWebRTCStats description: Latency and frame statistics for the RTMP-to-WebRTC path. operations: [getRTMPToWebRTCStats] relationships: - belongs_to: Broadcast via: streamId - name: Result description: The universal response envelope — success, message, dataId, errorId. Not an entity; see errors/. - name: SimpleStat description: A single-number response used by every /count operation. - name: User description: A management-panel operator account. Authenticated with e-mail plus MD5-hashed password. key: email operations: [addUser, addInitialUser, editUser, deleteUser, getUserList, authenticateUser, changeUserPassword, getBlockedStatus] spec: openapi/ant-media-management-api-openapi.yml - name: ApplicationContext description: >- A deployed application on the server (e.g. LiveApp, WebRTCAppEE). Everything in the app REST API is scoped to one of these, which is why the base URL carries {application}. operations: [getApplications, getApplicationInfo, createApplication, deleteApplication, getAppLiveStreams, resetBroadcast, getAppMetricsHistory] spec: openapi/ant-media-management-api-openapi.yml relationships: - has_one: AppSettings via: getSettings / changeSettings - has_many: Broadcast - name: AppSettings description: >- Per-application configuration — the largest object in the model. Carries the default webhook URL, the JWT/token security switches, the encoder ladder and the push-notification credentials (apnTeamId, apnKeyId). operations: [getSettings, changeSettings] spec: openapi/ant-media-management-api-openapi.yml relationships: - has_many: EncoderSettings via: encoderSettings - name: ServerSettings description: Server-wide configuration, including the cluster and licence settings. operations: [getServerSettings, changeServerSettings, configureSsl] spec: openapi/ant-media-management-api-openapi.yml relationships: - has_one: ApplicationContext via: applicationContext - name: ClusterNode description: A node in an Ant Media cluster. key: id operations: [getNodeList, getNodeCount, deleteNode, updateNodeNote] spec: openapi/ant-media-cluster-api-openapi.yml - name: Licence description: The instance's licence status. operations: [getLicenceStatus, getLicenceStatus_1, isEnterpriseEdition] spec: openapi/ant-media-management-api-openapi.yml - name: SupportRequest description: A support request submitted from the management panel. operations: [sendSupportRequest] spec: openapi/ant-media-management-api-openapi.yml notes: - >- Room is not a distinct entity. A conference room IS a Broadcast used as a main track, with participants joining as subtracks — which is why Token.roomId and the MCU filter operations take a roomId that is really a streamId. - >- The management specs expose Spring internals (ApplicationContext, BeanFactory, AutowireCapableBeanFactory, Environment) as component schemas. They are framework leakage from the Java reflection-based spec generator, not part of the intended data model. maintainers: - FN: Kin Lane email: info@apievangelist.com url: https://apievangelist.com