Protected
_clientProtected
_sourceThe user who triggered the callback query.
The chat instance that was used to generate the inline button, if available.
The data associated with the callback query.
The short name of the game to be returned, if this callback query is from a game message.
The ID of the callback query.
The ID of the inline message that was sent with the button that triggered the callback query, if available.
Answers the callback query with the specified parameters.
Optional
params: Partial<IAnswerCallbackQueryParams>The parameters to use for answering the callback query.
A Promise that resolves with the result of the API call to answer the callback query.
Converts the source object to a context object of a given type.
client.updates.on("message", message => {
const user = message.user.toContext<CustomUserContext>();
// Now user works correctly with your context
})
Generic type parameter for the context object.
The context object.
Generated using TypeDoc
The message context associated with the callback query, if available.