Pair Device With Phone Code
curl --request POST \
--url https://api.example.com/api/v1/devices/{device_id}/pair-phone \
--header 'Content-Type: application/json' \
--data '
{
"phone": "<string>"
}
'import requests
url = "https://api.example.com/api/v1/devices/{device_id}/pair-phone"
payload = { "phone": "<string>" }
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({phone: '<string>'})
};
fetch('https://api.example.com/api/v1/devices/{device_id}/pair-phone', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"ready": true,
"status": "<string>",
"linking_code": "<string>",
"phone": "<string>",
"proxy_enabled": false,
"connection_hint": "<string>"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}devices
Pair Device With Phone Code
Request a pairing code to link this device without scanning a QR.
POST
/
api
/
v1
/
devices
/
{device_id}
/
pair-phone
Pair Device With Phone Code
curl --request POST \
--url https://api.example.com/api/v1/devices/{device_id}/pair-phone \
--header 'Content-Type: application/json' \
--data '
{
"phone": "<string>"
}
'import requests
url = "https://api.example.com/api/v1/devices/{device_id}/pair-phone"
payload = { "phone": "<string>" }
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({phone: '<string>'})
};
fetch('https://api.example.com/api/v1/devices/{device_id}/pair-phone', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"ready": true,
"status": "<string>",
"linking_code": "<string>",
"phone": "<string>",
"proxy_enabled": false,
"connection_hint": "<string>"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Headers
Path Parameters
Body
application/json
Request a WhatsApp pairing code for a phone number.
WhatsApp number with country code, e.g. 6281234567890.
Required string length:
8 - 32