v1

latestOpenAPI 3.0.32026-07-1416059.6 KB

setWebhook

Use this method to specify a url and receive incoming updates via an outgoing webhook.

post/bot{token}/setWebhook

Path parameters

tokenstring required

Your Bot Token

Request body

urlstring

HTTPS url to send updates to. Use an empty string to remove webhook integration

certificatestring binary

Upload your public key certificate so that the root certificate in use can be checked. See our self-signed guide https://core.telegram.org/bots/self-signed for details.

Response

200

okboolean
resultboolean
descriptionstring

Example response

{
  "ok": true,
  "result": true,
  "description": "Webhook was set"
}