Month-end close is not a permission. It's an auditable state machine.
What the CFO fights every month — closing on time, knowing who touched what, explaining FX variance — cifraHQ solves in the schema, not in internal policy.
The four pains of corporate close
- Close drags because AR and AP don't close the same day. Systems that require closing everything at once force you to wait for the last vendor invoice before closing sales. The cifraHQ period machine supports asymmetric locks:
LockSaleson day 3,LockPurchasingon day 8,LockSalesAndPurchasingwith accountant adjustments still allowed,Lockedat the end. Close flows at the pace of the business, not the software. - FX nobody can explain to the auditor. A USD payment against a PAB invoice generated a difference — which account? which rate? The multi-currency module preserves original currency on every line; revaluation of open AR/AP runs at month-end with a configurable policy (average, spot, historical);
FXGain/FXLosspost to deterministic accounts without manual adjustment. - "Who changed this?" six months later. The question arrives at the worst moment — during an external audit. The dual audit trail combines temporal tables over every mutable entity with append-only
AuditEventsfor business events.DENY UPDATE/DELETEat the SQL principal means even an engineer cannot rewrite history. - Consolidated reporting that always needs "a small adjustment". Statements get prepared in one system and massaged in another. cifraHQ is API-first: the same public
OpenAPI 3.0the UI consumes feeds the reporting engine; the statement exporter snapshots the closed period, not the moving one.
Three concrete mechanisms
Period state machine
Six states with asymmetric locks. <code>LockSales</code>, <code>LockPurchasing</code>, adjustments, <code>Locked</code>, guided year-end. Transitions logged; reverse requires reason ≥ 20 characters.
Original currency preserved
Every line in its native currency; revaluation with configurable policy; <code>FXGain</code>/<code>FXLoss</code> to deterministic accounts without manual adjustment.
Dual audit trail
Temporal tables plus <code>AuditEvents</code> with <code>DENY UPDATE/DELETE</code>. Evidence does not depend on the application — it lives in the SQL engine.
What a well-run close looks like
- Day 1–3: AR sprint, AP still open. Sales and credit notes accrue; the AP team waits for the last vendor bills.
LockSalescloses AR without touching AP. - Day 3–8: AP wraps. Purchases post, expense accounts get reviewed.
LockPurchasingcloses AP; the period moves toLockSalesAndPurchasingso only accountant adjustments remain possible. - Day 8–10: currency revaluation. The Hangfire job revalues open AR/AP at the configured rate;
FXGain/FXLosspost. The accountant reviews entries before transitioning. - Day 10: Locked. The period moves to
Locked. Posting is blocked at the engine — no document with aPostingDateinside the period posts further. - Reversal available but costly. Surfacing an error after lock requires
PostingPeriod.ReverseClose, a reason ≥ 20 characters, and lands inAuditEvents. The door exists, but it's visible.
Talk to sales for CFOs
We simulate your month-end close with your data — asymmetric locks, FX revaluation, year-end and audit evidence — in a technical session.