API Documentation
Send emails with a single HTTP request.
Endpoint
POST /api/send
Authentication
Include a Bearer token in the Authorization header.
Authorization: Bearer YOUR_API_KEY
Request Body
Send as application/x-www-form-urlencoded or application/json.
| Field | Required | Description |
|---|---|---|
to |
Yes | Recipient email address |
subject |
Yes | Email subject line |
body |
No | Email body (HTML supported) |
from |
No | Sender address. Defaults to Congo <congo@theskyscape.com> |
template_id |
No | ID of a saved template. Uses template body and subject if not overridden. |
vars |
No | JSON object of variables to substitute in the template, e.g. {"name":"World"} |
Responses
200 — Success
{"status":"queued"}
401 — Unauthorized
{"error":"unauthorized"}
Missing or invalid Bearer token.
400 — Bad Request
{"error":"to and subject required"}
The to and subject fields are required.
Example
curl -X POST https://email.congo.gg/api/send \ -H "Authorization: Bearer YOUR_API_KEY" \ -H "Content-Type: application/x-www-form-urlencoded" \ -d "to=user@example.com" \ -d "subject=Hello from Congo" \ -d "body=<h1>Welcome</h1><p>Your account is ready.</p>"
Rate Limits
No rate limits are enforced at the API level. Delivery is subject to the upstream provider's limits (Resend). For high-volume sending, contact dev@congo.gg.