Wait for email
wait_for_emailWait until a new email arrives in the mailbox (long-poll), then return it like read_email, including extracted codes and links. Returns {"timed_out": true} if nothing matching arrives in time; just call it again. By default only emails received after this call started count (or since the mailbox was created, if that was under 2 minutes ago); pass "after" (an email id or ISO time) to include earlier ones or skip ones you handled.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"mailbox": "<mailbox>"
},
"name": "wait_for_email"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| after | No | Only emails received after this email id (eml_…) or ISO 8601 time. Default: when this call started, or when the mailbox was created if that was under 2 minutes ago. | |
| mailbox | Yes | Mailbox id (mbx_…) or full email address. | |
| from_contains | No | Case-insensitive substring the sender name or address must contain. | |
| timeout_seconds | No | How long to wait (default 30, max 120). | |
| subject_contains | No | Case-insensitive substring the subject must contain. |