🍗 PCK ZRA Middleware Wiki

Troubleshooting

Start from the symptom, confirm it in Reports (every failure keeps its full request and response), then apply the fix. Most issues resolve without server access.

Error catalog (POS-facing)

HTTPErrorCauseFix
400SellerName is requiredMissing SellerInfo/SellerName in the payloadInclude the SellerInfo block with SellerName
400FiscalFolioId is requiredBlank DocumentInfo.FiscalFolioIdSend a folio identifier
400PropertyTaxNumber is requiredMissing TPINInclude a valid TPIN in DocumentInfo
400TrxInfo missing for TrxCodeA Posting has no matching TrxInfo.CodeLink every TrxCode to a TrxInfo entry
400Validation listMalformed payload fieldsFix the listed fields; compare against the schema
401UnauthorizedMissing/invalid JWT (when validation enabled)Refresh the Oracle IDM token; check Bearer format
403Store not registered: XSellerName not in the databaseRegister the store; verify exact spelling/case
403Store is inactive: XStore deactivatedReactivate in the portal
500Chrilan API errorChrilan rejected the call (error body contains code/message/type)Read the Chrilan error in the transaction detail; commonly an invalid store API key or unknown PLU
500TimeoutChrilan unreachable for 30sCheck network/ZRA status; retries happen automatically (3 attempts)

Testing a store end to end

  1. Confirm the store is Active with a valid Chrilan API key in the portal.
  2. Check GET /pckzra/api/taxint/health returns UP.
  3. Submit a small test sale from the POS.
  4. In Reports, open the transaction: verify the Chrilan response contains rcptNo, sdcId and a QR code URL.
  5. Verify the receipt prints with the fiscal identifiers.
  6. If the product is new, confirm menu sync pushed it (look for the latest /product/createBulk call).

Common scenarios

“Every store is failing” (systemic)

“One store is failing”

“Menu changes aren't reaching Chrilan”

“Admins can't sign in to the portal”

“Credit note rejected”

Log analysis

# Recent application errors
grep "ERROR" logs/taxint-chrilan-middleware.log | tail -20

# Follow one transaction through the logs
grep "<transaction-id>" logs/taxint-chrilan-middleware.log

# Failed conversions from the database
SELECT * FROM conversion_logs WHERE conversion_success = FALSE
ORDER BY created_at DESC LIMIT 10;

Escalation

When the transaction detail and this catalog don't resolve it, escalate with: the transaction ID, store name, timestamp, the full Chrilan error body (from Reports), and what changed recently (deployments, key rotations, menu changes).