Start linking a number: show the returned QR code to the person holding the phone (WhatsApp, Settings, Linked devices, Link a device), or with method: code give them the pairing code to type on the phone. The QR changes about every 20 seconds: follow GET /whatsapp-accounts/{id}/link until it reads active, when account.connected also fires. A number already linked (in this workspace or another) is refused once scanned, and its new device leaves the phone. Needs the WhatsApp channel enabled for the workspace (403 otherwise). Rate-limited: 10 links an hour per workspace, 3 pairing codes a day per phone number.
Authorization
bearerAuth An API key created on the Access tokens page.
In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/whatsapp-accounts" \ -H "Content-Type: application/json" \ -d '{ "acceptRisk": true }'{ "data": { "id": "string", "checkpoint": { "type": "qr", "qrImage": "string", "code": "string", "expiresAt": "2019-08-24T14:15:22Z" } }}Follow a link GET
Where a link stands: `pending` with the current checkpoint (the QR changes about every 20 seconds), `expired` (nothing was scanned in time: POST /whatsapp-accounts/{id}/relink), `active` with the number, or `error` with its `code` (`duplicate`: the number is already linked).
List WhatsApp numbers GET
Linked WhatsApp numbers, newest first: status, connection, today's caps (the warm-up applied), usage, warm-up, and WhatsApp's own limits on the number (its new-chat quota and its block on new chats).