Skip to main content
Change
Fiscalization API
Returns on a sale from before OpenFiskal can release its open amount
  • A return with external_related_operation now accepts released_outstanding_amount. OpenFiskal never recorded that sale’s open amount, so the release is checked only against the value of the returned goods; 422 return_release_requires_related_operation is no longer returned.
  • For German fiscalization it is signed like any other release, and the DSFinV-K archive references the sale as an external process. See Returns on a sale with an open amount.
Change
Fiscalization API
Closing a session without a count
  • session_close no longer needs a session_cash_count before it. A close on a session nobody counted is accepted; 409 session_not_counted is no longer returned.
  • The close is signed as before. No difference is signed for such a session, and its DSFinV-K export has no DifferenzSollIst.
  • Counting stays as it is: a session_cash_count still freezes the session and signs the difference. See Closing without a count.
Change
Fiscalization API
Czech registers in LIVE
  • API keys can be created for CZE in LIVE, and POST /registers/{id}/fiscalize fiscalizes Czech registers in LIVE.
  • Until EET 2.0 starts on January 1, 2027, live Czech sales are reported to the authority’s test service (environment: "playground"), signed with its shared test certificate. Upload the merchant’s production cash certificate now: from January 1, 2027 live sales are filed in production with it, with no change on your side.
  • A report stays with the service it was first sent to. See Czechia.
Addition
Fiscalization API
Czech sales reported to EET 2.0 (sandbox)
  • A completed sale, return, exchange or payment on a Czech register is reported to the Czech Financial Administration’s test service as it completes.
  • Its fiscal_information has the new regime EET2: status (confirmed, retry, rejected, nothing_to_report), the confirmation code pok, environment, the reported_amount (cash as rounded), confirmed_at (by the authority’s clock), warnings and error. Each warning and error has the authority’s code, an English message, and the authority’s own Czech text in authority_message.
  • A failed report never fails the completion. See Czechia.
Addition
Fiscalization API
Czech registers (sandbox)
  • Merchants accept a CZE fiscal identity: vat_id, the DIČ (CZ and 8 to 10 digits). API keys can be created for CZE, in the sandbox.
  • POST /registers/{id}/fiscalize fiscalizes a register at a Czech location at once, with no signing device: fiscalization_status is fiscalized and fiscalization is regime: czechia_eet2 with fiscalized_at, without TSE fields. It needs the merchant’s CZE fiscal identity.
  • The DIČ is checked as the Financial Administration checks it (a company’s check digit, a person’s birth number); a DIČ that fails is refused with 400 invalid_request.
  • Operations on a Czech register complete with fiscal_information: null and may carry cash rounded to whole crowns (rounded_cash_amount).
  • They are recorded, not yet reported to the Czech Financial Administration (EET 2.0), so Czech registers are fiscalized in the sandbox only: in LIVE the call returns 422 validation_error. See Czechia.
Addition
Fiscalization API
Cash rounding on cash payments
  • POST /operations/{id}/complete accepts an optional rounded_cash_amount on a cash payment: the cash that actually changed hands where cash is rounded to coins that exist (173.63 CHF due, 173.65 taken). It has the sign of amount.
  • amount keeps its meaning, and the payments still add up to total_amount using amount. Nothing changes when you do not send the field.
  • It may differ from amount by at most half the smallest cash denomination of the currency, must be a whole multiple of it, and is only accepted on a cash payment: see rounded_cash_amount_invalid in Errors. A register fiscalized for Germany accepts it only when it equals amount (rounded_cash_amount_not_supported).
  • Payments always return rounded_cash_amount: as sent, or null.
  • See Cash rounding.
Change
Fiscalization API
German fiscal identity: Steuernummer or USt-IdNr
  • A DEU fiscal identity now needs tax_number (Steuernummer), vat_id (USt-IdNr), or both. Both used to be required, which locked out merchants without a USt-IdNr.
  • An identity with neither returns 400 invalid_request. A number you leave out is returned as null.
  • A PATCH replaces the DEU identity as a whole: a number you leave out is cleared.
  • Fiscalizing a German register still needs a DEU fiscal identity.
