Templates · Email

SendGrid Mail API collection template

Send email, manage contacts and check bounces with the SendGrid v3 API.

What's inside

Send a transactional email with the SendGrid v3 Mail Send API, add a marketing contact, and look at bounces and API key scopes.

4 requests in 2 folders · Base URL https://api.sendgrid.com/v3 · Bearer token

Set it up

  1. Open SendGrid Mail API in Requestarium (or in the app: Import, Start from a template) and import it. You get the collection and a "SendGrid Mail API" environment.
  2. Create an API key with Mail Send access in SendGrid, Settings, API Keys, and verify the sender address you put in fromEmail.
  3. Fill in the environment, pick it in the environment menu and send the first request.

Environment variables

VariableWhat it is
sendgridApiKeysecretAPI key, SG.…
fromEmailA verified sender address.
toEmailRecipient address.

Requests

Mail

  • POST
    Send an email /mail/send

    Answers 202 Accepted with an empty body.

  • GET
    List bounces /suppression/bounces

    Addresses that bounced.

Contacts and keys

  • PUT
    Add or update a contact /marketing/contacts

    Upserts a marketing contact; runs as a background job.

  • GET
    API key scopes /scopes

    What the key is allowed to do; a quick way to check it.