Smart Charging Api v2.0
General Changes
We have added a newer version of the Smart Charging Api. To prevent issues & confusion, we have also added v2 to the other api's (Test Car & Virtual Power Plant). They don't contain any changes other then the version change in the route. The version 1 of these api's will become deprecated once we release a version with breaking changes. So v1 of those api's is not deprecated, and will not be removed soon. Version 1 of the Smart Charging Api will be marked as deprecated after we move out of the beta phase and will be removed in 6 months.
Paging
In places where we thought it would be useful, we added paging. They all follow the same pattern. You use the query parameters pageSize
and pageIndex
to determine the size of your pages & what page you are on. The page size is in limited to 100 items. Items are ordered from new to old. So for example GET /api/v2/charging-locations?pageSize=10&pageIndex=1
will return the the 10 newest charging locations. As in the example below.
{
"pageIndex": 1,
"pageSize": 100,
"totalPages": 1,
"totalCount": 1,
"items": [
{
"id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"userId": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"coordinates": {
"latitude": 0,
"longitude": 0
},
"address": {
"street": "string",
"postalCode": "string",
"houseNumber": "1A",
"city": "string",
"region": "string",
"country": "NL",
"area": "string"
},
"createdAt": "2023-12-19T13:26:55.109Z",
"updatedAt": "2023-12-19T13:26:55.109Z"
}
]
}
Dates & times
We have updated the dateformat for all responses returning a datetime. Before there would be all kinds of formats. We have update them to use a single format: yyyy-MM-ddTHH:mm:ss.fffZ
e.g. 2023-10-31T09:20:46.123Z
We have also adjusted the query parameters of times. For example in GET /api/v2/sessions
the startTimeFrom
and other time related parameters use the same more readable format.
Enums and responses
To allow for additions & improvements without breaking the api contract, we are making some changes the the enums on responses. We are changing them to strings. They will still have the same options in the responses, but it should allow us to add additional values without breaking the contract.
Please be aware of this when adjusting your code for version 2. Your current code will probably still work, but once we add another option, it could mean that the response cannot be parsed anymore.
What's New
PUT
/users/{userId}/charging-locations/{chargingLocationId}/utility-contracts
PUT
/users/{userId}/charging-locations/{chargingLocationId}/utility-contractsReplacing
PUT
/users/{userId}/charging-locations/{chargingLocationId}/energy-supplier
POST
/users/{userId}/charging-locations/{chargingLocationId}/utility-contracts
POST
/users/{userId}/charging-locations/{chargingLocationId}/utility-contractsReplacing
POST
/users/{userId}/charging-locations/{chargingLocationId}/energy-supplier
DELETE
/users/{userId}/charging-locations/{chargingLocationId}/utility-contracts
DELETE
/users/{userId}/charging-locations/{chargingLocationId}/utility-contractsReplacing
DELETE
/users/{userId}/charging-locations/{chargingLocationId}/energy-supplier
GET
/users/{userId}/messages
GET
/users/{userId}/messagesList messages for a user in pages
What's Deleted
PUT
/users/{userId}/charging-locations/{chargingLocationId}/energy-supplier
PUT
/users/{userId}/charging-locations/{chargingLocationId}/energy-supplierReplaced by
PUT
/users/{userId}/charging-locations/{chargingLocationId}/utility-contracts
POST
/users/{userId}/charging-locations/{chargingLocationId}/energy-supplier
POST
/users/{userId}/charging-locations/{chargingLocationId}/energy-supplierReplaced by
POST
/users/{userId}/charging-locations/{chargingLocationId}/utility-contracts
DELETE
/users/{userId}/charging-locations/{chargingLocationId}/energy-supplier
DELETE
/users/{userId}/charging-locations/{chargingLocationId}/energy-supplierReplaced by
DELETE
/users/{userId}/charging-locations/{chargingLocationId}/utility-contracts
POST
/users/{userId}/charging-locations/{chargingLocationId}/chargers/start-connect-session
POST
/users/{userId}/charging-locations/{chargingLocationId}/chargers/start-connect-sessionConnect a charger
GET
/users/{userId}/messages/active
GET
/users/{userId}/messages/activeList active messages for a user
UseGET
/users/{userId}/messages?includeDismissed=false for the same behavior. Endpoint now uses paging.
POST
/users/{userId}/vehicles/{vehicleId}/session-settings
POST
/users/{userId}/vehicles/{vehicleId}/session-settingsUpdate the settings for an active session by vehicleId
You can use the/users/{userId}/sessions/{sessionId}/session-settings
instead, since they are related to a session, not a vehicle.
GET
/users/{userId}/vehicles/{vehicleId}/session-settings/active
GET
/users/{userId}/vehicles/{vehicleId}/session-settings/activeRetrieve the settings for an active session by vehicleId
You can use the/users/{userId}/sessions/{sessionId}/session-settings/active
instead, since they are related to a session, not a vehicle.
POST
/users/{userId}/vehicles/start-connect-session
POST
/users/{userId}/vehicles/start-connect-sessionSelect and connect a vehicle
What's Changed
GET
/charging-locations
GET
/charging-locationsList all charging locations of a tenant in pages
Parameters:
Added: createdFrom
in query
Added: createdTo
in query
Added: pageSize
in query
Added: pageIndex
in query
Return Type:
Changed response : 200 OK
Success
- Changed content type :
application/json
- Changed from
array
toobject
with an array of charging-locations in theitems
property.
- Changed from
GET
/vehicles
GET
/vehiclesList all vehicles of a tenant in pages
Parameters:
Added: createdFrom
in query
Added: createdTo
in query
Added: pageSize
in query
Added: pageIndex
in query
Return Type:
Changed response : 200 OK
Success
-
Changed content type :
application/json
-
Changed from
array
toobject
with an array of vehicles in theitems
property.-
Changed property
capabilities
(array)Changed items (string):
Removed enum values:
chargeState
stateOfCharge
charge
startStopDischarging
geoLocation
desiredStateOfCharge
pairing
departureTimes
pullTelemetry
pushTelemetry
geoFencing
startStopCharging
-
-
GET
/sessions
GET
/sessionsList all sessions of a tenant in pages
Parameters:
Added: pageSize
in query
The amount of entities returned in the list. Optional parameter, defaults to 20.
Added: pageIndex
in query
The page that should be loaded. Optional parameter, defaults to 1
Changed: startTimeFrom
in query
Beginning of date/time range for session start in UTC in date-time iso 8601 format.
Changed: startTimeTo
in query
End of date/time range for session start in UTC in date-time iso 8601 format.
Changed: endTimeFrom
in query
Beginning of date/time range for session end in UTC in date-time iso 8601 format.
Changed: endTimeTo
in query
End of date/time range for session end in UTC in date-time iso 8601 format.
Return Type:
Changed response : 200 OK
Success
-
Changed from
array
toobject
with an array of sessions in theitems
property.-
Changes to session object
-
Changed property
status
(string)The status of the session. Possible values: Active, Complete, ForceEnded
Removed enum values:
unknown
active
complete
forceEnded
- Changed property
calibrationState
(string)The calibration state of the session. Has value only for active session. Possible values: NoSession, NotStarted, InProgress, Complete
-
-
GET
/supported-car-models
GET
/supported-car-modelsReturn Type:
Changed response : 200 OK
Success
-
Changed content type :
application/json
Changed items (object):
-
Changed property
capabilities
(array)Changed items (string):
Removed enum values:
chargeState
stateOfCharge
charge
startStopDischarging
geoLocation
desiredStateOfCharge
pairing
departureTimes
pullTelemetry
pushTelemetry
geoFencing
startStopCharging
-
GET
/users/{userId}/chargers
GET
/users/{userId}/chargersReturn Type:
Changed response : 200 OK
Success
-
Changed content type :
application/json
Changed items (object):
-
Changed property
chargerState
(object)State of the charger
-
Changed property
chargeState
(string)The charge state of the charger at the indicated time. Possible values: Complete, Charging, Disconnected, Stopped
Removed enum values:
unknown
complete
charging
disconnected
stopped
-
-
GET
/users/{userId}/charging-locations/{chargingLocationId}/chargers
GET
/users/{userId}/charging-locations/{chargingLocationId}/chargersReturn Type:
Changed response : 200 OK
Success
-
Changed content type :
application/json
Changed items (object):
-
Changed property
chargerState
(object)State of the charger
-
Changed property
chargeState
(string)The charge state of the charger at the indicated time. Possible values: Complete, Charging, Disconnected, Stopped
Removed enum values:
unknown
complete
charging
disconnected
stopped
-
-
GET
/users/{userId}/charging-locations/{chargingLocationId}/chargers/{chargerId}
GET
/users/{userId}/charging-locations/{chargingLocationId}/chargers/{chargerId}Return Type:
Changed response : 200 OK
Success
-
Changed content type :
application/json
-
Changed property
chargerState
(object)State of the charger
-
Changed property
chargeState
(string)The charge state of the charger at the indicated time. Possible values: Complete, Charging, Disconnected, Stopped
Removed enum values:
unknown
complete
charging
disconnected
stopped
-
-
GET
/users/{userId}/charging-locations/{chargingLocationId}/chargers/{chargerId}/state
GET
/users/{userId}/charging-locations/{chargingLocationId}/chargers/{chargerId}/stateReturn Type:
Changed response : 200 OK
Success
-
Changed content type :
application/json
-
Changed property
chargeState
(string)The charge state of the charger at the indicated time. Possible values: Complete, Charging, Disconnected, Stopped
Removed enum values:
unknown
complete
charging
disconnected
stopped
-
GET
/users/{userId}/charging-locations/{chargingLocationId}/dynamic-tariffs
GET
/users/{userId}/charging-locations/{chargingLocationId}/dynamic-tariffsReturn Type:
Changed response : 200 OK
Success
-
Changed content type :
application/json
Changed items (object):
-
Changed property
dataType
(string)Type of data. Values are: Actual, Forecast
Removed enum values:
actual
forecast
-
GET
/users/{userId}/charging-locations/{chargingLocationId}/solar-energy
GET
/users/{userId}/charging-locations/{chargingLocationId}/solar-energyParameters:
Changed: startTime
in query
Time the interval started in UTC in date-time iso 8601 format.
Changed: endTime
in query
Time the interval finished in UTC in date-time iso 8601 format.
GET
/users/{userId}/financials
GET
/users/{userId}/financialsParameters:
Changed: startTimeFrom
in query
Beginning of date/time range for session startin UTC in date-time iso 8601 format.
Changed: startTimeTo
in query
End of date/time range for session start in UTC in date-time iso 8601 format.
Changed: endTimeFrom
in query
Beginning of date/time range for session end in UTC in date-time iso 8601 format.
Changed: endTimeTo
in query
End of date/time range for session end in UTC in date-time iso 8601 format.
GET
/users/{userId}/messages/{messageId}
GET
/users/{userId}/messages/{messageId}Return Type:
Changed response : 200 OK
Success
-
Changed content type :
application/json
-
Changed property
type
(string)The message Type
Removed enum values:
startSession
endSession
invalidCredentials
carNotFound
carNotReachable
zeInteractiveToBeActivated
zeInteractiveCannotBeActivated
zeInteractiveExpiresSoon
readyForPairing
sessionImpossible
checkCarActivation
receivedNoPower
geoLocationDisabled
audiNotPaired
audiPairingNotComplete
invalidUtilityContract
reconnectUtilityContract
invalidCredentialsBanner
myRenaultAccessRevoked
audiRemoteAccessDisabled
audiRemoteAccessDisabledBanner
-
Changed property
notificationType
(string)The type of the notification. Possible values: PushNotification, Email, SMS, Banner
Removed enum values:
pushNotification
email
sms
banner
-
PATCH
/users/{userId}/messages/{messageId}
PATCH
/users/{userId}/messages/{messageId}Return Type:
Changed response : 200 OK
Success
-
Changed content type :
application/json
-
Changed property
type
(string)The message Type
Removed enum values:
startSession
endSession
invalidCredentials
carNotFound
carNotReachable
zeInteractiveToBeActivated
zeInteractiveCannotBeActivated
zeInteractiveExpiresSoon
readyForPairing
sessionImpossible
checkCarActivation
receivedNoPower
geoLocationDisabled
audiNotPaired
audiPairingNotComplete
invalidUtilityContract
reconnectUtilityContract
invalidCredentialsBanner
myRenaultAccessRevoked
audiRemoteAccessDisabled
audiRemoteAccessDisabledBanner
-
Changed property
notificationType
(string)The type of the notification. Possible values: PushNotification, Email, SMS, Banner
Removed enum values:
pushNotification
email
sms
banner
-
GET
/users/{userId}/sessions
GET
/users/{userId}/sessionsList all sessions of a user in pages
Parameters:
Added: pageSize
in query
The amount of entities returned in the list. Optional parameter, defaults to 20.
Added: pageIndex
in query
The page that should be loaded. Optional parameter, defaults to 1
Changed: startTimeFrom
in query
Beginning of date/time range for session start in UTC in date-time iso 8601 format.
Changed: startTimeTo
in query
End of date/time range for session start in UTC in date-time iso 8601 format.
Changed: endTimeFrom
in query
Beginning of date/time range for session end in UTC in date-time iso 8601 format.
Changed: endTimeTo
in query
End of date/time range for session end in UTC in date-time iso 8601 format.
Return Type:
Changed response : 200 OK
Success
-
Changed content type :
application/json
Changed fromarray
toobject
with an array of sessions in theitems
property.-
Changes to session object
-
Changed property
status
(string)The status of the session. Possible values: Active, Complete, ForceEnded
Removed enum values:
unknown
active
complete
forceEnded
- Changed property
calibrationState
(string)The calibration state of the session. Has value only for active session. Possible values: NoSession, NotStarted, InProgress, Complete
-
-
GET
/users/{userId}/sessions/{sessionId}
GET
/users/{userId}/sessions/{sessionId}Return Type:
Changed response : 200 OK
Success
-
Changed content type :
application/json
-
Changed property
status
(string)The status of the session. Possible values: Active, Complete, ForceEnded
Removed enum values:
unknown
active
complete
forceEnded
-
Changed property
calibrationState
(string)The calibration state of the session. Has value only for active session. Possible values: NoSession, NotStarted, InProgress, Complete
-
Deleted property
chargeSpeed
(number)
The charge speed during the session in kw
-
GET
/users/{userId}/sessions/{sessionId}/tariffs
GET
/users/{userId}/sessions/{sessionId}/tariffsReturn Type:
Changed response : 200 OK
Success
-
Changed content type :
application/json
Changed items (object):
-
Changed property
tariffType
(string)The tariff type. Values are: Standard, Peak, OffPeak, SuperOffPeak, Dynamic
Removed enum values:
standard
peak
offPeak
superOffPeak
dynamic
-
GET
/users/{userId}/vehicles
GET
/users/{userId}/vehiclesReturn Type:
Changed response : 200 OK
Success
-
Changed content type :
application/json
Changed items (object):
-
Changed property
capabilities
(array)Changed items (string):
Removed enum values:
chargeState
stateOfCharge
charge
startStopDischarging
geoLocation
desiredStateOfCharge
pairing
departureTimes
pullTelemetry
pushTelemetry
geoFencing
startStopCharging
-
Changed property
chargeState
(object)-
Changed property
chargeState
(string)Charge state of the vehicle. Possible values: Complete, Charging, Disconnected, Stopped
Removed enum values:
unknown
complete
charging
disconnected
stopped
-
-
GET
/users/{userId}/vehicles/{vehicleId}
GET
/users/{userId}/vehicles/{vehicleId}Return Type:
Changed response : 200 OK
Success
-
Changed content type :
application/json
-
Changed property
capabilities
(array)Changed items (string):
Removed enum values:
chargeState
stateOfCharge
charge
startStopDischarging
geoLocation
desiredStateOfCharge
pairing
departureTimes
pullTelemetry
pushTelemetry
geoFencing
startStopCharging
-
Changed property
chargeState
(object)-
Changed property
chargeState
(string)Charge state of the vehicle. Possible values: Complete, Charging, Disconnected, Stopped
Removed enum values:
unknown
complete
charging
disconnected
stopped
-
-
GET
/users/{userId}/vehicles/{vehicleId}/sessions/last
GET
/users/{userId}/vehicles/{vehicleId}/sessions/lastReturn Type:
Changed response : 200 OK
Success
-
Changed content type :
application/json
-
Changed property
status
(string)The status of the session. Possible values: Active, Complete, ForceEnded
Removed enum values:
unknown
active
complete
forceEnded
-
Changed property
calibrationState
(string)The calibration state of the session. Has value only for active session. Possible values: NoSession, NotStarted, InProgress, Complete
-
Deleted property
chargeSpeed
(number)
The charge speed during the session in kw
-
GET
/users/{userId}/vehicles/{vehicleId}/state
GET
/users/{userId}/vehicles/{vehicleId}/stateReturn Type:
Changed response : 200 OK
Success
-
Changed content type :
application/json
-
Changed property
chargeState
(string)Charge state of the vehicle. Possible values: Complete, Charging, Disconnected, Stopped
Removed enum values:
unknown
complete
charging
disconnected
stopped
-
GET
/users/{userId}/charging-locations/{chargingLocationId}/tariffs
GET
/users/{userId}/charging-locations/{chargingLocationId}/tariffsReturn Type:
Changed response : 200 OK
Success
-
Changed content type :
application/json
-
Changed property
tariffs
(array)Tariffs of the charging location
Changed items (object):
-
Changed property
type
(string)Type of the tariff. Values are: Standard, Peak, OffPeak, SuperOffPeak, Dynamic
Removed enum values:
standard
peak
offPeak
superOffPeak
dynamic
-
-
PUT
/users/{userId}/charging-locations/{chargingLocationId}/tariffs
PUT
/users/{userId}/charging-locations/{chargingLocationId}/tariffsReturn Type:
Changed response : 200 OK
Success
-
Changed content type :
application/json
-
Changed property
tariffs
(array)Tariffs of the charging location
Changed items (object):
-
Changed property
type
(string)Type of the tariff. Values are: Standard, Peak, OffPeak, SuperOffPeak, Dynamic
Removed enum values:
standard
peak
offPeak
superOffPeak
dynamic
-
-
POST
/users/{userId}/charging-locations/{chargingLocationId}/tariffs
POST
/users/{userId}/charging-locations/{chargingLocationId}/tariffsCreate tariff settings v2
Return Type:
Changed response : 200 OK
Success
-
Changed content type :
application/json
-
Changed property
tariffs
(array)Tariffs of the charging location
Changed items (object):
-
Changed property
type
(string)Type of the tariff. Values are: Standard, Peak, OffPeak, SuperOffPeak, Dynamic
Removed enum values:
standard
peak
offPeak
superOffPeak
dynamic
-
-
GET
/users
GET
/usersList all users in pages
Parameters:
Added: createdFrom
in query
Added: createdTo
in query
Added: pageSize
in query
Added: pageIndex
in query
Return Type:
Changed response : 200 OK
Success
- Changed content type :
application/json