Charger Control API¶
The Charger Control API allows you to perform the following functions.
- Get list of power groups from external systems.
- Update the external power limit of a charger group from external systems.
- Prioritize and allocate the power sharing across different loads dynamically.
Prerequisites¶
Request for the Charger Group ID list from Siemens Regional Support.
API Usage¶
See Token Management API for more information on how to create and use the access token.
External Power Limit¶
Prepare Request Body¶
To prepare a request body, perform the following steps.
- Set charger group GUID to the request path parameter
chargerGroupId
. - Set
Content-Type
header asapplication/json
and use the parameters schemaExternalPowerLimit
as described in Charger Control API Reference.
Example Request¶
Note
Use the server URL applicable to your region. See API Reference for available server URLs applicable to your region.
export ACCESS_TOKEN = <YOUR_ACCESS_TOKEN>
export SOURCE = <YOUR_SOURCE>
export EXTERNALPOWERRATEUNIT = <YOUR_EXTERNALPOWERRATEUNIT>
export FROMDATE = <YOUR_FROMDATE> # Example "2022-11-22T19:54:10.143Z"
export TODATE = <YOUR_TODATE> # Example "2022-11-23T22:18:09.797Z"
export EXTERNALPOWERLIMIT = <YOUR_EXTERNALPOWERLIMIT>
export CHARGER_GROUP_ID = <YOUR_CHARGER_GROUP_ID>
curl --location --request PUT 'https://api.eu.depot.emobility.io/v1/chargerControl/chargerGroups/$CHARGER_GROUP_ID/externalPowerLimits' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--header 'Authorization: Bearer $ACCESS_TOKEN' \
--data-raw '{
"source": "$SOURCE",
"externalPowerRateUnit": "$EXTERNALPOWERRATEUNIT",
"dynamicPowerLimit": [
{
"fromDate": "$FROMDATE",
"toDate": "$TODATE",
"externalPowerLimit": $EXTERNALPOWERLIMIT
}
]
}'
Response Body¶
Successful response returns 200 HTTP status code with response body as Success
schema. For more information, see Charger Control API Reference.
Example Response¶
{
"message": "External power limit saved successfully."
}
Power Groups¶
Prepare Request Body¶
To prepare a request body, perform the following steps.
- Set
Content-Type
header asapplication/json
as described in Charger Control API Reference.
Example Request¶
Note
Use the server URL applicable to your region. See API Reference for available server URLs applicable to your region.
export ACCESS_TOKEN = <YOUR_ACCESS_TOKEN>
curl --location --request GET 'https://api.eu.depot.emobility.io/v1/chargerGroup/powergroups' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer $ACCESS_TOKEN'
Response Body¶
Successful response returns 200 HTTP status code with response body as PowerGroup
schema. For more information, see Charger Control API Reference.
Example Response¶
[
{
"PowerGroupID": 0123,
"CommonName": "xyz",
"Algorithm": "FO",
"DefaultMaxPower": 200000,
"DefaultPrice": 0,
"CreatedOn": "2022-05-13T03:00:35.830992",
"CreatedBy": "john@example.com",
"ModifiedOn": "2023-06-05T11:59:51",
"ModifiedBy": "henry@example.com",
"FullUpdateRequired": true,
"ChargeStrategy": null,
"IsOptimalChargingActive": false,
"LastAlgorithmTriggeredTime": null,
"LastAlgorithmRetriedTime": null,
"PowerElementEntries": [
{
"DefaultProfileStatus": "Pending",
"Type": "Charger",
"PowerElementID": "abc123",
"DefaultProfileRetryCount": 0,
"SendClearProfile": false
},
{
"DefaultProfileStatus": "Rejected",
"Type": "Charger",
"PowerElementID": "qwerty",
"DefaultProfileRetryCount": 3,
"SendClearProfile": false
}
],
"SetLimitsRetryNecessary": false,
"LastPowerLimits": {
"ClientID": "PQRS",
"GUID": "f29d2af3-6633-0000-920d-eb51b21f0000",
"Result": [
{
"ChargerID": "xyz",
"Connectors": [
{
"ChargingZone": "charging",
"ConnectorID": 1,
"ETC": 0,
"PowerSetPoint": 12000
}
]
}
]
},
"PowerSchedulingEntries": [],
"UserDefaultPowerProfile": "ChargerMaxPower",
"PriceSchedulingEntries": [],
"ID": "025052e4-1111-2222-abd4-22a01f1123456"
}
]