telegramsjs
    Preparing search index...

    Class ChatJoinRequest

    Hierarchy (View Summary)

    Index

    Constructors

    Properties

    author: User

    User that sent the join request

    bio?: string

    Bio of the user

    chat: Chat

    Chat to which the request was sent

    createdUnixTime: number

    Date the request was sent in Unix time

    inviteLink?: ChatInviteLink

    Chat invite link that was used by the user to send the join request

    userChatId: string

    Identifier of a private chat with the user who sent the join request. The bot can use this identifier for 5 minutes to send messages until the join request is processed, assuming no other administrator contacted the user.

    Accessors

    • get createdAt(): Date

      Date the request was sent

      Returns Date

    • get createdTimestamp(): number

      Return the timestamp request was sent, in milliseconds

      Returns number

    Methods

    • Protected

      Creates a clone of the current instance

      Returns Base

      A clone of the current instance

    • Protected

      Patches the current instance with new data

      Parameters

      • data: Record<string, any>

        The data to patch the instance with

      Returns Record<string, any>

      The patched data

    • Protected

      Updates the current instance with new data and returns a clone of the updated instance

      Parameters

      • data: Record<string, any>

        The data to update the instance with

      Returns Base

      A clone of the updated instance

    • Use this method to approve a chat join request. The bot must be an administrator in the chat for this to work and must have the can_invite_users administrator right.

      Returns Promise<true>

      Returns True on success.

    • Use this method to decline a chat join request. The bot must be an administrator in the chat for this to work and must have the can_invite_users administrator right.

      Returns Promise<true>

      Returns True on success.

    • Flatten an object. Any properties that are collections will get converted to an array of keys.

      Parameters

      • OptionalpropsRecursive: boolean

        Optional. If true, calls toJSON method on nested objects.

      • ...props: Record<string, string | boolean>[]

        Optional. Specific properties to include/exclude, or rename.

      Returns Record<string, any>

      Flattened object.

    • Returns the id instance Chat, User, ChatMember and other

      Returns string | null