Pair this phone by code (public)
After consent is given on this link: opens (or resumes) a WhatsApp pairing whose 8-character code is shown only here, never to the guardians. The person types it in WhatsApp → Aparelhos conectados → Conectar com número de telefone. Idempotent: while a code is valid the same one comes back; an attempt that ran out is replaced; a pairing the guardian opened with a QR is switched to the code. The code may arrive a moment later — read GET …/pairing or the stream GET …/events. Needs the guardian to have enabled WhatsApp on the seat. No body.
token*stringthe opaque token from the link
16 <= length <= 4096The pairing as this page shows it
application/json- response
success*truetruedata*curl -X POST 'http://localhost:3000/consent-requests/stringstringstri/pairing'{ "success": true, "data": { "phoneMasked": "string", "pairing": { "status": "starting", "method": "qr", "challengeShownTo": "guardian", "challenge": { "kind": "code", "code": "string", "expiresAt": "2019-08-24T14:15:22Z" }, "failure": "expired", "pairedAt": "2019-08-24T14:15:22Z", "endedAt": "2019-08-24T14:15:22Z" } }}This phone's pairing (public) GET
The open pairing, else the last one (its `failure` explains it), else null. Same gates as POST.
Answer WhatsApp's number check (public) POST
When `challenge.kind` is `passkey_confirm`: does the number WhatsApp shows match? `false` ends the pairing (`failure: passkey_refused`) — a mismatch means another device is being linked.
