robotframework-imaplibrary2
A IMAP email testing library for Robot Framework
What it is and what it does
ImapLibrary2 is a Robot Framework extension that wraps IMAP protocol access to enable email-based test automation. It lets you connect to mailboxes, wait for incoming messages, extract and verify email content, and inspect multipart messages—all within Robot Framework's keyword-driven test syntax. The library handles the low-level IMAP protocol details so test authors can focus on email verification logic.
Typical use is in end-to-end testing workflows where your application sends transactional emails and you need to verify they arrived with correct content. It depends on robotframework as its primary runtime dependency, plus future for Python 2/3 compatibility and pysocks for proxy support. The package is a fork of an earlier robotframework-imaplibrary project and remains in beta status.
Use it for:
- Verify that password-reset emails arrive with correct verification links after user signup
- Validate email content and formatting in multipart messages sent by your application
- Wait for and extract one-time codes or confirmation URLs from automated transactional emails
- Test email delivery workflows by polling an IMAP mailbox during end-to-end test runs
- Inspect email headers and payloads to confirm sender, subject, and body content match expectations
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
A Robot Framework library that connects to IMAP mailboxes to retrieve, verify, and inspect email content during automated testing.
Yes, if you are already using Robot Framework for test automation and need to verify email-driven workflows. Install friction is low and the Apache 2.0 license is permissive. However, note that maintenance is aging (534 days since last release) and Python version support is unclear—verify compatibility with your target Python version before committing to it in a production test suite.
Install
robotframework-imaplibrary2 on PyPI
pip
pip install robotframework-imaplibrary2uv
uv add robotframework-imaplibrary2poetry
poetry add robotframework-imaplibrary2Installing robotframework-imaplibrary2
Before you install
Low install friction with a pure-Python wheel distribution. Maintenance is aging—last release was 534 days ago, though the repository remains active with a recent commit on 2025-02-26. Depends on robotframework, future, and pysocks, all stable packages.
License in practice
Licensed under Apache License, Version 2.0 (permissive), which allows commercial and private use with minimal restrictions. No licensing barrier to adoption.
Quickstart
pip install robotframework-imaplibrary2
In a Robot Framework test file:
*** Settings ***
Library ImapLibrary2
*** Test Cases ***
Verify Email
Open Mailbox host=imap.domain.com user=email@domain.com password=secret
${email} = Wait For Email sender=noreply@domain.com timeout=300
Close Mailbox
Requires Robot Framework to be installed and a working IMAP server connection with valid credentials.
Verify before relying
- Current Python version support (classifiers list 2.7 and 3.5, but requires_python is unspecified)
- Whether pysocks is used for proxy support or is a transitive dependency
- Active maintenance cadence and responsiveness to issues given aging status
Package facts
| License | Apache License, Version 2.0 (permissive) |
| Python support | not specified |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 3 — future, robotframework, pysocks |
| Maintenance | aging — 534 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 78,969/month — #14,388 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: robotframework_imaplibrary2-0.4.11-py2.py3-none-any.whl
Keywords: robot, framework, testing, automation, imap, email, mail, softwaretesting
Tags
More Testing packages
Pluggy provides a plugin system that lets you…
permissive · top 100 on PyPI
pytestpytest is a testing framework that lets you…
permissive · top 100 on PyPI
virtualenvvirtualenv creates isolated Python environments…
permissive · top 100 on PyPI
coverageCoverage.py measures which lines of Python code…
permissive · top 1,000 on PyPI
pytest-asynciopytest-asyncio is a pytest plugin that enables…
permissive · top 1,000 on PyPI
pytest-json-ctrfA pytest plugin that generates test reports in…
permissive · top 1,000 on PyPI
robotframework-extendedselenium2libraryA Robot Framework library for web browser…
agpl · top 15,000 on PyPI
robotremoteserverHosts Robot Framework test libraries on…
permissive · top 15,000 on PyPI
robotframework-seleniumlibrarySeleniumLibrary is a Robot Framework library…
permissive · top 5,000 on PyPI
imap-toolsA high-level Python library for IMAP email…
permissive · top 15,000 on PyPI
IMAPClientIMAPClient provides a Pythonic interface to…
permissive · top 5,000 on PyPI
robotframework-databaselibraryA Robot Framework library that adds keywords…
permissive · top 15,000 on PyPI
mailsuitemailsuite retrieves, parses, and sends emails…
permissive · top 15,000 on PyPI
robotframework-selenium2libraryA Robot Framework library that wraps Selenium…
permissive · top 15,000 on PyPI
robotframework-debuglibraryProvides an interactive debug shell and library…
permissive · top 15,000 on PyPI
aioimaplibAn asyncio-based IMAP4rev1 client library that…
copyleft · top 15,000 on PyPI