Connect an IMAP mailbox
connect_imap_accountConnect a mailbox over IMAP with explicit credentials, instead of the OAuth providers (get_email_connect_url). profileId is required; get ids from list_profiles. The IMAP (and SMTP, when given) login is tested first and fails with 400 if it does not connect; a mailbox already connected also fails with 400. Monitoring starts from now: older mail is not read until trigger_email_sync is run with days. To change settings later use update_imap_account. Returns the account with its id.
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": {
"profileId": "<profileId>",
"emailAddress": "<emailAddress>",
"host": "<host>",
"port": "<port>",
"secure": "<secure>",
"username": "<username>",
"password": "<password>"
},
"name": "connect_imap_account"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| host | Yes | IMAP server hostname, e.g. imap.fastmail.com. | |
| port | Yes | IMAP server port, usually 993 with TLS or 143 without. | |
| secure | Yes | true to connect over TLS (port 993), false for a plain connection. | |
| password | Yes | IMAP password or app password; stored encrypted and never returned. | |
| smtpHost | No | SMTP server hostname for sending replies; omit if the mailbox only receives. | |
| smtpPort | No | SMTP server port, e.g. 465 or 587. | |
| username | Yes | IMAP login username, often the email address. | |
| profileId | Yes | The profile this mailbox belongs to — required. | |
| displayName | No | Optional label shown for the mailbox. | |
| emailAddress | Yes | The mailbox's email address; cannot be changed later. |