Open documentation ↗Overview
A cloud-based SMTP provider that allows you to send emails without having to maintain email servers
Sendgrid is an email API from sendgrid.com. Requests are authenticated with an API key. It is served over HTTPS. Its OpenAPI description documents 334 endpoints.
At a glance
- Authentication
- API key
- HTTPS
- Yes
- CORS
- Unknown
- Category
- Base URL
http://api.sendgrid.com/v3- Version
- 1.0.0
- Endpoints
- 334
- OpenAPI
- Specification ↗
- Spec updated
- 2023-03-06
Make a first request
Replace the placeholders; the documentation says exactly where credentials go.
curl -X GET "http://api.sendgrid.com/v3/access_settings/activity" \
-H "Accept: application/json" \
-H "X-API-Key: YOUR_API_KEY"const response = await fetch("http://api.sendgrid.com/v3/access_settings/activity", {
method: "GET",
headers: {
"Accept": "application/json",
"X-API-Key": "YOUR_API_KEY",
},
});
const data = await response.json();
console.log(data);import requests
response = requests.request(
"GET",
"http://api.sendgrid.com/v3/access_settings/activity",
headers={
"Accept": "application/json",
"X-API-Key": "YOUR_API_KEY",
},
timeout=30,
)
print(response.json())Endpoints
| Method | Path | What it does |
|---|---|---|
| GET | /access_settings/activity | Retrieve all recent access attempts |
| GET | /access_settings/whitelist | Retrieve a list of currently allowed IPs |
| POST | /access_settings/whitelist | Add one or more IPs to the allow list |
| DELETE | /access_settings/whitelist | Remove one or more IPs from the allow list |
| GET | /access_settings/whitelist/{rule_id} | Retrieve a specific allowed IP |
| DELETE | /access_settings/whitelist/{rule_id} | Remove a specific IP from the allowed list |
| GET | /alerts | Retrieve all alerts |
| POST | /alerts | Create a new Alert |
| GET | /alerts/{alert_id} | Retrieve a specific alert |
| PATCH | /alerts/{alert_id} | Update an alert |
| DELETE | /alerts/{alert_id} | Delete an alert |
| GET | /api_keys | Retrieve all API Keys belonging to the authenticated user |
| POST | /api_keys | Create API keys |
| GET | /api_keys/{api_key_id} | Retrieve an existing API Key |
| PUT | /api_keys/{api_key_id} | Update API key name and scopes |
| PATCH | /api_keys/{api_key_id} | Update API key name |
| DELETE | /api_keys/{api_key_id} | Delete API keys |
| GET | /asm/groups | Retrieve all suppression groups associated with the user. |
| POST | /asm/groups | Create a new suppression group |
| GET | /asm/groups/{group_id} | Get information on a single suppression group. |
| PATCH | /asm/groups/{group_id} | Update a suppression group. |
| DELETE | /asm/groups/{group_id} | Delete a Suppression Group |
| GET | /asm/groups/{group_id}/suppressions | Retrieve all suppressions for a suppression group |
| POST | /asm/groups/{group_id}/suppressions | Add suppressions to a suppression group |
| POST | /asm/groups/{group_id}/suppressions/search | Search for suppressions within a group |
| DELETE | /asm/groups/{group_id}/suppressions/{email} | Delete a suppression from a suppression group |
| GET | /asm/suppressions | Retrieve all suppressions |
| POST | /asm/suppressions/global | Add recipient addresses to the global suppression group. |
| GET | /asm/suppressions/global/{email} | Retrieve a Global Suppression |
| DELETE | /asm/suppressions/global/{email} | Delete a Global Suppression |
| GET | /asm/suppressions/{email} | Retrieve all suppression groups for an email address |
| GET | /browsers/stats | Retrieve email statistics by browser. |
| GET | /campaigns | Retrieve all Campaigns |
| POST | /campaigns | Create a Campaign |
| GET | /campaigns/{campaign_id} | Retrieve a single campaign |
| PATCH | /campaigns/{campaign_id} | Update a Campaign |
| DELETE | /campaigns/{campaign_id} | Delete a Campaign |
| GET | /campaigns/{campaign_id}/schedules | View Scheduled Time of a Campaign |
| POST | /campaigns/{campaign_id}/schedules | Schedule a Campaign |
| PATCH | /campaigns/{campaign_id}/schedules | Update a Scheduled Campaign |
| DELETE | /campaigns/{campaign_id}/schedules | Unschedule a Scheduled Campaign |
| POST | /campaigns/{campaign_id}/schedules/now | Send a Campaign |
| POST | /campaigns/{campaign_id}/schedules/test | Send a Test Campaign |
| GET | /categories | Retrieve all categories |
| GET | /categories/stats | Retrieve Email Statistics for Categories |
| GET | /categories/stats/sums | Retrieve sums of email stats for each category [Needs: Stats object defined, has category ID?] |
| GET | /clients/stats | Retrieve email statistics by client type. |
| GET | /clients/{client_type}/stats | Retrieve stats by a specific client type. |
| GET | /contactdb/custom_fields | Retrieve all custom fields |
| POST | /contactdb/custom_fields | Create a Custom Field |
| GET | /contactdb/custom_fields/{custom_field_id} | Retrieve a Custom Field |
| DELETE | /contactdb/custom_fields/{custom_field_id} | Delete a Custom Field |
| GET | /contactdb/lists | Retrieve all lists |
| POST | /contactdb/lists | Create a List |
| DELETE | /contactdb/lists | Delete Multiple lists |
| GET | /contactdb/lists/{list_id} | Retrieve a single list |
| PATCH | /contactdb/lists/{list_id} | Update a List |
| DELETE | /contactdb/lists/{list_id} | Delete a List |
| GET | /contactdb/lists/{list_id}/recipients | Retrieve all recipients on a List |
| POST | /contactdb/lists/{list_id}/recipients | Add Multiple Recipients to a List |
| POST | /contactdb/lists/{list_id}/recipients/{recipient_id} | Add a Single Recipient to a List |
| DELETE | /contactdb/lists/{list_id}/recipients/{recipient_id} | Delete a Single Recipient from a Single List |
| GET | /contactdb/recipients | Retrieve recipients |
| POST | /contactdb/recipients | Add recipients |
| PATCH | /contactdb/recipients | Update Recipient |
| DELETE | /contactdb/recipients | Delete Recipients |
| GET | /contactdb/recipients/billable_count | Retrieve the count of billable recipients |
| GET | /contactdb/recipients/count | Retrieve a Count of Recipients |
| GET | /contactdb/recipients/search | Search recipients |
| POST | /contactdb/recipients/search | Search recipients |
| GET | /contactdb/recipients/{recipient_id} | Retrieve a single recipient |
| DELETE | /contactdb/recipients/{recipient_id} | Delete a Recipient |
| GET | /contactdb/recipients/{recipient_id}/lists | Retrieve the lists that a recipient is on |
| GET | /contactdb/reserved_fields | Retrieve reserved fields |
| GET | /contactdb/segments | Retrieve all segments |
| POST | /contactdb/segments | Create a Segment |
| GET | /contactdb/segments/{segment_id} | Retrieve a segment |
| PATCH | /contactdb/segments/{segment_id} | Update a segment |
| DELETE | /contactdb/segments/{segment_id} | Delete a segment |
| GET | /contactdb/segments/{segment_id}/recipients | Retrieve recipients on a segment |
| GET | /contactdb/status | Get Recipient Upload Status |
| GET | /designs | List Designs |
| POST | /designs | Create Design |
| GET | /designs/pre-builts | List SendGrid Pre-built Designs |
| GET | /designs/pre-builts/{id} | Get SendGrid Pre-built Design |
| POST | /designs/pre-builts/{id} | Duplicate SendGrid Pre-built Design |
| GET | /designs/{id} | Get Design |
| POST | /designs/{id} | Duplicate Design |
| PATCH | /designs/{id} | Update Design |
| DELETE | /designs/{id} | Delete Design |
| GET | /devices/stats | Retrieve email statistics by device type. |
| GET | /geo/stats | Retrieve email statistics by country and state/province. |
| GET | /ips | Retrieve all IP addresses |
| POST | /ips | Add IPs |
| GET | /ips/assigned | Retrieve all assigned IPs |
| GET | /ips/pools | Retrieve all IP pools |
| POST | /ips/pools | Create an IP pool |
| GET | /ips/pools/{pool_name} | Retrieve all the IPs in a specified pool |
| PUT | /ips/pools/{pool_name} | Rename an IP pool |
| DELETE | /ips/pools/{pool_name} | Delete an IP pool |
Showing the first 100 of 334 endpoints; the full list is in the documentation.
Questions
Does the Sendgrid API need an API key?
Yes. The Sendgrid API uses API key authentication; the documentation explains how to get credentials.
Does the Sendgrid API support HTTPS?
Yes, the Sendgrid API is served over HTTPS.
How many endpoints does the Sendgrid API have?
Its OpenAPI description lists 334 endpoints in version 1.0.0. The first 100 are shown on this page.
What are alternatives to the Sendgrid API?
Other Email APIs include Sendinblue, mail.tm, Mandrill, Guerrilla Mail, Postmark Account-level API.
Similar email APIs
Compare alternatives →Sendinblue
EmailA service that provides solutions relating to marketing and/or transactional email and/or SMS
mail.tm
EmailTemporary Email Service
Mandrill
EmailMandrill is a reliable, scalable, and secure delivery API for transactional emails from websites and applications. It's ideal for sending data-driven transactional emails, including targeted e-commerce and personalized one-to-one messages.
Guerrilla Mail
EmailDisposable temporary Email addresses
Postmark Account-level API
EmailPostmark makes sending and receiving email incredibly easy. The Account-level API allows users to configure all Servers, Domains, and Sender Signatures associated with an Account.
ImprovMX
EmailAPI for free email forwarding service
Listed from public-apis (MIT), public-apis database (MIT), APIs.guru (CC0).