pub struct PostbackEvent {
pub type: Option<String>,
pub source: Option<Box<Source>>,
pub timestamp: i64,
pub mode: EventMode,
pub webhook_event_id: String,
pub delivery_context: Box<DeliveryContext>,
pub reply_token: Option<String>,
pub postback: Box<PostbackContent>,
}Expand description
PostbackEvent : Event object for when a user performs a postback action which initiates a postback. You can reply to postback events.
Fields§
§type: Option<String>Type of the event
source: Option<Box<Source>>§timestamp: i64Time of the event in milliseconds.
mode: EventMode§webhook_event_id: StringWebhook Event ID. An ID that uniquely identifies a webhook event. This is a string in ULID format.
delivery_context: Box<DeliveryContext>§reply_token: Option<String>Reply token used to send reply message to this event
postback: Box<PostbackContent>Implementations§
Source§impl PostbackEvent
impl PostbackEvent
Sourcepub fn new(
type: String,
timestamp: i64,
mode: EventMode,
webhook_event_id: String,
delivery_context: DeliveryContext,
postback: PostbackContent,
) -> PostbackEvent
pub fn new( type: String, timestamp: i64, mode: EventMode, webhook_event_id: String, delivery_context: DeliveryContext, postback: PostbackContent, ) -> PostbackEvent
Event object for when a user performs a postback action which initiates a postback. You can reply to postback events.
Trait Implementations§
Source§impl Clone for PostbackEvent
impl Clone for PostbackEvent
Source§fn clone(&self) -> PostbackEvent
fn clone(&self) -> PostbackEvent
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for PostbackEvent
impl Debug for PostbackEvent
Source§impl Default for PostbackEvent
impl Default for PostbackEvent
Source§fn default() -> PostbackEvent
fn default() -> PostbackEvent
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for PostbackEvent
impl<'de> Deserialize<'de> for PostbackEvent
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for PostbackEvent
impl PartialEq for PostbackEvent
Source§impl Serialize for PostbackEvent
impl Serialize for PostbackEvent
impl StructuralPartialEq for PostbackEvent
Auto Trait Implementations§
impl Freeze for PostbackEvent
impl RefUnwindSafe for PostbackEvent
impl Send for PostbackEvent
impl Sync for PostbackEvent
impl Unpin for PostbackEvent
impl UnwindSafe for PostbackEvent
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more