Single Sends
A Single Send is a one-time nonautomated 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/
Duplicate Single Send
POST /v3/marketing/singlesends/{id}
Base url: https://api.sendgrid.com
This endpoint allows you to duplicate an existing Single Send using its Single Send ID.
Duplicating a Single Send is useful when you want to create a Single Send but don't want to start from scratch. Once duplicated, you can update or edit the Single Send by making a PATCH request to the /marketing/singlesends/{id}
endpoint.
If you leave the name
field blank, your duplicate will be assigned the name of the Single Send it was copied from with the text “Copy of ” prepended to it. The name
field length is limited to 100 characters, so the end of the new Single Send name, including “Copy of ”, will be trimmed if the name exceeds this limit.
Authentication
- API Key
Headers
Request Body
The name of the duplicate Single Send. If you choose to leave the name field blank, your duplicate will be assigned the name of the Single Send it was copied from with the text 'Copy of ' prepended to it. The end of the new Single Send name, including 'Copy of ', will be trimmed if the name exceeds the character limit.
maxLength: 100minLength: 1Path Parameters
Responses
The name of the Single Send.
maxLength: 100minLength: 1The categories to associate with this Single Send.
maxItems: 10uniqueItems: TrueThe ISO 8601 time at which to send the Single Send. This must be in future or the string "now". Emails can be scheduled up to 72 hours in advance. However, this scheduling constraint does not apply to campaigns sent via Marketing Campaigns.
format: date-timeThe recipient List IDs that will receive the Single Send.
maxItems: 10The recipient Segment IDs that will receive the Single Send.
maxItems: 10Set to true
to send to All Contacts. If set to false
, at least one list_ids
or segment_ids
value must be provided before the Single Send is scheduled to be sent to recipients.
The subject line of the Single Send. Do not include this field when using a design_id
.
The HTML content of the Single Send. Do not include this field when using a design_id
.
The plain text content of the Single Send. Do not include this field when using a design_id
.
If set to true
, plain_content
is always generated from html_content
. If set to false, plain_content
is not altered.
A design_id
can be used in place of html_content
, plain_content
, and/or subject
. You can retrieve a design's ID from the "List Designs" endpoint or by pulling it from the design's detail page URL in the Marketing Campaigns App.
The editor — "design"
or "code"
— used to modify the Single Send's design in the Marketing Campaigns App.
The ID of the Suppression Group to allow recipients to unsubscribe — you must provide this or the custom_unsubscribe_url
.
The URL allowing recipients to unsubscribe — you must provide this or the suppression_group_id
.
The ID of the verified Sender. You can retrieve a verified Sender's ID from the "Get Verified Senders" endpoint or by pulling it from the Sender's detail page URL in the SendGrid App.
The name of the IP Pool from which the Single Send emails are sent.
current status of the Single Send
Allowed Values: draft, scheduled, triggeredthe ISO 8601 time at which the Single Send was last updated
format: date-timethe ISO 8601 time at which the Single Send was created
format: date-time{
"name": "Example API Created Single Send",
"id": "27c21bbf-a12c-440b-b8bf-c526975328ca",
"status": "scheduled",
"created_at": "2020-05-18T17:28:27.272Z",
"send_at": "2020-06-16T00:19:55.106Z",
"categories": [
"unique opens"
],
"email_config": {
"subject": "",
"html_content": "",
"plain_content": "",
"generate_plain_content": true,
"editor": "code",
"suppression_group_id": null,
"custom_unsubscribe_url": null,
"sender_id": null,
"ip_pool": null
},
"send_to": {
"list_ids": [
"f2fe66a1-43f3-4e3a-87b1-c6a600d805f0"
]
}
}
Need some help?
We all do sometimes. Get help now from the Twilio SendGrid Support Team.
Running into a coding hurdle? Lean on the wisdom of the crowd by browsing the SendGrid tag on Stack Overflow or visiting Twilio's Stack Overflow Collective.