The database is on your machine
An encrypted-at-rest SQLite database on the officine’s own disk. It is not a cache: it is the original. The server is your machine — counters reach it over the local network, never over the internet.
The line drops, the outage lasts three hours, and there is still a customer at the counter. Doctavie Pharmacy sells, takes payment, prints the ticket and keeps the stock without asking the network for permission — because the database is on your machine, not on ours.
Plenty of software says “offline mode” and means “we put the sale in a queue and hope”. Here is what it means with us, precisely.
An encrypted-at-rest SQLite database on the officine’s own disk. It is not a cache: it is the original. The server is your machine — counters reach it over the local network, never over the internet.
Taking payment, giving change, printing the ticket, decrementing stock, keeping the cash session: all local. None of it waits on a remote server, so none of it can fail because a remote server did not answer.
When the line comes back, only aggregates go up — sales, stock movements, CHIFA batches, rejections. Never a customer’s name, never a slate, never a beneficiary. This is not a setting: the list is hard-coded, and a test fails the build if anyone tries to add a nominative table to it (loi 18-07).
The question is not “is there an offline mode” but “what exactly stops”. Here are six things a pharmacist does during an outage.
| “Cloud” software | Doctavie Pharmacy | |
|---|---|---|
| Ring up a sale | Queued, or nothing | Normal, locally |
| Print the ticket | Often blocked | Normal |
| See real stock | Last known state | Current — it is the original |
| Open / close the till | Deferred | Normal |
| Check a customer’s slate | Unavailable | Normal — local by construction |
| Prepare a CHIFA batch | Deferred | Normal; transmission waits for the line |
A pharmacy with no line whatsoever can still be installed and licensed. Your reseller makes the three round trips for you, with a USB stick.
The reseller registers your officine with us and leaves with an `.officineid` file on the stick. It carries your pharmacy’s identifier — the one that must be the same on your machine and on ours.
On your machine the application reads the file, finishes the installation, and writes an `.officinereq` request back to the stick. No connection was needed.
The reseller brings the request back to us and hands you a signed `.officinelic` file. Your machine verifies it offline, against a public key compiled into the software. From there, the pharmacy runs.
An offline licence cannot renew itself: ask your reseller for the next one before the date shown in the application.
Yes, normally, with no change to how you work. The till, the stock, the ticket and the cash session are local. You will not notice a difference — that is the point.
That is a different problem: with no power, no software runs. What we guarantee is that the database is consistent when the power returns — sales confirmed before the cut are there, and the cash session reopens on the right amount.
Nominative data, never. It stays on the officine’s machine. What goes up, when there is a line, are nameless aggregates: quantities, amounts, stock movements, CHIFA batches. Loi 18-07 classes health data as sensitive, and we built the sync around that constraint rather than beside it.
Preparation does: you build your batches and bordereaux normally. The transmission itself goes through CHIFA_OFFICINE, which needs its own connection — as it does today. The difference is that nothing stops you working in the meantime.
Yes. One machine is the server — it holds the database — and the counters reach it over the local network. Neither needs the internet to talk to the other.
The software keeps working through the grace period shown in the application, then goes read-only. It is never locked: your registers and your exports stay reachable, whatever happens.
That is the test we suggest you run first, and the only one that really counts at the counter. Create your account, install, unplug, sell.