Send a Session update
OCPI 2.2.1 and 2.3.0
Read this step for OCPI 2.1.1In OCPI 2.2.1 and 2.3.0 the CPO sends every change to a Session it already pushed by calling PATCH on the eMSP's Sessions endpoint. Only the fields that need to be updated have to be present, and any field it does not specify is considered unchanged. Every PATCH request SHALL contain last_updated.
Sandbox run · OCPI 2.2.1
Run this exchange in the sandbox
Sandbox fault · OCPI 2.2.1
See one rule fail in the sandbox
The eMSP returns a Session without its id
The sandbox eMSP can answer one Session GET with the id removed. The check sessions-get-002 sends that GET and reads the answer. Read the Session back as it is, then remove the id.
The CPO sends a PATCH without last_updated
The run pushes a Session to the sandbox eMSP, then sends one PATCH that carries kwh and no last_updated. The rule binds the sender, so the finding is the sender's. How the eMSP answers is shown as an observation, not a verdict.
When a PATCH omits charging_periods or sends an empty list, the eMSP SHALL keep its existing charging periods.
Sessions cannot be deleted. The final status of a Session is COMPLETED.
What OCPI 2.2.1 defines for this lesson
Modules in this version
Advertised sender and receiver interfaces
An endpoint declares how another platform can pull or push data. Credentials uses the same interface for both roles.
The header token is encoded
The request header carries an encoded token; the Credentials body still carries the raw token.
Billing records name the Token owner
A charge record names the country and company that own the driver's Token.