SetChargingProfile
Installs a charging profile that limits how much current or power a connector may deliver, and when.
- Version
- OCPP 1.6
- Direction
- CSMS → Charge Point
- Feature profile
- Smart Charging
SetChargingProfile also exists in OCPP 2.0.1, with a different payload. See the OCPP 2.0.1 version.
SetChargingProfile is the load-management message. A profile carries a schedule of limits, a purpose that decides what it applies to, and a stack level that decides which profile wins when several apply.
The nesting is the hard part: a profile contains a schedule, and a schedule contains a list of periods whose startPeriod values are seconds relative to the start of the schedule — not wall-clock times.
Request
| Field | Type | Required | Description |
|---|---|---|---|
connectorId | integer | Required | Connector the profile applies to. 0 applies to the whole charge point. |
csChargingProfiles | ChargingProfile | Required | The profile itself. See the structure below. |
[2, "19223201", "SetChargingProfile", {
"connectorId": 1,
"csChargingProfiles": {
"chargingProfileId": 100,
"stackLevel": 0,
"chargingProfilePurpose": "TxDefaultProfile",
"chargingProfileKind": "Absolute",
"chargingSchedule": {
"chargingRateUnit": "A",
"chargingSchedulePeriod": [
{ "startPeriod": 0, "limit": 32.0 },
{ "startPeriod": 21600, "limit": 16.0 }
]
}
}
}]Response
| Field | Type | Required | Description |
|---|---|---|---|
status | ChargingProfileStatus | Required | Whether the profile was stored. |
[3, "19223201", {
"status": "Accepted"
}]Values
ChargingProfilePurpose
| Value | Meaning |
|---|---|
ChargePointMaxProfile | The physical ceiling for the whole charge point. Set on connector 0. |
TxDefaultProfile | Default limits for transactions, including future ones. |
TxProfile | Limits for one specific running transaction. Requires a transactionId, and is discarded when that transaction ends. |
ChargingProfileKind
| Value | Meaning |
|---|---|
Absolute | The schedule is anchored to startSchedule, an explicit timestamp. |
Recurring | The schedule repeats, daily or weekly per recurrencyKind. |
Relative | startPeriod: 0 is the moment the transaction starts. startSchedule is ignored. |
ChargingProfileStatus
| Value | Meaning |
|---|---|
Accepted | The profile was stored. |
Rejected | The profile was refused — commonly a malformed schedule. |
NotSupported | The charge point does not support this profile purpose. |
Implementation notes
Higher `stackLevel` replaces lower — it does not add to it. Within one purpose, the valid profile with the highest stack level wins outright. Across purposes, the effective limit is the lowest of the applicable ChargePointMax, TxDefault and Tx profiles.
`Accepted` means stored, not active. To see the limit the charger will actually follow once everything is combined, call GetCompositeSchedule.
`numberPhases` defaults to 3. On a single-phase installation that default makes a computed power limit three times too high.
Absolute and Recurring require startSchedule. Omitting it is a common bug that chargers handle inconsistently.