Quickstart
1. Get a sandbox key
curl -X POST https://api.live-direct-marketing.online/v1/signup \
-H "Content-Type: application/json" \
-d '{"email":"agent@example.com"}'Real 201 response (verified by curl):
{
"api_key": "ldm_pk_xoSydVRtHqisjkb1rFtVYkOjC28ZeDMe",
"key_id": "cmoue9vhr0009dukujccfbmcj",
"flow": "sandbox",
"scope": "sandbox",
"moderation_status": "pending",
"quota": {
"monthly": 500,
"remaining": 500,
"resets_at": "2026-06-01T00:00:00.000Z"
},
"next_steps": {
"message": "Your sandbox key is active. Messages are queued for moderation before delivery.",
"billing_contact": "welcome@live-direct-marketing.online"
},
"docs": "https://developers.live-direct-marketing.online/"
}2. Send a message
curl -X POST https://api.live-direct-marketing.online/v1/messages \
-H "Authorization: Bearer ldm_pk_..." \
-H "Content-Type: application/json" \
-d '{
"to": "test@example.com",
"subject": "Hello from my agent",
"body": "Plain-text or HTML body."
}'Real 202 response on a sandbox key:
{
"id": "cmoue9vyt000idukuojjrsbv0",
"status": "queued_for_moderation",
"queued_at": "2026-05-06T18:32:27.413Z",
"message": "Your message is held for moderation. You will be notified when approved.",
"billing_contact": "welcome@live-direct-marketing.online"
}3. Check status
curl -H "Authorization: Bearer ldm_pk_..." \
https://api.live-direct-marketing.online/v1/messages/cmoue9vyt000idukuojjrsbv0Real response shape:
{
"id": "cmoue9vyt000idukuojjrsbv0",
"status": "queued_for_moderation",
"to": "test@example.com",
"subject": "Hello from my agent",
"queued_at": "2026-05-06T18:32:44.103Z",
"sent_at": null,
"failed_at": null,
"error": null
}Python
import requests
API = "https://api.live-direct-marketing.online/v1"
# 1. signup
r = requests.post(f"{API}/signup", json={"email": "agent@example.com"})
key = r.json()["api_key"]
# 2. send
headers = {"Authorization": f"Bearer {key}"}
r = requests.post(
f"{API}/messages",
headers=headers,
json={"to": "test@example.com", "subject": "Hello", "body": "From my agent."},
)
msg_id = r.json()["id"]
# 3. status
r = requests.get(f"{API}/messages/{msg_id}", headers=headers)
print(r.json()["status"])