Skip to main content
PUT
/
api
/
v1
/
device-pairing
/
{pairing_id}
Deposit pairing keys
curl --request PUT \
  --url https://staging.zerolatencylabs.com/api/v1/device-pairing/{pairing_id} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "ecdh_pub": "BPvX1Yk2mN3oQ4rS5tU6vW7xZ8aB9cD0eF1gH2iJ3kL5mN7oP9qR1sT3uV5wX7yZ9aB1cD3eF5gH7iJ9kL1mN3o=",
  "session_pub": "AAECAwQFBgcICQoLDA0ODxAREhMUFRYXGBkaGxwdHh8="
}
'
{
  "code": "malformed_payload",
  "detail": "Submitted request payload is not well-formed",
  "status": 400,
  "title": "Bad Request",
  "type": "about:blank"
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

pairing_id
string<uuid>
required

Pairing id from the QR payload

Body

application/json
ecdh_pub
string
required

base64 (STANDARD) uncompressed P-256 public key, exactly 65 bytes, leading 0x04.

Example:

"BPvX1Yk2mN3oQ4rS5tU6vW7xZ8aB9cD0eF1gH2iJ3kL5mN7oP9qR1sT3uV5wX7yZ9aB1cD3eF5gH7iJ9kL1mN3o="

session_pub
string
required

base64 (STANDARD) Ed25519 session public key, exactly 32 bytes.

Example:

"AAECAwQFBgcICQoLDA0ODxAREhMUFRYXGBkaGxwdHh8="

Response

Keys deposited; the write token is now spent