设置webhook后为什么电报不发送更新?

时间:2016-04-11 23:50:17

标签: node.js curl webhooks telegram-bot

我可以使用Telegram getUpdates API获取更新,而在使用有效的SSL证书或自签名证书设置webhook之后,它会说:

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

但它没有向我的webhook链接发送任何更新(我检查了Nginx和node.js访问日志文件),我尝试了很多带有和没有证书的setWebhook API的curl命令,但仍然没有结果:

curl -s -X POST https://api.telegram.org/bot<TOKEN>/setWebhook -d url='https://www.example.tech/<TOKEN>/webhook' jq .

curl -F "url=https://www.example.tech/<TOKEN>/webhook" -F "certificate=@./www_example_tech.crt" https://api.telegram.org/bot<TOKEN>/setWebhook

1 个答案:

答案 0 :(得分:2)

您的证书可能存在问题。你能在任何SSL在线检查器中检查你的证书吗?可以吗?

例如,在这一个https://www.sslshopper.com/ssl-checker.html

如果直接调用webhook url,你也会在access.log中看到请求吗?

相关问题