Skip to contentSkip to navigationSkip to topbar
Rate this page:
On this page

Create Single Send



API Overview

api-overview page anchor

A Single Send is a one-time, non-automated email message delivered to a list or segment of your audience. A Single Send may be sent immediately or scheduled for future delivery.

Single Sends can serve many use cases, including promotional offers, engagement campaigns, newsletters, announcements, legal notices, or policy updates.

The Single Sends API allows you to create, retrieve, update, delete, schedule, and deliver your Single Sends. There are also endpoints for searching and statistics to help you maintain and alter your Single Sends as you learn more and further develop your campaigns.

The Single Sends API changed on May 6, 2020. Please check the SendGrid Knowledge Center for updates and instructions here: https://sendgrid.com/docs/for-developers/sending-email/single-sends-2020-update/


POST/v3/marketing/singlesends

Base url: https://api.sendgrid.com

This endpoint allows you to create a new Single Send.

Please note that if you are migrating from the previous version of Single Sends, you no longer need to pass a template ID with your request to this endpoint. Instead, you will pass all template data in the email_config object.

This endpoint will create a draft of the Single Send but will not send it or schedule it to be sent. Any send_at property value set with this endpoint will prepopulate the Single Send's send date. However, the Single Send will remain an unscheduled draft until it's updated with the Schedule Single Send endpoint or SendGrid application UI.


Authentication

authentication page anchor
Property nameTypeRequiredDescription
Authorizationstringrequired
Default: Bearer <<YOUR_API_KEY_HERE>>
Schema
Property nameTypeRequiredDescriptionChild properties
namestringrequired

The name of the Single Send.

Min length: 1Max length: 100

categoriesarray[string]Optional

The categories to associate with this Single Send.


send_atstring<date-time> or nullOptional

Set this property to an ISO 8601 formatted date-time when you would like to send the Single Send. Please note that any send_at property value set with this endpoint will prepopulate the send date in the SendGrid user interface (UI). However, the Single Send will remain an unscheduled draft until it's updated with the Schedule Single Send endpoint or SendGrid application UI. Additionally, the now keyword is a valid send_at value only when using the Schedule Single Send endpoint. Setting this property to now with this endpoint will cause an error.


send_toobjectOptional

email_configobjectOptional
201400500
SchemaExample
Property nameTypeRequiredDescriptionChild properties
idstring<uuid>

The unique ID for the Single Send.


namestring

The name of the Single Send.

Min length: 1Max length: 100

statusenum<string>

The current status of the Single Send. The status may be draft, scheduled, or triggered.

Possible values:
draftscheduledtriggered

categoriesarray[string]

The categories associated with this Single Send.


send_atstring<date-time> or null

An ISO 8601 formatted date-time when the Single Send is set to be sent. Please note that any send_at property value will have no effect while the Single Send status is draft. You must update the Single Send with the Schedule Single Send endpoint or SendGrid application UI to schedule it.


send_toobject

updated_atstring<date-time>

the ISO 8601 time at which the Single Send was last updated.


created_atstring<date-time>

the ISO 8601 time at which the Single Send was created.


email_configobject

warningsarray[object]

Create Single Send

create-single-send page anchor
Node.js
Python
C#
Java
Go
PHP
Ruby
curl

_21
const client = require('@sendgrid/client');
_21
client.setApiKey(process.env.SENDGRID_API_KEY);
_21
_21
const data = {
_21
"name": "Miss Christine Morgan"
_21
};
_21
_21
const request = {
_21
url: `/v3/marketing/singlesends`,
_21
method: 'POST',
_21
body: data
_21
}
_21
_21
client.request(request)
_21
.then(([response, body]) => {
_21
console.log(response.statusCode);
_21
console.log(response.body);
_21
})
_21
.catch(error => {
_21
console.error(error);
_21
});


Rate this page: