Skip to content

Create a WhatsApp connection (credentials.manage). The webhookUrl is shown only here.

POST
/v1/orgs/{org}/connections/whatsapp
curl --request POST \
--url https://api.replifier.com/v1/orgs/org_01hx0000000000000000000000/connections/whatsapp \
--header 'Content-Type: application/json' \
--data '{ "name": "example", "brandId": "example", "config": { "phoneNumberId": "example", "wabaId": "example", "appId": "example", "limits": { "perSecond": 1, "perDay": 1 } }, "secret": { "accessToken": "example", "appSecret": "example" } }'
org
required
string
/^org_[a-z0-9]{26}$/

Example

org_01hx0000000000000000000000
Media typeapplication/json
object
name
required
string
>= 1 characters <= 120 characters /^[^\x00-\x1f\x7f]*$/
brandId
string
nullable <= 64 characters
config
required
object
phoneNumberId
required
string
>= 1 characters
wabaId
required
string
>= 1 characters
appId
string
limits
object
perSecond
integer
perDay
integer
nullable
secret
required
object
accessToken
required
string
>= 1 characters
appSecret
string

Example generated

{
"name": "example",
"brandId": "example",
"config": {
"phoneNumberId": "example",
"wabaId": "example",
"appId": "example",
"limits": {
"perSecond": 1,
"perDay": 1
}
},
"secret": {
"accessToken": "example",
"appSecret": "example"
}
}

Connection created

Media typeapplication/json
object
id
required
string
name
required
string
brandId
required
string
nullable
provider
required
string
Allowed values: whatsapp
config
required
object
phoneNumberId
required
string
>= 1 characters
wabaId
required
string
>= 1 characters
appId
string
limits
object
perSecond
integer
perDay
integer
nullable
status
required
string
Allowed values: pending active error disabled
webhookConfigured
required
boolean
createdAt
required
string
updatedAt
required
string
lastCheckAt
required
string
nullable
webhookUrl
required

Full webhook URL. Shown only when the connection is created; Replifier does not store it.

string

Example

{
"provider": "whatsapp",
"status": "pending"
}

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

Conflict

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