API reference

Create or update a contact

POST /api/v1/contacts — add a new contact, or update an existing one with the same number.

POST/api/v1/contacts

Creates a contact, or updates it if the same number already exists in your account (upsert).

Headers

Header Value
X-API-Key Your key (or Authorization: Bearer <key>)
Content-Type application/json

Request body

Field Type Required Description
phone string Yes Phone number. to is accepted as an alias.
name string No Name
email string No Email
tags string[] No Tags

Response

200 OK

JSON
{
  "contact": {
    "id": "b6d8f0c2-1a2b-4c3d-9e8f-0a1b2c3d4e5f",
    "phone": "966500000000",
    "name": "Sara",
    "email": "[email protected]",
    "tags": ["vip"],
    "is_blocked": false,
    "opted_out": false,
    "created_at": "2026-11-16T10:00:00.000Z",
    "updated_at": "2026-11-16T10:00:00.000Z"
  }
}

Errors

Status error Cause
400 phone required Missing number
401 Invalid API key Invalid key
429 Too many requests Request limit exceeded
500 Failed to save contact Could not save

Examples

curl -X POST https://waabek.com/api/v1/contacts \
  -H "X-API-Key: $WABEK_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "phone": "966500000000",
    "name": "Sara",
    "email": "[email protected]",
    "tags": ["vip"]
  }'