Skip to main content
This guide follows one session from the moment a driver plugs in to the final bill. Drivers start and stop their sessions in the ChargeExpress app or at the charger; every session paid from your fleet wallet is visible through the API and its webhooks. You need a key with fleet:read (read charge points and sessions), and a webhook endpoint subscribed to the session.* events.
Build this flow with a sandbox key (cxk_test_…) first. In the sandbox, you run sessions on four simulated chargers from Developers → Sandbox in the fleet portal. They run on a simulated meter at 60× real time, finish within about two minutes, and every response and webhook below has the same shape.

1. Find charge points

GET /charge_points lists the public ChargeExpress network, for example to show your drivers where they can charge, with whether each charger is connected right now and the status of each connector.
Response
In the sandbox, the list holds only the simulated chargers, each with simulated: true. A charger is usable when it has online: true and status: "Operative", and a connector whose status is Available (or Preparing, once a cable is plugged in). Connector statuses are the charger’s OCPP 1.6 statuses.

2. Follow sessions with webhooks

Webhooks can arrive out of order or more than once. Dedupe on the event id, and if you only want the latest state, compare data.object with what you have or fetch GET /sessions/{sessionId}. See Webhooks. Session events fire for every session paid from the fleet wallet, whether the driver started it in the app or at the charger.

3. Read a session while it runs

GET /sessions/{sessionId} returns the session as it is now. While it is charging, energy_kwh and cost grow with each meter reading and ended_at is null:
Response
Sessions end when the driver stops them in the app or unplugs, or when they reach their budget. budget_kwh is the most the session can use: the smallest of any fleet or driver limit and what the wallet can cover.

4. Read the result

session.completed carries the settled session:
session.completed data.object
Prepaid energy comes out of the wallet’s balance_kwh. If on_credit is above zero, a usage invoice is raised for that part. Its id is the session id (GET /invoices/usage/48213), and invoice.created fires when the invoice number is assigned. Pay it as described in Funding flow. To list your fleet’s sessions, for example to reconcile a month, use GET /sessions with status, driver_id, vehicle_id, charge_point_id, from and to filters.