Skip to content
llms.txt

Testing with Mocks

Use our Mocked Vehicles UI to interact with mocked vehicles.

Before starting a rental, make sure your selected mock is in a clean idle state (doors closed, engine off, doors locked, immobilizer enabled):

Initial idle state in the Mocked Vehicles UI

To simulate a customer starting and completing a trip, first confirm your mock is in the idle state, then follow these steps after calling rental/start:

  1. Uncheck Immobilizer enabled
  2. Uncheck Doors Locked
  3. Check and then uncheck Open Doors: Front Left Open — this simulates the user entering the vehicle and prevents auto-cancellation of the rental
  4. Turn on the engine by checking engineOn
  5. Optionally update the vehicle’s GPS position to simulate driving
  6. Turn the engine off by unchecking engineOn

The rental/end endpoint validates all end rental criteria and reports any open criteria synchronously.

Once you receive an OK response from rental/end and an ENDING status from the customer status endpoint, re-check Immobilizer enabled and Doors Locked to emulate the vehicle locking securely:

Mock vehicle state after end rental request

After this step, the customer status endpoint transitions back to IDLE.