Program the business-capable messaging layer.
Atlas API connects WhatsApp, launches AI agents, executes transactional business operations, and delivers proactive messages — with idempotency, server-derived tenant identity, and full audit trails built in.
What Atlas API enables
Four capability pillars, one unified API.
Channel transport
Connect WhatsApp Business API, ingest inbound messages, and deliver outbound responses — structured and trackable.
AI orchestration
Launch Atlas-hosted agents or plug in external AI runtimes. Atlas handles intent classification, knowledge retrieval, and routing.
Transactional operations
Execute loyalty adjustments, voucher operations, and booking mutations — idempotent, atomic, and ledger-backed.
Proactive messaging
Send outbound WhatsApp messages to any phone number. Template-aware, window-aware, and delivery-tracked.
From sandbox credentials to first tool call in 4 steps.
Get sandbox credentials
Start with sandbox credentials before production go-live. Keys are scoped and tenant identity is derived by Mirai, not supplied in the request body.
curl https://api.usemirai.app/sandbox/credentialsConnect WhatsApp
Use Developer Console go-live only after channel readiness and human owner approval. Sandbox examples use the bundled phone fleet.
GET /v1/atlas/channels
// Returns connected production channels for the authenticated organization.Ingest knowledge
Upload your business knowledge — service menus, policies, pricing — so Atlas can ground responses in real data.
POST /v1/atlas/knowledge
{
"source_type": "text",
"title": "Menu and recovery policy",
"content": "Lunch sets start at S$14. Abandoned orders may receive a reminder, not an invented discount."
}Send your first message
Send a proactive WhatsApp message to any phone number. Atlas creates the customer and conversation automatically.
POST /atlas/v1/tools/send_message_to_phone
{
"idempotency_key": "sandbox-message-1",
"phone_number": "+10000000001",
"text": "Reminder: your pickup is ready.",
"category": "utility"
}Core endpoints
Send WhatsApp message
Send a text or template message to any phone number. Automatically creates or reuses a customer and conversation.
List conversations
Retrieve all WhatsApp conversations for your organization, filtered by status and date range.
Get conversation context
Fetch full conversation context — customer profile, message history, and knowledge grounding for a specific conversation.
Ingest inbound event
Feed an external event (webhook from another system) into the Atlas pipeline.
Execute action
Reply, draft, or hand off on a conversation. Replies are sent via WhatsApp.
Audit log
Retrieve the full audit log of all Atlas API operations — messages sent, actions executed, errors.
Canonical agent tool endpoints
Get tool manifest
Returns all available tools for your agent, filtered by the scopes granted to your API key.
Reply in conversation
Send a WhatsApp message within an active conversation. Requires a conversation_id.
Proactive send
Send to any phone number. Automatically creates or reuses a customer and conversation.
Search knowledge
Query the shared knowledge base for grounded answers using semantic search.
Built for correctness, not just speed
Scoped API keys
Every key is granted only the scopes it needs. Tenant isolation is enforced at the database layer — your keys can never access another organization's data.
Idempotent by design
All mutating endpoints accept an idempotency_key. Retrying within 24 hours replays the original response without double-executing. Safe for unreliable networks.
Audit trail
Every API call — messages sent, actions executed, knowledge retrieved — is logged with a stable run ID. Full traceability for compliance.