Skip to content

Journey Creation Flow ​

The supply side. A driver declares a journey they are already making.

Steps ​

  1. Select a verified vehicle.
  2. Set origin — a place or a generalised commute hub.
  3. Set destination.
  4. Set departure time.
  5. Set available seats, capped by vehicle seating capacity.
  6. Optionally make it recurring.
  7. Submit.

Server processing ​

text
Create Journey          → status DRAFT
      ↓
Calculate Route         → geometry, distance, duration
      ↓
Run Eligibility         → driver, vehicle, account, seats
      ↓
Run Compliance          → policy decision
      ↓
Publish                 → PUBLISHED   (only on ALLOW)

The driver sees the outcome, including the reason for a block or a review. A journey that cannot be published explains itself at creation time rather than failing silently later.

Recurring ​

text
Recurring template  SUN–THU 07:30
        ↓
Materialised occurrences
        ↓
Concrete journey rows, each independently auditable

Every occurrence is a real journeys row referencing its template. A recurring template is not itself a journey — it produces journeys, and each one is individually recorded, verifiable and auditable.

Constraints ​

RuleReason
Vehicle must be verified and eligibleVEHICLE-001
Seats must not exceed seating capacityVEHICLE-004
Driver must be verified and eligibleIDENTITY-001, DRIVER-001
Departure must be in the futureJourney would be immediately EXPIRED
Route must be calculableDetour cannot be evaluated without it

Anti-pattern ​

text
PROHIBITED
Passenger requests a trip
        ↓
System creates a driver journey
        ↓
Driver transports passenger

There is no flow in which this happens. A journey always belongs to a driver and a vehicle and is created by that driver. This is enforced structurally, not by a rule that could be misconfigured.

KHAWI — same route, go together.