Search Messages Within Specific Chat
search_messagesFind text keywords within a specific Telegram chat or supergroup. Retrieve matching past messages by chat ID and query, with an optional result limit.
Instructions
Search for text keywords within a specific Telegram chat or supergroup. Use when finding past conversations in a single chat. To search globally across all public channels, use search_global. To search the offline cache without live Telegram API calls, use search_cached_messages.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | Maximum number of items or records to retrieve (integer between 1 and 100). | |
| query | Yes | Search text string or keywords to match against messages, contacts, or entities. | |
| account | No | Optional account label for multi-account environments. If omitted in single-mode, the default account is used. In multi-mode without an account, read-only tools fan out across all configured accounts. | |
| chat_id | Yes | Target Telegram chat, group, supergroup, channel, or user identifier. Accepts numeric chat ID (e.g. -1001234567890 or 123456789), username (e.g. '@channel'), or phone number. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |