Accounts
Overview
Accounts represent your WhatsApp Business API connections. Each account is linked to a phone number registered with Meta’s WhatsApp Business Platform.
List Accounts
Retrieve all connected WhatsApp accounts.
GET /api/accountsResponse
{ "status": "success", "data": { "items": [ { "id": "uuid", "name": "Main Business", "phone_number": "+1234567890", "phone_number_id": "123456789", "business_account_id": "987654321", "status": "active", "created_at": "2024-01-01T00:00:00Z" } ] }}Get Account
Retrieve a single account.
GET /api/accounts/{id}Response
{ "status": "success", "data": { "id": "uuid", "name": "Main Business", "phone_number": "+1234567890", "phone_number_id": "123456789", "business_account_id": "987654321", "access_token": "EAAxxxx...", "webhook_verify_token": "your_verify_token", "status": "active", "quality_rating": "GREEN", "messaging_limit": "TIER_1K", "created_at": "2024-01-01T00:00:00Z" }}Create Account
Connect a new WhatsApp Business account.
POST /api/accountsRequest Body
{ "name": "Support Line", "phone_number_id": "123456789", "business_account_id": "987654321", "access_token": "EAAxxxx...", "webhook_verify_token": "your_custom_verify_token"}Response
{ "status": "success", "data": { "id": "uuid", "name": "Support Line", "status": "pending", "created_at": "2024-01-01T00:00:00Z" }}Update Account
Update account settings.
PUT /api/accounts/{id}Request Body
{ "name": "Customer Support", "access_token": "EAAyyyy..."}Delete Account
Remove a WhatsApp account connection.
DELETE /api/accounts/{id}Test Connection
Verify the account connection with Meta.
POST /api/accounts/{id}/testResponse
{ "status": "success", "data": { "connected": true, "phone_number": "+1234567890", "display_phone_number": "(123) 456-7890", "verified_name": "Your Business Name", "quality_rating": "GREEN" }}Account Status
| Status | Description |
|---|---|
pending | Account created, awaiting verification |
active | Account is connected and working |
disconnected | Connection lost, needs reconnection |
suspended | Account suspended by Meta |
Quality Rating
Meta assigns quality ratings based on message performance:
| Rating | Description |
|---|---|
GREEN | High quality, no issues |
YELLOW | Some issues, review messages |
RED | Low quality, account at risk |