squareup/models/subscription_test_result.rs
1//! Model struct for SubscriptionTestResult type.
2
3use crate::models::DateTime;
4use crate::models::enums::WebhookEventType;
5use serde::{Deserialize, Serialize};
6
7/// /// Subscription test result details.
8#[derive(Clone, Debug, Default, Deserialize, Eq, PartialEq, Serialize)]
9pub struct SubscriptionTestResult {
10 /// **Read only** A Square-generated unique ID for the subscription test result.
11 ///
12 /// Max Length: 64
13 pub id: Option<String>,
14 /// The status code returned by the subscription notification URL.
15 pub status_code: Option<i32>,
16 /// An object containing the payload of the test event.
17 ///
18 /// For example, a payment.created event.
19 pub payload: Option<WebhookEventType>,
20 /// The timestamp of when the subscription was created, in RFC 3339 format.
21 ///
22 /// Examples for January 25th, 2020 6:25:34pm Pacific Standard Time:
23 /// - UTC: 2020-01-26T02:25:34Z
24 /// - Pacific Standard Time with UTC offset: 2020-01-25T18:25:34-08:00
25 pub created_at: Option<DateTime>,
26 /// The timestamp of when the subscription was updated, in RFC 3339 format.
27 ///
28 /// Because a subscription test result is unique, this field is the same as the created_at field.
29 ///
30 /// Examples for January 25th, 2020 6:25:34pm Pacific Standard Time:
31 /// - UTC: 2020-01-26T02:25:34Z
32 /// - Pacific Standard Time with UTC offset: 2020-01-25T18:25:34-08:00
33 pub updated_at: Option<DateTime>,
34}