> ## Documentation Index
> Fetch the complete documentation index at: https://usegately.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Update Contact

> Partially update a contact — only the fields you send are changed

## Headers

<ParamField header="Authorization" type="string" required>
  `Bearer YOUR_API_KEY`
</ParamField>

<ParamField header="X-Project-ID" type="string">
  Your project UUID. Not required if the API key already encodes the project.
</ParamField>

## Path Parameters

<ParamField path="contactId" type="string" required>
  The contact UUID
</ParamField>

## Request Body

All fields are optional. Only the fields you include will be updated.

<ParamField body="name" type="string">Full name</ParamField>
<ParamField body="email" type="string">Email address</ParamField>
<ParamField body="phone" type="string">Phone number</ParamField>
<ParamField body="mobile" type="string">Mobile number</ParamField>
<ParamField body="company" type="string">Company name</ParamField>
<ParamField body="status" type="string">`new` · `active` · `inactive` · `archived`</ParamField>
<ParamField body="notes" type="string">Internal notes</ParamField>
<ParamField body="first_name" type="string">First name</ParamField>
<ParamField body="last_name" type="string">Last name</ParamField>
<ParamField body="city" type="string">City</ParamField>
<ParamField body="state" type="string">State or province</ParamField>
<ParamField body="zip" type="string">Postal / ZIP code</ParamField>
<ParamField body="country" type="string">Country</ParamField>

<ParamField body="custom_fields" type="object">
  Replaces the entire `custom_fields` object. Use the [custom fields endpoint](/docs/api-reference/contacts/list) for a merge-patch instead.
</ParamField>

<ParamField body="tags" type="string[]">
  Replaces all existing tags on the contact when provided.
</ParamField>

<ParamField body="unsubscribed" type="boolean">
  Set to `true` to mark as unsubscribed. Prefer the dedicated [unsubscribe endpoint](/docs/api-reference/contacts/unsubscribe) for a full audit trail.
</ParamField>

## Response

Returns the updated contact object.

<RequestExample>
  ```bash cURL theme={null}
  curl -X PATCH "https://api.usegately.com/api/v1/contacts/CONTACT_ID" \
    -H "Authorization: Bearer YOUR_API_KEY" \
    -H "X-Project-ID: YOUR_PROJECT_ID" \
    -H "Content-Type: application/json" \
    -d '{
      "status": "inactive",
      "notes": "Churned after trial"
    }'
  ```

  ```javascript JavaScript theme={null}
  const res = await fetch('https://api.usegately.com/api/v1/contacts/CONTACT_ID', {
    method: 'PATCH',
    headers: {
      'Authorization': 'Bearer YOUR_API_KEY',
      'X-Project-ID': 'YOUR_PROJECT_ID',
      'Content-Type': 'application/json',
    },
    body: JSON.stringify({ status: 'inactive', notes: 'Churned after trial' }),
  })
  const contact = await res.json()
  ```

  ```typescript SDK theme={null}
  import { GatelyContacts } from '@gately/sdk'

  const crm = new GatelyContacts({ projectId: 'YOUR_PROJECT_ID' })

  const updated = await crm.update('CONTACT_ID', {
    status: 'inactive',
    notes: 'Churned after trial',
  })
  ```
</RequestExample>

<ResponseExample>
  ```json Success theme={null}
  {
    "id": "a1b2c3d4-e5f6-4789-abcd-ef1234567890",
    "name": "Jane Smith",
    "email": "jane@example.com",
    "status": "inactive",
    "notes": "Churned after trial",
    "last_contacted_at": "2025-06-15T14:30:00.000Z",
    "updated_at": "2025-06-15T14:30:00.000Z"
  }
  ```
</ResponseExample>
