Sharing session data with partners

A CPO or an eMSP on Road can give a partner its sessions, and optionally their CDRs, through a data sharing permission. The partner receives them over OCPI even though it did not authorise them, which lets a smart charging provider follow the sessions on the EVSEs it manages, or a navigation provider see how a network is used. The eMSP that issued the card still receives each session in full and bills it as usual.

Who can share with whom

The party that owns the sessions grants the permission, and both parties need an active agreement on Road.

OwnerSessions it sharesPartners it can grant to
CPOSessions on its LocationseMSP, payment terminal provider (PTP), national access point (NAP), navigation service provider (NSP), smart charging service provider (SCSP)
eMSPSessions on its own cards, wherever they chargeCPO, smart charging service provider (SCSP)

A permission to receive sessions has the kind OBSERVE_SESSIONS.

What a permission sets

The owner decides everything about what the partner receives. The field names are those of Road's data sharing endpoints.

SettingFieldOptions
ScopescopeFor a CPO, all its Locations (all), or a list of its Locations and single EVSEs (entries). A list can be extended or trimmed later; an all-Locations scope cannot be edited. An eMSP uses all, which covers every session on its cards.
Driver identityidentity_policyPSEUDONYMISED, the default, replaces each card with a code. FULL shows the card as its eMSP sent it. PARTY_ONLY shows only which eMSP issued the card.
Costscost_sharedShared or left out.
CDRsinclude_cdrsIncluded or left out.

With PSEUDONYMISED, the code for a card stays the same for every session under one permission, so the partner can tell that two sessions used the same card without seeing it. The same card gets a different code under another permission.

How shared data arrives

Road pushes shared data to the partner, in the same way it sends sessions to the card's eMSP:

  • Each session goes to the partner's OCPI Sessions endpoint when it is created and on every update.
  • Each CDR goes to the partner's CDRs endpoint, when the permission includes CDRs.
  • Requests to Road's own Sessions endpoint keep returning only sessions on the partner's own cards. Shared sessions arrive by push.
  • The partner's connection must be live and expose the Sessions endpoint, and the CDRs endpoint when CDRs are included. Road does not push to a connection that lacks them.
  • Partners on OCPI 2.1.1 receive pushes too. Creating and managing permissions through the API needs OCPI 2.2.1 or 2.3.0.

A shared CDR never contains signed meter data, because it carries the card's identity. Only the card's eMSP receives it.

Setting it up

  1. Agree the sharing with your partner. Both parties need an active agreement on Road, which the roaming team can set up at [email protected].
  2. Create the permission. A CPO calls the data sharing endpoints on Road's eMSP interface and an eMSP on Road's CPO interface. The counterparties endpoint lists the partners you can grant to. You can also ask the roaming team to set the permission up for you.
  3. Make sure the partner exposes its Sessions endpoint, and its CDRs endpoint when CDRs are included.

The partner does not have to accept a permission, and Road does not notify it, so tell your partner when you grant one.

The same endpoints list permissions, change their scope and revoke them. They are described in the OCPI 2.2.1 and OCPI 2.3.0 references, marked with a ROAD badge.