Financial periods
You can open and close financial periods using our services. We do however recommend using either POS or a recurring task.
Opening
To open a financial period, use OpenFinancialPeriod
;
{}
{}
This request has no body, and returns an empty response. The appropriate OrganizationUnitID
should be defined in the headers of the request.
Closing
To close the period, use CloseFinancialPeriod
;
{}
{}
This request has no body, and returns an empty response. The appropriate OrganizationUnitID
should be defined in the headers of the request.
Checking impediments
Before we close the financial period, we should check for closing impediments using GetFinancialPeriodClosingImpediments
.
Financial period management flow
The services for financial period management have been set up to facilitate the below flow:
An employee opens the financial period by calling
OpenFinancialPeriod
.Once the period has been opened, a cash journal should be opened for each cash device (cash drawer or safe), which consists of counting the current cash contents of the device. This is done by calling
StartOpenCashJournal
. This service expects aDeviceID
, which is the ID of a cash drawer or safe device. To find the device that you want to open a cash journal for, call theListDevices
service, with a filter onTypeID
(CashDrawer
orSafe
) your currentOrganizationUnitID
, orStationID
if this is known. TheStartOpenCashJournal
service returns all that is needed to open a cash journal; the available denominations (which bills and coins are available for theCurrencyID
) and a summary of the previous cash journal (if any). If there is a previous journal, you can look at theClosingAmount
of that period. Logically, the opening amount counted should be equal to the previous closing amount, so this figure can be used to raise a warning to the user if they don't match. It should only be a warning though, since this is allowed: any difference will be corrected as an "opening deviation".To actually open the cash journal,
CompleteOpenCashJournal
must be called with the counted coins, bills and aTotalAmount
. Once a cash journal is opened, the device can be used to make cash mutations (cash payments, cash movements, expenses and deposits).An employee wants to use some money from the cash register to pay for their lunch, which is done by calling
CreateCashExpense
with an amount, a tax code and a reason.Throughout the day, cash payments are made, resulting in
CashTransactionLedger
records (other cash operations, such as creating an expense, moving cash, etc. also create ledgers), which could be viewed by callingListCashTransactionLedger
.Some cash is moved to the safe during the day, which is done by calling
MoveCash
which expects a list of cash denominations and a source and destination device, where the source is the cash drawer and the destination is the safe. Again, the source and destination devices can be discovered by callingListDevices
.A bank deposit is created, by calling
CreateCashDeposit
with a source device (most likely the safe), an amount, denominations and a seal bag number.The shop closes and each cash register is counted, which is initiated by calling
StartCloseCashJournal
. This service returns all the information you need to close a cash register, such as the opening amount, the cash transactions created during this cash journal. TheExpectedClosingAmount
is returned by the service, which is the opening amount of the cash journal plus all the cash transactions created. If the counted closing amount deviates from the expected closing amount, then this difference must be corrected in the call toCompleteCloseCashJournal
. Any unexplained deviations will result in aUnexplainedClosingDeviation
error when callingCompleteCloseCashJournal
.Once all cash devices have been counted, the financial period can be closed. To retrieve if there are any impediments to closing the period, call
GetFinancialPeriodClosingImpediments
. Impediments currently can be: user tasks that must be completed, clocked-in users or open cash journals. The current overall state of the financial period can be retrieved by callingGetFinancialPeriodInformation
, even if the period cannot be closed yet. The response contains information about the period and its cash journals, and is primarily meant for display purposes. To actually close the period, theCloseFinancialPeriod
service must be called.