1.1 KiB
1.1 KiB
POST /agent/pair
Public. No cookie required.
Pair printer agent
Public, unauthorized endpoint used by the printer agent to complete pairing using a 6-digit PIN.
Updates clientserial, clientmodel, and agentversion, clears the pairing PIN, and returns a device authentication token.
Body (JSON)
| Field | Required | Type | Description |
|---|---|---|---|
pairingpin |
yes | string | |
clientserial |
no | string | |
clientmodel |
no | string | |
agentversion |
no | string |
{
"pairingpin": "123456",
"clientserial": "SN-987654321",
"clientmodel": "Epson TM-T88VI",
"agentversion": "1.0.0"
}
Response 200
Pairing successful
{
"id": 1,
"name": "…",
"companyId": 1,
"token": "…",
"pairedAt": "…",
"clientserial": "…",
"clientmodel": "…",
"agentversion": "…",
"sort": 1
}
Errors
| Status | Description |
|---|---|
| 400 | Missing or invalid pairing PIN — {"error":"…"} |
Generated from @openapi JSDoc. Do not edit by hand — run npm run docs:api.