You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Operation codes 6 and 10 were swapped. Per the spec's operation-codes table (§4.4.1), wire
code 6 is print return receipt and code 10 is get returnable receipt (the read-only
lookup). The crate had them reversed because the spec describes them in section order (§4.5.6 get,
§4.5.7 print), which is the reverse of the code assignment. PrintReturnReceiptRequest now sends
op 6 and GetReturnableReceiptRequest op 10; a regression test pins both. The hardware-test matrix
rows for these two operations in README.md were captured with the codes swapped and are now
flagged as needing re-test.
Spec translation (docs/spec.md) corrections. The operation-codes table had codes 6/10 and
12/13 swapped, and rendered the recurring qualifier "(պահանջվում է ընթացիկ սեսիա)" ("requires an
active session") as the invented phrase "(kept for backward compatibility)" / "(requires the
updated version)" on ~39 lines. Response code 196 ("Այլ երկրի ծածկագիր", an eMark from
another country) was mistranslated as "other unknown error".
Changed
ServerErrorKind::OtherUnknownError renamed to ForeignCountryEmark (code 196) to match its
real meaning. Breaking for any consumer matching on that variant.
Human-facing operator listings now resolve assigned department IDs to department names and tax
regimes in the CLI, native app, and web demo. Missing operator/department names are rendered
explicitly as [operator name not provided] / [department name not provided].
hdm-am-bridge 0.4.0
Install hdm-am-bridge 0.4.0
Install prebuilt binaries via shell script
curl --proto '=https' --tlsv1.2 -LsSf https://github.com/lobotomoe/hdm-am/releases/download/v0.4.0/hdm-am-bridge-installer.sh | sh
format_receipt — render a fiscal receipt as human-friendly text. The device prints the legal
receipt itself and returns only structured identifiers, so this reconstructs a faithful summary
from the request/response pair (hdm_am::format_receipt(&PrintReceiptRequest, &ReceiptResponse)).
Returns a width- and locale-agnostic ReceiptLayout of semantic ReceiptLines with the device's
own Armenian labels (Գ/Հ = registration number, ԱՀ = serial, ԿՀ = receipt number); render it with ReceiptLayout::to_plain_text(width) (or Display at DEFAULT_WIDTH). Not a pixel clone of the
government layout — per-line VAT and taxation captions depend on data outside the pair and are
omitted. hdm receipt now prints the rendered receipt instead of a field dump.
OpenAPI 3.1 document for the bridge. Assembled from the same schemars-derived schemas the
handlers serialize (cargo run -p hdm-am-bridge --example dump-openapi --features schema),
committed at docs/openapi.json and CI-checked with --check, served at GET /v1/openapi.json,
and rendered as a Scalar API explorer at GET /docs.
clients/ — a TypeScript/JavaScript pnpm workspace generated from that document, with its own
CI job (gen:check, typecheck, lint, test, build):
@hdm-am/client — isomorphic, zero-dependency client (one typed method per operation, typed HdmBridgeError/HdmTransportError), types generated by openapi-typescript.
@hdm-am/react — provider and typed query/mutation hooks over the client (react peer dep only).
demo — a private Vite + React + shadcn/ui app that drives a real device from the browser.
hdm-am-bridge 0.3.0
Install hdm-am-bridge 0.3.0
Install prebuilt binaries via shell script
curl --proto '=https' --tlsv1.2 -LsSf https://github.com/lobotomoe/hdm-am/releases/download/v0.3.0/hdm-am-bridge-installer.sh | sh
hdm-am-bridge (binary hdm-bridge): a localhost HTTP server that exposes the protocol to a
browser over CORS — one POST /v1/<op> per operation, a configured default device with optional
per-request connection override, bearer-token auth, a CORS origin allow-list, the Private Network
Access preflight header, and single-session serialization. Embeddable via hdm_am_bridge::serve.
hdm bridge start / stop / status / run — the CLI supervises the bridge as a background
process (Unix) with no compile-time dependency on the bridge crate.
Deserialize for the operation request types and the request-only enums (PrintMode, FiscalReportKind, ReportFilter), and Serialize for HdmIdentity — so payloads round-trip
through JSON (consumed by the bridge).
Prebuilt cross-platform binaries (hdm, hdm-bridge) for Linux (x86_64/aarch64), macOS
(x86_64/aarch64), and Windows (x86_64) via cargo-dist, with shell/PowerShell installers and
checksums; CI now builds and tests the library, CLI, and bridge on macOS and Windows.
Changed
The bridge shuts down gracefully on SIGTERM as well as Ctrl-C/SIGINT.
hdm-am-bridge 0.2.0
Install hdm-am-bridge 0.2.0
Install prebuilt binaries via shell script
curl --proto '=https' --tlsv1.2 -LsSf https://github.com/lobotomoe/hdm-am/releases/download/v0.2.0/hdm-am-bridge-installer.sh | sh