In this section you will learn how the fiscal system generates an offline signature (failure of the tse device) and which data is returned in this case by the FiscalClient.
Sometimes communication to the TSE / TSS returns a failure message (hardware failure, cloud-tse cannot connect to the cloud-csp, ...). In this case continue the cashier process as usual, the fiscal system automatically creates offline-signatures and is taking care of automatic re-signing of the receipt as soon the TSE / TSS is available again.
There are several possibilites the fiscal systems has to react on failure of tse:
- tse failure only at createDocument
- tse failure only at storeDocument/cancelDocument
- tse failure at createDocument and storeDocument/cancelDocument
In all cases the fiscal system handles the tse failure for the pos system and only the different fiscal response has to be supported.
Tse failure at createDocument
In this case only opening the transaction on the tse has failed (createDocument).
The fiscal system is returning a special fiscal response:
{
"FiscalCountry":0,
"FiscalisationDocumentNumber": -99,
"FiscalisationDocumentRevision":0,
"FiscalDocumentStartTime":0,
"ProcessStartTime":0,
"ErrorDescription":"Tse connection error.",
"CashRegisterId":"3656-1",
"Signature":"Tse not connected.",
"UserMessage":"Tse not connected.",
"PrintMessage":"TSE ausgefallen.",
"RequestTime":"2021-09-07T07:07:09.5139728+02:00",
"RequestCompletionTime":"2021-09-07T07:07:09.7981746+02:00",
"AdditionalFields":
{
"QrCodeDataString":"", -- empty
"TransactionStartTime":0, -- zero
"TransactionEndTime":1630991229,
"ProcessData":"", -- empty
"ProcessType":"Kassenbeleg-V1",
"TseSerial":"7eeda69cb6fa8e78970150675ad03716fad85394447d6947d7a863b6cb6e5b3c",
"TseTimeFormat":"unixTime",
"TseHashAlgorithm":"ecdsa-plain-SHA256",
"TsePublicKey":"", -- empty
"TseSignatureCounter":0, -- zero
"TseCertificate":"Tse not connected."
}
}
The process for the pos system is the same as usual. Just send the stored values of the fiscal response (with fiscal document number for tse connection error) at storeDocument. The fiscal system itself cares for creating automatically the transaction in front of storing the document (signing) and will respond with a regular fiscal response at storeDocument.
Tse failure at storeDocument/cancelDocument
In this case a failure fiscal response will be returned by the fiscal system:
{
"FiscalCountry":0,
"FiscalisationDocumentNumber":0,
"FiscalisationDocumentRevision":0,
"FiscalDocumentStartTime":0,
"ProcessStartTime":0,
"ErrorDescription":"Tse connection error.",
"CashRegisterId":"3656-1",
"Signature":"Tse not connected.",
"UserMessage":"Tse not connected.",
"PrintMessage":"TSE ausgefallen.",
"RequestTime":"2021-09-07T07:07:09.5139728+02:00",
"RequestCompletionTime":"2021-09-07T07:07:09.7981746+02:00",
"AdditionalFields":
{
"QrCodeDataString":"", -- empty
"TransactionStartTime":0, -- zero
"TransactionEndTime":1630991229,
"ProcessData":"", -- empty
"ProcessType":"Kassenbeleg-V1",
"TseSerial":"7eeda69cb6fa8e78970150675ad03716fad85394447d6947d7a863b6cb6e5b3c",
"TseTimeFormat":"unixTime",
"TseHashAlgorithm":"ecdsa-plain-SHA256",
"TsePublicKey":"", -- empty
"TseSignatureCounter":0, -- zero
"TseCertificate":"Tse not connected."
}
}
At the end of the TSE failure, the fiscal system automatically re-signs all receipts generated and stored during the outage. The POS system does not have to do anything at this point.
Tse failure at createDocument and storeDocument/cancelDocument
In case of these TSE failures, the process to send data to the fiscal system stays the same, the POS software does not need to be adapted to this situation, only the fiscal response is difference to a regular signature response.
{
"FiscalCountry":0,
"FiscalisationDocumentNumber":0,
"FiscalisationDocumentRevision":0,
"FiscalDocumentStartTime":0,
"ProcessStartTime":0,
"ErrorDescription":"Tse connection error.",
"CashRegisterId":"3656-1",
"Signature":"Tse not connected.",
"UserMessage":"Tse not connected.",
"PrintMessage":"TSE ausgefallen.",
"RequestTime":"2021-09-07T07:07:09.5139728+02:00",
"RequestCompletionTime":"2021-09-07T07:07:09.7981746+02:00",
"AdditionalFields":
{
"QrCodeDataString":"", -- empty
"TransactionStartTime":0, -- zero
"TransactionEndTime":1630991229,
"ProcessData":"", -- empty
"ProcessType":"Kassenbeleg-V1",
"TseSerial":"7eeda69cb6fa8e78970150675ad03716fad85394447d6947d7a863b6cb6e5b3c",
"TseTimeFormat":"unixTime",
"TseHashAlgorithm":"ecdsa-plain-SHA256",
"TsePublicKey":"", -- empty
"TseSignatureCounter":0, -- zero
"TseCertificate":"Tse not connected."
}
}
At the end of the TSE failure, the fiscal system automatically re-signs all receipts generated and stored during the outage. The POS system does not have to do anything at this point.
Comments
0 comments
Please sign in to leave a comment.