mailslurp-client
Official MailSlurp Python SDK Email API
What it is and what it does
MailSlurp is a Python SDK for an email API service that enables you to create real email addresses in code, then send and receive emails and attachments from Python applications and tests. You configure it with an API key, then use controller classes (InboxController, EmailController, WaitForController, etc.) to manage inboxes, send emails via SMTP, wait for incoming messages, and download attachments. The package wraps HTTP calls to the MailSlurp backend service, so it requires network access and an active account.
The typical workflow is: create an inbox to get a real email address, optionally configure SMTP access for that inbox, send emails through the API or SMTP, then poll or wait for incoming emails and extract their content and attachments. It's designed for test automation, temporary email scenarios, and programmatic email workflows where you need real email addresses rather than mocks.
Use it for:
- Automated testing of email-dependent features in web applications or services
- Generating temporary email addresses for user registration or verification workflows
- Sending transactional emails from code without managing your own mail server
- Receiving and parsing emails in integration tests to verify email content and attachments
- Building email-driven automation or notification systems that need real email addresses
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
MailSlurp provides a Python client for an email API service that lets you create real email addresses on demand and send or receive emails and attachments programmatically.
Yes, if you need real email addresses and email operations in Python code or tests. The package has low install friction, active maintenance, no known vulnerabilities, and a clear use case for testing and automation. The main condition is that you must have a MailSlurp account and API key; verify the service's free tier limits and pricing before committing to it.
Install
mailslurp-client on PyPI
pip
pip install mailslurp-clientuv
uv add mailslurp-clientpoetry
poetry add mailslurp-clientInstalling mailslurp-client
Before you install
Low install friction with standard HTTP and date-handling dependencies. Package is actively maintained with a recent release.
Quickstart
pip install mailslurp-client
import mailslurp_client
configuration = mailslurp_client.Configuration()
configuration.api_key["x-api-key"] = YOUR_API_KEY
with mailslurp_client.ApiClient(configuration) as api_client:
inbox_controller = mailslurp_client.InboxControllerApi(api_client)
inbox = inbox_controller.create_inbox_with_defaults()
print(inbox.email_address)
You must obtain a MailSlurp API key by creating an account at https://app.mailslurp.com
Verify before relying
- Whether free tier API access is available or if a paid account is required to use the service
- Rate limits or quotas on email creation, sending, or receiving operations
- Data retention policies for emails and attachments stored via the API
- Whether the service provides webhook or polling mechanisms for real-time email notifications
Package facts
| License | not declared (unclear) |
| Python support | not specified |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 4 — urllib3, six, certifi, python-dateutil |
| Maintenance | actively maintained — 136 days since the last release |
| First released | |
| Downloads | 200,607/month — #9,687 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: mailslurp_client-17.5.0-py3-none-any.whl
Keywords: MailSlurp, Email, SMTP, Mailer, MailSlurp API, Test
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
mailosaurMailosaur is a Python client library for…
permissive · top 15,000 on PyPI
mailtrapOfficial Python client for Mailtrap's email…
permissive · top 15,000 on PyPI
sparkpostOfficial Python client for the SparkPost email…
permissive · top 15,000 on PyPI
temp-mailsProvides a unified Python API to generate…
permissive · top 15,000 on PyPI
emailsBuild and send HTML and plain-text emails with…
permissive · top 15,000 on PyPI
neverbounce-sdkPython client library for the NeverBounce email…
permissive · top 15,000 on PyPI
imap-toolsA high-level Python library for IMAP email…
permissive · top 15,000 on PyPI
simplegmailA Python wrapper around the Gmail API that…
permissive · top 15,000 on PyPI
postmarkerPostmarker is a Python client library for the…
permissive · top 5,000 on PyPI
mailchimp3A Python client for MailChimp API v3 that wraps…
permissive · top 15,000 on PyPI