v1.0.0
OpenAPI 3.1.0

Make a single request

US region

Client Libraries

Make a single request

​

This endpoint lets you create, update, or delete a single person or object—including managing relationships between objects and people.

An "object" is any kind of non-person entity that you want to associate with one or more people—like a company, an educational course that people signed up for, a product, etc.

Your request must be smaller than 32kb.

Body
application/json
    • Add or update a person.

      • action
        Discriminator
        enum
        const:  
        identify
        required

        Indicates that the operation will identify the item of the specified type.

        values
        • identify
      • identifiers
        required

        The person you want to perform an action for—one of id, email, phone, or cio_id. You cannot pass multiple identifiers. You can use email and phone only if they're enabled as identifiers in your workspace settings.

      • type
        enum
        const:  
        person
        required

        The operation modifies a person in Customer.io

        values
        • person
      • attributes
        Type: object

        Attributes that you want to add or update for this person. You can pass properties that aren't defined below to set custom attributes; the defined properties are reserved in the Customer.io Track API.

      • bulk
        Type: boolean

        Set to true to process this identify at a lower priority than your other requests. Use it for low-importance updates, like an attribute backfill or a nightly sync from your data warehouse. Customer.io can apply a bulk identify after requests you send later, but the bulk identify never overwrites an attribute that a request with a later timestamp set. The field doesn't change message delivery priority. If the identify includes cio_relationships, Customer.io deprioritizes only the person's attribute update.

      • cio_relationships
        Type: array object[]

        Each object in the array represents a relationship you want to add to, or remove from, a person.

      • timestamp
        Type: integer

        The Unix timestamp, in seconds, for when the attribute update occurred. Customer.io uses it to order attribute updates when you send multiple requests in rapid succession. If two updates to the same attribute have the same timestamp, Customer.io keeps the one it processes last. To order updates that happen within the same second, send timestamp_ms instead.

      • timestamp_ms

        The Unix timestamp, in milliseconds, for when the attribute update occurred, like the value of Date.now() in JavaScript. A valid timestamp_ms takes precedence over timestamp. Customer.io orders two updates to the same attribute by milliseconds only when both include timestamp_ms, so send it on every identify request for a person whose updates can happen within the same second. Customer.io ignores an invalid value and processes the request as if you hadn't sent one. If you've edited your workspace's actions to transform Track API calls before Customer.io processes them, Customer.io orders your identify calls by whole seconds and ignores timestamp_ms.

Responses
  • 200

    A successful request returns an empty object response.

  • application/json
  • 401

    Unauthorized request. Make sure that you provided the right credentials.

Request Example for post/api/v2/entity
{
  "action": "identify",
  "identifiers": {
    "id": "42"
  },
  "type": "person",
  "attributes": {
    "first_name": "Jane"
  }
}
No Body