PUT
/
contacts
/
bulk
Upload Bulk Contacts
curl --request PUT \
  --url https://app.formbricks.com/api/v2/management/contacts/bulk \
  --header 'Content-Type: application/json' \
  --header 'x-api-key: <api-key>' \
  --data '{
  "environmentId": "env_01h2xce9q8p3w4x5y6z7a8b9c0",
  "contacts": [
    {
      "attributes": [
        {
          "attributeKey": {
            "key": "email",
            "name": "Email Address"
          },
          "value": "john.doe@example.com"
        },
        {
          "attributeKey": {
            "key": "firstName",
            "name": "First Name"
          },
          "value": "John"
        },
        {
          "attributeKey": {
            "key": "lastName",
            "name": "Last Name"
          },
          "value": "Doe"
        }
      ]
    },
    {
      "attributes": [
        {
          "attributeKey": {
            "key": "email",
            "name": "Email Address"
          },
          "value": "jane.smith@example.com"
        },
        {
          "attributeKey": {
            "key": "firstName",
            "name": "First Name"
          },
          "value": "Jane"
        },
        {
          "attributeKey": {
            "key": "lastName",
            "name": "Last Name"
          },
          "value": "Smith"
        }
      ]
    }
  ]
}'
{
  "data": {
    "status": "<string>",
    "message": "<string>"
  }
}

Authorizations

x-api-key
string
header
required

Use your Formbricks x-api-key to authenticate.

Body

application/json

The contacts to upload. Each contact must include an 'email' attribute in their attributes array. The email is used as the unique identifier for the contact.

environmentId
string
required
contacts
object[]
required
Maximum length: 250

Response

Contacts uploaded successfully.

data
object
required