View on GitHub

examples

Email testing and SMS verification examples using MailSlurp and a wide range of frameworks.

MailSlurp Examples 📨

Create email addresses on demand then send and receive emails in code and tests. Test apps end-to-end with real email addresses

This repository contains examples of MailSlurp usage with a range of different languages and frameworks. See the README.md or Makefile in each module for more information.

See developer page for more guides and documentation. If you notice an issue in the examples please open an issue, pull request, or contact support.

Start here

Use MailSlurp when your tests need real, private inboxes and phone numbers: each test gets its own address or number, waits for the message and reads the code, locally or in CI.

Task Example Guide
Test sign-up, password reset and magic-link emails in Playwright playwright-email-testing Playwright email testing
Test email flows in Cypress cypress-email-testing-starter Cypress email testing
Test SMS two-factor login with a real phone number playwright-sms-2fa-real-number SMS OTP testing
Render email templates on real email clients in CI email-rendering-ci Device previews
Fail a build when Gmail or Outlook put your email in spam inbox-placement-ci Inbox placement

Projects

Running locally

If you wish to run these examples yourself:

Static site

Examples are hosted statically on mailtesting.net. The site is built using Jeykll and hosted on GitHub pages. To update the site run make in the root directory. This will build the site. Commit the site and push to GitHub to update the live site.