teamspeak.js - v1.11.0
    Preparing search index...

    Class Client

    Represents a client.

    Hierarchy (View Summary)

    Index

    Constructors

    Properties

    channelId: number | null = null
    databaseId: number | null = null
    description: string | null = null
    id: number
    nickname: string | null = null
    type: number | null = null
    uniqueId: string | null = null

    Accessors

    • get partial(): boolean

      Checks if the client is partially filled.

      Returns boolean

      Whether the client is partially filled.

    Methods

    • Bans the client from the server. Since TeamSpeak creates multiple ban entries for one client, this returns a collection of bans.

      Parameters

      Returns Promise<Collection<number, Ban>>

      The bans applied to the client. TeamSpeak creates multiple ban entries for one client.

    • Fetches the client from the server or the cache.

      Parameters

      • Optionalforce: boolean = false

        Whether to force the fetch.

      Returns Promise<Client>

      The fetched client.

    • Fetches the server groups the client belongs to.

      Returns Promise<Collection<number, ServerGroup>>

      The server groups the client belongs to.

    • Kicks the client from the current channel.

      Parameters

      • Optionalreason: string

        The reason for the kick.

      Returns Promise<void>

      A promise that resolves when the client has been kicked.

    • Kicks the client from the server.

      Parameters

      • Optionalreason: string

        The reason for the kick.

      Returns Promise<void>

      A promise that resolves when the client has been kicked.

    • Moves the client to a different channel.

      Parameters

      • channel: ChannelResolvable

        The channel to move the client to.

      • OptionalchannelPassword: string

        The password for the channel, if required.

      Returns Promise<Client>

      A promise that resolves to the moved client.

    • Pokes the client.

      Parameters

      • content: string

        The content of the poke message.

      Returns Promise<void>

      A promise that resolves when the poke has been sent.

    • Sends a message to the client.

      Parameters

      • content: string

        The content of the message.

      Returns Promise<void>

      A promise that resolves when the message has been sent.

    • Sets the description of the client.

      Parameters

      • description: string

        The new description.

      Returns Promise<Client>

      The updated client.

    • Sets whether the client is a talker.

      Parameters

      • isTalker: boolean

        Whether the client is a talker.

      Returns Promise<Client>

      The updated client.

    • Converts the client to a string representation.

      Returns string

      The string representation of the client.