Addition
Fiscalization API
Returns on a sale with an open amount
  • POST /operations on a return accepts released_outstanding_amount: the part of the related sale’s or exchange’s open amount that the return drops instead of paying it back, because goods come back that were never paid for. Without it nothing changes.
  • At complete, the payments add up to total_amount plus released_outstanding_amount. A return that releases its whole total, such as a cancelled order that was never paid, completes with payments: [].
  • It needs related_operation_id and can release at most the value of the returned goods and at most what is open now: see return_release_requires_related_operation, return_release_related_operation_not_releasable and release_exceeds_outstanding in Errors.
  • A return returns its released_outstanding_amount. Sales and exchanges count releases in outstanding_amount and list the returns in the new releasing_returns[], next to payment_operations.
  • For German fiscalization: the release is signed positive in the NULL bucket, and the DSFinV-K archive files a Forderungsaufloesung referencing the sale’s receipt. See Returns on a sale with an open amount.
Addition
Fiscalization API
Client timestamps on every operation
  • POST /operations now accepts an optional occurred_at (ISO 8601) on sale, return, exchange and payment: when the operation started on your POS. It is returned in the new started_at field, which is null when you send none.
  • POST /operations/{id}/complete accepts occurred_at as well: when the operation ended on your POS. It becomes completed_at. The completed_at request field stays accepted as an alias; sending both with different times returns 422 validation_error.
  • Without them nothing changes: OpenFiskal uses the time it receives the request.
  • 422 validation_error when occurred_at is more than 5 minutes in the future, or when the completion is earlier than the start you sent. The future check now also applies to completed_at, which used to accept any time.
  • For German fiscalization: the DSFinV-K archive files the receipt’s start from started_at and its end from completed_at. Without a start, both stay at completed_at, as before.
  • Send them when an operation can reach OpenFiskal later than it happened, for example from an offline queue. See Offline and recovery.
Addition
Fiscalization API
Client timestamps on session operations
  • session_open, session_cash_adjustment, session_cash_count and session_close now accept an optional occurred_at (ISO 8601): when the event happened on your POS. It becomes the operation’s completed_at and the session’s opening, counting or closing time.
  • Without it nothing changes: OpenFiskal uses the time it receives the request.
  • Send it when the operation can reach OpenFiskal later than it happened. A session your POS opened before it sent the first sale then opens before that sale, and the DSFinV-K archive keeps its receipts in chronological order. Send operations in the order they happened.
  • 422 validation_error when occurred_at is more than 5 minutes in the future, or, on an adjustment, count or close, earlier than the session’s opening.
Addition
Fiscalization API
Open amounts on exchanges
  • POST /operations/{id}/complete on an exchange now accepts outstanding_amount, as on a sale: the part of the upcharge the customer leaves open. The payments plus outstanding_amount must equal total_amount, and payments may be empty when everything is left open. Only money the customer owes can be left open: an exchange with a total of 0 or below completes with nothing open. Without the field nothing changes.
  • A payment operation may now name a completed exchange as its related_operation_id and settles that exchange’s open amount, with the same rules as for a sale (related_operation_not_payable, payment_exceeds_outstanding).
  • A sale and an exchange of the same order have separate open amounts: a payment settles only the operation it names, and an exchange never lowers its sale’s open amount.
  • An exchange now returns its outstanding_amount (what is open now) and payment_operations, like a sale.
  • For German fiscalization: the open part is signed in the NULL bucket, negative, as on a sale. The DSFinV-K archive files a Forderungsentstehung on the exchange’s receipt and a Forderungsaufloesung referencing it on the payment that settles it.
Addition
Fiscalization API
Gift cards on payment operations
  • A payment operation now accepts gift_card legs on POST /operations/{id}/complete: a voucher settling (part of) a sale’s open amount. As on a sale, gift_card_id is required (422 gift_card_id_required). The leg counts towards the payment’s total_amount and lowers the sale’s outstanding_amount like any other leg.
  • For German fiscalization: the voucher is not a payment type. The TSE signs only the money that moved, and the DSFinV-K archive files a MehrzweckgutscheinEinloesung (with voucher_id) next to the payment’s Forderungsaufloesung. No integrator action needed beyond setting gift_card_id.
  • DSFinV-K: a receipt with no money payment (a sale or payment settled entirely by gift cards, or a sale left entirely open) now files the payment type Keine with amount 0 instead of an empty list.
