Skip to content

Create a draft form (captures.write). Publishing it creates an immutable version and serves it on forms.replifier.com

POST
/v1/brands/{brand}/forms
curl --request POST \
--url https://api.replifier.com/v1/brands/brd_01hx0000000000000000000000/forms \
--header 'Content-Type: application/json' \
--data '{ "name": "example", "kind": "embedded", "document": { "defaultLocale": "es-MX", "fields": [ { "key": "example", "type": "email", "label": { "es-MX": "example", "es-ES": "example", "es-AR": "example", "en": "example", "pt-BR": "example", "fr": "example", "de": "example", "it": "example", "ja": "example", "ko": "example", "zh-CN": "example", "ar": "example" }, "required": false, "options": [ "example" ] } ], "listChoice": "all", "successMessage": { "es-MX": "example", "es-ES": "example", "es-AR": "example", "en": "example", "pt-BR": "example", "fr": "example", "de": "example", "it": "example", "ja": "example", "ko": "example", "zh-CN": "example", "ar": "example" }, "redirectUrl": "https://example.com", "redirectIncludeEmail": false, "privacyUrl": "https://example.com", "style": { "primary": "#1f4fd8", "text": "#1a1a1a", "background": "#ffffff", "font": "system", "radius": 8 }, "appearance": { "delaySeconds": 0, "scrollPercent": 0, "exitIntent": false, "includePaths": [], "excludePaths": [], "devices": [ "desktop", "mobile" ], "frequencyDays": 7 }, "whatsapp": { "phone": "example", "position": "bottom-right", "welcome": { "es-MX": "example", "es-ES": "example", "es-AR": "example", "en": "example", "pt-BR": "example", "fr": "example", "de": "example", "it": "example", "ja": "example", "ko": "example", "zh-CN": "example", "ar": "example" }, "prefill": { "es-MX": "example", "es-ES": "example", "es-AR": "example", "en": "example", "pt-BR": "example", "fr": "example", "de": "example", "it": "example", "ja": "example", "ko": "example", "zh-CN": "example", "ar": "example" }, "emailConsent": { "es-MX": "example", "es-ES": "example", "es-AR": "example", "en": "example", "pt-BR": "example", "fr": "example", "de": "example", "it": "example", "ja": "example", "ko": "example", "zh-CN": "example", "ar": "example" }, "defaultCountry": "MX" } }, "consent": { "version": "example", "text": { "es-MX": "example", "es-ES": "example", "es-AR": "example", "en": "example", "pt-BR": "example", "fr": "example", "de": "example", "it": "example", "ja": "example", "ko": "example", "zh-CN": "example", "ar": "example" }, "requireCheckbox": false, "preChecked": false }, "listIds": [], "allowedOrigins": [], "ratePerMinute": 600 }'
brand
required
string
/^brd_[a-z0-9]{26}$/

Example

brd_01hx0000000000000000000000
Media typeapplication/json
object
name
required
string
>= 1 characters <= 120 characters /^[^\x00-\x1f\x7f]*$/
kind
required
string
Allowed values: embedded popup bar hosted whatsapp_widget
document
required
object
defaultLocale
string
default: es-MX
Allowed values: es-MX es-ES es-AR en pt-BR fr de it ja ko zh-CN ar
fields
required
Array<object>
>= 1 items <= 30 items
object
key
required
string
/^[a-z][a-z0-9_]{0,63}$/
type
required
string
Allowed values: email text number date boolean select phone
label
required
object
es-MX
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
es-ES
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
es-AR
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
en
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
pt-BR
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
fr
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
de
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
it
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ja
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ko
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
zh-CN
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ar
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
required
boolean
options
Array<string>
<= 100 items
listChoice
string
default: all
Allowed values: all choose
successMessage
object
es-MX
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
es-ES
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
es-AR
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
en
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
pt-BR
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
fr
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
de
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
it
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ja
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ko
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
zh-CN
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ar
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
redirectUrl
string format: uri
<= 2000 characters
redirectIncludeEmail
boolean
privacyUrl
required
string format: uri
<= 2000 characters
style
object
primary
string
default: #1f4fd8 /^#[0-9a-fA-F]{6}$/
text
string
default: #1a1a1a /^#[0-9a-fA-F]{6}$/
background
string
default: #ffffff /^#[0-9a-fA-F]{6}$/
font
string
default: system
Allowed values: system serif mono
radius
integer
default: 8 <= 24
appearance
object
delaySeconds
integer
0 <= 600
scrollPercent
integer
0 <= 100
exitIntent
boolean
includePaths
Array<string>
default: <= 50 items
excludePaths
Array<string>
default: <= 50 items
devices
Array<string>
default: desktop,mobile >= 1 items
Allowed values: desktop mobile
frequencyDays
integer
default: 7 <= 365
whatsapp
object
phone
required
string
/^\+[1-9]\d{7,14}$/
position
string
default: bottom-right
Allowed values: bottom-right bottom-left
welcome
object
es-MX
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
es-ES
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
es-AR
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
en
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
pt-BR
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
fr
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
de
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
it
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ja
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ko
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
zh-CN
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ar
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
prefill
object
es-MX
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
es-ES
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
es-AR
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
en
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
pt-BR
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
fr
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
de
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
it
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ja
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ko
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
zh-CN
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ar
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
emailConsent
object
es-MX
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
es-ES
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
es-AR
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
en
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
pt-BR
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
fr
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
de
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
it
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ja
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ko
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
zh-CN
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ar
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
defaultCountry
string
default: MX /^[A-Z]{2}$/
consent
required
object
version
required
string
>= 1 characters <= 64 characters /^[^\x00-\x1f\x7f]*$/
text
required
object
es-MX
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
es-ES
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
es-AR
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
en
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
pt-BR
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
fr
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
de
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
it
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ja
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ko
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
zh-CN
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ar
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
requireCheckbox
boolean
preChecked
boolean
listIds
Array<string>
default: <= 50 items
allowedOrigins
Array<string>
default: <= 50 items
ratePerMinute
integer
default: 600 >= 1 <= 100000

