WebhookInfo

@Serializable
data class WebhookInfo(val url: String, val hasCustomCertificate: Boolean, val pendingUpdateCount: Int, val ipAddress: String? = null, val lastErrorDate: Instant? = null, val lastErrorMessage: String? = null, val lastSynchronizationErrorDate: Instant? = null, val maxConnections: Int? = null, val allowedUpdates: List<UpdateType>? = null)

Describes the current status of a webhook.

Api reference

Constructors

Link copied to clipboard
constructor(url: String, hasCustomCertificate: Boolean, pendingUpdateCount: Int, ipAddress: String? = null, lastErrorDate: Instant? = null, lastErrorMessage: String? = null, lastSynchronizationErrorDate: Instant? = null, maxConnections: Int? = null, allowedUpdates: List<UpdateType>? = null)

Properties

Link copied to clipboard

Optional. A list of update types the bot is subscribed to. Defaults to all update types except chat_member

Link copied to clipboard

True, if a custom certificate was provided for webhook certificate checks

Link copied to clipboard
val ipAddress: String? = null

Optional. Currently used webhook IP address

Link copied to clipboard
@Serializable(with = InstantSerializer::class)
val lastErrorDate: Instant? = null

Optional. Unix time for the most recent error that happened when trying to deliver an update via webhook

Link copied to clipboard

Optional. Error message in human-readable format for the most recent error that happened when trying to deliver an update via webhook

Link copied to clipboard
@Serializable(with = InstantSerializer::class)
val lastSynchronizationErrorDate: Instant? = null

Optional. Unix time of the most recent error that happened when trying to synchronize available updates with Telegram datacenters

Link copied to clipboard
val maxConnections: Int? = null

Optional. The maximum allowed number of simultaneous HTTPS connections to the webhook for update delivery

Link copied to clipboard

Number of updates awaiting delivery

Link copied to clipboard
val url: String

Webhook URL, may be empty if webhook is not set up