Update a contact
PUT/api/v2/contacts/{phone_number}
Update an existing contact. You may set SMS opt-out with opt_out (boolean); it updates the same recipient record used for inbound keyword opt-outs.
Update a contact
curl https://api.sendblue.co/api/v2/contacts/$PHONE_NUMBER \
-X PUT \
-H 'Content-Type: application/json' \
-H "sb-api-key-id: $SENDBLUE_API_API_KEY" \
-H "sb-api-secret-key: $SENDBLUE_API_API_SECRET" \
-d '{
"custom_variables": {
"Plan": "Premium"
}
}'{
"contact": {
"assigned_to_email": "[email protected]",
"company_name": "Example Corp",
"created_at": "2024-01-15T10:30:00Z",
"custom_variables": {
"Lead Source": "Website",
"Plan": "Enterprise"
},
"first_name": "John",
"last_name": "Doe",
"opt_out": false,
"phone": "+1234567890",
"sendblue_number": "+1987654321",
"tags": [
"customer",
"vip"
],
"verified": true
},
"status": "OK"
}Returns Examples
{
"contact": {
"assigned_to_email": "[email protected]",
"company_name": "Example Corp",
"created_at": "2024-01-15T10:30:00Z",
"custom_variables": {
"Lead Source": "Website",
"Plan": "Enterprise"
},
"first_name": "John",
"last_name": "Doe",
"opt_out": false,
"phone": "+1234567890",
"sendblue_number": "+1987654321",
"tags": [
"customer",
"vip"
],
"verified": true
},
"status": "OK"
}