AdditionChange
Fiscalization API
Open amounts and payment operations
  • POST /operations/{id}/complete on a sale accepts outstanding_amount: the part of total_amount left open. The payments plus outstanding_amount must equal total_amount, and payments may be empty when everything is left open. Without it nothing changes: the payments must cover the total.
  • New operation type payment: money against a completed sale’s open amount, with related_operation_id and total_amount, no line items. It can be taken on any register of the merchant and is its own signed receipt. It never collects more than is open: see related_operation_not_payable and payment_exceeds_outstanding in Errors.
  • Every operation now returns outstanding_amount. A sale also returns payment_operations[]: its completed payments with their legs. Both grow without changing the sale’s resource_version.
  • Money amounts in operation responses always carry at least two decimals: "33.80" instead of "33.8", "5.00" instead of "5". Amounts with more decimals (tax_amount, pretax_amount) keep them. Parse amounts as decimals; do not compare them as strings.
Change
Fiscalization API
Decommissioned registers keep recording; registers on a shared TSE can be decommissioned
  • Operations on a decommissioned register are accepted again, sessions included, and recorded without a signature: their fiscal_information is null. They used to be rejected with 409 register_decommissioned, which is no longer returned.
  • POST /registers/{id}/decommission now also decommissions a register whose TSE it shares with other registers at its location. It removes the register from that TSE, which keeps signing for the location’s other registers. It used to answer 422 for them.
  • It answers 409 register_busy (retryable: true, Retry-After) while the location’s shared TSE is being set up or replaced.
See Register lifecycle.
Change
Fiscalization API
Idempotency-Key is enforcedPOST /operations, POST /operations/{id}/complete, and POST /operations/{id}/void now act on Idempotency-Key as documented. A retried request runs once.
  • Retrying with the same key and the same request returns the original result, marked with the Idempotent-Replayed: true response header, instead of creating, completing, or voiding again.
  • Reusing a key with a different request returns 409 idempotency_key_conflict. details.operation_id names the operation the key already belongs to, so a client that lost the first response can find it.
  • A retry sent while the first request with its key is still running waits up to 5 seconds for it. If it is still running after that, the retry returns 409 idempotency_key_in_progress with Retry-After.
  • A missing header returns 400 idempotency_key_required. Every client we see in production already sends it.
  • Keys are retained for 30 days (previously documented as at least 24 hours).
  • register_busy and operation_in_progress responses now carry retryable: true and a Retry-After header. Their message always said to retry; the flag now agrees.
  • When the TSE stays busy signing other receipts, signing now answers 409 tse_busy (retryable: true, Retry-After) instead of a generic, non-retryable 409 conflict.
  • A complete whose payments repeat a payment_id now returns 422 payment_id_duplicate before anything is signed. It used to be signed on the TSE and then fail with a 500.
  • If a complete was signed on the TSE but did not finish, a later complete of the same operation with different amounts or payments now returns 409 operation_already_signed instead of completing with a signature over the original amounts.
See Idempotency rules.
Addition
Fiscalization API
Cart-level discounts on SALEPOST /operations for type: "sale" now accepts an optional cart_level_discounts[] array — discounts applied to the order as a whole, not apportioned onto specific line items.
  • Each entry carries an optional description (free-text label, e.g. promo code) and a required positive amount decimal string.
  • line_items[].total_amount values must already reflect their post-discount totals — cart_level_discounts[] is documentation of the order-level reduction, not a re-pricing instruction.
  • The same array is returned on sale operation responses, with server-issued id per entry.
  • For German fiscalization: each cart-level discount emits a separate Rabatt business case in the DSFinV-K cashpoint-closing archive, slotted between the line-item Umsatz lines and any gift-card MehrzweckgutscheinEinloesung lines. Descriptions over 255 characters are trimmed for the DSFinV-K text field; the original is preserved in the operation response.
