# Create or update a contact by external id



URL: https://getclickfix.com/docs/api-reference/contacts/create-or-update-a-contact-by-external-id?lang=en

Scope: `contacts:write`. `external_id` is required and is your own user id (the `user_id` of the widget `identify` call). If a contact with that id exists it is updated (`200`), otherwise created (`201`); no matching by email or phone. An id that belongs to another contact returns `409 EXTERNAL_ID_EXISTS`. `Idempotency-Key` is required.

This page is the API reference generated from the OpenAPI schema; request and response schemas, examples and curl/Node.js/Go/PHP requests are on the HTML page. Shared rules: https://getclickfix.com/docs/api.md?lang=en
