square_api_client/models/catalog_time_period.rs
1//! Model struct for CatalogTimePeriod type.
2
3use serde::{Deserialize, Serialize};
4
5/// Represents a time period - either a single period or a repeating period.
6#[derive(Clone, Debug, Default, Deserialize, Eq, PartialEq, Serialize)]
7pub struct CatalogTimePeriod {
8 /// An iCalendar (RFC 5545) [event](https://tools.ietf.org/html/rfc5545#section-3.6.1), which
9 /// specifies the name, timing, duration and recurrence of this time period.
10 ///
11 /// Example:
12 /// ```
13 /// use square_api_client::models::CatalogTimePeriod;
14 ///
15 /// CatalogTimePeriod {
16 /// event: Some(String::from("DTSTART:20190707T180000\nDURATION:P2H\nRRULE:FREQ=WEEKLY;BYDAY=MO,WE,FR")),
17 /// };
18 /// ```
19 /// Only `SUMMARY`, `DTSTART`, `DURATION` and `RRULE` fields are supported. `DTSTART` must be in
20 /// local (unzoned) time format. Note that while `BEGIN:VEVENT` and `END:VEVENT` is not required
21 /// in the request. The response will always include them.
22 pub event: Option<String>,
23}