Leads management
Upsert a customer
Create or update one customer by your externalId. A retry with the same idempotencyKey replays the stored response.
POST
Authorization
AuthorizationrequiredBearer token with the customers:import scope. You get it in exchange for an API key: see Authentication, or press Try in Playground, which takes your key and gets the token for you.
application/json- body
record*The customer to create or update.
idempotencyKey*stringA unique key for this call, such as a UUID. Retrying with the same key and the same record
returns the original response, with nothing written twice. Reusing a key with a different
request fails with already_exists.
At most 512 bytes.
Success
application/json- response
result?The outcome for the record.
curl -X POST \ 'https://app.getduranta.com/duranta.api.public.v1.CustomerService/UpsertCustomer' \ -H 'Content-Type: application/json' \ -d '{ "record": { "externalId": "crm-48213", "kind": "CUSTOMER_KIND_COMMERCIAL", "companyName": "Lakeside Office Park", "givenName": "Dana", "familyName": "Ortiz", "email": "dana.ortiz@example.com", "phone": "+1 715 555 0142", "address": { "line1": "2910 Mall Dr", "city": "Eau Claire", "region": "WI", "postalCode": "54701", "country": "US" }, "sourceRevision": "2026-06-05T17:30:00Z" }, "idempotencyKey": "6f1c2a1e-6d4b-4b8e-9a51-0c3f2d7e9b10"}'{ "result": { "externalId": "crm-48213", "customer": "customers/t0a1b2c3d4e5f6i", "outcome": "CUSTOMER_UPSERT_OUTCOME_CREATED", "serverRevision": "1" }}