Available Endpoints
Get Current User Voice State
Get the current user’s voice state in a guild. GET/guilds/:guild/voice-states/@me
getCurrentUserVoiceState- Handler functiongetCurrentUserVoiceStateSchema- Valibot schema for validationgetCurrentUserVoiceStateSafe- Validated handlergetCurrentUserVoiceStateProcedure- tRPC procedure (query)getCurrentUserVoiceStateQuery- Query helper
Get User Voice State
Get a specific user’s voice state in a guild. GET/guilds/:guild/voice-states/:user
getUserVoiceState- Handler functiongetUserVoiceStateSchema- Valibot schema for validationgetUserVoiceStateSafe- Validated handlergetUserVoiceStateProcedure- tRPC procedure (query)getUserVoiceStateQuery- Query helper
List Voice Regions
Get all available voice regions. GET/voice/regions
rtcRegion.
Exports:
listVoiceRegions- Handler functionlistVoiceRegionsSafe- Validated handlerlistVoiceRegionsProcedure- tRPC procedure (query)listVoiceRegionsQuery- Query helper
Modify Current User Voice State
Update the current user’s voice state. PATCH/guilds/:guild/voice-states/@me
204 No Content on success. Fires a Voice State Update Gateway event.
Caveats:
channelIdmust currently point to a stage channel- Current user must already have joined
channelId - You must have the
MUTE_MEMBERSpermission to unsuppress yourself (you can always suppress yourself) - You must have the
REQUEST_TO_SPEAKpermission to request to speak (you can always clear your own request) - You can set
requestToSpeakTimestampto any present or future time
modifyCurrentUserVoiceState- Handler functionmodifyCurrentUserVoiceStateSchema- Valibot schema for validationmodifyCurrentUserVoiceStateSafe- Validated handlermodifyCurrentUserVoiceStateProcedure- tRPC procedure (mutation)
Modify User Voice State
Update another user’s voice state. PATCH/guilds/:guild/voice-states/:user
MUTE_MEMBERS permission.
Returns: Fires a Voice State Update Gateway event.
Caveats:
channelIdmust currently point to a stage channel- User must already have joined
channelId - When unsuppressed, non-bot users will have their
requestToSpeakTimestampset to the current time (bot users will not) - When suppressed, the user will have their
requestToSpeakTimestampremoved
modifyUserVoiceState- Handler functionmodifyUserVoiceStateSchema- Valibot schema for validationmodifyUserVoiceStateSafe- Validated handlermodifyUserVoiceStateProcedure- tRPC procedure (mutation)