Skip to main content
PATCH
/
users
Upsert contacts
curl --request PATCH \
  --url https://apix.spotzee.com/api/client/users \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
[
  {
    "anonymous_id": "anon-2c8a3e",
    "external_id": "cust-9f4b21",
    "email": "jane@example.com",
    "phone": "+61400123456",
    "timezone": "Australia/Sydney",
    "locale": "en-AU",
    "data": {
      "first_name": "Jane",
      "plan": "pro"
    }
  }
]
'
{}

Documentation Index

Fetch the complete documentation index at: https://docs.spotzee.com/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

Authorization
string
header
required

Project-scoped secret API key (sk_…). Pass in the Authorization: Bearer <key> header. Grants access to the project the key was issued for.

Body

application/json
Required array length: 1 - 100 elements

A single contact upsert. At least one of anonymous_id or external_id must be present. When both are present they are linked.

anonymous_id
string
required

Anonymous tracking identifier captured before the contact was identified.

Example:

"anon-2c8a3e"

external_id
string | null

Optional system-of-record identifier to attach to this anonymous contact.

Example:

"cust-9f4b21"

email
string<email> | null

Contact’s email address. Validated against RFC 5322 on write.

Example:

"jane@example.com"

phone
string | null

Contact’s phone number. E.164 preferred; other formats are normalised when possible.

Example:

"+61400123456"

timezone
string | null

IANA timezone (for example Australia/Sydney).

Maximum string length: 50
Example:

"Australia/Sydney"

locale
string | null

BCP-47 locale tag (for example en-AU).

Maximum string length: 255
Example:

"en-AU"

data
object

Free-form custom attributes attached to the contact. Used in segmentation and template rendering.

Example:
{ "first_name": "Jane", "plan": "pro" }

Response

The batch was accepted for asynchronous processing.

Empty response body. Returned with HTTP 204 when an operation is accepted for processing.