Addition
Fiscalization API
Gift card redemptionspayments[] on POST /operations/{id}/complete now accepts an optional gift_card_id field — the integrator-supplied identifier of the voucher being redeemed.
  • gift_card_id is required when method: "gift_card". Sending a gift_card payment without it (or with empty/whitespace) returns 422 gift_card_id_required.
  • The same field is returned on payments in the operation response.
  • For German fiscalization: each gift_card payment on a sale now emits a MehrzweckgutscheinEinloesung line in the DSFinV-K cashpoint-closing archive, carrying the redeemed amount (negative) and voucher_id. Per §3 Abs. 15 Satz 2 UStG, the redemption is anti-payment rather than revenue, so the gift-card leg is no longer reported under payment_types; the SALE’s full_amount_incl_vat is reduced by the redeemed total and a balancing entry is added to amounts_per_vat_id at the non-taxable bucket. No integrator action needed beyond setting gift_card_id.
Addition
Fiscalization API
Gift card line itemsLine items on POST /operations (for sale, return, exchange) now accept an optional type field with values item (default) or gift_card.
  • gift_card lines represent multi-purpose voucher sales (Mehrzweckgutschein). All taxes on a gift_card line must carry rate: "0" and tax_amount: "0" — non-zero rates are rejected with 422 gift_card_tax_rate_must_be_zero. VAT on multi-purpose vouchers is deferred to redemption.
  • An optional gift_card_id field carries the integrator-supplied gift card identifier.
  • The same type and gift_card_id fields are returned on line items in operation responses.
  • For German fiscalization: gift_card lines emit MehrzweckgutscheinKauf (instead of Umsatz) in the DSFinV-K cashpoint-closing archive. No integrator action needed beyond setting type.
Addition
Fiscalization API
tax_amount consistency checkEach line_items[].taxes[].tax_amount is now checked against total_amount × rate_i / (1 + Σ rate_j) at 8 dp; mismatches return 422 tax_amount_precision_invalid. Submit tax_amount rounded to 8 dp. See Decimal precision.
BreakingAddition
Fiscalization API
Line items now require sku_identifierEach entry in line_items[] on POST /operations (for sale, return, exchange) now requires a sku_identifier field — the merchant’s stable variant identifier (e.g. "TSHIRT-BLUE-M").Identifies a unique number used to maintain and manage the item, product, or merchandise category in the company’s systems. Example: A Tshirt has one sku for each size + color combination.Breaking — sku_identifier is mandatory, as it’s required for regulatory exportsThe same field is returned on every line item in the operation response.
BreakingAddition
Fiscalization API
Session close split into count + closeEnd-of-shift is now a two-step flow: the merchant counts the drawer first (session_cash_count), then seals the session (session_close). The two events attest to different fiscal facts and produce up to two TSE signatures from one end-of-shift sequence.
  • session_cash_count — new operation type. Carries counted_closing_amount (and optional discrepancy_note). Server returns expected_closing_amount and signed closing_cashcount_diff (counted − expected). The variance is fiscally attested.
  • session_close — slimmed. Now carries only the optional closing pull/add (closing_adjustment_amount signed: negative = cash out, positive = cash in; plus closing_adjustment_note). Fiscally signed only when the pull is non-zero; null/zero is a state-transition close with no TSE signature.
Breaking — session_close no longer accepts counted_closing_amount or discrepancy_note. Those fields moved to session_cash_count. Bodies that include them on a close return 400.Breaking — session_close requires a preceding session_cash_count. A close on an un-counted session returns 409 session_not_counted.Breaking — once counted, the session is frozen. Posting sale / return / exchange / session_cash_adjustment / a second session_cash_count against a counted session returns 409 session_already_counted. Only session_close is accepted from the counted state.Breaking — SessionCloseOperation response shape narrowed. counted_closing_amount and discrepancy_note are no longer on the close response (they’re on the SessionCashCountOperation response).New session lifecycle state. Sessions transition open → counted → closed (was open → closed). The counted state is short-lived in the happy path — most integrators will POST count then close back-to-back.Update integrator end-of-shift flows to count first, then close, before your next release. See Sessions for the walkthrough.
BreakingAddition
Fiscalization API
Register sessions: new operation types + session-bound POS operationsThree new operation types model the cash-drawer shift on a fiscalized register:
  • session_open — start a shift with a counted opening float
  • session_cash_adjustment — record mid-shift cash movement (drop, pay-in, correction)
  • session_close — end the shift with a merchant-counted closing balance
