Skip to content

Quickstart: Send Your First SMS

This walkthrough gets you from a dashboard key to a real SMS in one request. After it succeeds, use the same apikey header for WhatsApp, RCS, and OTP.

Before you send

Complete this in the portal. Skip any row that does not apply to a test SMS on your account.

NeedWhereWhy
Wallet creditsHeader Wallet / AccountSends are billed from credits
Approved Sender IDSMS → Utility → Manage Sender IDShown on the phone. India: PE ID
Approved template (India)SMS → Utility → Manage TemplateDLT template ID. What DLT is
Gateway typeAssigned to the accountHTTP field type is that gateway API code (for example TRANSACTIONAL)
API keySystem → Developer → API KeyNext step

International / non-India routes still need an approved sender and credits; they do not use DLT.

Get an API key

  1. Log in and open System → Developer → API Key (or Profile → API Key).
  2. Generate a key and copy it. Do not put it in a mobile app or a public ticket.
  3. Optional: restrict it with an IP allowlist.

How the header works, rotate, and allowlist: Authentication. Portal screens: Account → API keys.

Note your Base URL

The HTTP API host is https://api.azmarq.com. Open the SMS page to copy the full URL, such as https://api.azmarq.com/v1/sms. In the examples below, $API_BASE_URL is https://api.azmarq.com.

Send one SMS

This is the same body as Send SMS on the Message App page. Replace the sender ID, destination, and type (your assigned gateway API code) with values from your account.

POST
/v1/sms
curl --location --request POST 'https://api.azmarq.com/v1/sms' \
--header 'Content-Type: application/json' \
--header 'apikey: YOUR_API_KEY' \
--data-raw '{
  "sender": "senderName",
  "to": "91XXXXXXXXXX",
  "text": "Hello World!",
  "type": "TRANSACTIONAL"
}'

A successful send looks like this. Store messageId if you will match delivery reports later.

Response

{
  "id": "58d63c02-XXXX-XXXX-XXXX-XXXXbb39453",
  "data": [
    {
      "recipient": "91XXXXXXXXXX",
      "messageId": "58d63c02-XXXXX-XXXXX-XXXXX-XXXX9bb39453:1"
    }
  ],
  "totalCount": 1,
  "message": "Message Sent Successfully!",
  "error": null
}

type is the gateway API code assigned to the account — for example TRANSACTIONAL. It must match the route on the account. See SMS (Message App).

Prefer POST + JSON. The same fields also work as GET query parameters on /v1/sms.

After a successful send

error is null and HTTP is 200: the API accepted the job. The phone may still show later as PENDING, DELIVERED, or FAILED.

  1. Save data[0].messageId next to your own user or order id.
  2. Watch SMS → Number report, or configure a DLR URL. Webhooks.
  3. Do not send the same OTP or alert again until you know this job failed.

If the send fails

You seeStart here
Api Key not foundAuthentication
Sender / template pendingApprove them, or finish DLT for India
Insufficient creditsWallet
HTTP 400Errors — fix the body, then retry
HTTP 200, empty dataNumber may be on the blocklist

Full table: Errors → Typical first-send issues.

What to do next

Same apikey and $API_BASE_URL for every channel.

Omni SDK — azmarqomni in Node, Python, Go, PHP, Java, C#, and Ruby

Omni MCP — azmarqomni-mcp for Claude Desktop, Cursor, or HTTP hosts

Team Inbox · Automations · Fallback · Account · My CDP

Was this page helpful?