SuperdindaDocs
Channels

Fetch a fresh QR/code

POST
/seats/{uid}/pairing/challenge

On demand; the workers also refresh it on a timer and push it through SSE. With ?method=qr, takes over a pairing the dependent was doing by code on their own phone (the fallback "Vocês estão juntos agora?"): same session, a QR on this screen, the code stops working. Owner only.

Authorization

Bearer
headerAuthorizationBearer <JWT>

Path Parameters

uid*string

seat uid

Formatuuid

Query Parameters

method?"qr"

qr: take the challenge over to this screen — the fallback "Vocês estão juntos agora?" while the dependent was being shown a code. Same session, the code stops working

Value in"qr"

Response Body

The pairing with its current challenge (null when the provider has none yet)

application/json
  1. response
success*true
Value intrue
data*
Example Request
curl -X POST 'http://localhost:3000/seats/497f6eca-6276-4993-bfeb-53cbbbba6f08/pairing/challenge'
Example Response
{  "success": true,  "data": {    "uid": "string",    "channel": "whatsapp",    "status": "starting",    "method": "qr",    "challenge": {      "kind": "qr",      "image": "string",      "mime": "string",      "expiresAt": "2019-08-24T14:15:22Z"    },    "challengeShownTo": "guardian",    "identity": {      "phone": "string",      "pushName": "string",      "avatarUrl": "string"    },    "reconnectAttempts": 0,    "nextRetryAt": "2019-08-24T14:15:22Z",    "failureReason": "string",    "pairedAt": "2019-08-24T14:15:22Z",    "lastSeenAt": "2019-08-24T14:15:22Z",    "endedAt": "2019-08-24T14:15:22Z",    "createdAt": "2019-08-24T14:15:22Z"  }}