Update a contact▾
Update a contact
Change the name, tags, attributes or opt-in state.
Only the fields you send are changed. Sending attributes replaces the whole object — merge client-side first if you only mean to add one key.
PATCH
/v1/contacts/{wa_id}Path parameters
wa_idstringrequiredDigits-only WhatsApp id, or ct_….
Body parameters
namestringDisplay name.
tagsarrayReplaces the current tag list.
attributesobjectReplaces the current attribute object.
opted_inbooleanMarketing opt-in state.
curl -X PATCH https://api.sendport.tech/v1/contacts/{wa_id} \
-H "Authorization: Bearer $SENDPORT_KEY" \
-H "Content-Type: application/json" \
-d '{"tags":["vip","renewal"],"opted_in":true}'Responses
200OK
{
"object": "contact",
"id": "ct_01JZQ7B2M4N8P0R2T4V6X8ZACE",
"wa_id": "201005550123",
"phone": "+201005550123",
"name": "Nadia Haddad",
"locale": "en",
"tags": ["vip", "renewal"],
"attributes": { "plan": "pro", "city": "Cairo" },
"opted_in": true,
"last_seen_at": "2026-09-06T08:41:02.000Z",
"created_at": "2026-05-14T08:12:44.000Z"
}401Unauthorized
{
"error": {
"type": "authentication_error",
"code": "missing_api_key",
"message": "No API key provided.",
"doc_url": "https://sendport.tech/docs/errors#missing_api_key",
"request_id": "req_9f3c2a7b41de08c5b2e6"
}
}Try itsandbox