Two very different worlds
Diar Dzair is a full virtual banking platform: a React Native (Expo) app for end users, and a Spring Boot backend handling accounts, transactions, digital wallets and history streams. Those two halves are built by people thinking in completely different idioms — one side is optimizing for render performance and gesture feel on a phone, the other is optimizing for transactional correctness and throughput on a server. Getting them to agree on a contract is most of the job.
Contracts before code
We locked down REST API contracts before writing the screens that would consume them — request/response shapes, error codes, pagination conventions for transaction history — because the alternative is a frontend and backend evolving their own private dialects and reconciling them in painful late-stage debugging sessions. Spring Boot's typed DTOs made this easy to keep honest: if the contract changed, the backend wouldn't compile until every consumer was updated too.
Money movement forced a stricter version of this discipline. Every balance-changing endpoint is idempotent by design, keyed off a client-generated request ID, because a mobile network retry that silently double-submits a transfer is not an edge case in banking — it's a certainty you have to design for from day one, not patch in after the first incident.
What React Native actually needed from the backend
The mobile side cared about two things above all: predictable latency and rich filtering on transaction history without shipping the whole ledger to the phone. That pushed filtering and pagination logic server-side, with the Expo client staying a thin rendering layer over a well-shaped API rather than reimplementing business rules on-device — which also meant a rule change (say, a new fraud check) shipped instantly to every user without an app store release.
The payoff of getting the contract right early was that the two teams could work almost independently after the first two weeks — the backend team scaling out the wallet and fraud-prevention layer, the mobile team polishing gesture-level UX — without either side blocking the other.