OCPI 2.3.0 - Commands Module - Sender Interface (2.2.1)

Download OpenAPI specification:

The Sender Interface is typically implemented by market roles like the eMSP. It receives the asynchronous responses from the Charge Point via the CPO.

The URL structure is open for the Sender to define. The URL is provided to the Receiver by the Sender in the POST to the Receiver interface via the response_url field. Therefore OCPI does not define fixed URL variables.

The path shown here is a typical implementation pattern.

Schemas

CommandResultType

string <enum> (CommandResultType)
Enum Description
ACCEPTED

Command request accepted by the Charge Point.

CANCELED_RESERVATION

The Reservation has been canceled by the CPO.

EVSE_OCCUPIED

EVSE is currently occupied, another session is ongoing. Cannot start a new session.

EVSE_INOPERATIVE

EVSE is currently inoperative or faulted.

FAILED

Execution of the command failed at the Charge Point.

NOT_SUPPORTED

The requested command is not supported by this Charge Point, EVSE etc.

REJECTED

Command request rejected by the Charge Point.

TIMEOUT

Command request timeout, no response received from the Charge Point in a reasonable time.

UNKNOWN_RESERVATION

The Reservation in the requested command is not known by this Charge Point.

Result of the command that was sent to the Charge Point.

"ACCEPTED"

DisplayText

language
required
string = 2 characters

Language Code ISO 639-1.

text
required
string <= 512 characters

Text to be displayed to an end user. No markup, html etc. allowed.

{
  • "language": "st",
  • "text": "string"
}

CommandResult

result
required
string <enum> (CommandResultType)
Enum Description
ACCEPTED

Command request accepted by the Charge Point.

CANCELED_RESERVATION

The Reservation has been canceled by the CPO.

EVSE_OCCUPIED

EVSE is currently occupied, another session is ongoing. Cannot start a new session.

EVSE_INOPERATIVE

EVSE is currently inoperative or faulted.

FAILED

Execution of the command failed at the Charge Point.

NOT_SUPPORTED

The requested command is not supported by this Charge Point, EVSE etc.

REJECTED

Command request rejected by the Charge Point.

TIMEOUT

Command request timeout, no response received from the Charge Point in a reasonable time.

UNKNOWN_RESERVATION

The Reservation in the requested command is not known by this Charge Point.

Result of the command request as sent by the Charge Point to the CPO.

Array of objects (DisplayText)

Human-readable description of the reason (if one can be provided), multiple languages can be provided.

{
  • "result": "ACCEPTED",
  • "message": [
    ]
}

OCPIResponse

status_code
required
integer

OCPI status code, 1000 for success.

status_message
string

An optional status message which may help when debugging.

timestamp
required
string <date-time>

The time this message was generated.

data
any

Response data object or list of objects.

{
  • "status_code": 1000,
  • "status_message": "string",
  • "timestamp": "2019-08-24T14:15:22Z",
  • "data": null
}

Commands

Receive asynchronous command result

It is up to the implementation of the eMSP to determine what parameters are put in the URL. The eMSP sends a URL in the POST method body to the CPO. The CPO is required to use this URL for the asynchronous response by the Charge Point. It is advised to make this URL unique for every request to differentiate simultaneous commands, for example by adding a unique id as a URL segment.

No structure defined. This is open to the Sender to define, the URL is provided to the Receiver by the Sender in the POST to the Receiver interface. Therefor OCPI does not define variables.

Authorizations:
ocpiAuthorization
header Parameters
X-Request-ID
required
string

Every request SHALL contain a unique request ID, the response to this request SHALL contain the same ID. It is advised to use GUID/UUID as values.

X-Correlation-ID
required
string

Every request/response SHALL contain a unique correlation ID, every response to this request SHALL contain the same ID. It is advised to use GUID/UUID as values. When a Hub forwards a request to a party, the request SHALL contain the same X-Correlation-ID HTTP header (with the same value).

OCPI-from-country-code
string = 2 characters

'country code' of the connected party this message is sent from.

OCPI-from-party-id
string = 3 characters

'party id' of the connected party this message is sent from.

OCPI-to-country-code
string = 2 characters

'country code' of the connected party this message is to be sent to.

OCPI-to-party-id
string = 3 characters

'party id' of the connected party this message is to be sent to.

Request Body schema: application/json
required

Result of the command request, from the Charge Point.

result
required
string <enum> (CommandResultType)
Enum Description
ACCEPTED

Command request accepted by the Charge Point.

CANCELED_RESERVATION

The Reservation has been canceled by the CPO.

EVSE_OCCUPIED

EVSE is currently occupied, another session is ongoing. Cannot start a new session.

EVSE_INOPERATIVE

EVSE is currently inoperative or faulted.

FAILED

Execution of the command failed at the Charge Point.

NOT_SUPPORTED

The requested command is not supported by this Charge Point, EVSE etc.

REJECTED

Command request rejected by the Charge Point.

TIMEOUT

Command request timeout, no response received from the Charge Point in a reasonable time.

UNKNOWN_RESERVATION

The Reservation in the requested command is not known by this Charge Point.

Result of the command request as sent by the Charge Point to the CPO.

Array of objects (DisplayText)

Human-readable description of the reason (if one can be provided), multiple languages can be provided.

Responses

Request samples

Content type
application/json
{
  • "result": "ACCEPTED",
  • "message": [
    ]
}

Response samples

Content type
application/json
{
  • "status_code": 1000,
  • "status_message": "string",
  • "timestamp": "2019-08-24T14:15:22Z",
  • "data": null
}