MailSlurp Examples

Developer example projects and guides are available in many languages and frameworks.

Sign up for a free account and integrate MailSlurp into your application or test. Try an example project to learn how or see the examples repository on GitHub. For tutorials and guides please see the usage guide section or the API documentation.

Recommended

CypressJS Email Testing

Use real email accounts in CypressJS to test user sign-up, email verification, and more.

.NET Selenium C#

Send and receive email in DotNET Nunit tests using Selenium and MailSlurp.

Java, Selenium

Receive emails in Java test suites using MailSlurp, Junit, and Selenium.

Featured

Jest, Puppeteer

Test email accounts in React with Jest and Puppeteer. Send and receive emails in Javascript.

Python Robot Framework email test

Python automation email testing Robotframework plugin

Testing authentication using real email addresses in Ruby with Capybara, Cucumber, and Selenium

Cucumber example project using Capybara to test user authentication using real email addresses.

TestCafe end-to-end MFA testing for user sign-up and email verification

End-to-end testing with MailSlurp, NodeJS, and TestCafe.

Test applications with real emails using Serenity BDD, JBehave and Selenium

Email acceptance testing with Serenity and MailSlurp. Test applications with real email addresses.

PHP Email Test Plugins: send and receive email in PHPUnit (example code)

How to send and receive emails in PHPUnit tests.

How to send and read email in Laravel (PHP)

Email tutorial for Laravel and Composer. Create mailboxes and compose mail using PHP.

Golang mail Library (SMTP)

How to send and receive emails in Go (test email addresses).

Codeception PHP acceptance testing using real email address APIs

Write acceptance tests in PHP with real email addresses using Codeception and MailSlurp

Webdriver, JS, WDIO

Test email related processes like sign-up and verification using WDIO WebDriver and MailSlurp.

TestNG Selenium Java Example

Testing user sign up in Java using TestNG and MailSlurp test email accounts

Specflow user sign-up testing with MailSlurp accounts

How to test .NET authentication and sign-up using real email accounts with MailSlurp and SpecFlow.

PyTest Email Testing

Send and receive email in Pytest Python tests.

Java JVM Examples

Test email sending and receive emails without a mail server.

CypressJS Example

Test email sign-up, password verification and more with Cypress JS and MailSlurp. Capture OTP magic links and test auth flows end-to-end.

Cucumber, Ruby

Generate test email accounts with Ruby and Cucumber. Test email sign-up, password verification and more.

.NET Selenium C#

Send and receive email in DotNET Nunit tests using Selenium and MailSlurp.

Other

Send and receive email in Swift using MailSlurp email API

Send email in Javascript with MailSlurp email API

Test email in PHP using real email addresses

Use disposable email accounts with Playwright JS to test application end-to-end with real emails.

Ensure email delivery using MailSlurp scalable message queues

How to create SDK libraries a language of your choice