Booking vending machine sales
From the monthly statement to a booking per session in the ERP system, with rounding, tax and deposit.
- Task
- Book sales, tax and deposit of vending machines in the ERP system
- Scope
- One module with around 5,000 lines of code and more than 100 automated tests
- Checks
- Trial month with 3,505 sales at 11 machines, comparison over 18 months
- Interface
- REST interface of the telemetry system
The module runs on the test system. The start in operation follows after approval.
The problem
Booking from monthly statements
Until now, the sales of the machines were booked from monthly statements per location. Card and cash sales, deposit and the tax rates had to be brought together. That is manual work that costs time with every special case, and the booking only appears weeks after the sale.
The solution
Every machine runs a daily session
In the ERP system, every machine runs a daily session like a till. The sales come from the telemetry system, and each sale is taken over only once. Goods issue and revenue booking only arise once the session is closed. Refills are booked as a stock transfer, withdrawals of notes and coins in the cash book.
Architecture
From sale to booking
- External systemSale at the machineCard, cash, deposit
- External systemTelemetry systemcollects sales, refills, withdrawalsREST interface, read access, one limited write access
- Own systemImport every 10 minutesevery transaction exactly onceUnique through the transaction number
- Own systemDaily session per machinelike a tillSupplements for late sales
- Own systemSession closeGoods issue, revenue, tax, depositRounding per session
What we learned
Rounding, keys and the comparison
Rounding per session
The gross amount of a sale is fixed. If tax is calculated per sale, the tax calculation of the ERP system misses every sixth price by one cent for prices in five-cent steps. That is why rounding is done per session.
Protection in our own client
The telemetry system only knows full access keys. That is why the protection lives in our own module: reading is the default, a single write access (creating an article) is released through an allow list, only with its own key and after confirmation.
The comparison
The trial month (3,505 sales, 11 machines, 258 daily sessions) matches the previous monthly statements to the cent for cash, card and deposit. Over 18 months of history, rounding differences remain of 9 cents at most.
A similar problem?
Tell us about it. The case studies show how we work, but every project starts with listening.
Discuss a project