Skip to main content
PATCH
Update Lead
Update an existing lead. Matches leads by id, externalId, email, or phone (in that priority order). At least one identifier (id, externalId, email, or phone) is required. email and phone can be sent as a single string or as an array of up to 10 strings. Array values are tried sequentially. Octanist first tries the first email, then the next email, and only moves on to phone values if none of the email values match.

Request Body

* At least one of id, externalId, email, or phone is required. When both status and changedTo are provided, status takes precedence. When email or phone is an array, values are matched in order and the first value with a match wins. The matching order is:
  1. id, if provided
  2. externalId, if provided
  3. email[0], email[1], and so on
  4. phone[0], phone[1], and so on
When matching by email or phone, multiple leads may match. If your organization settings allow bulk updates, all matching leads are updated. Otherwise, a 409 CONFLICT error is returned. externalId is a lookup identifier on this endpoint. It does not replace or rotate the external ID stored on the lead.

Example Request

Example Request With Fallback Identifiers

Example Request by External ID

Example Response

Error Responses

Authorizations

X-API-KEY
string
header
required

API key for authentication

Body

application/json

Lead update data. At least one of id, externalId, email, or phone is required.

At least one of id, externalId, email, or phone is required as an identifier. email and phone can be strings or arrays of up to 10 strings. Identifiers are tried sequentially: id first, then externalId, then email values in order, then phone values in order. externalId is used for lookup and is not changed by this endpoint.

id
string

Lead ID (highest priority match)

Example:

"lead_abc123"

externalId
string

Customer-owned lead identifier (second priority match). Whitespace is trimmed.

Required string length: 1 - 255
Example:

"QUOTE-2026-0042"

email

Lead email or ordered email candidates (third priority match). Arrays are tried sequentially.

Example:

"john@example.com"

phone

Lead phone or ordered phone candidates (fourth priority match). Arrays are tried sequentially after all email candidates.

Example:

"+1234567890"

status
enum<string>

New status. Takes precedence over changedTo if both are provided.

Available options:
qualified,
won,
lost
Example:

"won"

changedTo
enum<string>

Legacy alias for status (same values).

Available options:
qualified,
won,
lost
Example:

"won"

value

Lead value. Strings are auto-converted to numbers.

Example:

5000

note
string

Note to attach to the lead

lossReason
string

Reason for loss (only used when status is lost)

Response

Lead updated successfully

success
boolean
Example:

true

data
object
meta
object