Please Wait...
| Method | POST |
|---|---|
| Request URL | https://insprl.com/api/email/send-email |
| Authentication | Required How to Generate API keys? |
| Parameter | Type | Description |
|---|---|---|
| Authorization | String | Use your "CLIENT KEY" for this Parameter |
| Parameter | Type | Validate | Description |
|---|---|---|---|
| client_id | String | Required | Use your "CLIENT ID" for this Parameter |
| email_type | String | Required | Define email route "txn" for Transaction or "promo" for Promotional |
| sender_email | String | Required | Mailing Sender Email Address |
| groupslug | String | Required | Add Group Slug |
| subject | String | Required | Add Email Subject |
| mail_body | String | Required | Email Message |
| campaign_name | String | Optional | Maximum 100 characters allowed. |
| files | URL | Optional | Add multiple file URls with comma separated (Max 4 urls) |
| Parameter | Type | Description |
|---|---|---|
| code | Numeric | Find the code information below under "API Codes" |
| message | String / Array | As per the request handler |
| data | Array | Response parameters:
|
| Code | Mode | Type | Description |
|---|---|---|---|
| 100 | success | String | On Success |
| 101 | failed | String | Authorization Error |
| 102 | failed | Array | Parameter Validation Error |
echo <<$ch = curl_init();
curl_setopt($ch, CURLOPT_URL,"https://insprl.com/api/email/send-email");
curl_setopt($ch, CURLOPT_POST, 1);
curl_setopt($ch, CURLOPT_HTTPHEADER,
array( 'Authorization: {CLIENT_KEY}'
));
curl_setopt($ch, CURLOPT_POSTFIELDS,
http_build_query(
array(
'client_id' => '{CLIENT_ID}',
'sender_email' => 'marketing@website.com',
'recipient_email' => 'customeremail@example.com',
'subject' => 'Welcome to My Site',
'mail_body' => 'Dear Customer, Write you message here.',
'campaign_name' => 'Marketing Campaign 1',
'files' => 'https://insprl.com/resource-doc/SPRL-SAMPLE-API-DOCUMENT.pdf,https://insprl.com/uploads/logo/logo-300.png',
)
));
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, 10);
curl_setopt($ch, CURLOPT_TIMEOUT, 10);
$response = curl_exec($ch);
curl_close ($ch); {
"code":"100",
"message":"success",
"data":{
"queue_id":"95510990",
"status":"accepted",
"msg":"Mail Queued"
}
} If you'd like to use our REST API into your application, Feel free to contact us.
8088 948 172 or Contact Us
Read our latest posts from our blog
If you are into marketing, you must have heard of Bulk URL shortening. They are saying Bulk URL shortening is the new ..
Every profit driven business enterprise is adopting and incorporating URL Shortening as a part of best business ..
If your company or business isn’t using email promoting, ought to they? The solution is affirmative, as email is ..
We use cookies to improve your experience, analyse traffic, and personalise content. By clicking “Accept”, you consent to the use of cookies as described in our Cookie Policy .
Accept cookies Learn more