Pular para o conteúdo principal

Commands

VoltBras is the Receiver of Commands. Send POST /2.2.1/commands/{command}. VoltBras answers at once whether it accepts the command, then sends the charger's result to your response_url.

CommandAnswer
START_SESSION, STOP_SESSIONSee below.
RESERVE_NOW, CANCEL_RESERVATION, UNLOCK_CONNECTORNOT_SUPPORTED.

Every answer has timeout: 60: if no result arrives in 60 seconds, assume it will not come.

response_url must be an absolute https URL without user or password, of up to 255 characters. Otherwise the request gets status 2001.

START_SESSION​

Send location_id, evse_uid, token, and response_url. connector_id and authorization_reference are optional. The token's country_code and party_id must be one of your eMSP roles.

{
"response_url": "https://emsp.example.com/ocpi/2.2.1/commands/START_SESSION/6f1b",
"token": {
"country_code": "NL",
"party_id": "EMS",
"uid": "b5e1f0c2-44aa-4c11-9d7e-1f2a3b4c5d6e",
"type": "APP_USER",
"contract_id": "NL-EMS-C12345678-X"
},
"location_id": "3f1c9a52-7b1e-4d0a-9c35-2a6e8f10b7d4",
"evse_uid": "96f9a7dc-ee9f-5f48-825e-7bfd1fa9b596",
"connector_id": "1",
"authorization_reference": "auth-20261110-0001"
}

The answer when the command is accepted:

{
"data": {
"result": "ACCEPTED",
"timeout": 60
},
"status_code": 1000,
"timestamp": "2026-11-10T14:00:01.000Z"
}

The answer for an unknown Location:

{
"data": {
"result": "REJECTED",
"timeout": 60
},
"status_code": 2003,
"status_message": "Unknown Location",
"timestamp": "2026-11-10T14:00:01.000Z"
}

All the answers:

SituationStatusresult
Accepted1000ACCEPTED
No evse_uid1000NOT_SUPPORTED
connector_id without evse_uid, or an invalid body2001none
Unknown Location, or all its EVSEs are REMOVED2003REJECTED
Unknown or REMOVED EVSE, or another connector1000REJECTED
EVSE is OUTOFORDER, or has no Tariff or no evse_id1000REJECTED
The token is not from one of your eMSP roles1000REJECTED

These answers use HTTP 200.

CommandResultMeaning
ACCEPTEDThe charger accepted the start. Charging begins when the cable is connected.
EVSE_OCCUPIEDThe connector is in use, or another start is in progress on it.
EVSE_INOPERATIVEThe connector is unavailable or faulted.
REJECTEDThe charger refused, or the connector is reserved.
TIMEOUTNo answer in time.
FAILEDThe charger is disconnected, or the start failed.

A start can still lead to a charge after TIMEOUT or FAILED. If it does, you receive its Session and CDR. Use the token and your authorization_reference to match them.

STOP_SESSION​

{
"response_url": "https://emsp.example.com/ocpi/2.2.1/commands/STOP_SESSION/91c4",
"session_id": "8c2f4b6e-1d3a-4f57-a9b0-6e7d5c4b3a21"
}

Send session_id and response_url. Only sessions started through OCPI can be stopped, and only by the platform that started them.

Situationresult
A session you startedACCEPTED
A session another platform startedREJECTED
Unknown sessionUNKNOWN_SESSION
CommandResultMeaning
ACCEPTEDThe charger accepted the stop, or the session is already stopping or finished.
REJECTEDThe charger refused, or the charge has not started.
TIMEOUTNo answer in time.
FAILEDThe charger is disconnected, or the stop failed.

The result​

POST https://emsp.example.com/ocpi/2.2.1/commands/START_SESSION/6f1b HTTP/1.1
OCPI-from-country-code: BR
OCPI-from-party-id: EXA
OCPI-to-country-code: NL
OCPI-to-party-id: EMS
{
"result": "ACCEPTED"
}

VoltBras sends one POST with the CommandResult to your response_url, using your token. It is not repeated.