Send an action-based email using POST /v1/messages. You need an API key and an email channel with a verified sending domain.

Prerequisites

  • API key — create one in Workspace settings → API keys.
  • Email channel ID — find it in Channels in the dashboard. It uses a ch_ prefix (e.g. ch_550e8400e29b41d4a716446655440000).
  • Sending domain verified with SPF, DKIM, and DMARC records.

Steps

1

Find your channel ID

In the dashboard, open Channels and click your email channel. Copy the Channel ID — you’ll pass it as channel_id in every send request.
2

Send with curl

curl -sS -X POST "https://api.arowana.app/v1/messages" \
  -H "Authorization: Bearer $API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
    "channel_id": "ch_your_channel_id",
    "to": "customer@example.com",
    "message_type": "MESSAGE",
    "subject": "Order confirmed",
    "content": {
      "html": "<p>Thanks for your order. We'\''ll ship it within 24 hours.</p>",
      "text": "Thanks for your order. We'll ship it within 24 hours."
    }
  }'
A successful response returns status: queued and a billing snapshot:
{
  "message_id": "msg_email_xxxx",
  "status": "queued",
  "created_at": "2026-03-28T09:00:00Z",
  "billing": {
    "message_type": "basic_message",
    "hold_amount": 0.005,
    "balance": { "free": 49.995, "total": 50.0 }
  }
}
3

Track delivery via webhook

Email delivery events use the email.* prefix. Subscribe to them when registering your endpoint:
curl -sS -X POST "https://api.arowana.app/v1/webhooks" \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "url": "https://your-server.example.com/webhooks/arowana",
    "events": ["email.delivered", "email.bounced"],
    "secret": "whsec_your_random_secret"
  }'
When the mail server accepts the message you receive:
{
  "id": "evt_a1b2c3",
  "event": "email.delivered",
  "timestamp": "2026-03-28T09:01:00Z",
  "data": {
    "message_id": "msg_email_xxxx",
    "to": "customer@example.com",
    "delivered_at": "2026-03-28T09:01:00Z"
  }
}
Email uses email.delivered and email.bouncednot message.delivered. Subscribing to the wrong event name means you will not receive email delivery updates.

Learn more