The Platform

One data model. Four surfaces. Built to run real fleets.

FleetCommand is a single, multi-tenant operations system exposed through four surfaces — a web operations dashboard, a desktop power-user console, a Flutter driver app, and a 130+ endpoint REST API — backed by AWS Bedrock for AI and Mix Telematics for live GPS. This page is the architectural truth of how it's built and how data flows.

Tenancy
Multi-tenant by default
Region
AWS eu-west-1 production
AI
Claude Sonnet 4.6 + Haiku 4.5
Driver app
Flutter, 5 languages

Architecture

One data model, exposed through four surfaces.

Operations runs in NestJS on AWS Fargate, persisted in Postgres 16, with S3 for evidence (POD photos, signatures), Bedrock for AI, and Mix Telematics for live GPS. Every surface speaks the same REST and WebSocket API.

Web
Next.js
Desktop
Electron
Mobile
Flutter
API
REST + Webhooks
API Layer · NestJS · TypeScript
130+ endpoints · JWT + API key
/orders
/trips
/tracking
/pod
/warehouse
/ai
Postgres 16
RDS · multi-AZ ready
AWS Bedrock
Sonnet 4.6 · Haiku 4.5
Amazon S3
POD evidence · backups
Mix Telematics
GPS · 30 s polling
Webhooks
Per-tenant HMAC
Slack · Teams · Telegram
Alerts · per event
ERP
SAP · Oracle · custom

Multi-tenant from day one

Every query is scoped by organizationId. Per-tenant webhook signing keys, per-tenant RBAC, per-tenant default geofences and cross-dock sites. Single-tenant deployments are a config flag, not a fork.

Real-time, end to end

WebSocket fan-out broadcasts vehicle positions to web and mobile clients within 30 s of the GPS tick. Geofence evaluations and bay-arrival stamping happen server-side, not on the device.

Evidence, not promises

POD photos and signatures land directly in S3 with KMS-managed encryption. The Order, the Trip, the Document, and the OrderEvent are written in a single Prisma transaction.

Data flow

From an inbound order to a billable proof of delivery — six stages.

Every state transition is a row in the database. Every status change emits a TripEvent. Audit-grade by design — your AR team can defend any invoice three years later.

  1. 01
    Stage 1 of 6

    Order intake

    Drop an Excel, CSV, or PDF onto the web upload. AI extraction (Bedrock Haiku 4.5) maps columns, normalises dates, validates client and lane references, and flags missing data before it lands as Order rows. Orders enter VALIDATED state with a parent client and zone.

    OrderAI extractionVALIDATED
  2. 02
    Stage 2 of 6

    Allocation & dispatch

    The auto-allocator runs three explainable filters: contractual lane match (ContractualLane rows), vehicle availability (no active trip), and GPS proximity (closest available unit). It produces a Trip with explicit reasoning — every allocation is defendable in a Monday standup.

    TripVehicleDriver
  3. 03
    Stage 3 of 6

    Loading bay & dispatch

    Bay assignment matches truck size and time slot. Driver crosses the geofence (50 m radius), the LiveTelematicsWorker stamps an arrival event, the bay clerk releases the truck, the driver app advances to LOADING → LOADED_WAITING → DISPATCHED. Every transition is a TripEvent.

    BaySlotGeofenceTripEvent
  4. 04
    Stage 4 of 6

    On-route tracking

    Mix Telematics polls the truck every 30 s. Positions land in tracking.service, get fused with the driver phone GPS (gps-fusion.service handles disagreement and mock detection), broadcast over WebSocket to web + mobile, and evaluated against geofences for breach alerts.

    PositionGeofenceWebSocket
  5. 05
    Stage 5 of 6

    Proof of delivery

    Driver captures POD: 1–5 photos, recipient signature, geofence-validated GPS coordinates. Photos go to S3 directly, the Document row + OrderEvent + Order.status=DELIVERED are written in a single transaction. Bedrock OCR runs async to extract recipient and stamp metadata.

    PODS3OCR
  6. 06
    Stage 6 of 6

    Returns & offload

    If the delivery carries return goods (empty barrels, glass crates, claims), the trip parks in RETURNING after POD instead of COMPLETED. The driver stays on the trip in the app, dispatch keeps them unavailable for new allocation, and they confirm warehouse offload with one tap to release the vehicle.

    RETURNINGVehicle releaseTrip COMPLETED

The four surfaces

One platform, four places where work actually happens.

01 · Web

The Operations Command Center

Next.js 14 · React 18 · WebSocket · Tailwind

A single-pane control room for dispatchers and ops directors. Orders, dispatch board, dock management, TAT analytics, and tenant administration. Real-time vehicle map fed by WebSocket. Drag-and-drop reallocation. Geofence editor. Built for fleets that staff a 24/7 control room, not a spreadsheet.

  • Live dispatch board with drag-and-drop reallocation
  • Vehicle map with geofence overlays and breach alerts
  • TAT/KDTAT dashboards by site, lane, and driver
  • Multi-tenant administration with RBAC down to bay-clerk
  • Cross-dock site management with auto-slotting
  • POD history with photo evidence and OCR results
02 · Desktop

The Power-User Console

Electron · Vite · React · Native menubar