Form created

Media typeapplication/json
object
id
required
string
brandId
required
string
name
required
string
kind
required
string
Allowed values: embedded popup bar hosted whatsapp_widget
publicId
required
string
status
required
string
Allowed values: draft published paused suspended
currentVersion
required
number
nullable
allowedOrigins
required
Array<string>
ratePerMinute
required
number
document
required
object
defaultLocale
string
default: es-MX
Allowed values: es-MX es-ES es-AR en pt-BR fr de it ja ko zh-CN ar
fields
required
Array<object>
>= 1 items <= 30 items
object
key
required
string
/^[a-z][a-z0-9_]{0,63}$/
type
required
string
Allowed values: email text number date boolean select phone
label
required
object
es-MX
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
es-ES
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
es-AR
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
en
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
pt-BR
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
fr
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
de
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
it
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ja
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ko
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
zh-CN
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ar
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
required
boolean
options
Array<string>
<= 100 items
listChoice
string
default: all
Allowed values: all choose
successMessage
object
es-MX
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
es-ES
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
es-AR
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
en
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
pt-BR
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
fr
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
de
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
it
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ja
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ko
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
zh-CN
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ar
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
redirectUrl
string format: uri
<= 2000 characters
redirectIncludeEmail
boolean
privacyUrl
required
string format: uri
<= 2000 characters
style
object
primary
string
default: #1f4fd8 /^#[0-9a-fA-F]{6}$/
text
string
default: #1a1a1a /^#[0-9a-fA-F]{6}$/
background
string
default: #ffffff /^#[0-9a-fA-F]{6}$/
font
string
default: system
Allowed values: system serif mono
radius
integer
default: 8 <= 24
appearance
object
delaySeconds
integer
0 <= 600
scrollPercent
integer
0 <= 100
exitIntent
boolean
includePaths
Array<string>
default: <= 50 items
excludePaths
Array<string>
default: <= 50 items
devices
Array<string>
default: desktop,mobile >= 1 items
Allowed values: desktop mobile
frequencyDays
integer
default: 7 <= 365
whatsapp
object
phone
required
string
/^\+[1-9]\d{7,14}$/
position
string
default: bottom-right
Allowed values: bottom-right bottom-left
welcome
object
es-MX
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
es-ES
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
es-AR
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
en
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
pt-BR
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
fr
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
de
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
it
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ja
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ko
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
zh-CN
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ar
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
prefill
object
es-MX
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
es-ES
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
es-AR
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
en
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
pt-BR
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
fr
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
de
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
it
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ja
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ko
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
zh-CN
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ar
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
emailConsent
object
es-MX
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
es-ES
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
es-AR
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
en
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
pt-BR
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
fr
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
de
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
it
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ja
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ko
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
zh-CN
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ar
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
defaultCountry
string
default: MX /^[A-Z]{2}$/
consent
required
object
version
required
string
>= 1 characters <= 64 characters /^[^\x00-\x1f\x7f]*$/
text
required
object
es-MX
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
es-ES
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
es-AR
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
en
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
pt-BR
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
fr
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
de
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
it
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ja
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ko
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
zh-CN
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
ar
string
>= 1 characters <= 2000 characters /^[^\x00-\x1f\x7f]*$/
requireCheckbox
boolean
preChecked
boolean
listIds
required
Array<string>
suspendedReason
required
string
nullable
createdAt
required
string
updatedAt
required
string

Example

{
"kind": "embedded",
"status": "draft",
"document": {
"defaultLocale": "es-MX",
"fields": [
{
"type": "email",
"required": false
}
],
"listChoice": "all",
"redirectIncludeEmail": false,
"style": {
"primary": "#1f4fd8",
"text": "#1a1a1a",
"background": "#ffffff",
"font": "system",
"radius": 8
},
"appearance": {
"delaySeconds": 0,
"scrollPercent": 0,
"exitIntent": false,
"includePaths": [],
"excludePaths": [],
"devices": [
"desktop",
"mobile"
],
"frequencyDays": 7
},
"whatsapp": {
"position": "bottom-right",
"defaultCountry": "MX"
}
},
"consent": {
"requireCheckbox": false,
"preChecked": false
}
}

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"
}
}