Push queued changes
Admin or cashier. Replays a device’s queued sales, customer, supplier, medicine changes. Per-entity results sit in the 200 body, and a replayed client_mutation_id is deduped.
POST
/api/v1/sync/pushAuthorization
AuthorizationBearer token (JWT) · headerrequiredJWT from POST /api/v1/auth/login sent as Authorization Bearer.
Request body
requiredapplication/jsondevice_idstringrequiredchangesobject[]requiredShow propertiesHide properties
Array of
objectclient_mutation_idstringrequiredentitystringrequiredopstringrequiredpayloadobjectrequiredResponses
200
Accepted changes and per-entity rejections
acceptedobject[]requiredShow propertiesHide properties
Array of
objectclient_mutation_idstringrequiredidstringrequiredicvintegermin -9007199254740991 · max 9007199254740991
invoice_numberstringrejectedobject[]requiredShow propertiesHide properties
Array of
objectclient_mutation_idstringrequiredcodestringrequiredmessagestringrequired400
Body must contain device_id and a changes array
detailstringrequired401
Not authenticated
detailstringrequired403
Caller's role is not allowed, the device belongs to another branch, or the device has been revoked
detailstringrequired404
Unknown device
detailstringrequired