MailSlurp logo

Insomnia MailSlurp integration

Use email and SMS APIs in Insomnia REST client.

View Markdown Agent setup

Use MailSlurp email and SMS APIs in Insomnia REST client.

Endpoint URL
Run insomnia.svg
Swagger Spec https://swagger.mailslurp.com
Get API KEY https://app.mailslurp.com

Set API Key authentication

Requests to MailSlurp must be authenticated with a MailSlurp API Key. There are several ways to do this:

Set xApiKey environment variable

Set the xApiKey variable in the environment settings to your MailSlurp API Key.

insomnia-collection-set-env.jpeg insomnia-set-api-key.jpeg

Set x-api-key header

Alternatively, set the x-api-key header in the Auth tab of a request to use your MailSlurp API Key.

insomnia-request-auth.jpeg

Setup instructions

MailSlurp has an OpenAPI specification that can be imported into Insomnia as a document or a collection.

Import document

  1. Open Insomnia and click Import in the bottom left

  1. Paste in the MailSlurp Swagger url: https://swagger.mailslurp.com

  1. Click Scan to import the MailSlurp API collection.

Import collection

You can also import collections and execute requests.

  1. In your collection click the + icon in the request tab

insomnia-collection-1.jpeg

  1. Import the collection via the URL import of https://swagger.mailslurp.com

insomnia-collection-2.jpeg

  1. Execute requests in the collection panel insomnia-collection-3.jpeg