get_messages
Retrieve recent messages from any Telegram chat, with optional search and pagination controls.
Instructions
Read recent messages from one chat.
Args: chat: Chat id, @username, or exact/substring title. limit: Max messages (default 30, capped at 200). before_id: Only messages older than this message id (pagination). search: Optional full-text filter within the chat.
Returns message dicts (id, chat_id, date, sender_id, text, has_media, media_type).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| chat | Yes | ||
| limit | No | ||
| search | No | ||
| before_id | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |