From c2460087ae47f2d9f2785cd9532ff4a134417095 Mon Sep 17 00:00:00 2001 From: Michael Rosinsky Date: Thu, 3 Dec 2026 15:50:29 -0500 Subject: [PATCH] Livestream docs: host_id on Mute and Unmute a Chat User Chat moderators can pass host_id to mute or unmute in the chats of the broadcaster they moderate for, whether or not that broadcaster is live. Documents host_id on both pages and in the Livestream SKILL.md (1.4), the 400 when host_id and broadcast_id are sent together, the 403 for a host you don't moderate for, and that a request with neither field always applies to the caller's own chats. Co-authored-by: Cursor --- livestream-api/chat/mute-user.mdx | 10 ++++++++-- livestream-api/chat/unmute-user.mdx | 10 ++++++++-- livestream-api/skill-md.mdx | 4 ++-- 3 files changed, 18 insertions(+), 6 deletions(-) diff --git a/livestream-api/chat/mute-user.mdx b/livestream-api/chat/mute-user.mdx index 66242508f..db84386b7 100644 --- a/livestream-api/chat/mute-user.mdx +++ b/livestream-api/chat/mute-user.mdx @@ -10,9 +10,15 @@ Prevents a user from posting chat messages in a broadcaster's chat. Mutes belong Pass the numeric id of the user to mute as `user_id` in the request body. `user_id` is the only required field. -Without `broadcast_id`, you mute the user in your own chats. You don't need a live broadcast to do this. +Without `host_id` or `broadcast_id`, you mute the user in your own chats. You don't need a live broadcast to do this. -Chat moderators pass `broadcast_id` to mute the user in that broadcast host's chats. The broadcast must be live. See [List Broadcast Moderators](/livestream-api/chat/list-moderators) for how moderators are managed. +Chat moderators pass `host_id`, the numeric id of the broadcaster they moderate for, to mute the user in that host's chats. The host doesn't need to be live. A moderator can instead pass the `broadcast_id` of one of the host's live broadcasts. See [List Broadcast Moderators](/livestream-api/chat/list-moderators) for how moderators are managed. + + +A request with neither `host_id` nor `broadcast_id` always applies to your own chats, even if you moderate for other broadcasters. To act on another broadcaster's chats, a moderator app that uses its own account must send one of the two on every request. + + +Send `host_id` or `broadcast_id`, not both. A request with both returns `400`. A `host_id` that is neither your own id nor a broadcaster you moderate for returns `403`. Pass an optional `message_id` to remove that chat message at the same time. This is useful when muting is in response to a particular message. `message_id` requires `broadcast_id`. diff --git a/livestream-api/chat/unmute-user.mdx b/livestream-api/chat/unmute-user.mdx index e5693e2a7..25e5322ec 100644 --- a/livestream-api/chat/unmute-user.mdx +++ b/livestream-api/chat/unmute-user.mdx @@ -10,9 +10,15 @@ Allows a muted user to post chat messages in a broadcaster's chat again. The unm `:user_id` is the numeric id of the user to unmute. -Without the `broadcast_id` query parameter, you unmute the user in your own chats. You don't need a live broadcast to do this. +Without the `host_id` or `broadcast_id` query parameter, you unmute the user in your own chats. You don't need a live broadcast to do this. -Chat moderators pass `broadcast_id` to unmute the user in that broadcast host's chats. The broadcast must be live. See [List Broadcast Moderators](/livestream-api/chat/list-moderators) for how moderators are managed. +Chat moderators pass `host_id`, the numeric id of the broadcaster they moderate for, to unmute the user in that host's chats. The host doesn't need to be live. A moderator can instead pass the `broadcast_id` of one of the host's live broadcasts. See [List Broadcast Moderators](/livestream-api/chat/list-moderators) for how moderators are managed. + + +A request with neither `host_id` nor `broadcast_id` always applies to your own chats, even if you moderate for other broadcasters. To act on another broadcaster's chats, a moderator app that uses its own account must send one of the two on every request. + + +Send `host_id` or `broadcast_id`, not both. A request with both returns `400`. A `host_id` that is neither your own id nor a broadcaster you moderate for returns `403`. To mute a user, use [Mute a Chat User](/livestream-api/chat/mute-user). To see who you have muted, use [List Muted Chat Users](/livestream-api/chat/list-muted-chat-users). diff --git a/livestream-api/skill-md.mdx b/livestream-api/skill-md.mdx index 00197324a..f0b8e4410 100644 --- a/livestream-api/skill-md.mdx +++ b/livestream-api/skill-md.mdx @@ -14,7 +14,7 @@ To use it, save the block below as `SKILL.md` in a folder your agent loads skill name: x-livestream-api description: Use when building or migrating an integration with the X Livestream API (https://api.x.com/2): creating and managing RTMP/RTMPS stream sources, going live in one call, ending or deleting broadcasts, scheduling broadcasts, reading and moderating live chat, handling its errors, or moving off the deprecated /2/users/:id/sources and /2/users/:id/broadcasts routes before their January 1, 2027 end of life. metadata: - version: "1.3" + version: "1.4" --- # X Livestream API @@ -100,7 +100,7 @@ Go live behavior: ### Live chat - History: `GET /2/broadcasts/:id/chat`. Send: `POST /2/broadcasts/:id/chat`. Remove a message: `DELETE /2/broadcasts/:id/chat/:message_id`. -- Mutes apply across all of the host's broadcasts: `GET`, `POST /2/broadcasts/chat/mutes`, `DELETE /2/broadcasts/chat/mutes/:user_id`. +- Mutes apply across all of the host's broadcasts: `GET`, `POST /2/broadcasts/chat/mutes`, `DELETE /2/broadcasts/chat/mutes/:user_id`. Mute and unmute act on your own chats unless you pass `host_id` (the broadcaster you moderate for, live or not) or the `broadcast_id` of one of their live broadcasts. Both together return `400`; a `host_id` that is neither your own id nor a broadcaster you moderate for returns `403`. - Moderators: `GET`, `POST /2/broadcasts/chat/moderators`, `DELETE /2/broadcasts/chat/moderators/:user_id`. ## Typical workflow