Wait for an email (OTP, verification link)
wait_for_messageWait for a new unread email matching filters and return its OTP code, links, and text; use after sign-up to capture verification messages before timeout.
Instructions
Return the newest UNREAD message matching the filters, or wait until one arrives.
The result includes otp (the one-time code found in the message, or null), codes, links and the text.
Returning a message marks it as read, so the next call waits for the next one. If nothing arrives in time,
status is "timeout": call again if the email may still come (for example the sign-up was just submitted).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| Yes | The email address, as returned by create_mailbox or list_mailboxes. | ||
| max_chars | No | Maximum characters of message text to return (longer text is cut). | |
| from_contains | No | Only messages whose sender name or address contains this text. | |
| timeout_seconds | No | How long to wait for a new message. | |
| subject_contains | No | Only messages whose subject contains this text. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| hint | No | ||
| Yes | |||
| status | Yes | ||
| message | No | ||
| message_id | No | ||
| waited_seconds | No |