Get Recent Telegram Updates
telegram_get_updatesFetch recent incoming updates for your Telegram bot to discover chat IDs and read messages.
Instructions
Fetch recent incoming updates the bot has received (messages sent to it, chats it was added to, etc.). This is the primary way to discover a chat_id: ask the user to send any message to the bot (or add it to a group), then call this tool to read the resulting update and find the chat.id to use with telegram_send_message.
Note: calling this tool consumes the updates (Telegram's long-polling semantics), so previously fetched updates won't reappear on the next call once acknowledged.
Args:
limit (number): Max updates to return, 1-100 (default: 20)
offset (number, optional): Only return updates at/after this update_id
Returns: JSON list of updates with chat_id, chat type/title, sender, and message text for each.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | Maximum number of recent updates to return (1-100, default 20) | |
| offset | No | Only return updates with update_id greater than or equal to this value. Omit to get the most recent updates. |