Skip to main content
POST
/
api
/
customers
/
update
curl --request POST \
  --url https://app.sphinxhq.com/api/customers/update/ \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "external_id": "cust-123",
  "full_name": "Jane Smith"
}
'
{
  "id": 123,
  "external_id": "<string>",
  "full_name": "<string>",
  "customer_type": "INDIVIDUAL",
  "input_details": {},
  "delete_after": 123,
  "created_at": "2023-11-07T05:31:56Z",
  "updated_at": "2023-11-07T05:31:56Z",
  "parent": 123
}

Authorizations

Authorization
string
header
required

OAuth2 access token obtained from POST /api/oauth/token/ using client credentials.

Body

application/json

Partial update for an existing customer. Only provided fields are applied; omitted fields are left unchanged.

external_id
string
required

External ID to identify the customer to update.

full_name
string

Full name of the customer.

customer_type
enum<string> | null
  • INDIVIDUAL - Individual
  • COMPANY - Company
Available options:
INDIVIDUAL,
COMPANY,
,
null
input_details
object

Flexible JSON for customer fields.

delete_after
integer

Number of days until deletion. Use 0 for immediate, -1 for never.

Response

Read-only serializer for Customer with computed fields.

id
integer
required
external_id
string | null
required

ID from the source system, for lookups.

full_name
string
required
customer_type
enum<string> | null
required
  • INDIVIDUAL - Individual
  • COMPANY - Company
Available options:
INDIVIDUAL,
COMPANY,
null
input_details
object
required

Flexible JSON for inputting customer fields such as first_name, address, etc. Any format accepted.

delete_after
integer
required

Days until deletion. -1 means never delete.

created_at
string<date-time>
required
updated_at
string<date-time>
required
parent
integer | null
required

Parent customer ID.