Web API
JSON over HTTPS. Authentication via API key. Idempotent sends, batch endpoints and signed webhooks.
Base URL & authentication
Send your API key in the Api-Key header on every request.
| Setting | Value |
|---|---|
| Base URL | https://api.sendorx.com/v1 |
| Auth header | Api-Key: YOUR_KEY |
| Content-Type | application/json |
| Rate limit | 600 requests/min on Starter, scales with plan |
Send a transactional email
POST /v1/email — returns a messageId you can correlate with webhook events.
curl -X POST https://api.sendorx.com/v1/email \ -H "Api-Key: $SENDORX_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "from": {"email": "sender@yourdomain.com", "name": "Your App"}, "to": [{"email": "recipient@example.com"}], "subject": "Welcome to Your App", "html": "<h1>Hello</h1><p>Thanks for signing up.</p>", "tags": ["welcome", "v2"] }'
$payload = [ 'from' => ['email' => 'sender@yourdomain.com', 'name' => 'Your App'], 'to' => [['email' => 'recipient@example.com']], 'subject' => 'Welcome to Your App', 'html' => '<h1>Hello</h1>', ]; $ch = curl_init('https://api.sendorx.com/v1/email'); curl_setopt_array($ch, [ CURLOPT_POST => true, CURLOPT_RETURNTRANSFER => true, CURLOPT_HTTPHEADER => [ 'Api-Key: ' . getenv('SENDORX_API_KEY'), 'Content-Type: application/json', ], CURLOPT_POSTFIELDS => json_encode($payload), ]); $response = curl_exec($ch);
import os, requests resp = requests.post( 'https://api.sendorx.com/v1/email', headers={'Api-Key': os.environ['SENDORX_API_KEY']}, json={ 'from': {'email': 'sender@yourdomain.com', 'name': 'Your App'}, 'to': [{'email': 'recipient@example.com'}], 'subject': 'Welcome to Your App', 'html': '<h1>Hello</h1>', }, ) print(resp.json()['messageId'])
const resp = await fetch('https://api.sendorx.com/v1/email', { method: 'POST', headers: { 'Api-Key': process.env.SENDORX_API_KEY, 'Content-Type': 'application/json', }, body: JSON.stringify({ from: { email: 'sender@yourdomain.com', name: 'Your App' }, to: [{ email: 'recipient@example.com' }], subject: 'Welcome to Your App', html: '<h1>Hello</h1>', }), }); const { messageId } = await resp.json();
Endpoints overview
The full reference lives in your dashboard once you sign in.
| Method | Path | Purpose |
|---|---|---|
POST | /v1/email | Send a transactional email |
POST | /v1/email/batch | Send up to 1,000 messages in one call |
POST | /v1/campaigns | Create a marketing campaign |
GET | /v1/messages/{id} | Look up delivery status of a message |
GET | /v1/contacts | List contacts (paginated) |
POST | /v1/contacts | Create or upsert a contact |
POST | /v1/webhooks | Subscribe to event types |