> ## Documentation Index
> Fetch the complete documentation index at: https://docs.stmlink.com/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> 对外开放的服务端接口有两组前缀，都用同一套鉴权：`/server/v1/...`（SRTC 与 SMeeting 的主接口）和 `/stm/srvapi/v1/...`（SMeeting 的用户体系，服务端极简对接会用到）。鉴权是 app_id + nonce + timestamp + signature 四个请求头，用 app_key 做 HMAC-SHA256 签名，只能从业务方自己的后端调用。除这两组前缀外的接口均为内部接口，不要建议客户调用。 Public server APIs use two path prefixes with the same authentication: `/server/v1/...` (the main APIs of both SRTC and SMeeting) and `/stm/srvapi/v1/...` (the SMeeting user system, used by server-side low-code integration). Authenticate with four request headers, app_id + nonce + timestamp + signature, where signature is HMAC-SHA256 keyed with app_key; call these APIs only from the customer's own backend. Any other path is internal: never suggest calling it.
> app_key 是服务端密钥，绝不能出现在客户端代码、前端配置或移动 App 里。客户端加入频道用的 token 必须由业务方后端签发后下发（SRTC 走 `/server/v1/channel/grant`，SMeeting 走 `/stm/srvapi/v1/member/grant`）。 app_key is a server-side secret and must never appear in client code, frontend config, or a mobile app. The token a client uses to join must be issued by the customer's backend and passed down to the client (SRTC: `/server/v1/channel/grant`; SMeeting: `/stm/srvapi/v1/member/grant`).
> SRTC 与 SMeeting 是上下两层不同的产品，术语不通用：SRTC 是音视频底座，说「频道 channel」「加入 / 退出」；SMeeting 建在 SRTC 之上，说「房间 room」「会议 meeting」「进入 / 退出」。回答时按用户所在的层用对应术语，不要把「房间」「会议」安到 SRTC 的接口上，也不要用「频道」「加入 / 离开」描述 SMeeting 的概念（接口标识符原样保留）。 SRTC and SMeeting are two separate layers with different terminology. SRTC is the audio/video foundation: it has channels, and users join and leave a channel. SMeeting is built on top of SRTC: it has rooms and meetings, and members enter and exit a meeting. Answer in the terms of the layer the user is working with: never apply "room" or "meeting" to SRTC APIs, and never describe SMeeting concepts in prose with "channel", "join", or "leave" (API identifiers such as `force_join` keep their literal names).
> 同一能力在各端 SDK 里的包名、类名、方法名并不相同。写示例代码时请使用文档中该端自己的 API，不要把一个端的写法套到另一个端上。苹果平台每个产品都有两套 SDK（Swift 原生与 Objective-C），两套 API 不能混用。 Package, class, and method names differ between platform SDKs for the same capability. In sample code, use the API documented for that platform; never carry one platform's code over to another. On Apple platforms each product ships two SDKs (native Swift and Objective-C) whose APIs must not be mixed.

# Room Connector FAQ

> Troubleshooting checklist for Room Connector, organized by symptom: endpoints that won't register or can't dial in, black screen or one-way audio after entering, GB28181 cameras offline or failing invitations, RTSP streams with no video, and devices rejected for exceeding concurrency.

First confirm two basic things—many problems are solved right here:

