Skip to content

Lexware vouchers by type; JSON-RPC errors in an HTTP 200 are errors - #836

Merged
keysersoft merged 2 commits into
mainfrom
keysersoft/lexware-jsonrpc-errors
Oct 3, 2026
Merged

keysersoft merged 2 commits into
mainfrom
keysersoft/lexware-jsonrpc-errors

Conversation

@keysersoft

@keysersoft keysersoft commented Oct 3, 2026 •

Copy link
Copy Markdown
Contributor

Was stacked on #831, which is now merged (75633af); rebased onto main.

Lexware Office (from the catalog audit, #833; a paying user hit both errors):

  • lexware_office_get_voucher (/vouchers/{id}): voucher-list rows of type salesinvoice / purchaseinvoice / salescreditnote / purchasecreditnote live there. The user's get_invoice 404 was a salesinvoice id sent to /invoices/{id}. The get_invoice id description now says which types belong where.
  • lexware_office_get_sales_document: down payment invoices, order confirmations, delivery notes, dunnings.
  • list_vouchers: voucher number, created/updated date ranges, sort, unchecked, and "open already includes overdue, so open,sepadebit,transferred is everything unpaid" (the user asked for open,overdue, which Rate limits, actionable errors, adapter fixes, onboarding nudges #831 now explains is refused).
  • create_contact: it always sent roles: {customer, vendor}, an empty person next to company, and a billing address [{}] without a country. Now roles (default customer) and an optional billingAddress object.
  • create_invoice unchanged: the user created three drafts with it successfully.

RestEngine: JSON-RPC errors with HTTP 200 (assertNotJsonRpcError): a body {jsonrpc, error} without result is raised as JsonRpcError with the server's message (error.data.message for Odoo, error.data for Zabbix), no traceback. Before, it was returned as a result and logged as SUCCESS; the install probe passed with a wrong key. Affects zabbix and odoo-jsonrpc only (no custom connector in prod uses JSON-RPC); last 30 days: 3 of 39 such "successes" were errors.

Tests: new rest.engine.jsonrpc.spec.ts (Odoo and Zabbix shapes as logged in prod, results/batches/ordinary error fields pass, and an engine round-trip against a local server); Lexware static spec pins /vouchers/{id}, /{resource}/{id} and the contact body. adapters/connectors/mcp-server suites green, typecheck and lint clean.

Second commit: the zabbix and odoo-jsonrpc instructions no longer tell the model to look for errors inside a 200, and Zabbix's Test connection moves from /api_jsonrpc.php (a GET there answers a JSON-RPC parse error, now raised) to the frontend root /.

@keysersoft
keysersoft requested a review from D3nisty as a code owner October 3, 2026 09:37
Base automatically changed from keysersoft/retry-after-actionable-errors to main October 3, 2026 11:54
Lexware Office (on top of #831, which made voucherType/voucherStatus
required):
- lexware_office_get_voucher reads /vouchers/{id}. Voucher-list rows of
  type salesinvoice, purchaseinvoice, salescreditnote and
  purchasecreditnote live there; a paying user sent one to /invoices/{id}
  and got 404.
- lexware_office_get_sales_document reads down payment invoices, order
  confirmations, delivery notes and dunnings.
- list_vouchers: the documented filters (voucher number, created/updated
  dates, sort), `unchecked`, and "open already includes overdue".
- create_contact sent both roles, an empty person and an address without a
  country on every call. It now takes the roles as given (default customer)
  and drops an absent address.

RestEngine: Odoo's /jsonrpc and Zabbix answer errors with HTTP 200 and an
`error` member. Such a body was returned as a result, logged as SUCCESS,
and a connection probe passed with a wrong key. It is now raised as a
JsonRpcError carrying the server's message (error.data.message or
error.data), without Odoo's traceback. Production, last 30 days: 3 of 39
JSON-RPC calls logged as successes were errors.
…nection on the frontend

A GET on /api_jsonrpc.php answers a JSON-RPC parse error, which the engine
now raises, so Test connection points at the frontend root instead. The
instructions no longer tell the model to look for errors inside a 200.
@keysersoft
keysersoft force-pushed the keysersoft/lexware-jsonrpc-errors branch from e1853fc to c5f9ad3 Compare October 3, 2026 11:55
@keysersoft
keysersoft merged commit b9619a7 into main Oct 3, 2026
13 checks passed
@keysersoft
keysersoft deleted the keysersoft/lexware-jsonrpc-errors branch October 3, 2026 11:58
@github-actions github-actions Bot locked and limited conversation to collaborators Oct 3, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant