Skip to content

export Class

WebhookManager ​

extends ​

BaseManager<WebhookManagerOptions>

Constructor ​

ts
new WebhookManager( client )
ParameterTypeDescription
clientClient

Properties ​

get endpoint : string ​

readonly client : Client ​

readonly default? : WebhookManagerOptions ​

express : any ​

static max : number ​

static min : number ​

readonly options : WebhookManagerOptions ​

Methods ​

asyncdelete( drop_pending_updates ) ​

Deletes the webhook from Telegram.

ParameterTypeDescription
drop_pending_updates?booleanPass True to drop all pending updates

Returns: Promise<boolean>

asyncget( ) ​

Gets the webhook information from Telegram.

Returns: Promise<boolean | WebhookInfo>

asyncintialize( ) ​

Returns: Promise<void>

asyncset( options ) ​

Updates the webhook on the Telegram api.

The following values are taken from options: drop_pending_updates, secret_token, max_connections, ip_address, certificate.

ParameterTypeDescription
options = ...WebhookManagerOptions

Returns: Promise<boolean>