Class REST/Lobbies

Various methods for interacting with lobbies. Located at Client#rest.lobbies.

Constructors

Methods

  • Leave a lobby. This requires bearer token authentication.

    Parameters

    • lobbyID: string

      The ID of the lobby to leave.

    • Optional accessToken: string

      An optional access token to use instead of the client's token. This overrides the client's auth.

    Returns Promise<void>

  • Link a lobby to a channel. This requires bearer token authentication and the CAN_LINK_LOBBY flag on the member.

    Parameters

    • lobbyID: string

      The ID of the lobby to link the channel to.

    • channelID: undefined | string

      The ID of the channel to link the lobby to.

    • Optional accessToken: string

      An optional access token to use instead of the client's token. This overrides the client's auth.

    Returns Promise<Lobby>

  • Remove a member from a lobby.

    Parameters

    • lobbyID: string

      The ID of the lobby to remove the member from.

    • userID: string

      The ID of the user to remove from the lobby.

    Returns Promise<void>

  • Unlink a lobby from a channel. This requires bearer token authentication and the CAN_LINK_LOBBY flag on the member.

    Parameters

    • lobbyID: string

      The ID of the lobby to unlink the channel from.

    • Optional accessToken: string

      An optional access token to use instead of the client's token. This overrides the client's auth.

    Returns Promise<Lobby>

  • Update the moderation metadata for a message in a lobby.

    Parameters

    • lobbyID: string

      The ID of the lobby the message is in.

    • messageID: string

      The ID of the message to update the metadata for.

    • metadata: Record<string, string>

      The metadata to set for the message.

    Returns Promise<void>