Resolution cascade
At runtime fire-kds always walks the same list:- Active vendor row for the order’s vendor (backoffice Vendor ID).
- Account default (empty vendor).
- Environment variables on the fire-kds server.
The stored API key is the same row for both jobs. Print sends
Authorization: Bearer. Cancel sends x-api-key.
base_url is the Fire host only (https://br.app.fire.rest). fire-kds appends the path. A URL with /v1/print is rejected in the backoffice.Fiscal print call
After credentials resolve, fire-kds requests:- v1 — Brazil.
- v2 — Ecuador and later (RIDE layout in
fiscalRepresentation).
400 / 401 / 403 are permanent; other failures enqueue a retry.
Cancel when Fire says no
Cancel uses the same cascade, thenPOST to the XMART cancel adapter with x-api-key.
If Fire (or the adapter) returns 4xx:
- The operator sees Fire rejected the cancellation plus the policy detail (
reasonDetail, and threshold/elapsed when present). - The cancel job stays failed. The ticket is not marked cancelled.
- The same input is not retried automatically.
What this is not
- Not Fire Agent (local printer WebSocket). That is Peripherals, printing and validation.
- Not the catalog of cancellation reasons. Those live in store KDS settings.

