Skip to main content
This page provides detailed information about each webhook event type, including payload structures and examples.

ocpp.message

The ocpp.message event is triggered whenever an OCPP message is sent to or received from a charging station. This provides real-time visibility into all communication between the Nayax Energy Core platform and your charging infrastructure.

OCPP RPC Framework

OCPP (Open Charge Point Protocol) uses a JSON-RPC-like framework for communication between the central system (Nayax Energy Core) and charging stations. Understanding the message types is essential for processing these webhooks correctly.

Message Types

Message Correlation

Every OCPP message includes a messageId field. This ID is used to correlate requests with their responses:
  1. A CALL message is sent with a unique messageId
  2. The recipient responds with either a CALL_RESULT or CALL_ERROR using the same messageId
This allows you to match responses to their original requests when processing webhooks.

Supported Protocols

The protocol field indicates which OCPP version the station is using:
  • ocpp1.6 - OCPP 1.6 (JSON)
  • ocpp2.0.1 - OCPP 2.0.1

Payload Structure

The data object in an ocpp.message webhook contains:

Examples

CALL - BootNotification (Station to Nayax Energy Core)

When a charging station connects to the network, it sends a BootNotification to register itself:

CALL_RESULT - BootNotification Response (Nayax Energy Core to Station)

The response to a successful BootNotification:

CALL - Heartbeat (Station to Nayax Energy Core)

Stations send periodic Heartbeat messages to indicate they are still connected. The interval is determined by the interval field in the BootNotification response (e.g., every 300 seconds):

CALL_RESULT - Heartbeat Response (Nayax Energy Core to Station)

The response contains the current server time, which stations use to synchronize their clocks:

CALL - StartTransaction (Station to Nayax Energy Core)

When a charging session begins:

CALL - MeterValues (Station to Nayax Energy Core)

Periodic energy consumption updates during charging:

CALL - StatusNotification (Station to Nayax Energy Core)

Stations send StatusNotification messages whenever a connector’s status changes. The payload contains a status field indicating the connector state and an errorCode field for fault detection. Connector Statuses (OCPP 1.6): Detecting Faults: To detect faults, check both the status and errorCode fields in the payload:
  • If status is Faulted, the connector has an active fault
  • The errorCode field provides details about the fault type (e.g., GroundFailure, OverCurrentFailure, PowerMeterFailure)
  • When errorCode is NoError, the connector is operating normally
Example - Normal Status Change (Charging):
Example - Faulted Connector:
Error Codes (OCPP 1.6):

CALL - RemoteStartTransaction (Nayax Energy Core to Station)

When you initiate a charging session remotely via the API:

CALL_RESULT - RemoteStartTransaction Response

CALL_ERROR - Request Rejected

When a station cannot process a request:

Common Error Codes

When processing CALL_ERROR messages, you may encounter these error codes:

asset.connectivity

The asset.connectivity event is triggered when a charging station’s connection status changes. This allows you to monitor the online/offline status of your charging infrastructure in real-time.

Connectivity Statuses

The connectivityStatus field indicates what happened:

Connection Lifecycle

Payload Structure

The data object in an asset.connectivity webhook contains:

Examples

Station Connected

When a station first establishes a connection:

Station Disconnected

When a station loses connection:

Use Cases

Common use cases for asset.connectivity events:
  • Monitoring dashboards - Display real-time station status
  • Alerting - Notify operators when stations go offline
  • Analytics - Track station uptime and reliability metrics
  • Automated diagnostics - Trigger health checks when stations reconnect