Contacts
Update contact
Updates an existing contact record. Requires crm:write scope.
PATCH
/
contacts
/
{id}
Update Contact
curl --request PATCH \
--url https://crm-api.automatebusiness.com/api/v1/integrations-public/contacts/{id} \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"first_name": "Jane",
"last_name": "Smith",
"phone_number": "5551234567",
"country_code": "+1",
"email": "jane.smith@example.com",
"tags": [
"vip",
"promoted"
],
"custom_fields": {
"department": "Executive"
}
}
'import requests
url = "https://crm-api.automatebusiness.com/api/v1/integrations-public/contacts/{id}"
payload = {
"first_name": "Jane",
"last_name": "Smith",
"phone_number": "5551234567",
"country_code": "+1",
"email": "jane.smith@example.com",
"tags": ["vip", "promoted"],
"custom_fields": { "department": "Executive" }
}
headers = {
"x-api-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {'x-api-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
first_name: 'Jane',
last_name: 'Smith',
phone_number: '5551234567',
country_code: '+1',
email: 'jane.smith@example.com',
tags: ['vip', 'promoted'],
custom_fields: {department: 'Executive'}
})
};
fetch('https://crm-api.automatebusiness.com/api/v1/integrations-public/contacts/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://crm-api.automatebusiness.com/api/v1/integrations-public/contacts/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'first_name' => 'Jane',
'last_name' => 'Smith',
'phone_number' => '5551234567',
'country_code' => '+1',
'email' => 'jane.smith@example.com',
'tags' => [
'vip',
'promoted'
],
'custom_fields' => [
'department' => 'Executive'
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-api-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://crm-api.automatebusiness.com/api/v1/integrations-public/contacts/{id}"
payload := strings.NewReader("{\n \"first_name\": \"Jane\",\n \"last_name\": \"Smith\",\n \"phone_number\": \"5551234567\",\n \"country_code\": \"+1\",\n \"email\": \"jane.smith@example.com\",\n \"tags\": [\n \"vip\",\n \"promoted\"\n ],\n \"custom_fields\": {\n \"department\": \"Executive\"\n }\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("x-api-key", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.patch("https://crm-api.automatebusiness.com/api/v1/integrations-public/contacts/{id}")
.header("x-api-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"first_name\": \"Jane\",\n \"last_name\": \"Smith\",\n \"phone_number\": \"5551234567\",\n \"country_code\": \"+1\",\n \"email\": \"jane.smith@example.com\",\n \"tags\": [\n \"vip\",\n \"promoted\"\n ],\n \"custom_fields\": {\n \"department\": \"Executive\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://crm-api.automatebusiness.com/api/v1/integrations-public/contacts/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["x-api-key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"first_name\": \"Jane\",\n \"last_name\": \"Smith\",\n \"phone_number\": \"5551234567\",\n \"country_code\": \"+1\",\n \"email\": \"jane.smith@example.com\",\n \"tags\": [\n \"vip\",\n \"promoted\"\n ],\n \"custom_fields\": {\n \"department\": \"Executive\"\n }\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"data": {
"id": "cnt_941a7bc2",
"first_name": "Jane",
"last_name": "Doe",
"phone_number": "5551234567",
"country_code": "+1",
"email": "jane.doe@example.com",
"tags": [
"vip",
"decision-maker"
],
"custom_fields": {
"company_size": "100-500"
},
"created_at": "2026-10-26T08:00:00.000Z",
"updated_at": "2026-10-26T08:00:00.000Z"
},
"error": null
}{
"success": false,
"data": null,
"error": {
"message": "Validation failed",
"details": [
{
"message": "Required",
"field": "email",
"code": "invalid_type"
}
]
}
}{
"success": false,
"data": null,
"error": {
"message": "Invalid or missing API key."
}
}{
"success": false,
"data": null,
"error": {
"message": "Forbidden: insufficient permissions for this operation."
}
}{
"success": false,
"data": null,
"error": {
"message": "Resource not found"
}
}Updates fields on an existing contact record.
Path parameters
id(string, required): The unique identifier of the contact to update.
Required permissions
Requires an API key with thecrm:write scope.Authorizations
Workspace API key header. The key implicitly determines your workspace isolation. Scopes: crm:read for GET/HEAD/OPTIONS, crm:write for POST/PATCH/PUT/DELETE.
Path Parameters
The unique identifier of the contact
Body
application/json
⌘I
Update Contact
curl --request PATCH \
--url https://crm-api.automatebusiness.com/api/v1/integrations-public/contacts/{id} \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"first_name": "Jane",
"last_name": "Smith",
"phone_number": "5551234567",
"country_code": "+1",
"email": "jane.smith@example.com",
"tags": [
"vip",
"promoted"
],
"custom_fields": {
"department": "Executive"
}
}
'import requests
url = "https://crm-api.automatebusiness.com/api/v1/integrations-public/contacts/{id}"
payload = {
"first_name": "Jane",
"last_name": "Smith",
"phone_number": "5551234567",
"country_code": "+1",
"email": "jane.smith@example.com",
"tags": ["vip", "promoted"],
"custom_fields": { "department": "Executive" }
}
headers = {
"x-api-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {'x-api-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
first_name: 'Jane',
last_name: 'Smith',
phone_number: '5551234567',
country_code: '+1',
email: 'jane.smith@example.com',
tags: ['vip', 'promoted'],
custom_fields: {department: 'Executive'}
})
};
fetch('https://crm-api.automatebusiness.com/api/v1/integrations-public/contacts/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://crm-api.automatebusiness.com/api/v1/integrations-public/contacts/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'first_name' => 'Jane',
'last_name' => 'Smith',
'phone_number' => '5551234567',
'country_code' => '+1',
'email' => 'jane.smith@example.com',
'tags' => [
'vip',
'promoted'
],
'custom_fields' => [
'department' => 'Executive'
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-api-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://crm-api.automatebusiness.com/api/v1/integrations-public/contacts/{id}"
payload := strings.NewReader("{\n \"first_name\": \"Jane\",\n \"last_name\": \"Smith\",\n \"phone_number\": \"5551234567\",\n \"country_code\": \"+1\",\n \"email\": \"jane.smith@example.com\",\n \"tags\": [\n \"vip\",\n \"promoted\"\n ],\n \"custom_fields\": {\n \"department\": \"Executive\"\n }\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("x-api-key", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.patch("https://crm-api.automatebusiness.com/api/v1/integrations-public/contacts/{id}")
.header("x-api-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"first_name\": \"Jane\",\n \"last_name\": \"Smith\",\n \"phone_number\": \"5551234567\",\n \"country_code\": \"+1\",\n \"email\": \"jane.smith@example.com\",\n \"tags\": [\n \"vip\",\n \"promoted\"\n ],\n \"custom_fields\": {\n \"department\": \"Executive\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://crm-api.automatebusiness.com/api/v1/integrations-public/contacts/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["x-api-key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"first_name\": \"Jane\",\n \"last_name\": \"Smith\",\n \"phone_number\": \"5551234567\",\n \"country_code\": \"+1\",\n \"email\": \"jane.smith@example.com\",\n \"tags\": [\n \"vip\",\n \"promoted\"\n ],\n \"custom_fields\": {\n \"department\": \"Executive\"\n }\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"data": {
"id": "cnt_941a7bc2",
"first_name": "Jane",
"last_name": "Doe",
"phone_number": "5551234567",
"country_code": "+1",
"email": "jane.doe@example.com",
"tags": [
"vip",
"decision-maker"
],
"custom_fields": {
"company_size": "100-500"
},
"created_at": "2026-10-26T08:00:00.000Z",
"updated_at": "2026-10-26T08:00:00.000Z"
},
"error": null
}{
"success": false,
"data": null,
"error": {
"message": "Validation failed",
"details": [
{
"message": "Required",
"field": "email",
"code": "invalid_type"
}
]
}
}{
"success": false,
"data": null,
"error": {
"message": "Invalid or missing API key."
}
}{
"success": false,
"data": null,
"error": {
"message": "Forbidden: insufficient permissions for this operation."
}
}{
"success": false,
"data": null,
"error": {
"message": "Resource not found"
}
}