Case Study
Mototaxi App + API
Motorcycle taxi platform built by a team for a startup
- Type
- Mobile + API
- Team
- Team
Owned by the contracting startup — source code is private by contract.
The problem
The startup needed a two-sided product (driver and passenger) with real-time geolocation, integrated payments and reliable app-to-backend communication, even on unstable mobile networks.
Architecture and technical decisions
Mobile app in React Native + Expo, with Firebase login (native Google Sign-In), maps and route calculation with react-native-maps and Google Directions, and push notifications via Expo/Firebase. The app includes an internal wallet for payments: passengers can top up their balance by card or Pix, and drivers can redeem (withdraw) their earnings via Pix. The backend is a dedicated Fastify + TypeScript API: PostgreSQL via Prisma for persistence, Redis for caching, WebSocket for real-time ride tracking, payments and transfers via Mercado Pago, Swagger documentation and Sentry monitoring. Containerized deployment with Docker on Fly.io.
Design process
Overview of the wireframe board produced at the start of the project, before implementation. Click to enlarge.
Wireframe board produced at the start of the project to map the driver and passenger flows before implementation.
Challenges
Reliable real-time tracking
Mobile connections drop often. The WebSocket channel was built with automatic reconnection and position resending so the ride tracking is never lost.
Driver wallet payouts
The driver/platform payment split isn't handled directly by Mercado Pago. Instead, the received balance is held in the driver's internal wallet, and the redemption (withdrawal) is processed through payment platforms integrated via Pix, with asynchronous webhook validation before confirming the release of funds.
Consistent state on an unstable network
App events (accepting a ride, updating position) use idempotency on the backend to avoid duplicates when the app resends an action after losing connection.
Impact
Results
- •Working product built by a team, with app and backend integrated end to end.
- •The architecture sustained real-time tracking and payments in the startup's production environment.
- •App published and working on the App Store and Google Play.