rust_ocpp/v1_6/messages/
trigger_message.rs

1use crate::v1_6::types::{MessageTrigger, TriggerMessageStatus};
2
3/// This contains the field definition of the TriggerMessage.req PDU sent by the Central System to the Charge Point. See also Trigger Message
4#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Default)]
5#[serde(rename_all = "camelCase")]
6pub struct TriggerMessageRequest {
7    /// Required.
8    pub requested_message: MessageTrigger,
9    /// Optional. Only filled in when request applies to a specific connector.
10    #[serde(skip_serializing_if = "Option::is_none")]
11    pub connector_id: Option<u32>,
12}
13
14/// This contains the field definition of the TriggerMessage.req PDU sent by the Central System to the Charge Point. See also Trigger Message
15#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Default)]
16#[serde(rename_all = "camelCase")]
17pub struct TriggerMessageResponse {
18    /// Required. Indicates whether the Charge Point will send the requested notification or not.
19    pub status: TriggerMessageStatus,
20}