API Key (how to configure MailSlurp)

Use your api access token to call the MailSlurp API and control your inboxes remotely.

The MailSlurp email inbox API is free for personal use but requires an API KEY to be used. This page explains to get an API KEY and how to configure HTTP requests or SDK clients to use the MailSlurp API.

Create an account

First create an account or sign into your dashboard. You will see the API key displayed on the home page once logged in.

Configure HTTP requests

curl -H x-api-key:YOUR_API_KEY -X POST https://api.mailslurp.com/inboxes

Configure SDK Clients

See the documentation for each client or use the example below to configure the NodeJS package:

const apiKey = process.env.API_KEY ?? 'your-apikey';
const { MailSlurp } = require('mailslurp-client');
const mailslurp = new MailSlurp({ apiKey });

Ready to dive in?Start building email applications today.