Skip to main content

Upsert account

POST 

/accounts/_upsert

Upsert an account. If the account does not exist, it will be created. If the account does exist, it will be updated. Only supported for Salesforce and Hubspot.

Request

Header Parameters

    x-customer-id stringrequired

    The customer ID that uniquely identifies the customer in your application

    Example: my-customer-1
    x-provider-name stringrequired

    The provider name

    Example: salesforce

Body

required
    record objectrequired
    description stringnullable
    industry stringnullable
    name stringnullable
    number_of_employees integernullable
    website stringnullable
    addresses object[]
  • Array [
  • address_type stringrequired

    Possible values: [primary, mailing, other, billing, shipping]

    city stringnullablerequired
    country stringnullablerequired
    postal_code stringnullablerequired
    state stringnullablerequired
    street_1 stringnullablerequired
    street_2 stringnullablerequired
  • ]
  • phone_numbers object[]
  • Array [
  • phone_number stringnullablerequired
    phone_number_type stringrequired

    Possible values: [primary, mobile, fax, other]

  • ]
  • owner_id stringnullable
    lifecycle_stage lifecycle_stagenullable

    Possible values: [subscriber, lead, marketingqualifiedlead, salesqualifiedlead, opportunity, customer, evangelist, other]

    custom_fields object

    Custom properties to be inserted that are not covered by the common object. Object keys must match exactly to the corresponding provider API.

    property name* any

    Custom properties to be inserted that are not covered by the common object. Object keys must match exactly to the corresponding provider API.

    upsert_on objectrequired
    key stringrequired

    Possible values: [domain, website]

    The key to upsert on. Only website is supported for Salesforce, while both domain and website are supported for Hubspot.

    values string[]required

    The values to upsert on. If more than one value is provided, it will act as a logical OR. If more than one account is found that matches, then an error will be thrown.

Responses

Account upserted

Schema
    record object
    id stringrequired
    warnings object[]
  • Array [
  • detail string
    problem_type string
    title string
  • ]
Loading...