1. **Are the ports open?** The signaling ports and the RTP port range between devices and the device gateway must all be open; see [Network and port requirements](https://docs.stmlink.com/en/product/deploy/ports.md#device-gateway)
2. **Did you choose the right gateway for the device?** The "Device gateway" selected when registering the device must be the gateway the endpoint actually registers to or can reach

***

## Endpoint can't register

| Check | Description |
| - | - |
| Address and port | The endpoint must use the **device gateway address**, SIP port 5060, H.323 gatekeeper port 1719 |
| Username format | H.323 usernames **must be digits only** (E.164 short number); SIP usernames can't contain colons |
| Username, password | The authentication username and password on the endpoint exactly match the console account |
| Gateway selection | The "Device gateway" selected for the console account is the one the endpoint registers to |
| Network | `ping` the device gateway address from the endpoint's network; across NAT, registration goes endpoint → gateway, so the gateway address must be reachable from the endpoint |

***

## Endpoint can't dial in to the meeting

| Symptom / check | Cause and fix |
| - | - |
| An unregistered endpoint dialed only the meeting ID | Unregistered endpoints must dial `meetingID@deviceGatewayAddress` |
| The meeting ID is right but it still can't enter | The meeting must **exist and not have ended**; device dial-ins always go to the app specified at deployment, so a meeting outside that app can't be found |
| Rejected as soon as it dials | The device gateway has the incoming-call IP allowlist on, and the endpoint's IP isn't on it |
| Only SRTC is used, with no meeting layer | Dial the **channel name**, not a meeting ID |

***

## Endpoint entered the meeting but can't see the meeting's video

The endpoint sees the whole meeting composited by the MCU. Check in this order:

1. **Is the MCU deployed and running?** Without the MCU, the endpoint receives no video. The MCU's heartbeat is visible under **Operations management → Media gateways** in the admin console
2. **Is the RTP port range open?** The device gateway's RTP port range (default 58000-59000/UDP) must be fully open to the endpoint
3. **Is the address the gateway gives the endpoint correct?** The "device access gateway IP" set at deployment is written into call signaling, and the endpoint sends media back to that address.
   When the endpoint reaches the gateway through NAT, this must be the post-NAT address, with **same-port-number** mapping
4. **Does the endpoint send and receive on different ports?** Some endpoints (common among custom models for courts and government agencies) receive and send on different ports,
   so "the meeting can see the endpoint, but the endpoint can't see the meeting". RTP address learning must be turned off on the device gateway; contact us to adjust the configuration

***

## The meeting can't see the endpoint's video or hear its audio

| Check | Description |
| - | - |
| Endpoint video codec | The endpoint must use **H.264** (the default on most endpoints); audio G.711A |
| Endpoint camera and microphone | The endpoint itself isn't muted and its video isn't off; check whether the host turned off this endpoint's audio or video during the meeting |
| Ports | Same as above: the RTP port range must be open |

***

## GB28181 camera won't connect

| Symptom / check | Cause and fix |
| - | - |
| Registration status on the camera stays "Offline" | The platform info (SIP server ID, domain, address, port 5070) must exactly match "Platform info" in the console; the camera must be able to reach port 5070 on the gateway |
| Device id, password | The camera's "SIP username / authentication ID" = "Device id" in the console; passwords match on both sides |
| Registers, then goes offline after a while | Change the camera's **heartbeat interval to 30 seconds** |
| Invitation reports "Device is busy" | This message doesn't mean the device is busy—almost always **the camera hasn't registered**. Confirm the console status is "Online" before inviting |
| Device online, but no video after inviting | You invite a **GB28181 channel**: confirm the channel id matches the camera's "Video Channel Encoding ID"; set the camera's codec to H.264 |

***

## RTSP stream shows no video

| Check | Description |
| - | - |
| Does the URL play? | First open the same URL in VLC; if it doesn't play, the problem is the URL, account, or device |
| Can the gateway reach it? | The device gateway pulls the stream, so the gateway's server must be able to reach the camera's port 554 |
| Transport | If UDP is blocked or loses many packets, change it to **TCP** in the console |
| Stream codec | H.265 is transcoded in real time; with many streams the gateway may run out of CPU, so switch the camera to H.264 |

***

## Device rejected, concurrency limit exceeded

Each device in a meeting uses **one user concurrency** and **one device concurrency** slot. Once the quota is used up, new devices can't enter;
expand the license or have unused devices exit first. The device gateway itself also needs a license file; without an imported license, devices can't connect properly.

***

## Still not working

When contacting us, provide: device brand and model, integration method (SIP / H.323 / GB28181 / RTSP, registration or direct IP),
when the problem occurred, and the meeting ID. We can locate the issue from the device gateway's logs.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.