plaid/model/
link_delivery_metadata.rs

1use serde::{Serialize, Deserialize};
2use super::{LinkDeliveryWebhookCommunicationMethod, LinkDeliveryWebhookDeliveryStatus};
3///Information related to the related to the delivery of the link session to users
4#[derive(Debug, Clone, Serialize, Deserialize)]
5pub struct LinkDeliveryMetadata {
6    ///The communication method used to deliver the Hosted Link session
7    #[serde(default, skip_serializing_if = "Option::is_none")]
8    pub communication_method: Option<LinkDeliveryWebhookCommunicationMethod>,
9    ///The status of the delivery of the Hosted Link to the user
10    #[serde(default, skip_serializing_if = "Option::is_none")]
11    pub delivery_status: Option<LinkDeliveryWebhookDeliveryStatus>,
12}
13impl std::fmt::Display for LinkDeliveryMetadata {
14    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
15        write!(f, "{}", serde_json::to_string(self).unwrap())
16    }
17}