Actions24
- Chat Actions
- Callback Actions
- File Actions
- Message Actions
Overview
This node operation answers an inline query callback from Telegram. It is used to respond to inline queries sent by users interacting with a Telegram bot, providing a JSON-serialized array of results as the response. This is useful for bots that offer inline search or content suggestions directly within the chat interface.
Use Case Examples
- A bot that provides inline search results for GIFs or images based on user input.
- A bot that offers inline product suggestions or quick replies in a chat.
Properties
| Name | Meaning |
|---|---|
| Query ID | Unique identifier for the answered inline query, used to specify which query is being answered. |
| Results | A JSON-serialized array of results to be sent as the answer to the inline query. |
| Additional Fields | Optional parameters to customize the response, such as cache time, whether to show an alert, notification text, and a URL to open. |
Output
JSON
jsoninline_query_id- The unique identifier of the inline query answered.results- The array of results sent as the answer to the inline query.cache_time- The cache time set for the inline query results.show_alert- Indicates if an alert was shown instead of a notification.text- Notification text shown to the user.url- URL opened by the user's client if specified.
Dependencies
- Telegram API access with an API key credential
Troubleshooting
- Ensure the 'Query ID' is correctly obtained from the inline query callback to avoid errors.
- The 'Results' must be a valid JSON-serialized array; invalid JSON will cause the request to fail.
- If the bot does not have permission to answer inline queries, the API call will fail.
- Check that optional fields like 'cache_time' and 'show_alert' are set correctly according to Telegram API specifications.
Links
- Telegram Bot API - answerInlineQuery - Official Telegram API documentation for answering inline queries.