Read messages from a WhatsApp chat
read_messagesRetrieve messages from a single WhatsApp chat, oldest to newest. Page back through older history by passing the oldest message ID you already have.
Instructions
Read messages from one chat, oldest to newest.
Without before you get the most recent messages. Pass before (the oldest
message_id you already have) to page further back; wazap asks the phone for
older history when the local store runs out, which takes a few seconds.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | Maximum number of messages (1-200) | |
| types | No | Keep only these message types; omit for every type. The limit counts matching messages, so ["call"] returns that many calls, not that many messages of which some are calls. | |
| before | No | Return the messages immediately older than this message_id | |
| chat_id | Yes | Chat id as returned by another tool ("<digits>@s.whatsapp.net" or "<id>@g.us"), or a phone number in international format | |
| account_id | No | Registry account id (default, work, …). Omit to resolve from chat_id or message_id, or the default account. | |
| include_previews | No | Attach a small JPEG of each photo, newest first, up to 12 per call, so you can see what was sent: the preview WhatsApp shipped when there is one, otherwise the photo is downloaded once and shrunk on the machine running wazap |