Telegram API:answerCallbackQuery 的 "text" 不是可选的? (文档说明是)
Telegram API: answerCallbackQuery's "text" is not optional? (documentation states it is)
我认为 answerCallbackQuery
API 请求的 "text"
参数不是可选的,即使文档 states it is:
Text String Optional Text of the notification. If not specified,
nothing will be shown to the user, 0-200 characters
它也says:
NOTE: After the user presses a callback button, Telegram clients will
display a progress bar until you call answerCallbackQuery. It is,
therefore, necessary to react by calling answerCallbackQuery even if
no notification to the user is needed (e.g., without specifying any of
the optional parameters)
这正是我想要做的,但遗憾的是,如果 "text"
属性 被省略,我会收到错误 "Bad Request: MESSAGE_EMPTY"
。我不敢相信我是唯一一个被这个问题绊倒的人。因此,我强烈怀疑我在这里做错了什么。你能帮忙吗?
我不希望在点击时显示通知,因为对点击的反应将作为消息发送,在点击后短暂发送。其他机器人似乎也没有这样的问题,例如 BotFather.
另外,有谁知道我可以在哪个论坛或其他地方获得有关 API 的支持?
我认为text
参数是可选。
我试过 this request,没有显示错误。
可以加入Telegram Support Force创建的@BotTalk群,询问其他人是否有同样的问题。
好像是临时bug,当天就修复了
感谢 Sean 建议 @BotTalk 问题已解决。
我认为 answerCallbackQuery
API 请求的 "text"
参数不是可选的,即使文档 states it is:
Text String Optional Text of the notification. If not specified, nothing will be shown to the user, 0-200 characters
它也says:
NOTE: After the user presses a callback button, Telegram clients will display a progress bar until you call answerCallbackQuery. It is, therefore, necessary to react by calling answerCallbackQuery even if no notification to the user is needed (e.g., without specifying any of the optional parameters)
这正是我想要做的,但遗憾的是,如果 "text"
属性 被省略,我会收到错误 "Bad Request: MESSAGE_EMPTY"
。我不敢相信我是唯一一个被这个问题绊倒的人。因此,我强烈怀疑我在这里做错了什么。你能帮忙吗?
我不希望在点击时显示通知,因为对点击的反应将作为消息发送,在点击后短暂发送。其他机器人似乎也没有这样的问题,例如 BotFather.
另外,有谁知道我可以在哪个论坛或其他地方获得有关 API 的支持?
我认为text
参数是可选。
我试过 this request,没有显示错误。
可以加入Telegram Support Force创建的@BotTalk群,询问其他人是否有同样的问题。
好像是临时bug,当天就修复了
感谢 Sean 建议 @BotTalk 问题已解决。