Overview
Use this method to send a single email from a created message to a contact who is subscribed to the message list.
The Method
API | - | Method |
---|---|---|
REST | POST | https://[Your URL]/api/3.0/emails/resend/emailId |
The ’emailId’ is the ID of the message that you want to resend.
Parameters
Required Parameters
You must include the properties of the email you want to create.
Property | Type | Description |
---|---|---|
contact id | integer | The contact id is the ID of the contact you want to re-send it to |
The API will only send to a contact on the list of the originally sent message.
Responses
The system will return either a success or failure message. If the request failed, the system will provide you with an error message.
Code Samples
$json = ' { "contactId":1, } '; $url = '(Your URL)/api/3.0/emails/resend/(The emailId)'; $method = 'POST'; $cSession = curl_init(); $headers = array(); $auth = base64_encode($username . ':' . $apikey); $headers[] = 'Authorization: Basic ' . $auth; curl_setopt($cSession, CURLOPT_URL, $url); curl_setopt($cSession, CURLOPT_RETURNTRANSFER, true); curl_setopt($cSession, CURLOPT_HEADER, false); curl_setopt($cSession, CURLOPT_CUSTOMREQUEST, strtoupper($method)); curl_setopt($cSession, CURLOPT_POSTFIELDS, $json); $headers[] = 'Content-Type: application/json'; curl_setopt($cSession, CURLOPT_HTTPHEADER, $headers); $result = curl_exec($cSession); curl_close($cSession);