Skip to main content
Mute Conversation
Sets or clears the acting user’s mute on a conversation. Muting suppresses the message push for this conversation only — the message is still delivered, socket-emitted, and readable. Timed mutes expire lazily (push resumes once the window passes). Requires authentication. Acting-user-scoped: an end-user token (Authorization: Bearer <accessToken>) mutes its own membership. A service key acts on behalf of a named user via the body actingUserId, which it must send; an end-user token must not send it (both consistent with every other per-user write). Requires the chat bundle.

Path Parameters

string
required
The ID of the conversation to mute or unmute.

Body Parameters

string | null
required
The mute duration choice — send the choice, never a raw timestamp. One of:
  • "8h" — mute for 8 hours from now
  • "24h" — mute for 24 hours from now
  • "1w" — mute for 1 week from now
  • "forever" — mute indefinitely
  • null — clear the mute (unmute)
The server resolves the window from its own clock, so client clock skew can’t distort it.
string
Service key only, and required with one: the user this request acts as. Their membership is muted. A user token always acts as its own user and must not send it (400 chat/acting-user-not-allowed).

Response

Returns 200 with the acting user’s own (self-serialized) member row under currentMember. The mutedUntil / mutedForever fields reflect the new state.
“Forever” is an explicit signal. A forever mute returns mutedForever: true with mutedUntil: null — the far-future storage sentinel is never exposed as a date. A timed mute returns mutedForever: false with a real ISO mutedUntil. An unmuted conversation returns mutedForever: false, mutedUntil: null. Read the boolean; never string-match a date.

Error Responses

A user token sent actingUserId, even naming its own user. Only a service key names the user it acts as; a user token always acts as its own user.
Returned when a service key names an actingUserId that isn’t a user in this project.
The request sent userId. On this route the user a service key acts as is actingUserId.With a service key:
With a user token, or with no credentials:
Returned when a service key omits the required actingUserId (it has no implicit session user).
Returned when duration is not one of the accepted choices (or null).

See Also