Set Charging Profile
curl --request POST \
--url https://app.plugchoice.com/api/v3/chargers/{charger}/actions/charging-profile \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"connector_id": 123,
"charging_profile": {
"charging_profile_id": 123,
"transaction_id": 123,
"stack_level": 123,
"charging_profile_purpose": "<string>",
"charging_profile_kind": "<string>",
"recurrency_kind": "<string>",
"valid_from": "<string>",
"valid_to": "<string>",
"charging_schedule": {
"duration": 123,
"start_schedule": "<string>",
"charging_rate_unit": "<string>",
"charging_schedule_period": [
{
"start_period": 123,
"limit": 123,
"number_phases": 123
}
],
"min_charging_rate": 123
}
}
}
'import requests
url = "https://app.plugchoice.com/api/v3/chargers/{charger}/actions/charging-profile"
payload = {
"connector_id": 123,
"charging_profile": {
"charging_profile_id": 123,
"transaction_id": 123,
"stack_level": 123,
"charging_profile_purpose": "<string>",
"charging_profile_kind": "<string>",
"recurrency_kind": "<string>",
"valid_from": "<string>",
"valid_to": "<string>",
"charging_schedule": {
"duration": 123,
"start_schedule": "<string>",
"charging_rate_unit": "<string>",
"charging_schedule_period": [
{
"start_period": 123,
"limit": 123,
"number_phases": 123
}
],
"min_charging_rate": 123
}
}
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
connector_id: 123,
charging_profile: {
charging_profile_id: 123,
transaction_id: 123,
stack_level: 123,
charging_profile_purpose: '<string>',
charging_profile_kind: '<string>',
recurrency_kind: '<string>',
valid_from: '<string>',
valid_to: '<string>',
charging_schedule: {
duration: 123,
start_schedule: '<string>',
charging_rate_unit: '<string>',
charging_schedule_period: [{start_period: 123, limit: 123, number_phases: 123}],
min_charging_rate: 123
}
}
})
};
fetch('https://app.plugchoice.com/api/v3/chargers/{charger}/actions/charging-profile', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://app.plugchoice.com/api/v3/chargers/{charger}/actions/charging-profile",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'connector_id' => 123,
'charging_profile' => [
'charging_profile_id' => 123,
'transaction_id' => 123,
'stack_level' => 123,
'charging_profile_purpose' => '<string>',
'charging_profile_kind' => '<string>',
'recurrency_kind' => '<string>',
'valid_from' => '<string>',
'valid_to' => '<string>',
'charging_schedule' => [
'duration' => 123,
'start_schedule' => '<string>',
'charging_rate_unit' => '<string>',
'charging_schedule_period' => [
[
'start_period' => 123,
'limit' => 123,
'number_phases' => 123
]
],
'min_charging_rate' => 123
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://app.plugchoice.com/api/v3/chargers/{charger}/actions/charging-profile"
payload := strings.NewReader("{\n \"connector_id\": 123,\n \"charging_profile\": {\n \"charging_profile_id\": 123,\n \"transaction_id\": 123,\n \"stack_level\": 123,\n \"charging_profile_purpose\": \"<string>\",\n \"charging_profile_kind\": \"<string>\",\n \"recurrency_kind\": \"<string>\",\n \"valid_from\": \"<string>\",\n \"valid_to\": \"<string>\",\n \"charging_schedule\": {\n \"duration\": 123,\n \"start_schedule\": \"<string>\",\n \"charging_rate_unit\": \"<string>\",\n \"charging_schedule_period\": [\n {\n \"start_period\": 123,\n \"limit\": 123,\n \"number_phases\": 123\n }\n ],\n \"min_charging_rate\": 123\n }\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://app.plugchoice.com/api/v3/chargers/{charger}/actions/charging-profile")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"connector_id\": 123,\n \"charging_profile\": {\n \"charging_profile_id\": 123,\n \"transaction_id\": 123,\n \"stack_level\": 123,\n \"charging_profile_purpose\": \"<string>\",\n \"charging_profile_kind\": \"<string>\",\n \"recurrency_kind\": \"<string>\",\n \"valid_from\": \"<string>\",\n \"valid_to\": \"<string>\",\n \"charging_schedule\": {\n \"duration\": 123,\n \"start_schedule\": \"<string>\",\n \"charging_rate_unit\": \"<string>\",\n \"charging_schedule_period\": [\n {\n \"start_period\": 123,\n \"limit\": 123,\n \"number_phases\": 123\n }\n ],\n \"min_charging_rate\": 123\n }\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.plugchoice.com/api/v3/chargers/{charger}/actions/charging-profile")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"connector_id\": 123,\n \"charging_profile\": {\n \"charging_profile_id\": 123,\n \"transaction_id\": 123,\n \"stack_level\": 123,\n \"charging_profile_purpose\": \"<string>\",\n \"charging_profile_kind\": \"<string>\",\n \"recurrency_kind\": \"<string>\",\n \"valid_from\": \"<string>\",\n \"valid_to\": \"<string>\",\n \"charging_schedule\": {\n \"duration\": 123,\n \"start_schedule\": \"<string>\",\n \"charging_rate_unit\": \"<string>\",\n \"charging_schedule_period\": [\n {\n \"start_period\": 123,\n \"limit\": 123,\n \"number_phases\": 123\n }\n ],\n \"min_charging_rate\": 123\n }\n }\n}"
response = http.request(request)
puts response.read_body{
"status": "<string>"
}Actions
Set Charging Profile
POST
/
v3
/
chargers
/
{charger}
/
actions
/
charging-profile
Set Charging Profile
curl --request POST \
--url https://app.plugchoice.com/api/v3/chargers/{charger}/actions/charging-profile \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"connector_id": 123,
"charging_profile": {
"charging_profile_id": 123,
"transaction_id": 123,
"stack_level": 123,
"charging_profile_purpose": "<string>",
"charging_profile_kind": "<string>",
"recurrency_kind": "<string>",
"valid_from": "<string>",
"valid_to": "<string>",
"charging_schedule": {
"duration": 123,
"start_schedule": "<string>",
"charging_rate_unit": "<string>",
"charging_schedule_period": [
{
"start_period": 123,
"limit": 123,
"number_phases": 123
}
],
"min_charging_rate": 123
}
}
}
'import requests
url = "https://app.plugchoice.com/api/v3/chargers/{charger}/actions/charging-profile"
payload = {
"connector_id": 123,
"charging_profile": {
"charging_profile_id": 123,
"transaction_id": 123,
"stack_level": 123,
"charging_profile_purpose": "<string>",
"charging_profile_kind": "<string>",
"recurrency_kind": "<string>",
"valid_from": "<string>",
"valid_to": "<string>",
"charging_schedule": {
"duration": 123,
"start_schedule": "<string>",
"charging_rate_unit": "<string>",
"charging_schedule_period": [
{
"start_period": 123,
"limit": 123,
"number_phases": 123
}
],
"min_charging_rate": 123
}
}
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
connector_id: 123,
charging_profile: {
charging_profile_id: 123,
transaction_id: 123,
stack_level: 123,
charging_profile_purpose: '<string>',
charging_profile_kind: '<string>',
recurrency_kind: '<string>',
valid_from: '<string>',
valid_to: '<string>',
charging_schedule: {
duration: 123,
start_schedule: '<string>',
charging_rate_unit: '<string>',
charging_schedule_period: [{start_period: 123, limit: 123, number_phases: 123}],
min_charging_rate: 123
}
}
})
};
fetch('https://app.plugchoice.com/api/v3/chargers/{charger}/actions/charging-profile', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://app.plugchoice.com/api/v3/chargers/{charger}/actions/charging-profile",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'connector_id' => 123,
'charging_profile' => [
'charging_profile_id' => 123,
'transaction_id' => 123,
'stack_level' => 123,
'charging_profile_purpose' => '<string>',
'charging_profile_kind' => '<string>',
'recurrency_kind' => '<string>',
'valid_from' => '<string>',
'valid_to' => '<string>',
'charging_schedule' => [
'duration' => 123,
'start_schedule' => '<string>',
'charging_rate_unit' => '<string>',
'charging_schedule_period' => [
[
'start_period' => 123,
'limit' => 123,
'number_phases' => 123
]
],
'min_charging_rate' => 123
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://app.plugchoice.com/api/v3/chargers/{charger}/actions/charging-profile"
payload := strings.NewReader("{\n \"connector_id\": 123,\n \"charging_profile\": {\n \"charging_profile_id\": 123,\n \"transaction_id\": 123,\n \"stack_level\": 123,\n \"charging_profile_purpose\": \"<string>\",\n \"charging_profile_kind\": \"<string>\",\n \"recurrency_kind\": \"<string>\",\n \"valid_from\": \"<string>\",\n \"valid_to\": \"<string>\",\n \"charging_schedule\": {\n \"duration\": 123,\n \"start_schedule\": \"<string>\",\n \"charging_rate_unit\": \"<string>\",\n \"charging_schedule_period\": [\n {\n \"start_period\": 123,\n \"limit\": 123,\n \"number_phases\": 123\n }\n ],\n \"min_charging_rate\": 123\n }\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://app.plugchoice.com/api/v3/chargers/{charger}/actions/charging-profile")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"connector_id\": 123,\n \"charging_profile\": {\n \"charging_profile_id\": 123,\n \"transaction_id\": 123,\n \"stack_level\": 123,\n \"charging_profile_purpose\": \"<string>\",\n \"charging_profile_kind\": \"<string>\",\n \"recurrency_kind\": \"<string>\",\n \"valid_from\": \"<string>\",\n \"valid_to\": \"<string>\",\n \"charging_schedule\": {\n \"duration\": 123,\n \"start_schedule\": \"<string>\",\n \"charging_rate_unit\": \"<string>\",\n \"charging_schedule_period\": [\n {\n \"start_period\": 123,\n \"limit\": 123,\n \"number_phases\": 123\n }\n ],\n \"min_charging_rate\": 123\n }\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.plugchoice.com/api/v3/chargers/{charger}/actions/charging-profile")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"connector_id\": 123,\n \"charging_profile\": {\n \"charging_profile_id\": 123,\n \"transaction_id\": 123,\n \"stack_level\": 123,\n \"charging_profile_purpose\": \"<string>\",\n \"charging_profile_kind\": \"<string>\",\n \"recurrency_kind\": \"<string>\",\n \"valid_from\": \"<string>\",\n \"valid_to\": \"<string>\",\n \"charging_schedule\": {\n \"duration\": 123,\n \"start_schedule\": \"<string>\",\n \"charging_rate_unit\": \"<string>\",\n \"charging_schedule_period\": [\n {\n \"start_period\": 123,\n \"limit\": 123,\n \"number_phases\": 123\n }\n ],\n \"min_charging_rate\": 123\n }\n }\n}"
response = http.request(request)
puts response.read_body{
"status": "<string>"
}Sends a SetChargingProfile command to the charger. Supports the full OCPP 1.6 SetChargingProfile structure including
ChargePointMaxProfile, TxDefaultProfile, and TxProfile purposes.
string
required
The UUID of the charger.
integer
required
The connector ID. Use
0 for the charge point level, or a positive integer for a specific connector.object
required
The charging profile to set.
Show charging_profile
Show charging_profile
integer
required
Unique identifier for the charging profile.
integer
Transaction ID. Only applicable for
TxProfile purpose.integer
required
Priority level of the profile in the stack. Must be 0 or greater.
string
required
Purpose of the profile. One of
ChargePointMaxProfile, TxDefaultProfile, or TxProfile.string
required
Kind of schedule. One of
Absolute, Recurring, or Relative.string
Recurrency period. One of
Daily or Weekly. Only applicable for Recurring kind.string
Start of profile validity as an ISO 8601 date-time.
string
End of profile validity as an ISO 8601 date-time.
object
required
The charging schedule.
Show charging_schedule
Show charging_schedule
integer
Duration of the schedule in seconds.
string
Start of the schedule as an ISO 8601 date-time.
string
required
Unit of rate. Either
A (Amperes) or W (Watts).object[]
required
number
Minimum charging rate supported.
Response
string
The response status from the charger (e.g.,
Accepted, Rejected).⌘I