Class InlineQueryContext

Hierarchy

Constructors

Properties

Accessors

Methods

Constructors

Properties

_client: Evogram
_source: IInlineQuery
client: Evogram = ...
location: undefined | LocationContext = ...

Sender location, only for bots that request user location

user: UserContext = ...

Sender

Accessors

  • get chatType(): undefined | "channel" | "private" | "group" | "supergroup" | "sender"
  • Type of the chat from which the inline query was sent

    Returns undefined | "channel" | "private" | "group" | "supergroup" | "sender"

Methods

  • Converts the source object to a context object of a given type.

    Example

    client.updates.on("message", message => {
    const user = message.user.toContext<CustomUserContext>();
    // Now user works correctly with your context
    })

    Type Parameters

    • TContext extends object

      Generic type parameter for the context object.

    Returns TContext

    The context object.

Generated using TypeDoc