Answer Callback Query
telegram.answer_callback_query
ActionChat & messagingconnection required
Calls the Telegram API with the connection's credentials.
Answer an inline-keyboard button press with a toast or an alert.
Connection
- Required
- Yes — the node will not save without one
- Auth type
- API key
- Providers
- Telegram
- Secret shape
- the bot token, or {"token": "…"}
- Resolved by
- config.connection_id, else node.connection_id
Configuration
5 fields, 1 required. A dotted path is a nested object and name[] an array of objects — the editor renders the same tree.
| Field | Type | Required | Default | Constraints | Example |
|---|---|---|---|---|---|
callback_query_id Id of the callback query to answer, from the incoming update. | string | Yes | — | — | — |
text Notification text, 0-200 characters; nothing is shown when blank. | string | No | — | ≤ 200 characters | — |
show_alert Show a modal alert the user must dismiss instead of a toast. | boolean | No | — | — | — |
url URL the client opens; only works for a game button or a t.me/<bot>?start= link. | string | No | — | url format | — |
cache_time Seconds the client may cache this answer for; 0 means do not cache. | integer | No | — | ≥ 0 | — |
Output
One shape.
result
| Field | Type | Example |
|---|---|---|
ok True when Telegram accepted the call. | boolean | true |
callback_query_id The query that was answered. | string | — |
{
"callback_query_id": "",
"ok": true
}Notes
- chat_id is a numeric chat/user id or an @channelusername. A bot can only message a user who started it, or a group/channel it has been added to.
- The bot token sits in the request URL, so it is redacted out of every error message and dry-run report these nodes produce.
- Telegram answers HTTP 200 even for failures; the node reads the {'ok': …} envelope and raises on ok:false with Telegram's own description.
- Telegram expects every callback query to be answered, even with an empty text, or the button keeps spinning in the client.
See Answer Callback Query run in a workflow.
In a technical demo we add the Telegram connection, drop the node on the canvas and let Workflow Health pre-flight it before the first real run.