All three flow through POST /operations (no separate sessions endpoint) and carry the same resource_version / ETag mechanics as goods-movement operations. They are born status: "completed" — there is no POST .../complete step for session events.Breaking — POS goods-movement now requires an open session. Sending POST /operations with source: "POS" on a register that has no open session is rejected with 409 no_open_session. Open the register’s session with session_open before posting POS sales, returns, or exchanges. At most one open session per register; opening a second while one is open returns 409 session_invalid_state.New field — session_id on operation responses. Every operation response now carries session_id on the envelope. For POS goods-movement, it’s the session the operation was rung up during. For session-event variants, it’s the session being opened/adjusted/closed. For ONLINE goods-movement (no register), it’s null.Breaking — GET /operations/{id} is now a discriminated union on type. Six variants: SaleOperation, ReturnOperation, ExchangeOperation, SessionOpenOperation, SessionCashAdjustmentOperation, SessionCloseOperation. Each variant carries only the fields meaningful to its type — SESSION_* responses no longer include zero-padded pretax_amount / total_amount / line_items / payments / fiscal_information, and goods-movement responses no longer include null session_*_details placeholders. SALE responses also drop the always-null related_operation_id and external_related_operation.See Sessions for the full walkthrough.Update integrators that issue POS operations to bracket each shift with session_open / session_close before your next release.
Breaking
Fiscalization API
Merchant tax_id removed; Italian fiscal_identity reshapedThe top-level Merchant.tax_id field has been removed from create, update, and response shapes. Tax identifiers now live exclusively on fiscal_identity, where they can vary by country.The Italian fiscal_identity object (country_code: "ITA") has been replaced:
  • Removed (both optional): vat_id, codice_fiscale.
  • Added (all required): tax_number (Codice Fiscale — 11 numeric digits or 16 alphanumeric characters), vat_number (Partita IVA — 11 numeric digits), fisconline_user (16 alphanumeric characters; the Codice Fiscale of the person delegated to access the Agenzia delle Entrate portal), fisconline_password, fisconline_pin.
  • legal_entity_type (COMPANY | INDIVIDUAL) is unchanged.
The German (DEU) and Austrian (AUT) fiscal_identity shapes are unchanged.Update integrator code that creates or updates Italian merchants, and stop sending the top-level tax_id field for all merchants, before your next release.
Addition
Fiscalization API
New endpoints: POST /exports, GET /exports/{exportId}Two new endpoints expose asynchronous fiscal export jobs.POST /exports enqueues a job and returns 202 Accepted with { id, type, status: "pending", register_id?, from, to, created_at }. Required body fields: type (dsfinvk is the first available type), from and to (ISO 8601 date-times). Optional register_id scopes the export to a single register; when omitted, the export covers all eligible registers under the merchant for the matching fiscal regime.GET /exports/{exportId} returns the job. Once status is completed, download_url is a signed URL to fetch the artifact. When status is failed, error.message (and optional error.details) describes why.Both endpoints require the X-OpenFiskal-Merchant header.
Addition
Fiscalization API
external_related_operation accepted on returns/exchangesPOST /operations with type: "return" or type: "exchange" now accepts a new optional field, external_related_operation, for cases where the original sale was never ingested into OpenFiskal (typically during platform migration before backfill).
  • Mutually exclusive with related_operation_id — exactly one must be set on a return or exchange.
  • Both fields on the nested object are required strings.
  • The same field is echoed on the operation response.
Use related_operation_id when the original sale exists in OpenFiskal; use external_related_operation otherwise.
Breaking
Fiscalization API
Sign convention enforced on total_amount and line_items[].total_amountPOST /operations now rejects payloads whose amount signs do not match Operation.type:
  • sale: total_amount and every line_items[].total_amount must be >= 0.
  • return: total_amount and every line_items[].total_amount must be <= 0.
  • exchange: no sign constraint (an exchange may net positive, negative, or zero).