The desktop is for the dispatcher managing 100+ active trips with mouse-and-keyboard density that no browser can match. Native window chrome, OS notifications, multi-window layouts, multi-monitor support. Same data model, denser UI.

  • Multi-window mode (dispatch board + map + analytics)
  • OS-level notifications for breach alerts
  • Keyboard-first allocation flow
  • Offline draft for orders during connectivity blips
  • Available for Windows, macOS, Linux
03 · Mobile

The Driver App

Flutter · Android (iOS coming) · 5 locales

Designed for the daily reality of long-haul work, not for the App Store screenshot. Big buttons, low-light contrast, single-glance status. Offline-tolerant POD with auto-resync queue. Foreground-service GPS with battery-aware throttling. Mock-GPS spoofing detection running in production.

  • Five-language localisation, more on roadmap
  • Geofence-enforced POD with photo + signature + GPS
  • Mock-GPS spoofing detection (live in production)
  • Offline-tolerant POD queue with auto-resync
  • Foreground-service battery handling
  • Cross-dock and shunting handover flows
04 · API

The Developer Surface

REST · OpenAPI · 8 SDK languages · Webhooks

Everything the UIs do, your engineers can do. 130+ REST endpoints with JWT (interactive) and API key (machine-to-machine) dual auth. Per-tenant signed webhook subscriptions for downstream ERPs. SDKs in TypeScript, Python, Go, Java, C#, PHP, Ruby, Swift. Full OpenAPI spec for codegen.

  • 130+ REST endpoints under /api/v1
  • JWT (interactive) + API key (M2M) dual auth
  • Per-tenant webhook signing keys with HMAC-SHA256
  • OpenAPI 3 specification for codegen
  • SDKs in 8 languages
  • Rate limiting per IP and per tenant

AI layer · Built on AWS Bedrock

Four places where AI replaces the spreadsheet.

Every AI feature runs through AWS Bedrock inference profiles in eu-west-1, authenticated via the ECS task IAM role — no API keys to rotate, no third-party providers, no PII leaving your VPC.

Document ingestionClaude Haiku 4.5

Drop any Excel, CSV, or PDF — get structured orders.

Bedrock Haiku 4.5 reads the document, identifies the columns (orderNumber, client, address, commodity, weight, ETA), normalises dates to ISO-8601, resolves client references against your tenant directory, and flags missing or inconsistent rows before they reach dispatch. A typical 200-row Excel converts in under 8 seconds.

POD OCRClaude Haiku 4.5

Photo evidence becomes searchable structured data.

Every POD photo is sent to Bedrock for vision OCR. Recipient names, time stamps, and stamp/seal markings are extracted, indexed, and surfaced on the POD-history page. Three years later, your AR team can search for a specific recipient name without scrolling photos.

Predictive ETAHybrid · Sonnet 4.6 + heuristics

ETAs that factor traffic, weather, and your historicals.

Live GPS progress combined with rush-hour patterns, route history, weather data, and the driver's typical pace. Sonnet 4.6 reasons over the inputs to produce an ETA confidence band — not just a point estimate. The dispatch board shows orange when confidence drops below 80%.

Intelligence CenterClaude Sonnet 4.6

Natural-language fleet queries.

Type questions in plain English: "Which trips were delayed on the Mombasa corridor last week?" "Show me drivers with more than 3 geofence breaches this month." The Intelligence Center routes the query to read-only Postgres views via Sonnet 4.6 with strict tool-use guardrails.

Telematics & integrations

Live GPS. Live alerts. Live ERPs.

FleetCommand connects to the providers your fleet already uses, and pushes events into the systems your finance team already runs.

Webhook signing & security
GPS / Telematics
Mix Telematics
Geotab, Samsara, Webfleet on roadmap
Alerts
Slack · Microsoft Teams · Telegram · Discord
Email, SMS, push
ERP
SAP, Oracle, custom
Webhook + REST integration
Email & SMS
AWS SES · SNS · SendGrid
Per-tenant templates
Authentication
JWT · TOTP MFA · API keys
SAML / OIDC SSO on Enterprise
Storage
Amazon S3 (KMS-encrypted)
POD evidence · backups · exports

The stack

Boring choices, made deliberately.

Production fleets don't want exotic infrastructure — they want tools their next engineer can read on day one. Every choice below is documented and defendable.

Frontend
  • Next.js 14 · React 18
  • Tailwind CSS · Radix UI
  • WebSocket client (real-time)
Backend
  • NestJS · TypeScript
  • Prisma ORM · Postgres 16
  • Pino structured logging
Mobile
  • Flutter 3.9
  • Geolocator + foreground service
  • Firebase Cloud Messaging
Desktop
  • Electron + Vite
  • Native menubar + notifications
  • Windows · macOS · Linux
AI
  • AWS Bedrock
  • Claude Sonnet 4.6 (intelligence)
  • Claude Haiku 4.5 (OCR + ingestion)
Cloud
  • AWS eu-west-1 (Ireland)
  • ECS Fargate · ALB · RDS · S3
  • ACM · CloudWatch · Route 53
Telematics
  • Mix Telematics REST + webhooks
  • 30 s polling · live position fan-out
  • Geofence engine (server-side)
Security
  • TLS 1.2+ only at edge
  • AES-256 at rest · KMS-managed
  • Per-tenant webhook HMAC-SHA256

See the platform running on a real fleet.

30-minute walkthrough. We'll show you the dispatch board, the driver app, the API console, and the AI layer — all on a live tenant of similar size to yours.