---
title: "IMAP integration · RUAL Documentation"
description: "Use IMAP in RUAL blueprints. Read a mailbox: list folders, search and fetch messages, set flags, move, delete, and file a copy of what you sent."
canonical: https://docs.rual.nl/integrations/imap
language: en
---

# IMAP

Read a mailbox: list folders, search and fetch messages, set flags, move, delete, and file a copy of what you sent.

## Blocks

Add these blocks on the canvas by searching for their name. Each block page lists its pins and how it behaves.

- [append message `imapconnection_append` Files a raw message into a mailbox : typically a copy of what smtp send email just delivered, into the Sent folder, so the thread is complete in the user's mail client.](https://docs.rual.nl/block-types/imap/imapconnection_append)

- [delete messages `imapconnection_delete` Deletes messages by UID: flags them \Deleted and, by default, expunges them from the mailbox. Prefer imap move to the Trash folder when the account has one.](https://docs.rual.nl/block-types/imap/imapconnection_delete)

- [fetch messages `imapconnection_fetch` Downloads messages by UID and parses each into the same object mail parse produces : addresses, subject, text, html, attachments, headers. Does not mark them read unless mark seen is on.](https://docs.rual.nl/block-types/imap/imapconnection_fetch)

- [list mailboxes `imapconnection_list_mailboxes` Lists the mailboxes (folders) on the account, with their special-use role (inbox, sent, trash, …) and, optionally, their message counts.](https://docs.rual.nl/block-types/imap/imapconnection_list_mailboxes)

- [move messages `imapconnection_move` Moves messages by UID into another mailbox : the usual way to file what a flow has processed so the next poll does not see it again.](https://docs.rual.nl/block-types/imap/imapconnection_move)

- [open connection `imapconnection_open` Opens an IMAP connection to a mailbox server. Nothing is read until another imap block runs; with verify on, the block signs in once and reports the result on success so a flow can branch before it polls.](https://docs.rual.nl/block-types/imap/imapconnection_open)

- [search `imapconnection_search` Finds messages in a mailbox and returns their UIDs, newest first. Wire the UIDs into imap fetch to read them. Every criterion that is filled must match.](https://docs.rual.nl/block-types/imap/imapconnection_search)

- [set flags `imapconnection_set_flags` Marks messages read, unread, flagged, answered : or with a keyword of your own : by UID.](https://docs.rual.nl/block-types/imap/imapconnection_set_flags)

## Next steps

- [Third-Party Integrations](https://docs.rual.nl/tutorials/third-party-integrations): Calling outside APIs, receiving their webhooks, keeping data in sync and handling failures.

- [All integrations](https://docs.rual.nl/integrations): Everything RUAL connects to, by what it is for.
