Authentication

Ranla authenticates API requests with Bearer API keys that start with rnl_ or stx_. Newly created keys still start with rnl_. A rnl_ key with the same secret after the prefix authenticates as the existing key.

Obtain a key

  1. Open the dashboard.
  2. Go to API Keys → Create.
  3. Copy the secret — it is shown once.
export RANLA_API_KEY=rnl_your_key_here

Keep keys server-side only. Never ship them in browser bundles or public repos.

Request header

Send the key on every management and send request:

curl https://api.ranla.ai/emails \
  -H "Authorization: Bearer $RANLA_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "from": "[email protected]",
    "to": "[email protected]",
    "subject": "Hello",
    "html": "<p>It works.</p>"
  }'

Node SDK

import { Ranla } from '@supersend/ranla'

const client = new Ranla(process.env.RANLA_API_KEY)

CLI

export RANLA_API_KEY=rnl_your_key_here
npx -y --package=ranla-cli -- ranla emails send \
  --from [email protected] \
  --to [email protected] \
  --subject "Hello" \
  --html "<p>It works.</p>"

Base URLs

Surface URL
API https://api.ranla.ai
Dashboard https://app.ranla.ai

Unauthorized responses

Missing or invalid keys return 401 with:

{
  "error": {
    "message": "Unauthorized"
  }
}

See Errors for the full error shape.