Skip to content

Create or update by email, up to 1,000 per call (an email repeated in the batch is merged)

POST
/v1/brands/{brand}/contacts:batch
curl --request POST \
--url https://api.replifier.com/v1/brands/brd_01hx0000000000000000000000/contacts:batch \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "contacts": [ { "email": "example", "firstName": "example", "lastName": "example", "locale": "es-MX", "timezone": "example", "country": "example", "referrer": "example", "notes": "example", "trackingConsent": "full", "fields": { "additionalProperty": "example" }, "tags": [ "example" ] } ] }'
brand
required
string
/^brd_[a-z0-9]{26}$/

Example

brd_01hx0000000000000000000000
Media typeapplication/json
object
contacts
required
Array<object>
>= 1 items <= 1000 items
object
email
required
string
<= 254 characters
firstName
string
nullable <= 120 characters /^[^\x00-\x1f\x7f]*$/
lastName
string
nullable <= 120 characters /^[^\x00-\x1f\x7f]*$/
locale
string
nullable
Allowed values: es-MX es-ES es-AR en pt-BR fr de it ja ko zh-CN ar
timezone
string
nullable <= 64 characters
country

Two-letter ISO 3166-1 country code

string
nullable /^[A-Za-z]{2}$/
referrer
string
nullable <= 500 characters /^[^\x00-\x1f\x7f]*$/
notes
string
nullable <= 5000 characters /^[^\x00-\x08\x0b\x0c\x0e-\x1f\x7f]*$/
trackingConsent
string
Allowed values: full anonymous none
fields
object
key
additional properties
nullable
tags
Array<string>
<= 50 items

Result

Media typeapplication/json
object
created
required
number
updated
required
number

Example generated

{
"created": 1,
"updated": 1
}

Invalid data

Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
cause
required
string
fix
required
string
requestId
required
string

Example

{
"error": {
"code": "not_found"
}
}

No session, expired session, or invalid, expired or revoked API key

Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
cause
required
string
fix
required
string
requestId
required
string

Example

{
"error": {
"code": "not_found"
}
}

Not allowed, API key missing the scope, IP not allowed, or request rejected (csrf_rejected)

Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
cause
required
string
fix
required
string
requestId
required
string

Example

{
"error": {
"code": "not_found"
}
}

Does not exist or is not visible to you

Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
cause
required
string
fix
required
string
requestId
required
string

Example

{
"error": {
"code": "not_found"
}
}

Internal error

Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
cause
required
string
fix
required
string
requestId
required
string

Example

{
"error": {
"code": "not_found"
}
}