How to Begin Charging
To begin charging, you first need to select a charging station connection. This can be done by fetching available charging stations through several API calls (How To Fetch Charging Stations). Choose a charging station connection and then verify via the availableCardsForChargingProcess API call as long as the user has an existing contract allowing them to begin charging using this connection.
Example request for availableCardsForChargingProcess:
query availableCardsForChargingProcess {
availableCardsForChargingProcess(
connectorId: "ad7adac5-1111-2345-abcs-cc1c3115bd12"
) {
id
tagId
number
label
expiryDate
type
}
}
Example response for availableCardsForChargingProcess:
{
"data": {
"availableCardsForChargingProcess": [
{
"id": "abc123",
"tagId": "026347BA",
"number": "abc123",
"label": "xyz789"
}
]
}
}
If there is a valid contract, this can now be used to begin charging via the selected connection. See the remoteStart API call. If no contract exists, the user may not yet have a contract (How To Create A Contract). Once charging has successfully begun, a RemoteStartResponse data object response will be received.
Example request to begin charging. You have to use the tagId from availableCardsForChargingProcess as the authorization identifier:
mutation remoteStart {
remoteStart(
authorization: {
identifier: "026347BA"
type: AUTO
},
connector: "ad7adac5-1111-2345-abcs-cc1c3115bd12"
) {
remoteStartResponse
}