NotifyEvent OCPP 2.1
Der Simulator antwortet mit NotSupported, prüft die Nachricht aber gegen das Schema.
Auch in: OCPP 2.0.1
Request
| Feld | Typ | Einschränkungen / Beschreibung | |
|---|---|---|---|
generatedAt | string | Pflicht | format date-time Timestamp of the moment this message was generated at the Charging Station. |
tbc | boolean | “to be continued” indicator. Indicates whether another part of the report follows in an upcoming notifyEventRequest message. Default value when omitted is false. | |
seqNo | integer | Pflicht | minimum 0.0 Sequence number of this message. First message starts at 0. |
eventData | array<object> | Pflicht | minItems 1 |
eventData[].eventId | integer | Pflicht | minimum 0.0 Identifies the event. This field can be referred to as a cause by other events. |
eventData[].timestamp | string | Pflicht | format date-time Timestamp of the moment the report was generated. |
eventData[].trigger | string | Pflicht | enum: Alerting, Delta, Periodic Type of trigger for this event, e.g. exceeding a threshold value. |
eventData[].cause | integer | minimum 0.0 Refers to the Id of an event that is considered to be the cause for this event. | |
eventData[].actualValue | string | Pflicht | maxLength 2500 Actual value (_attributeType_ Actual) of the variable. The Configuration Variable <<configkey-reporting-value-size,ReportingValueSize>> can be used to limit GetVariableResult.attributeValue, VariableAttribute.value and EventData.actualValue. The max size of these values will always remain equal. |
eventData[].techCode | string | maxLength 50 Technical (error) code as reported by component. | |
eventData[].techInfo | string | maxLength 500 Technical detail information as reported by component. | |
eventData[].cleared | boolean | _Cleared_ is set to true to report the clearing of a monitored situation, i.e. a 'return to normal'. | |
eventData[].transactionId | string | maxLength 36 If an event notification is linked to a specific transaction, this field can be used to specify its transactionId. | |
eventData[].component | object | Pflicht | A physical or logical component |
eventData[].component.evse | object | Electric Vehicle Supply Equipment | |
eventData[].component.evse.id | integer | Pflicht | minimum 0.0 EVSE Identifier. This contains a number (> 0) designating an EVSE of the Charging Station. |
eventData[].component.evse.connectorId | integer | minimum 0.0 An id to designate a specific connector (on an EVSE) by connector index number. | |
eventData[].component.name | string | Pflicht | maxLength 50 Name of the component. Name should be taken from the list of standardized component names whenever possible. Case Insensitive. strongly advised to use Camel Case. |
eventData[].component.instance | string | maxLength 50 Name of instance in case the component exists as multiple instances. Case Insensitive. strongly advised to use Camel Case. | |
eventData[].variableMonitoringId | integer | minimum 0.0 Identifies the VariableMonitoring which triggered the event. | |
eventData[].eventNotificationType | string | Pflicht | enum: HardWiredNotification, HardWiredMonitor, PreconfiguredMonitor, CustomMonitor Specifies the event notification type of the message. |
eventData[].variable | object | Pflicht | Reference key to a component-variable. |
eventData[].variable.name | string | Pflicht | maxLength 50 Name of the variable. Name should be taken from the list of standardized variable names whenever possible. Case Insensitive. strongly advised to use Camel Case. |
eventData[].variable.instance | string | maxLength 50 Name of instance in case the variable exists as multiple instances. Case Insensitive. strongly advised to use Camel Case. | |
eventData[].severity | integer | minimum 0.0 *(2.1)* Severity associated with the monitor in _variableMonitoringId_ or with the hardwired notification. |
JSON-Schema (Request)
{
"$schema": "http://json-schema.org/draft-06/schema#",
"$id": "urn:OCPP:Cp:2:2025:1:NotifyEventRequest",
"comment": "OCPP 2.1 Edition 1 (c) OCA, Creative Commons Attribution-NoDerivatives 4.0 International Public License",
"definitions": {
"EventNotificationEnumType": {
"description": "Specifies the event notification type of the message.\r\n\r\n",
"javaType": "EventNotificationEnum",
"type": "string",
"additionalProperties": false,
"enum": [
"HardWiredNotification",
"HardWiredMonitor",
"PreconfiguredMonitor",
"CustomMonitor"
]
},
"EventTriggerEnumType": {
"description": "Type of trigger for this event, e.g. exceeding a threshold value.\r\n\r\n",
"javaType": "EventTriggerEnum",
"type": "string",
"additionalProperties": false,
"enum": [
"Alerting",
"Delta",
"Periodic"
]
},
"ComponentType": {
"description": "A physical or logical component\r\n",
"javaType": "Component",
"type": "object",
"additionalProperties": false,
"properties": {
"evse": {
"$ref": "#/definitions/EVSEType"
},
"name": {
"description": "Name of the component. Name should be taken from the list of standardized component names whenever possible. Case Insensitive. strongly advised to use Camel Case.\r\n",
"type": "string",
"maxLength": 50
},
"instance": {
"description": "Name of instance in case the component exists as multiple instances. Case Insensitive. strongly advised to use Camel Case.\r\n",
"type": "string",
"maxLength": 50
},
"customData": {
"$ref": "#/definitions/CustomDataType"
}
},
"required": [
"name"
]
},
"EventDataType": {
"description": "Class to report an event notification for a component-variable.\r\n",
"javaType": "EventData",
"type": "object",
"additionalProperties": false,
"properties": {
"eventId": {
"description": "Identifies the event. This field can be referred to as a cause by other events.\r\n\r\n",
"type": "integer",
"minimum": 0.0
},
"timestamp": {
"description": "Timestamp of the moment the report was generated.\r\n",
"type": "string",
"format": "date-time"
},
"trigger": {
"$ref": "#/definitions/EventTriggerEnumType"
},
"cause": {
"description": "Refers to the Id of an event that is considered to be the cause for this event.\r\n\r\n",
"type": "integer",
"minimum": 0.0
},
"actualValue": {
"description": "Actual value (_attributeType_ Actual) of the variable.\r\n\r\nThe Configuration Variable <<configkey-reporting-value-size,ReportingValueSize>> can be used to limit GetVariableResult.attributeValue, VariableAttribute.value and EventData.actualValue. The max size of these values will always remain equal. \r\n\r\n",
"type": "string",
"maxLength": 2500
},
"techCode": {
"description": "Technical (error) code as reported by component.\r\n",
"type": "string",
"maxLength": 50
},
"techInfo": {
"description": "Technical detail information as reported by component.\r\n",
"type": "string",
"maxLength": 500
},
"cleared": {
"description": "_Cleared_ is set to true to report the clearing of a monitored situation, i.e. a 'return to normal'. \r\n\r\n",
"type": "boolean"
},
"transactionId": {
"description": "If an event notification is linked to a specific transaction, this field can be used to specify its transactionId.\r\n",
"type": "string",
"maxLength": 36
},
"component": {
"$ref": "#/definitions/ComponentType"
},
"variableMonitoringId": {
"description": "Identifies the VariableMonitoring which triggered the event.\r\n",
"type": "integer",
"minimum": 0.0
},
"eventNotificationType": {
"$ref": "#/definitions/EventNotificationEnumType"
},
"variable": {
"$ref": "#/definitions/VariableType"
},
"severity": {
"description": "*(2.1)* Severity associated with the monitor in _variableMonitoringId_ or with the hardwired notification.\r\n",
"type": "integer",
"minimum": 0.0
},
"customData": {
"$ref": "#/definitions/CustomDataType"
}
},
"required": [
"eventId",
"timestamp",
"trigger",
"actualValue",
"eventNotificationType",
"component",
"variable"
]
},
"EVSEType": {
"description": "Electric Vehicle Supply Equipment\r\n",
"javaType": "EVSE",
"type": "object",
"additionalProperties": false,
"properties": {
"id": {
"description": "EVSE Identifier. This contains a number (> 0) designating an EVSE of the Charging Station.\r\n",
"type": "integer",
"minimum": 0.0
},
"connectorId": {
"description": "An id to designate a specific connector (on an EVSE) by connector index number.\r\n",
"type": "integer",
"minimum": 0.0
},
"customData": {
"$ref": "#/definitions/CustomDataType"
}
},
"required": [
"id"
]
},
"VariableType": {
"description": "Reference key to a component-variable.\r\n",
"javaType": "Variable",
"type": "object",
"additionalProperties": false,
"properties": {
"name": {
"description": "Name of the variable. Name should be taken from the list of standardized variable names whenever possible. Case Insensitive. strongly advised to use Camel Case.\r\n",
"type": "string",
"maxLength": 50
},
"instance": {
"description": "Name of instance in case the variable exists as multiple instances. Case Insensitive. strongly advised to use Camel Case.\r\n",
"type": "string",
"maxLength": 50
},
"customData": {
"$ref": "#/definitions/CustomDataType"
}
},
"required": [
"name"
]
},
"CustomDataType": {
"description": "This class does not get 'AdditionalProperties = false' in the schema generation, so it can be extended with arbitrary JSON properties to allow adding custom data.",
"javaType": "CustomData",
"type": "object",
"properties": {
"vendorId": {
"type": "string",
"maxLength": 255
}
},
"required": [
"vendorId"
]
}
},
"type": "object",
"additionalProperties": false,
"properties": {
"generatedAt": {
"description": "Timestamp of the moment this message was generated at the Charging Station.\r\n",
"type": "string",
"format": "date-time"
},
"tbc": {
"description": "“to be continued” indicator. Indicates whether another part of the report follows in an upcoming notifyEventRequest message. Default value when omitted is false. \r\n",
"type": "boolean",
"default": false
},
"seqNo": {
"description": "Sequence number of this message. First message starts at 0.\r\n",
"type": "integer",
"minimum": 0.0
},
"eventData": {
"type": "array",
"additionalItems": false,
"items": {
"$ref": "#/definitions/EventDataType"
},
"minItems": 1
},
"customData": {
"$ref": "#/definitions/CustomDataType"
}
},
"required": [
"generatedAt",
"seqNo",
"eventData"
]
}Response
Leeres Objekt {}.
JSON-Schema (Response)
{
"$schema": "http://json-schema.org/draft-06/schema#",
"$id": "urn:OCPP:Cp:2:2025:1:NotifyEventResponse",
"comment": "OCPP 2.1 Edition 1 (c) OCA, Creative Commons Attribution-NoDerivatives 4.0 International Public License",
"definitions": {
"CustomDataType": {
"description": "This class does not get 'AdditionalProperties = false' in the schema generation, so it can be extended with arbitrary JSON properties to allow adding custom data.",
"javaType": "CustomData",
"type": "object",
"properties": {
"vendorId": {
"type": "string",
"maxLength": 255
}
},
"required": [
"vendorId"
]
}
},
"type": "object",
"additionalProperties": false,
"properties": {
"customData": {
"$ref": "#/definitions/CustomDataType"
}
}
}Quelle: Open Charge Alliance, OCPP 2.1 – JSON-Schemas, unverändert wiedergegeben. © Open Charge Alliance. Lizenz: CC BY-ND 4.0. Die vollständige Spezifikation gibt es bei der Open Charge Alliance. ocpp-sim ist nicht mit der OCA verbunden.