Zero is permitted on both sale (freebie) and return (zero-value return). Violations return 422 Unprocessable Entity.Sign is the only signal the TSE has to tell a sale from a return in its signature, so OpenFiskal enforces it before signing.Update return flows that previously sent positive amounts on type: "return" to send non-positive amounts before your next release.
Breaking
Fiscalization API
fiscal_identities[].country renamed to country_code; DE fields now requiredThe discriminator field on every fiscal_identity entry has been renamed from country to country_code. This applies to all three country variants (DEU, AUT, ITA) on both the create/update payload and the merchant response. Payloads that send country will reject.For DEU fiscal identities, tax_number (Steuernummer) and vat_id (USt-IdNr) are now both required. Previously both were optional. AUT and ITA requirements are unchanged.Update integrator code that creates or parses merchant fiscal_identities before your next release.
Addition
Fiscalization API
OpenAPI JSON now served at /openapi-jsonThe current production OpenAPI spec is now served at:
  • Production: https://api.openfiskal.com/openapi-json
  • Sandbox: https://sandbox.api.openfiskal.com/openapi-json
The previous Swagger-default path /docs-json is preserved as a 301 redirect to the new path. Import the new URL into Postman, Insomnia, or an OpenAPI code generator to scaffold a client.The OpenAPI spec always matches the live API implementation.
Breaking
Fiscalization API
Operation.status enum corrected; 412 payload includes expected_resource_versionThe Operation.status enum has been corrected from 'open' | 'completed' | 'cancelled' to 'open' | 'completed' | 'voided'. Operations that you POST /operations/{id}/void resolve to status: "voided", not cancelled. There were never any operations with status: "cancelled" in production — the OpenAPI value was wrong.412 Precondition Failed error bodies now include details.expected_resource_version alongside details.current_resource_version. The message field is the literal string "Resource version mismatch." (previously "The supplied If-Match value is stale.").Update Operation.status parsers to accept voided, and update any UI that surfaces the precondition_failed error message string.
Breaking
Fiscalization API
Operation type refund renamed to returnThe Operation.type enum now uses return instead of refund for operations where goods come back from the customer. The valid values are sale | return | exchange.OpenFiskal now distinguishes goods movement from money movement: operations model goods (sale/return/exchange), refund is reserved for money movement (a negative payment transaction on an operation) and is not an operation type. This unlocks flows the old terminology could not express cleanly — return with store credit (goods back, no money), goodwill refund (money back, no goods), or partial refunds on kept items.
  • POST /operations with type: "refund" will now reject. Use type: "return".
  • Response shapes now return type: "return" for what was previously type: "refund".
  • Payment.status enum is unchanged — refunded is still the correct status for a payment that has been reversed, because it describes money movement.
Update integrator code that creates or parses return/refund operations before your next release.
Breaking
Fiscalization API
KassenSichV schema changes
  • FiscalInformationKassenSichVVerification: renamed tse_serial to tss_serial_number and client_id to pos_client_serial_number. Both remain required.
  • FiscalInformationKassenSichVEndEvent: added required public_key (string).
  • FiscalInformationKassenSichVStartEvent: removed transaction_counter and signature. signed_at is now the only required field.
Update integrations that submit or parse KassenSichV fiscal information before your next release.
Clarification
Fiscalization API
Country code casingClarified that the country field on Address and on the legal entity schema must be an ISO 3166-1 alpha-3 code in uppercase (for example, DEU). No behavior change; existing uppercase values continue to validate.
Addition
Fiscalization API
New endpoint: POST /registers/{registerId}/decommissionPermanently retires a fiscalized register. The endpoint calls the underlying TSE provider to decommission the register’s fiscal components and returns the updated register with decommissionedAt populated. Currently DE/KassenSichV only; AT/IT will follow as those regimes ship publicly.Conflicts return 409 decommission_conflict:
  • Register has not been fiscalized.
  • Register has already been decommissioned.
A decommissioned register cannot be re-fiscalized — create a new register for that location instead.