rivet_chat/
model.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2/// An identity handle.
3#[non_exhaustive]
4#[derive(std::clone::Clone, std::cmp::PartialEq)]
5pub struct IdentityHandle {
6	/// A universally unique identifier.
7	pub identity_id: std::option::Option<std::string::String>,
8	/// Represent a resource's readable display name.
9	pub display_name: std::option::Option<std::string::String>,
10	/// Identity profile account number (#1234). These are assigned in addition to an identity's display name in order to allow multiple identities to have the same display name while still providing a unique handle. These are unique to each display name; you can have multiple accounts with different display names and the same account number.
11	pub account_number: std::option::Option<i32>,
12	/// The URL of this identity's avatar image.
13	pub avatar_url: std::option::Option<std::string::String>,
14	/// Information about the identity's current status, party, and active game.
15	pub presence: std::option::Option<crate::model::IdentityPresence>,
16	/// A party handle.
17	pub party: std::option::Option<crate::model::PartyHandle>,
18	/// Whether or not this identity is registered with a linked account.
19	pub is_registered: std::option::Option<bool>,
20	/// External links for an identity.
21	pub external: std::option::Option<crate::model::IdentityExternalLinks>,
22}
23impl IdentityHandle {
24	/// A universally unique identifier.
25	pub fn identity_id(&self) -> std::option::Option<&str> {
26		self.identity_id.as_deref()
27	}
28	/// Represent a resource's readable display name.
29	pub fn display_name(&self) -> std::option::Option<&str> {
30		self.display_name.as_deref()
31	}
32	/// Identity profile account number (#1234). These are assigned in addition to an identity's display name in order to allow multiple identities to have the same display name while still providing a unique handle. These are unique to each display name; you can have multiple accounts with different display names and the same account number.
33	pub fn account_number(&self) -> std::option::Option<i32> {
34		self.account_number
35	}
36	/// The URL of this identity's avatar image.
37	pub fn avatar_url(&self) -> std::option::Option<&str> {
38		self.avatar_url.as_deref()
39	}
40	/// Information about the identity's current status, party, and active game.
41	pub fn presence(&self) -> std::option::Option<&crate::model::IdentityPresence> {
42		self.presence.as_ref()
43	}
44	/// A party handle.
45	pub fn party(&self) -> std::option::Option<&crate::model::PartyHandle> {
46		self.party.as_ref()
47	}
48	/// Whether or not this identity is registered with a linked account.
49	pub fn is_registered(&self) -> std::option::Option<bool> {
50		self.is_registered
51	}
52	/// External links for an identity.
53	pub fn external(&self) -> std::option::Option<&crate::model::IdentityExternalLinks> {
54		self.external.as_ref()
55	}
56}
57impl std::fmt::Debug for IdentityHandle {
58	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
59		let mut formatter = f.debug_struct("IdentityHandle");
60		formatter.field("identity_id", &self.identity_id);
61		formatter.field("display_name", &self.display_name);
62		formatter.field("account_number", &self.account_number);
63		formatter.field("avatar_url", &self.avatar_url);
64		formatter.field("presence", &self.presence);
65		formatter.field("party", &self.party);
66		formatter.field("is_registered", &self.is_registered);
67		formatter.field("external", &self.external);
68		formatter.finish()
69	}
70}
71/// See [`IdentityHandle`](crate::model::IdentityHandle)
72pub mod identity_handle {
73	/// A builder for [`IdentityHandle`](crate::model::IdentityHandle)
74	#[non_exhaustive]
75	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
76	pub struct Builder {
77		pub(crate) identity_id: std::option::Option<std::string::String>,
78		pub(crate) display_name: std::option::Option<std::string::String>,
79		pub(crate) account_number: std::option::Option<i32>,
80		pub(crate) avatar_url: std::option::Option<std::string::String>,
81		pub(crate) presence: std::option::Option<crate::model::IdentityPresence>,
82		pub(crate) party: std::option::Option<crate::model::PartyHandle>,
83		pub(crate) is_registered: std::option::Option<bool>,
84		pub(crate) external: std::option::Option<crate::model::IdentityExternalLinks>,
85	}
86	impl Builder {
87		/// A universally unique identifier.
88		pub fn identity_id(mut self, input: impl Into<std::string::String>) -> Self {
89			self.identity_id = Some(input.into());
90			self
91		}
92		/// A universally unique identifier.
93		pub fn set_identity_id(mut self, input: std::option::Option<std::string::String>) -> Self {
94			self.identity_id = input;
95			self
96		}
97		/// Represent a resource's readable display name.
98		pub fn display_name(mut self, input: impl Into<std::string::String>) -> Self {
99			self.display_name = Some(input.into());
100			self
101		}
102		/// Represent a resource's readable display name.
103		pub fn set_display_name(mut self, input: std::option::Option<std::string::String>) -> Self {
104			self.display_name = input;
105			self
106		}
107		/// Identity profile account number (#1234). These are assigned in addition to an identity's display name in order to allow multiple identities to have the same display name while still providing a unique handle. These are unique to each display name; you can have multiple accounts with different display names and the same account number.
108		pub fn account_number(mut self, input: i32) -> Self {
109			self.account_number = Some(input);
110			self
111		}
112		/// Identity profile account number (#1234). These are assigned in addition to an identity's display name in order to allow multiple identities to have the same display name while still providing a unique handle. These are unique to each display name; you can have multiple accounts with different display names and the same account number.
113		pub fn set_account_number(mut self, input: std::option::Option<i32>) -> Self {
114			self.account_number = input;
115			self
116		}
117		/// The URL of this identity's avatar image.
118		pub fn avatar_url(mut self, input: impl Into<std::string::String>) -> Self {
119			self.avatar_url = Some(input.into());
120			self
121		}
122		/// The URL of this identity's avatar image.
123		pub fn set_avatar_url(mut self, input: std::option::Option<std::string::String>) -> Self {
124			self.avatar_url = input;
125			self
126		}
127		/// Information about the identity's current status, party, and active game.
128		pub fn presence(mut self, input: crate::model::IdentityPresence) -> Self {
129			self.presence = Some(input);
130			self
131		}
132		/// Information about the identity's current status, party, and active game.
133		pub fn set_presence(
134			mut self,
135			input: std::option::Option<crate::model::IdentityPresence>,
136		) -> Self {
137			self.presence = input;
138			self
139		}
140		/// A party handle.
141		pub fn party(mut self, input: crate::model::PartyHandle) -> Self {
142			self.party = Some(input);
143			self
144		}
145		/// A party handle.
146		pub fn set_party(mut self, input: std::option::Option<crate::model::PartyHandle>) -> Self {
147			self.party = input;
148			self
149		}
150		/// Whether or not this identity is registered with a linked account.
151		pub fn is_registered(mut self, input: bool) -> Self {
152			self.is_registered = Some(input);
153			self
154		}
155		/// Whether or not this identity is registered with a linked account.
156		pub fn set_is_registered(mut self, input: std::option::Option<bool>) -> Self {
157			self.is_registered = input;
158			self
159		}
160		/// External links for an identity.
161		pub fn external(mut self, input: crate::model::IdentityExternalLinks) -> Self {
162			self.external = Some(input);
163			self
164		}
165		/// External links for an identity.
166		pub fn set_external(
167			mut self,
168			input: std::option::Option<crate::model::IdentityExternalLinks>,
169		) -> Self {
170			self.external = input;
171			self
172		}
173		/// Consumes the builder and constructs a [`IdentityHandle`](crate::model::IdentityHandle)
174		pub fn build(self) -> crate::model::IdentityHandle {
175			crate::model::IdentityHandle {
176				identity_id: self.identity_id,
177				display_name: self.display_name,
178				account_number: self.account_number,
179				avatar_url: self.avatar_url,
180				presence: self.presence,
181				party: self.party,
182				is_registered: self.is_registered,
183				external: self.external,
184			}
185		}
186	}
187}
188impl IdentityHandle {
189	/// Creates a new builder-style object to manufacture [`IdentityHandle`](crate::model::IdentityHandle)
190	pub fn builder() -> crate::model::identity_handle::Builder {
191		crate::model::identity_handle::Builder::default()
192	}
193}
194
195/// External links for an identity.
196#[non_exhaustive]
197#[derive(std::clone::Clone, std::cmp::PartialEq)]
198pub struct IdentityExternalLinks {
199	/// A link to this identity's profile page.
200	pub profile: std::option::Option<std::string::String>,
201	/// A link to the Rivet settings page.
202	pub settings: std::option::Option<std::string::String>,
203	/// A link to a chat page with the given identity.
204	pub chat: std::option::Option<std::string::String>,
205}
206impl IdentityExternalLinks {
207	/// A link to this identity's profile page.
208	pub fn profile(&self) -> std::option::Option<&str> {
209		self.profile.as_deref()
210	}
211	/// A link to the Rivet settings page.
212	pub fn settings(&self) -> std::option::Option<&str> {
213		self.settings.as_deref()
214	}
215	/// A link to a chat page with the given identity.
216	pub fn chat(&self) -> std::option::Option<&str> {
217		self.chat.as_deref()
218	}
219}
220impl std::fmt::Debug for IdentityExternalLinks {
221	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
222		let mut formatter = f.debug_struct("IdentityExternalLinks");
223		formatter.field("profile", &self.profile);
224		formatter.field("settings", &self.settings);
225		formatter.field("chat", &self.chat);
226		formatter.finish()
227	}
228}
229/// See [`IdentityExternalLinks`](crate::model::IdentityExternalLinks)
230pub mod identity_external_links {
231	/// A builder for [`IdentityExternalLinks`](crate::model::IdentityExternalLinks)
232	#[non_exhaustive]
233	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
234	pub struct Builder {
235		pub(crate) profile: std::option::Option<std::string::String>,
236		pub(crate) settings: std::option::Option<std::string::String>,
237		pub(crate) chat: std::option::Option<std::string::String>,
238	}
239	impl Builder {
240		/// A link to this identity's profile page.
241		pub fn profile(mut self, input: impl Into<std::string::String>) -> Self {
242			self.profile = Some(input.into());
243			self
244		}
245		/// A link to this identity's profile page.
246		pub fn set_profile(mut self, input: std::option::Option<std::string::String>) -> Self {
247			self.profile = input;
248			self
249		}
250		/// A link to the Rivet settings page.
251		pub fn settings(mut self, input: impl Into<std::string::String>) -> Self {
252			self.settings = Some(input.into());
253			self
254		}
255		/// A link to the Rivet settings page.
256		pub fn set_settings(mut self, input: std::option::Option<std::string::String>) -> Self {
257			self.settings = input;
258			self
259		}
260		/// A link to a chat page with the given identity.
261		pub fn chat(mut self, input: impl Into<std::string::String>) -> Self {
262			self.chat = Some(input.into());
263			self
264		}
265		/// A link to a chat page with the given identity.
266		pub fn set_chat(mut self, input: std::option::Option<std::string::String>) -> Self {
267			self.chat = input;
268			self
269		}
270		/// Consumes the builder and constructs a [`IdentityExternalLinks`](crate::model::IdentityExternalLinks)
271		pub fn build(self) -> crate::model::IdentityExternalLinks {
272			crate::model::IdentityExternalLinks {
273				profile: self.profile,
274				settings: self.settings,
275				chat: self.chat,
276			}
277		}
278	}
279}
280impl IdentityExternalLinks {
281	/// Creates a new builder-style object to manufacture [`IdentityExternalLinks`](crate::model::IdentityExternalLinks)
282	pub fn builder() -> crate::model::identity_external_links::Builder {
283		crate::model::identity_external_links::Builder::default()
284	}
285}
286
287/// A party handle.
288#[non_exhaustive]
289#[derive(std::clone::Clone, std::cmp::PartialEq)]
290pub struct PartyHandle {
291	/// A universally unique identifier.
292	pub party_id: std::option::Option<std::string::String>,
293	/// RFC3339 timestamp.
294	pub create_ts: std::option::Option<aws_smithy_types::DateTime>,
295	/// A union representing the activity of a given party.
296	pub activity: std::option::Option<crate::model::PartyActivity>,
297	/// External links for a party.
298	pub external: std::option::Option<crate::model::PartyExternalLinks>,
299}
300impl PartyHandle {
301	/// A universally unique identifier.
302	pub fn party_id(&self) -> std::option::Option<&str> {
303		self.party_id.as_deref()
304	}
305	/// RFC3339 timestamp.
306	pub fn create_ts(&self) -> std::option::Option<&aws_smithy_types::DateTime> {
307		self.create_ts.as_ref()
308	}
309	/// A union representing the activity of a given party.
310	pub fn activity(&self) -> std::option::Option<&crate::model::PartyActivity> {
311		self.activity.as_ref()
312	}
313	/// External links for a party.
314	pub fn external(&self) -> std::option::Option<&crate::model::PartyExternalLinks> {
315		self.external.as_ref()
316	}
317}
318impl std::fmt::Debug for PartyHandle {
319	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
320		let mut formatter = f.debug_struct("PartyHandle");
321		formatter.field("party_id", &self.party_id);
322		formatter.field("create_ts", &self.create_ts);
323		formatter.field("activity", &self.activity);
324		formatter.field("external", &self.external);
325		formatter.finish()
326	}
327}
328/// See [`PartyHandle`](crate::model::PartyHandle)
329pub mod party_handle {
330	/// A builder for [`PartyHandle`](crate::model::PartyHandle)
331	#[non_exhaustive]
332	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
333	pub struct Builder {
334		pub(crate) party_id: std::option::Option<std::string::String>,
335		pub(crate) create_ts: std::option::Option<aws_smithy_types::DateTime>,
336		pub(crate) activity: std::option::Option<crate::model::PartyActivity>,
337		pub(crate) external: std::option::Option<crate::model::PartyExternalLinks>,
338	}
339	impl Builder {
340		/// A universally unique identifier.
341		pub fn party_id(mut self, input: impl Into<std::string::String>) -> Self {
342			self.party_id = Some(input.into());
343			self
344		}
345		/// A universally unique identifier.
346		pub fn set_party_id(mut self, input: std::option::Option<std::string::String>) -> Self {
347			self.party_id = input;
348			self
349		}
350		/// RFC3339 timestamp.
351		pub fn create_ts(mut self, input: aws_smithy_types::DateTime) -> Self {
352			self.create_ts = Some(input);
353			self
354		}
355		/// RFC3339 timestamp.
356		pub fn set_create_ts(
357			mut self,
358			input: std::option::Option<aws_smithy_types::DateTime>,
359		) -> Self {
360			self.create_ts = input;
361			self
362		}
363		/// A union representing the activity of a given party.
364		pub fn activity(mut self, input: crate::model::PartyActivity) -> Self {
365			self.activity = Some(input);
366			self
367		}
368		/// A union representing the activity of a given party.
369		pub fn set_activity(
370			mut self,
371			input: std::option::Option<crate::model::PartyActivity>,
372		) -> Self {
373			self.activity = input;
374			self
375		}
376		/// External links for a party.
377		pub fn external(mut self, input: crate::model::PartyExternalLinks) -> Self {
378			self.external = Some(input);
379			self
380		}
381		/// External links for a party.
382		pub fn set_external(
383			mut self,
384			input: std::option::Option<crate::model::PartyExternalLinks>,
385		) -> Self {
386			self.external = input;
387			self
388		}
389		/// Consumes the builder and constructs a [`PartyHandle`](crate::model::PartyHandle)
390		pub fn build(self) -> crate::model::PartyHandle {
391			crate::model::PartyHandle {
392				party_id: self.party_id,
393				create_ts: self.create_ts,
394				activity: self.activity,
395				external: self.external,
396			}
397		}
398	}
399}
400impl PartyHandle {
401	/// Creates a new builder-style object to manufacture [`PartyHandle`](crate::model::PartyHandle)
402	pub fn builder() -> crate::model::party_handle::Builder {
403		crate::model::party_handle::Builder::default()
404	}
405}
406
407/// External links for a party.
408#[non_exhaustive]
409#[derive(std::clone::Clone, std::cmp::PartialEq)]
410pub struct PartyExternalLinks {
411	/// A link to the given party's chat thread.
412	pub chat: std::option::Option<std::string::String>,
413}
414impl PartyExternalLinks {
415	/// A link to the given party's chat thread.
416	pub fn chat(&self) -> std::option::Option<&str> {
417		self.chat.as_deref()
418	}
419}
420impl std::fmt::Debug for PartyExternalLinks {
421	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
422		let mut formatter = f.debug_struct("PartyExternalLinks");
423		formatter.field("chat", &self.chat);
424		formatter.finish()
425	}
426}
427/// See [`PartyExternalLinks`](crate::model::PartyExternalLinks)
428pub mod party_external_links {
429	/// A builder for [`PartyExternalLinks`](crate::model::PartyExternalLinks)
430	#[non_exhaustive]
431	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
432	pub struct Builder {
433		pub(crate) chat: std::option::Option<std::string::String>,
434	}
435	impl Builder {
436		/// A link to the given party's chat thread.
437		pub fn chat(mut self, input: impl Into<std::string::String>) -> Self {
438			self.chat = Some(input.into());
439			self
440		}
441		/// A link to the given party's chat thread.
442		pub fn set_chat(mut self, input: std::option::Option<std::string::String>) -> Self {
443			self.chat = input;
444			self
445		}
446		/// Consumes the builder and constructs a [`PartyExternalLinks`](crate::model::PartyExternalLinks)
447		pub fn build(self) -> crate::model::PartyExternalLinks {
448			crate::model::PartyExternalLinks { chat: self.chat }
449		}
450	}
451}
452impl PartyExternalLinks {
453	/// Creates a new builder-style object to manufacture [`PartyExternalLinks`](crate::model::PartyExternalLinks)
454	pub fn builder() -> crate::model::party_external_links::Builder {
455		crate::model::party_external_links::Builder::default()
456	}
457}
458
459/// A union representing the activity of a given party.
460#[non_exhaustive]
461#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
462pub enum PartyActivity {
463	/// A party activity denoting that the party is idle.
464	Idle(crate::model::PartyActivityIdle),
465	/// A party activity denoting that the party is currently searching for a lobby.
466	MatchmakerFindingLobby(crate::model::PartyActivityMatchmakerFindingLobby),
467	/// A party activity denoting that the party is currently in a lobby.
468	MatchmakerLobby(crate::model::PartyActivityMatchmakerLobby),
469	/// The `Unknown` variant represents cases where new union variant was received. Consider upgrading the SDK to the latest available version.
470	/// An unknown enum variant
471	///
472	/// _Note: If you encounter this error, consider upgrading your SDK to the latest version._
473	/// The `Unknown` variant represents cases where the server sent a value that wasn't recognized
474	/// by the client. This can happen when the server adds new functionality, but the client has not been updated.
475	/// To investigate this, consider turning on debug logging to print the raw HTTP response.
476	#[non_exhaustive]
477	Unknown,
478}
479impl PartyActivity {
480	/// Tries to convert the enum instance into [`Idle`](crate::model::PartyActivity::Idle), extracting the inner [`PartyActivityIdle`](crate::model::PartyActivityIdle).
481	/// Returns `Err(&Self)` if it can't be converted.
482	pub fn as_idle(&self) -> std::result::Result<&crate::model::PartyActivityIdle, &Self> {
483		if let PartyActivity::Idle(val) = &self {
484			Ok(val)
485		} else {
486			Err(self)
487		}
488	}
489	/// Returns true if this is a [`Idle`](crate::model::PartyActivity::Idle).
490	pub fn is_idle(&self) -> bool {
491		self.as_idle().is_ok()
492	}
493	/// Tries to convert the enum instance into [`MatchmakerFindingLobby`](crate::model::PartyActivity::MatchmakerFindingLobby), extracting the inner [`PartyActivityMatchmakerFindingLobby`](crate::model::PartyActivityMatchmakerFindingLobby).
494	/// Returns `Err(&Self)` if it can't be converted.
495	pub fn as_matchmaker_finding_lobby(
496		&self,
497	) -> std::result::Result<&crate::model::PartyActivityMatchmakerFindingLobby, &Self> {
498		if let PartyActivity::MatchmakerFindingLobby(val) = &self {
499			Ok(val)
500		} else {
501			Err(self)
502		}
503	}
504	/// Returns true if this is a [`MatchmakerFindingLobby`](crate::model::PartyActivity::MatchmakerFindingLobby).
505	pub fn is_matchmaker_finding_lobby(&self) -> bool {
506		self.as_matchmaker_finding_lobby().is_ok()
507	}
508	/// Tries to convert the enum instance into [`MatchmakerLobby`](crate::model::PartyActivity::MatchmakerLobby), extracting the inner [`PartyActivityMatchmakerLobby`](crate::model::PartyActivityMatchmakerLobby).
509	/// Returns `Err(&Self)` if it can't be converted.
510	pub fn as_matchmaker_lobby(
511		&self,
512	) -> std::result::Result<&crate::model::PartyActivityMatchmakerLobby, &Self> {
513		if let PartyActivity::MatchmakerLobby(val) = &self {
514			Ok(val)
515		} else {
516			Err(self)
517		}
518	}
519	/// Returns true if this is a [`MatchmakerLobby`](crate::model::PartyActivity::MatchmakerLobby).
520	pub fn is_matchmaker_lobby(&self) -> bool {
521		self.as_matchmaker_lobby().is_ok()
522	}
523	/// Returns true if the enum instance is the `Unknown` variant.
524	pub fn is_unknown(&self) -> bool {
525		matches!(self, Self::Unknown)
526	}
527}
528
529/// A party activity denoting that the party is currently in a lobby.
530#[non_exhaustive]
531#[derive(std::clone::Clone, std::cmp::PartialEq)]
532pub struct PartyActivityMatchmakerLobby {
533	/// A party lobby.
534	pub lobby: std::option::Option<crate::model::PartyMatchmakerLobby>,
535	/// A game handle.
536	pub game: std::option::Option<crate::model::GameHandle>,
537}
538impl PartyActivityMatchmakerLobby {
539	/// A party lobby.
540	pub fn lobby(&self) -> std::option::Option<&crate::model::PartyMatchmakerLobby> {
541		self.lobby.as_ref()
542	}
543	/// A game handle.
544	pub fn game(&self) -> std::option::Option<&crate::model::GameHandle> {
545		self.game.as_ref()
546	}
547}
548impl std::fmt::Debug for PartyActivityMatchmakerLobby {
549	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
550		let mut formatter = f.debug_struct("PartyActivityMatchmakerLobby");
551		formatter.field("lobby", &self.lobby);
552		formatter.field("game", &self.game);
553		formatter.finish()
554	}
555}
556/// See [`PartyActivityMatchmakerLobby`](crate::model::PartyActivityMatchmakerLobby)
557pub mod party_activity_matchmaker_lobby {
558	/// A builder for [`PartyActivityMatchmakerLobby`](crate::model::PartyActivityMatchmakerLobby)
559	#[non_exhaustive]
560	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
561	pub struct Builder {
562		pub(crate) lobby: std::option::Option<crate::model::PartyMatchmakerLobby>,
563		pub(crate) game: std::option::Option<crate::model::GameHandle>,
564	}
565	impl Builder {
566		/// A party lobby.
567		pub fn lobby(mut self, input: crate::model::PartyMatchmakerLobby) -> Self {
568			self.lobby = Some(input);
569			self
570		}
571		/// A party lobby.
572		pub fn set_lobby(
573			mut self,
574			input: std::option::Option<crate::model::PartyMatchmakerLobby>,
575		) -> Self {
576			self.lobby = input;
577			self
578		}
579		/// A game handle.
580		pub fn game(mut self, input: crate::model::GameHandle) -> Self {
581			self.game = Some(input);
582			self
583		}
584		/// A game handle.
585		pub fn set_game(mut self, input: std::option::Option<crate::model::GameHandle>) -> Self {
586			self.game = input;
587			self
588		}
589		/// Consumes the builder and constructs a [`PartyActivityMatchmakerLobby`](crate::model::PartyActivityMatchmakerLobby)
590		pub fn build(self) -> crate::model::PartyActivityMatchmakerLobby {
591			crate::model::PartyActivityMatchmakerLobby {
592				lobby: self.lobby,
593				game: self.game,
594			}
595		}
596	}
597}
598impl PartyActivityMatchmakerLobby {
599	/// Creates a new builder-style object to manufacture [`PartyActivityMatchmakerLobby`](crate::model::PartyActivityMatchmakerLobby)
600	pub fn builder() -> crate::model::party_activity_matchmaker_lobby::Builder {
601		crate::model::party_activity_matchmaker_lobby::Builder::default()
602	}
603}
604
605/// A game handle.
606#[non_exhaustive]
607#[derive(std::clone::Clone, std::cmp::PartialEq)]
608pub struct GameHandle {
609	/// A universally unique identifier.
610	pub game_id: std::option::Option<std::string::String>,
611	/// A human readable short identifier used to references resources. Different than a `rivet.common#Uuid` because this is intended to be human readable. Different than `rivet.common#DisplayName` because this should not include special characters and be short.
612	pub name_id: std::option::Option<std::string::String>,
613	/// Represent a resource's readable display name.
614	pub display_name: std::option::Option<std::string::String>,
615	/// The URL of this game's logo image.
616	pub logo_url: std::option::Option<std::string::String>,
617	/// The URL of this game's banner image.
618	pub banner_url: std::option::Option<std::string::String>,
619}
620impl GameHandle {
621	/// A universally unique identifier.
622	pub fn game_id(&self) -> std::option::Option<&str> {
623		self.game_id.as_deref()
624	}
625	/// A human readable short identifier used to references resources. Different than a `rivet.common#Uuid` because this is intended to be human readable. Different than `rivet.common#DisplayName` because this should not include special characters and be short.
626	pub fn name_id(&self) -> std::option::Option<&str> {
627		self.name_id.as_deref()
628	}
629	/// Represent a resource's readable display name.
630	pub fn display_name(&self) -> std::option::Option<&str> {
631		self.display_name.as_deref()
632	}
633	/// The URL of this game's logo image.
634	pub fn logo_url(&self) -> std::option::Option<&str> {
635		self.logo_url.as_deref()
636	}
637	/// The URL of this game's banner image.
638	pub fn banner_url(&self) -> std::option::Option<&str> {
639		self.banner_url.as_deref()
640	}
641}
642impl std::fmt::Debug for GameHandle {
643	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
644		let mut formatter = f.debug_struct("GameHandle");
645		formatter.field("game_id", &self.game_id);
646		formatter.field("name_id", &self.name_id);
647		formatter.field("display_name", &self.display_name);
648		formatter.field("logo_url", &self.logo_url);
649		formatter.field("banner_url", &self.banner_url);
650		formatter.finish()
651	}
652}
653/// See [`GameHandle`](crate::model::GameHandle)
654pub mod game_handle {
655	/// A builder for [`GameHandle`](crate::model::GameHandle)
656	#[non_exhaustive]
657	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
658	pub struct Builder {
659		pub(crate) game_id: std::option::Option<std::string::String>,
660		pub(crate) name_id: std::option::Option<std::string::String>,
661		pub(crate) display_name: std::option::Option<std::string::String>,
662		pub(crate) logo_url: std::option::Option<std::string::String>,
663		pub(crate) banner_url: std::option::Option<std::string::String>,
664	}
665	impl Builder {
666		/// A universally unique identifier.
667		pub fn game_id(mut self, input: impl Into<std::string::String>) -> Self {
668			self.game_id = Some(input.into());
669			self
670		}
671		/// A universally unique identifier.
672		pub fn set_game_id(mut self, input: std::option::Option<std::string::String>) -> Self {
673			self.game_id = input;
674			self
675		}
676		/// A human readable short identifier used to references resources. Different than a `rivet.common#Uuid` because this is intended to be human readable. Different than `rivet.common#DisplayName` because this should not include special characters and be short.
677		pub fn name_id(mut self, input: impl Into<std::string::String>) -> Self {
678			self.name_id = Some(input.into());
679			self
680		}
681		/// A human readable short identifier used to references resources. Different than a `rivet.common#Uuid` because this is intended to be human readable. Different than `rivet.common#DisplayName` because this should not include special characters and be short.
682		pub fn set_name_id(mut self, input: std::option::Option<std::string::String>) -> Self {
683			self.name_id = input;
684			self
685		}
686		/// Represent a resource's readable display name.
687		pub fn display_name(mut self, input: impl Into<std::string::String>) -> Self {
688			self.display_name = Some(input.into());
689			self
690		}
691		/// Represent a resource's readable display name.
692		pub fn set_display_name(mut self, input: std::option::Option<std::string::String>) -> Self {
693			self.display_name = input;
694			self
695		}
696		/// The URL of this game's logo image.
697		pub fn logo_url(mut self, input: impl Into<std::string::String>) -> Self {
698			self.logo_url = Some(input.into());
699			self
700		}
701		/// The URL of this game's logo image.
702		pub fn set_logo_url(mut self, input: std::option::Option<std::string::String>) -> Self {
703			self.logo_url = input;
704			self
705		}
706		/// The URL of this game's banner image.
707		pub fn banner_url(mut self, input: impl Into<std::string::String>) -> Self {
708			self.banner_url = Some(input.into());
709			self
710		}
711		/// The URL of this game's banner image.
712		pub fn set_banner_url(mut self, input: std::option::Option<std::string::String>) -> Self {
713			self.banner_url = input;
714			self
715		}
716		/// Consumes the builder and constructs a [`GameHandle`](crate::model::GameHandle)
717		pub fn build(self) -> crate::model::GameHandle {
718			crate::model::GameHandle {
719				game_id: self.game_id,
720				name_id: self.name_id,
721				display_name: self.display_name,
722				logo_url: self.logo_url,
723				banner_url: self.banner_url,
724			}
725		}
726	}
727}
728impl GameHandle {
729	/// Creates a new builder-style object to manufacture [`GameHandle`](crate::model::GameHandle)
730	pub fn builder() -> crate::model::game_handle::Builder {
731		crate::model::game_handle::Builder::default()
732	}
733}
734
735/// A party lobby.
736#[non_exhaustive]
737#[derive(std::clone::Clone, std::cmp::PartialEq)]
738pub struct PartyMatchmakerLobby {
739	/// A universally unique identifier.
740	pub lobby_id: std::option::Option<std::string::String>,
741}
742impl PartyMatchmakerLobby {
743	/// A universally unique identifier.
744	pub fn lobby_id(&self) -> std::option::Option<&str> {
745		self.lobby_id.as_deref()
746	}
747}
748impl std::fmt::Debug for PartyMatchmakerLobby {
749	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
750		let mut formatter = f.debug_struct("PartyMatchmakerLobby");
751		formatter.field("lobby_id", &self.lobby_id);
752		formatter.finish()
753	}
754}
755/// See [`PartyMatchmakerLobby`](crate::model::PartyMatchmakerLobby)
756pub mod party_matchmaker_lobby {
757	/// A builder for [`PartyMatchmakerLobby`](crate::model::PartyMatchmakerLobby)
758	#[non_exhaustive]
759	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
760	pub struct Builder {
761		pub(crate) lobby_id: std::option::Option<std::string::String>,
762	}
763	impl Builder {
764		/// A universally unique identifier.
765		pub fn lobby_id(mut self, input: impl Into<std::string::String>) -> Self {
766			self.lobby_id = Some(input.into());
767			self
768		}
769		/// A universally unique identifier.
770		pub fn set_lobby_id(mut self, input: std::option::Option<std::string::String>) -> Self {
771			self.lobby_id = input;
772			self
773		}
774		/// Consumes the builder and constructs a [`PartyMatchmakerLobby`](crate::model::PartyMatchmakerLobby)
775		pub fn build(self) -> crate::model::PartyMatchmakerLobby {
776			crate::model::PartyMatchmakerLobby {
777				lobby_id: self.lobby_id,
778			}
779		}
780	}
781}
782impl PartyMatchmakerLobby {
783	/// Creates a new builder-style object to manufacture [`PartyMatchmakerLobby`](crate::model::PartyMatchmakerLobby)
784	pub fn builder() -> crate::model::party_matchmaker_lobby::Builder {
785		crate::model::party_matchmaker_lobby::Builder::default()
786	}
787}
788
789/// A party activity denoting that the party is currently searching for a lobby.
790#[non_exhaustive]
791#[derive(std::clone::Clone, std::cmp::PartialEq)]
792pub struct PartyActivityMatchmakerFindingLobby {
793	/// A game handle.
794	pub game: std::option::Option<crate::model::GameHandle>,
795}
796impl PartyActivityMatchmakerFindingLobby {
797	/// A game handle.
798	pub fn game(&self) -> std::option::Option<&crate::model::GameHandle> {
799		self.game.as_ref()
800	}
801}
802impl std::fmt::Debug for PartyActivityMatchmakerFindingLobby {
803	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
804		let mut formatter = f.debug_struct("PartyActivityMatchmakerFindingLobby");
805		formatter.field("game", &self.game);
806		formatter.finish()
807	}
808}
809/// See [`PartyActivityMatchmakerFindingLobby`](crate::model::PartyActivityMatchmakerFindingLobby)
810pub mod party_activity_matchmaker_finding_lobby {
811	/// A builder for [`PartyActivityMatchmakerFindingLobby`](crate::model::PartyActivityMatchmakerFindingLobby)
812	#[non_exhaustive]
813	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
814	pub struct Builder {
815		pub(crate) game: std::option::Option<crate::model::GameHandle>,
816	}
817	impl Builder {
818		/// A game handle.
819		pub fn game(mut self, input: crate::model::GameHandle) -> Self {
820			self.game = Some(input);
821			self
822		}
823		/// A game handle.
824		pub fn set_game(mut self, input: std::option::Option<crate::model::GameHandle>) -> Self {
825			self.game = input;
826			self
827		}
828		/// Consumes the builder and constructs a [`PartyActivityMatchmakerFindingLobby`](crate::model::PartyActivityMatchmakerFindingLobby)
829		pub fn build(self) -> crate::model::PartyActivityMatchmakerFindingLobby {
830			crate::model::PartyActivityMatchmakerFindingLobby { game: self.game }
831		}
832	}
833}
834impl PartyActivityMatchmakerFindingLobby {
835	/// Creates a new builder-style object to manufacture [`PartyActivityMatchmakerFindingLobby`](crate::model::PartyActivityMatchmakerFindingLobby)
836	pub fn builder() -> crate::model::party_activity_matchmaker_finding_lobby::Builder {
837		crate::model::party_activity_matchmaker_finding_lobby::Builder::default()
838	}
839}
840
841/// A party activity denoting that the party is idle.
842#[non_exhaustive]
843#[derive(std::clone::Clone, std::cmp::PartialEq)]
844pub struct PartyActivityIdle {}
845impl std::fmt::Debug for PartyActivityIdle {
846	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
847		let mut formatter = f.debug_struct("PartyActivityIdle");
848		formatter.finish()
849	}
850}
851/// See [`PartyActivityIdle`](crate::model::PartyActivityIdle)
852pub mod party_activity_idle {
853	/// A builder for [`PartyActivityIdle`](crate::model::PartyActivityIdle)
854	#[non_exhaustive]
855	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
856	pub struct Builder {}
857	impl Builder {
858		/// Consumes the builder and constructs a [`PartyActivityIdle`](crate::model::PartyActivityIdle)
859		pub fn build(self) -> crate::model::PartyActivityIdle {
860			crate::model::PartyActivityIdle {}
861		}
862	}
863}
864impl PartyActivityIdle {
865	/// Creates a new builder-style object to manufacture [`PartyActivityIdle`](crate::model::PartyActivityIdle)
866	pub fn builder() -> crate::model::party_activity_idle::Builder {
867		crate::model::party_activity_idle::Builder::default()
868	}
869}
870
871/// Information about the identity's current status, party, and active game.
872#[non_exhaustive]
873#[derive(std::clone::Clone, std::cmp::PartialEq)]
874pub struct IdentityPresence {
875	/// RFC3339 timestamp.
876	pub update_ts: std::option::Option<aws_smithy_types::DateTime>,
877	/// The current status of an identity. This helps players understand if another player is currently playing or has their game in the background.
878	pub status: std::option::Option<crate::model::IdentityStatus>,
879	/// The game an identity is currently participating in.
880	pub game_activity: std::option::Option<crate::model::IdentityGameActivity>,
881}
882impl IdentityPresence {
883	/// RFC3339 timestamp.
884	pub fn update_ts(&self) -> std::option::Option<&aws_smithy_types::DateTime> {
885		self.update_ts.as_ref()
886	}
887	/// The current status of an identity. This helps players understand if another player is currently playing or has their game in the background.
888	pub fn status(&self) -> std::option::Option<&crate::model::IdentityStatus> {
889		self.status.as_ref()
890	}
891	/// The game an identity is currently participating in.
892	pub fn game_activity(&self) -> std::option::Option<&crate::model::IdentityGameActivity> {
893		self.game_activity.as_ref()
894	}
895}
896impl std::fmt::Debug for IdentityPresence {
897	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
898		let mut formatter = f.debug_struct("IdentityPresence");
899		formatter.field("update_ts", &self.update_ts);
900		formatter.field("status", &self.status);
901		formatter.field("game_activity", &self.game_activity);
902		formatter.finish()
903	}
904}
905/// See [`IdentityPresence`](crate::model::IdentityPresence)
906pub mod identity_presence {
907	/// A builder for [`IdentityPresence`](crate::model::IdentityPresence)
908	#[non_exhaustive]
909	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
910	pub struct Builder {
911		pub(crate) update_ts: std::option::Option<aws_smithy_types::DateTime>,
912		pub(crate) status: std::option::Option<crate::model::IdentityStatus>,
913		pub(crate) game_activity: std::option::Option<crate::model::IdentityGameActivity>,
914	}
915	impl Builder {
916		/// RFC3339 timestamp.
917		pub fn update_ts(mut self, input: aws_smithy_types::DateTime) -> Self {
918			self.update_ts = Some(input);
919			self
920		}
921		/// RFC3339 timestamp.
922		pub fn set_update_ts(
923			mut self,
924			input: std::option::Option<aws_smithy_types::DateTime>,
925		) -> Self {
926			self.update_ts = input;
927			self
928		}
929		/// The current status of an identity. This helps players understand if another player is currently playing or has their game in the background.
930		pub fn status(mut self, input: crate::model::IdentityStatus) -> Self {
931			self.status = Some(input);
932			self
933		}
934		/// The current status of an identity. This helps players understand if another player is currently playing or has their game in the background.
935		pub fn set_status(
936			mut self,
937			input: std::option::Option<crate::model::IdentityStatus>,
938		) -> Self {
939			self.status = input;
940			self
941		}
942		/// The game an identity is currently participating in.
943		pub fn game_activity(mut self, input: crate::model::IdentityGameActivity) -> Self {
944			self.game_activity = Some(input);
945			self
946		}
947		/// The game an identity is currently participating in.
948		pub fn set_game_activity(
949			mut self,
950			input: std::option::Option<crate::model::IdentityGameActivity>,
951		) -> Self {
952			self.game_activity = input;
953			self
954		}
955		/// Consumes the builder and constructs a [`IdentityPresence`](crate::model::IdentityPresence)
956		pub fn build(self) -> crate::model::IdentityPresence {
957			crate::model::IdentityPresence {
958				update_ts: self.update_ts,
959				status: self.status,
960				game_activity: self.game_activity,
961			}
962		}
963	}
964}
965impl IdentityPresence {
966	/// Creates a new builder-style object to manufacture [`IdentityPresence`](crate::model::IdentityPresence)
967	pub fn builder() -> crate::model::identity_presence::Builder {
968		crate::model::identity_presence::Builder::default()
969	}
970}
971
972/// The game an identity is currently participating in.
973#[non_exhaustive]
974#[derive(std::clone::Clone, std::cmp::PartialEq)]
975pub struct IdentityGameActivity {
976	/// A game handle.
977	pub game: std::option::Option<crate::model::GameHandle>,
978	/// A short activity message about the current game activity.
979	pub message: std::option::Option<std::string::String>,
980	/// JSON data seen by anyone.
981	pub public_metadata: std::option::Option<aws_smithy_types::Document>,
982	/// JSON data seen only by the given identity and their mutual followers.
983	pub mutual_metadata: std::option::Option<aws_smithy_types::Document>,
984}
985impl IdentityGameActivity {
986	/// A game handle.
987	pub fn game(&self) -> std::option::Option<&crate::model::GameHandle> {
988		self.game.as_ref()
989	}
990	/// A short activity message about the current game activity.
991	pub fn message(&self) -> std::option::Option<&str> {
992		self.message.as_deref()
993	}
994	/// JSON data seen by anyone.
995	pub fn public_metadata(&self) -> std::option::Option<&aws_smithy_types::Document> {
996		self.public_metadata.as_ref()
997	}
998	/// JSON data seen only by the given identity and their mutual followers.
999	pub fn mutual_metadata(&self) -> std::option::Option<&aws_smithy_types::Document> {
1000		self.mutual_metadata.as_ref()
1001	}
1002}
1003impl std::fmt::Debug for IdentityGameActivity {
1004	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
1005		let mut formatter = f.debug_struct("IdentityGameActivity");
1006		formatter.field("game", &self.game);
1007		formatter.field("message", &self.message);
1008		formatter.field("public_metadata", &self.public_metadata);
1009		formatter.field("mutual_metadata", &self.mutual_metadata);
1010		formatter.finish()
1011	}
1012}
1013/// See [`IdentityGameActivity`](crate::model::IdentityGameActivity)
1014pub mod identity_game_activity {
1015	/// A builder for [`IdentityGameActivity`](crate::model::IdentityGameActivity)
1016	#[non_exhaustive]
1017	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
1018	pub struct Builder {
1019		pub(crate) game: std::option::Option<crate::model::GameHandle>,
1020		pub(crate) message: std::option::Option<std::string::String>,
1021		pub(crate) public_metadata: std::option::Option<aws_smithy_types::Document>,
1022		pub(crate) mutual_metadata: std::option::Option<aws_smithy_types::Document>,
1023	}
1024	impl Builder {
1025		/// A game handle.
1026		pub fn game(mut self, input: crate::model::GameHandle) -> Self {
1027			self.game = Some(input);
1028			self
1029		}
1030		/// A game handle.
1031		pub fn set_game(mut self, input: std::option::Option<crate::model::GameHandle>) -> Self {
1032			self.game = input;
1033			self
1034		}
1035		/// A short activity message about the current game activity.
1036		pub fn message(mut self, input: impl Into<std::string::String>) -> Self {
1037			self.message = Some(input.into());
1038			self
1039		}
1040		/// A short activity message about the current game activity.
1041		pub fn set_message(mut self, input: std::option::Option<std::string::String>) -> Self {
1042			self.message = input;
1043			self
1044		}
1045		/// JSON data seen by anyone.
1046		pub fn public_metadata(mut self, input: aws_smithy_types::Document) -> Self {
1047			self.public_metadata = Some(input);
1048			self
1049		}
1050		/// JSON data seen by anyone.
1051		pub fn set_public_metadata(
1052			mut self,
1053			input: std::option::Option<aws_smithy_types::Document>,
1054		) -> Self {
1055			self.public_metadata = input;
1056			self
1057		}
1058		/// JSON data seen only by the given identity and their mutual followers.
1059		pub fn mutual_metadata(mut self, input: aws_smithy_types::Document) -> Self {
1060			self.mutual_metadata = Some(input);
1061			self
1062		}
1063		/// JSON data seen only by the given identity and their mutual followers.
1064		pub fn set_mutual_metadata(
1065			mut self,
1066			input: std::option::Option<aws_smithy_types::Document>,
1067		) -> Self {
1068			self.mutual_metadata = input;
1069			self
1070		}
1071		/// Consumes the builder and constructs a [`IdentityGameActivity`](crate::model::IdentityGameActivity)
1072		pub fn build(self) -> crate::model::IdentityGameActivity {
1073			crate::model::IdentityGameActivity {
1074				game: self.game,
1075				message: self.message,
1076				public_metadata: self.public_metadata,
1077				mutual_metadata: self.mutual_metadata,
1078			}
1079		}
1080	}
1081}
1082impl IdentityGameActivity {
1083	/// Creates a new builder-style object to manufacture [`IdentityGameActivity`](crate::model::IdentityGameActivity)
1084	pub fn builder() -> crate::model::identity_game_activity::Builder {
1085		crate::model::identity_game_activity::Builder::default()
1086	}
1087}
1088
1089/// The current status of an identity. This helps players understand if another
1090/// player is currently playing or has their game in the background.
1091#[non_exhaustive]
1092#[derive(
1093	std::clone::Clone,
1094	std::cmp::Eq,
1095	std::cmp::Ord,
1096	std::cmp::PartialEq,
1097	std::cmp::PartialOrd,
1098	std::fmt::Debug,
1099	std::hash::Hash,
1100)]
1101pub enum IdentityStatus {
1102	#[allow(missing_docs)] // documentation missing in model
1103	Away,
1104	#[allow(missing_docs)] // documentation missing in model
1105	Offline,
1106	#[allow(missing_docs)] // documentation missing in model
1107	Online,
1108	/// Unknown contains new variants that have been added since this code was generated.
1109	Unknown(String),
1110}
1111impl std::convert::From<&str> for IdentityStatus {
1112	fn from(s: &str) -> Self {
1113		match s {
1114			"away" => IdentityStatus::Away,
1115			"offline" => IdentityStatus::Offline,
1116			"online" => IdentityStatus::Online,
1117			other => IdentityStatus::Unknown(other.to_owned()),
1118		}
1119	}
1120}
1121impl std::str::FromStr for IdentityStatus {
1122	type Err = std::convert::Infallible;
1123
1124	fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
1125		Ok(IdentityStatus::from(s))
1126	}
1127}
1128impl IdentityStatus {
1129	/// Returns the `&str` value of the enum member.
1130	pub fn as_str(&self) -> &str {
1131		match self {
1132			IdentityStatus::Away => "away",
1133			IdentityStatus::Offline => "offline",
1134			IdentityStatus::Online => "online",
1135			IdentityStatus::Unknown(s) => s.as_ref(),
1136		}
1137	}
1138	/// Returns all the `&str` values of the enum members.
1139	pub fn values() -> &'static [&'static str] {
1140		&["away", "offline", "online"]
1141	}
1142}
1143impl AsRef<str> for IdentityStatus {
1144	fn as_ref(&self) -> &str {
1145		self.as_str()
1146	}
1147}
1148
1149/// Data to send in a chat message.
1150#[non_exhaustive]
1151#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
1152pub enum SendMessageBody {
1153	/// `SendMessageBody` variant for party invite messages. Cannot send to party topics.
1154	PartyInvite(crate::model::SendMessageBodyPartyInvite),
1155	/// `rivet.api.chat.common#SendMessageBody` variant for text messages.
1156	Text(crate::model::SendMessageBodyText),
1157	/// The `Unknown` variant represents cases where new union variant was received. Consider upgrading the SDK to the latest available version.
1158	/// An unknown enum variant
1159	///
1160	/// _Note: If you encounter this error, consider upgrading your SDK to the latest version._
1161	/// The `Unknown` variant represents cases where the server sent a value that wasn't recognized
1162	/// by the client. This can happen when the server adds new functionality, but the client has not been updated.
1163	/// To investigate this, consider turning on debug logging to print the raw HTTP response.
1164	#[non_exhaustive]
1165	Unknown,
1166}
1167impl SendMessageBody {
1168	/// Tries to convert the enum instance into [`PartyInvite`](crate::model::SendMessageBody::PartyInvite), extracting the inner [`SendMessageBodyPartyInvite`](crate::model::SendMessageBodyPartyInvite).
1169	/// Returns `Err(&Self)` if it can't be converted.
1170	pub fn as_party_invite(
1171		&self,
1172	) -> std::result::Result<&crate::model::SendMessageBodyPartyInvite, &Self> {
1173		if let SendMessageBody::PartyInvite(val) = &self {
1174			Ok(val)
1175		} else {
1176			Err(self)
1177		}
1178	}
1179	/// Returns true if this is a [`PartyInvite`](crate::model::SendMessageBody::PartyInvite).
1180	pub fn is_party_invite(&self) -> bool {
1181		self.as_party_invite().is_ok()
1182	}
1183	/// Tries to convert the enum instance into [`Text`](crate::model::SendMessageBody::Text), extracting the inner [`SendMessageBodyText`](crate::model::SendMessageBodyText).
1184	/// Returns `Err(&Self)` if it can't be converted.
1185	pub fn as_text(&self) -> std::result::Result<&crate::model::SendMessageBodyText, &Self> {
1186		if let SendMessageBody::Text(val) = &self {
1187			Ok(val)
1188		} else {
1189			Err(self)
1190		}
1191	}
1192	/// Returns true if this is a [`Text`](crate::model::SendMessageBody::Text).
1193	pub fn is_text(&self) -> bool {
1194		self.as_text().is_ok()
1195	}
1196	/// Returns true if the enum instance is the `Unknown` variant.
1197	pub fn is_unknown(&self) -> bool {
1198		matches!(self, Self::Unknown)
1199	}
1200}
1201
1202/// `SendMessageBody` variant for party invite messages. Cannot send to party topics.
1203#[non_exhaustive]
1204#[derive(std::clone::Clone, std::cmp::PartialEq)]
1205pub struct SendMessageBodyPartyInvite {
1206	/// An invite token.
1207	pub token: std::option::Option<std::string::String>,
1208}
1209impl SendMessageBodyPartyInvite {
1210	/// An invite token.
1211	pub fn token(&self) -> std::option::Option<&str> {
1212		self.token.as_deref()
1213	}
1214}
1215impl std::fmt::Debug for SendMessageBodyPartyInvite {
1216	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
1217		let mut formatter = f.debug_struct("SendMessageBodyPartyInvite");
1218		formatter.field("token", &"*** Sensitive Data Redacted ***");
1219		formatter.finish()
1220	}
1221}
1222/// See [`SendMessageBodyPartyInvite`](crate::model::SendMessageBodyPartyInvite)
1223pub mod send_message_body_party_invite {
1224	/// A builder for [`SendMessageBodyPartyInvite`](crate::model::SendMessageBodyPartyInvite)
1225	#[non_exhaustive]
1226	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
1227	pub struct Builder {
1228		pub(crate) token: std::option::Option<std::string::String>,
1229	}
1230	impl Builder {
1231		/// An invite token.
1232		pub fn token(mut self, input: impl Into<std::string::String>) -> Self {
1233			self.token = Some(input.into());
1234			self
1235		}
1236		/// An invite token.
1237		pub fn set_token(mut self, input: std::option::Option<std::string::String>) -> Self {
1238			self.token = input;
1239			self
1240		}
1241		/// Consumes the builder and constructs a [`SendMessageBodyPartyInvite`](crate::model::SendMessageBodyPartyInvite)
1242		pub fn build(self) -> crate::model::SendMessageBodyPartyInvite {
1243			crate::model::SendMessageBodyPartyInvite { token: self.token }
1244		}
1245	}
1246}
1247impl SendMessageBodyPartyInvite {
1248	/// Creates a new builder-style object to manufacture [`SendMessageBodyPartyInvite`](crate::model::SendMessageBodyPartyInvite)
1249	pub fn builder() -> crate::model::send_message_body_party_invite::Builder {
1250		crate::model::send_message_body_party_invite::Builder::default()
1251	}
1252}
1253
1254/// `rivet.api.chat.common#SendMessageBody` variant for text messages.
1255#[non_exhaustive]
1256#[derive(std::clone::Clone, std::cmp::PartialEq)]
1257pub struct SendMessageBodyText {
1258	#[allow(missing_docs)] // documentation missing in model
1259	pub body: std::option::Option<std::string::String>,
1260}
1261impl SendMessageBodyText {
1262	#[allow(missing_docs)] // documentation missing in model
1263	pub fn body(&self) -> std::option::Option<&str> {
1264		self.body.as_deref()
1265	}
1266}
1267impl std::fmt::Debug for SendMessageBodyText {
1268	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
1269		let mut formatter = f.debug_struct("SendMessageBodyText");
1270		formatter.field("body", &self.body);
1271		formatter.finish()
1272	}
1273}
1274/// See [`SendMessageBodyText`](crate::model::SendMessageBodyText)
1275pub mod send_message_body_text {
1276	/// A builder for [`SendMessageBodyText`](crate::model::SendMessageBodyText)
1277	#[non_exhaustive]
1278	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
1279	pub struct Builder {
1280		pub(crate) body: std::option::Option<std::string::String>,
1281	}
1282	impl Builder {
1283		#[allow(missing_docs)] // documentation missing in model
1284		pub fn body(mut self, input: impl Into<std::string::String>) -> Self {
1285			self.body = Some(input.into());
1286			self
1287		}
1288		#[allow(missing_docs)] // documentation missing in model
1289		pub fn set_body(mut self, input: std::option::Option<std::string::String>) -> Self {
1290			self.body = input;
1291			self
1292		}
1293		/// Consumes the builder and constructs a [`SendMessageBodyText`](crate::model::SendMessageBodyText)
1294		pub fn build(self) -> crate::model::SendMessageBodyText {
1295			crate::model::SendMessageBodyText { body: self.body }
1296		}
1297	}
1298}
1299impl SendMessageBodyText {
1300	/// Creates a new builder-style object to manufacture [`SendMessageBodyText`](crate::model::SendMessageBodyText)
1301	pub fn builder() -> crate::model::send_message_body_text::Builder {
1302		crate::model::send_message_body_text::Builder::default()
1303	}
1304}
1305
1306/// Topic to send a chat message to. If you already know the thread ID, use `thread_id`.
1307#[non_exhaustive]
1308#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
1309pub enum SendChatTopic {
1310	/// A universally unique identifier.
1311	GroupId(std::string::String),
1312	/// A universally unique identifier.
1313	IdentityId(std::string::String),
1314	/// A universally unique identifier.
1315	PartyId(std::string::String),
1316	/// A universally unique identifier.
1317	ThreadId(std::string::String),
1318	/// The `Unknown` variant represents cases where new union variant was received. Consider upgrading the SDK to the latest available version.
1319	/// An unknown enum variant
1320	///
1321	/// _Note: If you encounter this error, consider upgrading your SDK to the latest version._
1322	/// The `Unknown` variant represents cases where the server sent a value that wasn't recognized
1323	/// by the client. This can happen when the server adds new functionality, but the client has not been updated.
1324	/// To investigate this, consider turning on debug logging to print the raw HTTP response.
1325	#[non_exhaustive]
1326	Unknown,
1327}
1328impl SendChatTopic {
1329	/// Tries to convert the enum instance into [`GroupId`](crate::model::SendChatTopic::GroupId), extracting the inner [`String`](std::string::String).
1330	/// Returns `Err(&Self)` if it can't be converted.
1331	pub fn as_group_id(&self) -> std::result::Result<&std::string::String, &Self> {
1332		if let SendChatTopic::GroupId(val) = &self {
1333			Ok(val)
1334		} else {
1335			Err(self)
1336		}
1337	}
1338	/// Returns true if this is a [`GroupId`](crate::model::SendChatTopic::GroupId).
1339	pub fn is_group_id(&self) -> bool {
1340		self.as_group_id().is_ok()
1341	}
1342	/// Tries to convert the enum instance into [`IdentityId`](crate::model::SendChatTopic::IdentityId), extracting the inner [`String`](std::string::String).
1343	/// Returns `Err(&Self)` if it can't be converted.
1344	pub fn as_identity_id(&self) -> std::result::Result<&std::string::String, &Self> {
1345		if let SendChatTopic::IdentityId(val) = &self {
1346			Ok(val)
1347		} else {
1348			Err(self)
1349		}
1350	}
1351	/// Returns true if this is a [`IdentityId`](crate::model::SendChatTopic::IdentityId).
1352	pub fn is_identity_id(&self) -> bool {
1353		self.as_identity_id().is_ok()
1354	}
1355	/// Tries to convert the enum instance into [`PartyId`](crate::model::SendChatTopic::PartyId), extracting the inner [`String`](std::string::String).
1356	/// Returns `Err(&Self)` if it can't be converted.
1357	pub fn as_party_id(&self) -> std::result::Result<&std::string::String, &Self> {
1358		if let SendChatTopic::PartyId(val) = &self {
1359			Ok(val)
1360		} else {
1361			Err(self)
1362		}
1363	}
1364	/// Returns true if this is a [`PartyId`](crate::model::SendChatTopic::PartyId).
1365	pub fn is_party_id(&self) -> bool {
1366		self.as_party_id().is_ok()
1367	}
1368	/// Tries to convert the enum instance into [`ThreadId`](crate::model::SendChatTopic::ThreadId), extracting the inner [`String`](std::string::String).
1369	/// Returns `Err(&Self)` if it can't be converted.
1370	pub fn as_thread_id(&self) -> std::result::Result<&std::string::String, &Self> {
1371		if let SendChatTopic::ThreadId(val) = &self {
1372			Ok(val)
1373		} else {
1374			Err(self)
1375		}
1376	}
1377	/// Returns true if this is a [`ThreadId`](crate::model::SendChatTopic::ThreadId).
1378	pub fn is_thread_id(&self) -> bool {
1379		self.as_thread_id().is_ok()
1380	}
1381	/// Returns true if the enum instance is the `Unknown` variant.
1382	pub fn is_unknown(&self) -> bool {
1383		matches!(self, Self::Unknown)
1384	}
1385}
1386
1387/// Represents a chat typing status.
1388#[non_exhaustive]
1389#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
1390pub enum ChatTypingStatus {
1391	/// Not typing.
1392	Idle(crate::model::Unit),
1393	/// Typing.
1394	Typing(crate::model::Unit),
1395	/// The `Unknown` variant represents cases where new union variant was received. Consider upgrading the SDK to the latest available version.
1396	/// An unknown enum variant
1397	///
1398	/// _Note: If you encounter this error, consider upgrading your SDK to the latest version._
1399	/// The `Unknown` variant represents cases where the server sent a value that wasn't recognized
1400	/// by the client. This can happen when the server adds new functionality, but the client has not been updated.
1401	/// To investigate this, consider turning on debug logging to print the raw HTTP response.
1402	#[non_exhaustive]
1403	Unknown,
1404}
1405impl ChatTypingStatus {
1406	/// Tries to convert the enum instance into [`Idle`](crate::model::ChatTypingStatus::Idle), extracting the inner [`Unit`](crate::model::Unit).
1407	/// Returns `Err(&Self)` if it can't be converted.
1408	pub fn as_idle(&self) -> std::result::Result<&crate::model::Unit, &Self> {
1409		if let ChatTypingStatus::Idle(val) = &self {
1410			Ok(val)
1411		} else {
1412			Err(self)
1413		}
1414	}
1415	/// Returns true if this is a [`Idle`](crate::model::ChatTypingStatus::Idle).
1416	pub fn is_idle(&self) -> bool {
1417		self.as_idle().is_ok()
1418	}
1419	/// Tries to convert the enum instance into [`Typing`](crate::model::ChatTypingStatus::Typing), extracting the inner [`Unit`](crate::model::Unit).
1420	/// Returns `Err(&Self)` if it can't be converted.
1421	pub fn as_typing(&self) -> std::result::Result<&crate::model::Unit, &Self> {
1422		if let ChatTypingStatus::Typing(val) = &self {
1423			Ok(val)
1424		} else {
1425			Err(self)
1426		}
1427	}
1428	/// Returns true if this is a [`Typing`](crate::model::ChatTypingStatus::Typing).
1429	pub fn is_typing(&self) -> bool {
1430		self.as_typing().is_ok()
1431	}
1432	/// Returns true if the enum instance is the `Unknown` variant.
1433	pub fn is_unknown(&self) -> bool {
1434		matches!(self, Self::Unknown)
1435	}
1436}
1437
1438#[allow(missing_docs)] // documentation missing in model
1439#[non_exhaustive]
1440#[derive(std::clone::Clone, std::cmp::PartialEq)]
1441pub struct Unit {}
1442impl std::fmt::Debug for Unit {
1443	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
1444		let mut formatter = f.debug_struct("Unit");
1445		formatter.finish()
1446	}
1447}
1448/// See [`Unit`](crate::model::Unit)
1449pub mod unit {
1450	/// A builder for [`Unit`](crate::model::Unit)
1451	#[non_exhaustive]
1452	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
1453	pub struct Builder {}
1454	impl Builder {
1455		/// Consumes the builder and constructs a [`Unit`](crate::model::Unit)
1456		pub fn build(self) -> crate::model::Unit {
1457			crate::model::Unit {}
1458		}
1459	}
1460}
1461impl Unit {
1462	/// Creates a new builder-style object to manufacture [`Unit`](crate::model::Unit)
1463	pub fn builder() -> crate::model::unit::Builder {
1464		crate::model::unit::Builder::default()
1465	}
1466}
1467
1468/// A chat message.
1469#[non_exhaustive]
1470#[derive(std::clone::Clone, std::cmp::PartialEq)]
1471pub struct ChatMessage {
1472	/// A universally unique identifier.
1473	pub chat_message_id: std::option::Option<std::string::String>,
1474	/// A universally unique identifier.
1475	pub thread_id: std::option::Option<std::string::String>,
1476	/// RFC3339 timestamp.
1477	pub send_ts: std::option::Option<aws_smithy_types::DateTime>,
1478	/// Represents types of chat message bodies.
1479	pub body: std::option::Option<crate::model::ChatMessageBody>,
1480}
1481impl ChatMessage {
1482	/// A universally unique identifier.
1483	pub fn chat_message_id(&self) -> std::option::Option<&str> {
1484		self.chat_message_id.as_deref()
1485	}
1486	/// A universally unique identifier.
1487	pub fn thread_id(&self) -> std::option::Option<&str> {
1488		self.thread_id.as_deref()
1489	}
1490	/// RFC3339 timestamp.
1491	pub fn send_ts(&self) -> std::option::Option<&aws_smithy_types::DateTime> {
1492		self.send_ts.as_ref()
1493	}
1494	/// Represents types of chat message bodies.
1495	pub fn body(&self) -> std::option::Option<&crate::model::ChatMessageBody> {
1496		self.body.as_ref()
1497	}
1498}
1499impl std::fmt::Debug for ChatMessage {
1500	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
1501		let mut formatter = f.debug_struct("ChatMessage");
1502		formatter.field("chat_message_id", &self.chat_message_id);
1503		formatter.field("thread_id", &self.thread_id);
1504		formatter.field("send_ts", &self.send_ts);
1505		formatter.field("body", &self.body);
1506		formatter.finish()
1507	}
1508}
1509/// See [`ChatMessage`](crate::model::ChatMessage)
1510pub mod chat_message {
1511	/// A builder for [`ChatMessage`](crate::model::ChatMessage)
1512	#[non_exhaustive]
1513	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
1514	pub struct Builder {
1515		pub(crate) chat_message_id: std::option::Option<std::string::String>,
1516		pub(crate) thread_id: std::option::Option<std::string::String>,
1517		pub(crate) send_ts: std::option::Option<aws_smithy_types::DateTime>,
1518		pub(crate) body: std::option::Option<crate::model::ChatMessageBody>,
1519	}
1520	impl Builder {
1521		/// A universally unique identifier.
1522		pub fn chat_message_id(mut self, input: impl Into<std::string::String>) -> Self {
1523			self.chat_message_id = Some(input.into());
1524			self
1525		}
1526		/// A universally unique identifier.
1527		pub fn set_chat_message_id(
1528			mut self,
1529			input: std::option::Option<std::string::String>,
1530		) -> Self {
1531			self.chat_message_id = input;
1532			self
1533		}
1534		/// A universally unique identifier.
1535		pub fn thread_id(mut self, input: impl Into<std::string::String>) -> Self {
1536			self.thread_id = Some(input.into());
1537			self
1538		}
1539		/// A universally unique identifier.
1540		pub fn set_thread_id(mut self, input: std::option::Option<std::string::String>) -> Self {
1541			self.thread_id = input;
1542			self
1543		}
1544		/// RFC3339 timestamp.
1545		pub fn send_ts(mut self, input: aws_smithy_types::DateTime) -> Self {
1546			self.send_ts = Some(input);
1547			self
1548		}
1549		/// RFC3339 timestamp.
1550		pub fn set_send_ts(
1551			mut self,
1552			input: std::option::Option<aws_smithy_types::DateTime>,
1553		) -> Self {
1554			self.send_ts = input;
1555			self
1556		}
1557		/// Represents types of chat message bodies.
1558		pub fn body(mut self, input: crate::model::ChatMessageBody) -> Self {
1559			self.body = Some(input);
1560			self
1561		}
1562		/// Represents types of chat message bodies.
1563		pub fn set_body(
1564			mut self,
1565			input: std::option::Option<crate::model::ChatMessageBody>,
1566		) -> Self {
1567			self.body = input;
1568			self
1569		}
1570		/// Consumes the builder and constructs a [`ChatMessage`](crate::model::ChatMessage)
1571		pub fn build(self) -> crate::model::ChatMessage {
1572			crate::model::ChatMessage {
1573				chat_message_id: self.chat_message_id,
1574				thread_id: self.thread_id,
1575				send_ts: self.send_ts,
1576				body: self.body,
1577			}
1578		}
1579	}
1580}
1581impl ChatMessage {
1582	/// Creates a new builder-style object to manufacture [`ChatMessage`](crate::model::ChatMessage)
1583	pub fn builder() -> crate::model::chat_message::Builder {
1584		crate::model::chat_message::Builder::default()
1585	}
1586}
1587
1588/// Represents types of chat message bodies.
1589#[non_exhaustive]
1590#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
1591pub enum ChatMessageBody {
1592	/// `rivet.chat#ChatMessageBody` variant for indicating a new chat was created.
1593	ChatCreate(crate::model::ChatMessageBodyChatCreate),
1594	/// `rivet.chat#ChatMessageBody` variant for indicating an identity joined the group.
1595	GroupJoin(crate::model::ChatMessageBodyGroupJoin),
1596	/// `rivet.chat#ChatMessageBody` variant for indicating an identity left the group.
1597	GroupLeave(crate::model::ChatMessageBodyGroupLeave),
1598	/// `rivet.chat#ChatMessageBody` variant for indicating an identity followed the identity.
1599	IdentityFollow(crate::model::ChatMessageBodyIdentityFollow),
1600	/// `rivet.chat#ChatMessageBody` variant for indicating a change in the party's current activity.
1601	PartyActivityChange(crate::model::ChatMessageBodyPartyActivityChange),
1602	/// `rivet.chat#ChatMessageBody` variant holding an a party invitation.
1603	PartyInvite(crate::model::ChatMessageBodyPartyInvite),
1604	/// `rivet.chat#ChatMessageBody` variant for indicating an identity joined the party.
1605	PartyJoin(crate::model::ChatMessageBodyPartyJoin),
1606	/// `rivet.chat#ChatMessageBody` variant for indicating an identity requesting to join your party.
1607	PartyJoinRequest(crate::model::ChatMessageBodyPartyJoinRequest),
1608	/// `rivet.chat#ChatMessageBody` variant for indicating an identity left the party.
1609	PartyLeave(crate::model::ChatMessageBodyPartyLeave),
1610	/// `rivet.chat#ChatMessageBody` variant for text messages. Sent by other identities using the chat interface.
1611	Text(crate::model::ChatMessageBodyText),
1612	/// The `Unknown` variant represents cases where new union variant was received. Consider upgrading the SDK to the latest available version.
1613	/// An unknown enum variant
1614	///
1615	/// _Note: If you encounter this error, consider upgrading your SDK to the latest version._
1616	/// The `Unknown` variant represents cases where the server sent a value that wasn't recognized
1617	/// by the client. This can happen when the server adds new functionality, but the client has not been updated.
1618	/// To investigate this, consider turning on debug logging to print the raw HTTP response.
1619	#[non_exhaustive]
1620	Unknown,
1621}
1622impl ChatMessageBody {
1623	/// Tries to convert the enum instance into [`ChatCreate`](crate::model::ChatMessageBody::ChatCreate), extracting the inner [`ChatMessageBodyChatCreate`](crate::model::ChatMessageBodyChatCreate).
1624	/// Returns `Err(&Self)` if it can't be converted.
1625	pub fn as_chat_create(
1626		&self,
1627	) -> std::result::Result<&crate::model::ChatMessageBodyChatCreate, &Self> {
1628		if let ChatMessageBody::ChatCreate(val) = &self {
1629			Ok(val)
1630		} else {
1631			Err(self)
1632		}
1633	}
1634	/// Returns true if this is a [`ChatCreate`](crate::model::ChatMessageBody::ChatCreate).
1635	pub fn is_chat_create(&self) -> bool {
1636		self.as_chat_create().is_ok()
1637	}
1638	/// Tries to convert the enum instance into [`GroupJoin`](crate::model::ChatMessageBody::GroupJoin), extracting the inner [`ChatMessageBodyGroupJoin`](crate::model::ChatMessageBodyGroupJoin).
1639	/// Returns `Err(&Self)` if it can't be converted.
1640	pub fn as_group_join(
1641		&self,
1642	) -> std::result::Result<&crate::model::ChatMessageBodyGroupJoin, &Self> {
1643		if let ChatMessageBody::GroupJoin(val) = &self {
1644			Ok(val)
1645		} else {
1646			Err(self)
1647		}
1648	}
1649	/// Returns true if this is a [`GroupJoin`](crate::model::ChatMessageBody::GroupJoin).
1650	pub fn is_group_join(&self) -> bool {
1651		self.as_group_join().is_ok()
1652	}
1653	/// Tries to convert the enum instance into [`GroupLeave`](crate::model::ChatMessageBody::GroupLeave), extracting the inner [`ChatMessageBodyGroupLeave`](crate::model::ChatMessageBodyGroupLeave).
1654	/// Returns `Err(&Self)` if it can't be converted.
1655	pub fn as_group_leave(
1656		&self,
1657	) -> std::result::Result<&crate::model::ChatMessageBodyGroupLeave, &Self> {
1658		if let ChatMessageBody::GroupLeave(val) = &self {
1659			Ok(val)
1660		} else {
1661			Err(self)
1662		}
1663	}
1664	/// Returns true if this is a [`GroupLeave`](crate::model::ChatMessageBody::GroupLeave).
1665	pub fn is_group_leave(&self) -> bool {
1666		self.as_group_leave().is_ok()
1667	}
1668	/// Tries to convert the enum instance into [`IdentityFollow`](crate::model::ChatMessageBody::IdentityFollow), extracting the inner [`ChatMessageBodyIdentityFollow`](crate::model::ChatMessageBodyIdentityFollow).
1669	/// Returns `Err(&Self)` if it can't be converted.
1670	pub fn as_identity_follow(
1671		&self,
1672	) -> std::result::Result<&crate::model::ChatMessageBodyIdentityFollow, &Self> {
1673		if let ChatMessageBody::IdentityFollow(val) = &self {
1674			Ok(val)
1675		} else {
1676			Err(self)
1677		}
1678	}
1679	/// Returns true if this is a [`IdentityFollow`](crate::model::ChatMessageBody::IdentityFollow).
1680	pub fn is_identity_follow(&self) -> bool {
1681		self.as_identity_follow().is_ok()
1682	}
1683	/// Tries to convert the enum instance into [`PartyActivityChange`](crate::model::ChatMessageBody::PartyActivityChange), extracting the inner [`ChatMessageBodyPartyActivityChange`](crate::model::ChatMessageBodyPartyActivityChange).
1684	/// Returns `Err(&Self)` if it can't be converted.
1685	pub fn as_party_activity_change(
1686		&self,
1687	) -> std::result::Result<&crate::model::ChatMessageBodyPartyActivityChange, &Self> {
1688		if let ChatMessageBody::PartyActivityChange(val) = &self {
1689			Ok(val)
1690		} else {
1691			Err(self)
1692		}
1693	}
1694	/// Returns true if this is a [`PartyActivityChange`](crate::model::ChatMessageBody::PartyActivityChange).
1695	pub fn is_party_activity_change(&self) -> bool {
1696		self.as_party_activity_change().is_ok()
1697	}
1698	/// Tries to convert the enum instance into [`PartyInvite`](crate::model::ChatMessageBody::PartyInvite), extracting the inner [`ChatMessageBodyPartyInvite`](crate::model::ChatMessageBodyPartyInvite).
1699	/// Returns `Err(&Self)` if it can't be converted.
1700	pub fn as_party_invite(
1701		&self,
1702	) -> std::result::Result<&crate::model::ChatMessageBodyPartyInvite, &Self> {
1703		if let ChatMessageBody::PartyInvite(val) = &self {
1704			Ok(val)
1705		} else {
1706			Err(self)
1707		}
1708	}
1709	/// Returns true if this is a [`PartyInvite`](crate::model::ChatMessageBody::PartyInvite).
1710	pub fn is_party_invite(&self) -> bool {
1711		self.as_party_invite().is_ok()
1712	}
1713	/// Tries to convert the enum instance into [`PartyJoin`](crate::model::ChatMessageBody::PartyJoin), extracting the inner [`ChatMessageBodyPartyJoin`](crate::model::ChatMessageBodyPartyJoin).
1714	/// Returns `Err(&Self)` if it can't be converted.
1715	pub fn as_party_join(
1716		&self,
1717	) -> std::result::Result<&crate::model::ChatMessageBodyPartyJoin, &Self> {
1718		if let ChatMessageBody::PartyJoin(val) = &self {
1719			Ok(val)
1720		} else {
1721			Err(self)
1722		}
1723	}
1724	/// Returns true if this is a [`PartyJoin`](crate::model::ChatMessageBody::PartyJoin).
1725	pub fn is_party_join(&self) -> bool {
1726		self.as_party_join().is_ok()
1727	}
1728	/// Tries to convert the enum instance into [`PartyJoinRequest`](crate::model::ChatMessageBody::PartyJoinRequest), extracting the inner [`ChatMessageBodyPartyJoinRequest`](crate::model::ChatMessageBodyPartyJoinRequest).
1729	/// Returns `Err(&Self)` if it can't be converted.
1730	pub fn as_party_join_request(
1731		&self,
1732	) -> std::result::Result<&crate::model::ChatMessageBodyPartyJoinRequest, &Self> {
1733		if let ChatMessageBody::PartyJoinRequest(val) = &self {
1734			Ok(val)
1735		} else {
1736			Err(self)
1737		}
1738	}
1739	/// Returns true if this is a [`PartyJoinRequest`](crate::model::ChatMessageBody::PartyJoinRequest).
1740	pub fn is_party_join_request(&self) -> bool {
1741		self.as_party_join_request().is_ok()
1742	}
1743	/// Tries to convert the enum instance into [`PartyLeave`](crate::model::ChatMessageBody::PartyLeave), extracting the inner [`ChatMessageBodyPartyLeave`](crate::model::ChatMessageBodyPartyLeave).
1744	/// Returns `Err(&Self)` if it can't be converted.
1745	pub fn as_party_leave(
1746		&self,
1747	) -> std::result::Result<&crate::model::ChatMessageBodyPartyLeave, &Self> {
1748		if let ChatMessageBody::PartyLeave(val) = &self {
1749			Ok(val)
1750		} else {
1751			Err(self)
1752		}
1753	}
1754	/// Returns true if this is a [`PartyLeave`](crate::model::ChatMessageBody::PartyLeave).
1755	pub fn is_party_leave(&self) -> bool {
1756		self.as_party_leave().is_ok()
1757	}
1758	/// Tries to convert the enum instance into [`Text`](crate::model::ChatMessageBody::Text), extracting the inner [`ChatMessageBodyText`](crate::model::ChatMessageBodyText).
1759	/// Returns `Err(&Self)` if it can't be converted.
1760	pub fn as_text(&self) -> std::result::Result<&crate::model::ChatMessageBodyText, &Self> {
1761		if let ChatMessageBody::Text(val) = &self {
1762			Ok(val)
1763		} else {
1764			Err(self)
1765		}
1766	}
1767	/// Returns true if this is a [`Text`](crate::model::ChatMessageBody::Text).
1768	pub fn is_text(&self) -> bool {
1769		self.as_text().is_ok()
1770	}
1771	/// Returns true if the enum instance is the `Unknown` variant.
1772	pub fn is_unknown(&self) -> bool {
1773		matches!(self, Self::Unknown)
1774	}
1775}
1776
1777/// `rivet.chat#ChatMessageBody` variant for indicating a change in the party's current activity.
1778#[non_exhaustive]
1779#[derive(std::clone::Clone, std::cmp::PartialEq)]
1780pub struct ChatMessageBodyPartyActivityChange {}
1781impl std::fmt::Debug for ChatMessageBodyPartyActivityChange {
1782	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
1783		let mut formatter = f.debug_struct("ChatMessageBodyPartyActivityChange");
1784		formatter.finish()
1785	}
1786}
1787/// See [`ChatMessageBodyPartyActivityChange`](crate::model::ChatMessageBodyPartyActivityChange)
1788pub mod chat_message_body_party_activity_change {
1789	/// A builder for [`ChatMessageBodyPartyActivityChange`](crate::model::ChatMessageBodyPartyActivityChange)
1790	#[non_exhaustive]
1791	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
1792	pub struct Builder {}
1793	impl Builder {
1794		/// Consumes the builder and constructs a [`ChatMessageBodyPartyActivityChange`](crate::model::ChatMessageBodyPartyActivityChange)
1795		pub fn build(self) -> crate::model::ChatMessageBodyPartyActivityChange {
1796			crate::model::ChatMessageBodyPartyActivityChange {}
1797		}
1798	}
1799}
1800impl ChatMessageBodyPartyActivityChange {
1801	/// Creates a new builder-style object to manufacture [`ChatMessageBodyPartyActivityChange`](crate::model::ChatMessageBodyPartyActivityChange)
1802	pub fn builder() -> crate::model::chat_message_body_party_activity_change::Builder {
1803		crate::model::chat_message_body_party_activity_change::Builder::default()
1804	}
1805}
1806
1807/// `rivet.chat#ChatMessageBody` variant for indicating an identity left the party.
1808#[non_exhaustive]
1809#[derive(std::clone::Clone, std::cmp::PartialEq)]
1810pub struct ChatMessageBodyPartyLeave {
1811	/// An identity handle.
1812	pub identity: std::option::Option<crate::model::IdentityHandle>,
1813}
1814impl ChatMessageBodyPartyLeave {
1815	/// An identity handle.
1816	pub fn identity(&self) -> std::option::Option<&crate::model::IdentityHandle> {
1817		self.identity.as_ref()
1818	}
1819}
1820impl std::fmt::Debug for ChatMessageBodyPartyLeave {
1821	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
1822		let mut formatter = f.debug_struct("ChatMessageBodyPartyLeave");
1823		formatter.field("identity", &self.identity);
1824		formatter.finish()
1825	}
1826}
1827/// See [`ChatMessageBodyPartyLeave`](crate::model::ChatMessageBodyPartyLeave)
1828pub mod chat_message_body_party_leave {
1829	/// A builder for [`ChatMessageBodyPartyLeave`](crate::model::ChatMessageBodyPartyLeave)
1830	#[non_exhaustive]
1831	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
1832	pub struct Builder {
1833		pub(crate) identity: std::option::Option<crate::model::IdentityHandle>,
1834	}
1835	impl Builder {
1836		/// An identity handle.
1837		pub fn identity(mut self, input: crate::model::IdentityHandle) -> Self {
1838			self.identity = Some(input);
1839			self
1840		}
1841		/// An identity handle.
1842		pub fn set_identity(
1843			mut self,
1844			input: std::option::Option<crate::model::IdentityHandle>,
1845		) -> Self {
1846			self.identity = input;
1847			self
1848		}
1849		/// Consumes the builder and constructs a [`ChatMessageBodyPartyLeave`](crate::model::ChatMessageBodyPartyLeave)
1850		pub fn build(self) -> crate::model::ChatMessageBodyPartyLeave {
1851			crate::model::ChatMessageBodyPartyLeave {
1852				identity: self.identity,
1853			}
1854		}
1855	}
1856}
1857impl ChatMessageBodyPartyLeave {
1858	/// Creates a new builder-style object to manufacture [`ChatMessageBodyPartyLeave`](crate::model::ChatMessageBodyPartyLeave)
1859	pub fn builder() -> crate::model::chat_message_body_party_leave::Builder {
1860		crate::model::chat_message_body_party_leave::Builder::default()
1861	}
1862}
1863
1864/// `rivet.chat#ChatMessageBody` variant for indicating an identity joined the party.
1865#[non_exhaustive]
1866#[derive(std::clone::Clone, std::cmp::PartialEq)]
1867pub struct ChatMessageBodyPartyJoin {
1868	/// An identity handle.
1869	pub identity: std::option::Option<crate::model::IdentityHandle>,
1870}
1871impl ChatMessageBodyPartyJoin {
1872	/// An identity handle.
1873	pub fn identity(&self) -> std::option::Option<&crate::model::IdentityHandle> {
1874		self.identity.as_ref()
1875	}
1876}
1877impl std::fmt::Debug for ChatMessageBodyPartyJoin {
1878	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
1879		let mut formatter = f.debug_struct("ChatMessageBodyPartyJoin");
1880		formatter.field("identity", &self.identity);
1881		formatter.finish()
1882	}
1883}
1884/// See [`ChatMessageBodyPartyJoin`](crate::model::ChatMessageBodyPartyJoin)
1885pub mod chat_message_body_party_join {
1886	/// A builder for [`ChatMessageBodyPartyJoin`](crate::model::ChatMessageBodyPartyJoin)
1887	#[non_exhaustive]
1888	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
1889	pub struct Builder {
1890		pub(crate) identity: std::option::Option<crate::model::IdentityHandle>,
1891	}
1892	impl Builder {
1893		/// An identity handle.
1894		pub fn identity(mut self, input: crate::model::IdentityHandle) -> Self {
1895			self.identity = Some(input);
1896			self
1897		}
1898		/// An identity handle.
1899		pub fn set_identity(
1900			mut self,
1901			input: std::option::Option<crate::model::IdentityHandle>,
1902		) -> Self {
1903			self.identity = input;
1904			self
1905		}
1906		/// Consumes the builder and constructs a [`ChatMessageBodyPartyJoin`](crate::model::ChatMessageBodyPartyJoin)
1907		pub fn build(self) -> crate::model::ChatMessageBodyPartyJoin {
1908			crate::model::ChatMessageBodyPartyJoin {
1909				identity: self.identity,
1910			}
1911		}
1912	}
1913}
1914impl ChatMessageBodyPartyJoin {
1915	/// Creates a new builder-style object to manufacture [`ChatMessageBodyPartyJoin`](crate::model::ChatMessageBodyPartyJoin)
1916	pub fn builder() -> crate::model::chat_message_body_party_join::Builder {
1917		crate::model::chat_message_body_party_join::Builder::default()
1918	}
1919}
1920
1921/// `rivet.chat#ChatMessageBody` variant for indicating an identity requesting to join your party.
1922#[non_exhaustive]
1923#[derive(std::clone::Clone, std::cmp::PartialEq)]
1924pub struct ChatMessageBodyPartyJoinRequest {
1925	/// An identity handle.
1926	pub sender: std::option::Option<crate::model::IdentityHandle>,
1927}
1928impl ChatMessageBodyPartyJoinRequest {
1929	/// An identity handle.
1930	pub fn sender(&self) -> std::option::Option<&crate::model::IdentityHandle> {
1931		self.sender.as_ref()
1932	}
1933}
1934impl std::fmt::Debug for ChatMessageBodyPartyJoinRequest {
1935	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
1936		let mut formatter = f.debug_struct("ChatMessageBodyPartyJoinRequest");
1937		formatter.field("sender", &self.sender);
1938		formatter.finish()
1939	}
1940}
1941/// See [`ChatMessageBodyPartyJoinRequest`](crate::model::ChatMessageBodyPartyJoinRequest)
1942pub mod chat_message_body_party_join_request {
1943	/// A builder for [`ChatMessageBodyPartyJoinRequest`](crate::model::ChatMessageBodyPartyJoinRequest)
1944	#[non_exhaustive]
1945	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
1946	pub struct Builder {
1947		pub(crate) sender: std::option::Option<crate::model::IdentityHandle>,
1948	}
1949	impl Builder {
1950		/// An identity handle.
1951		pub fn sender(mut self, input: crate::model::IdentityHandle) -> Self {
1952			self.sender = Some(input);
1953			self
1954		}
1955		/// An identity handle.
1956		pub fn set_sender(
1957			mut self,
1958			input: std::option::Option<crate::model::IdentityHandle>,
1959		) -> Self {
1960			self.sender = input;
1961			self
1962		}
1963		/// Consumes the builder and constructs a [`ChatMessageBodyPartyJoinRequest`](crate::model::ChatMessageBodyPartyJoinRequest)
1964		pub fn build(self) -> crate::model::ChatMessageBodyPartyJoinRequest {
1965			crate::model::ChatMessageBodyPartyJoinRequest {
1966				sender: self.sender,
1967			}
1968		}
1969	}
1970}
1971impl ChatMessageBodyPartyJoinRequest {
1972	/// Creates a new builder-style object to manufacture [`ChatMessageBodyPartyJoinRequest`](crate::model::ChatMessageBodyPartyJoinRequest)
1973	pub fn builder() -> crate::model::chat_message_body_party_join_request::Builder {
1974		crate::model::chat_message_body_party_join_request::Builder::default()
1975	}
1976}
1977
1978/// `rivet.chat#ChatMessageBody` variant holding an a party invitation.
1979#[non_exhaustive]
1980#[derive(std::clone::Clone, std::cmp::PartialEq)]
1981pub struct ChatMessageBodyPartyInvite {
1982	/// An identity handle.
1983	pub sender: std::option::Option<crate::model::IdentityHandle>,
1984	/// A party handle.
1985	pub party: std::option::Option<crate::model::PartyHandle>,
1986	/// Pass to `rivet.api.party#GetPartyFromInvite$token` to view more information about the party. Pass to `rivet.api.party.common#JoinPartyInvite$token` to join the party.
1987	pub invite_token: std::option::Option<std::string::String>,
1988}
1989impl ChatMessageBodyPartyInvite {
1990	/// An identity handle.
1991	pub fn sender(&self) -> std::option::Option<&crate::model::IdentityHandle> {
1992		self.sender.as_ref()
1993	}
1994	/// A party handle.
1995	pub fn party(&self) -> std::option::Option<&crate::model::PartyHandle> {
1996		self.party.as_ref()
1997	}
1998	/// Pass to `rivet.api.party#GetPartyFromInvite$token` to view more information about the party. Pass to `rivet.api.party.common#JoinPartyInvite$token` to join the party.
1999	pub fn invite_token(&self) -> std::option::Option<&str> {
2000		self.invite_token.as_deref()
2001	}
2002}
2003impl std::fmt::Debug for ChatMessageBodyPartyInvite {
2004	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
2005		let mut formatter = f.debug_struct("ChatMessageBodyPartyInvite");
2006		formatter.field("sender", &self.sender);
2007		formatter.field("party", &self.party);
2008		formatter.field("invite_token", &"*** Sensitive Data Redacted ***");
2009		formatter.finish()
2010	}
2011}
2012/// See [`ChatMessageBodyPartyInvite`](crate::model::ChatMessageBodyPartyInvite)
2013pub mod chat_message_body_party_invite {
2014	/// A builder for [`ChatMessageBodyPartyInvite`](crate::model::ChatMessageBodyPartyInvite)
2015	#[non_exhaustive]
2016	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
2017	pub struct Builder {
2018		pub(crate) sender: std::option::Option<crate::model::IdentityHandle>,
2019		pub(crate) party: std::option::Option<crate::model::PartyHandle>,
2020		pub(crate) invite_token: std::option::Option<std::string::String>,
2021	}
2022	impl Builder {
2023		/// An identity handle.
2024		pub fn sender(mut self, input: crate::model::IdentityHandle) -> Self {
2025			self.sender = Some(input);
2026			self
2027		}
2028		/// An identity handle.
2029		pub fn set_sender(
2030			mut self,
2031			input: std::option::Option<crate::model::IdentityHandle>,
2032		) -> Self {
2033			self.sender = input;
2034			self
2035		}
2036		/// A party handle.
2037		pub fn party(mut self, input: crate::model::PartyHandle) -> Self {
2038			self.party = Some(input);
2039			self
2040		}
2041		/// A party handle.
2042		pub fn set_party(mut self, input: std::option::Option<crate::model::PartyHandle>) -> Self {
2043			self.party = input;
2044			self
2045		}
2046		/// Pass to `rivet.api.party#GetPartyFromInvite$token` to view more information about the party. Pass to `rivet.api.party.common#JoinPartyInvite$token` to join the party.
2047		pub fn invite_token(mut self, input: impl Into<std::string::String>) -> Self {
2048			self.invite_token = Some(input.into());
2049			self
2050		}
2051		/// Pass to `rivet.api.party#GetPartyFromInvite$token` to view more information about the party. Pass to `rivet.api.party.common#JoinPartyInvite$token` to join the party.
2052		pub fn set_invite_token(mut self, input: std::option::Option<std::string::String>) -> Self {
2053			self.invite_token = input;
2054			self
2055		}
2056		/// Consumes the builder and constructs a [`ChatMessageBodyPartyInvite`](crate::model::ChatMessageBodyPartyInvite)
2057		pub fn build(self) -> crate::model::ChatMessageBodyPartyInvite {
2058			crate::model::ChatMessageBodyPartyInvite {
2059				sender: self.sender,
2060				party: self.party,
2061				invite_token: self.invite_token,
2062			}
2063		}
2064	}
2065}
2066impl ChatMessageBodyPartyInvite {
2067	/// Creates a new builder-style object to manufacture [`ChatMessageBodyPartyInvite`](crate::model::ChatMessageBodyPartyInvite)
2068	pub fn builder() -> crate::model::chat_message_body_party_invite::Builder {
2069		crate::model::chat_message_body_party_invite::Builder::default()
2070	}
2071}
2072
2073/// `rivet.chat#ChatMessageBody` variant for indicating an identity left the group.
2074#[non_exhaustive]
2075#[derive(std::clone::Clone, std::cmp::PartialEq)]
2076pub struct ChatMessageBodyGroupLeave {
2077	/// An identity handle.
2078	pub identity: std::option::Option<crate::model::IdentityHandle>,
2079}
2080impl ChatMessageBodyGroupLeave {
2081	/// An identity handle.
2082	pub fn identity(&self) -> std::option::Option<&crate::model::IdentityHandle> {
2083		self.identity.as_ref()
2084	}
2085}
2086impl std::fmt::Debug for ChatMessageBodyGroupLeave {
2087	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
2088		let mut formatter = f.debug_struct("ChatMessageBodyGroupLeave");
2089		formatter.field("identity", &self.identity);
2090		formatter.finish()
2091	}
2092}
2093/// See [`ChatMessageBodyGroupLeave`](crate::model::ChatMessageBodyGroupLeave)
2094pub mod chat_message_body_group_leave {
2095	/// A builder for [`ChatMessageBodyGroupLeave`](crate::model::ChatMessageBodyGroupLeave)
2096	#[non_exhaustive]
2097	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
2098	pub struct Builder {
2099		pub(crate) identity: std::option::Option<crate::model::IdentityHandle>,
2100	}
2101	impl Builder {
2102		/// An identity handle.
2103		pub fn identity(mut self, input: crate::model::IdentityHandle) -> Self {
2104			self.identity = Some(input);
2105			self
2106		}
2107		/// An identity handle.
2108		pub fn set_identity(
2109			mut self,
2110			input: std::option::Option<crate::model::IdentityHandle>,
2111		) -> Self {
2112			self.identity = input;
2113			self
2114		}
2115		/// Consumes the builder and constructs a [`ChatMessageBodyGroupLeave`](crate::model::ChatMessageBodyGroupLeave)
2116		pub fn build(self) -> crate::model::ChatMessageBodyGroupLeave {
2117			crate::model::ChatMessageBodyGroupLeave {
2118				identity: self.identity,
2119			}
2120		}
2121	}
2122}
2123impl ChatMessageBodyGroupLeave {
2124	/// Creates a new builder-style object to manufacture [`ChatMessageBodyGroupLeave`](crate::model::ChatMessageBodyGroupLeave)
2125	pub fn builder() -> crate::model::chat_message_body_group_leave::Builder {
2126		crate::model::chat_message_body_group_leave::Builder::default()
2127	}
2128}
2129
2130/// `rivet.chat#ChatMessageBody` variant for indicating an identity joined the group.
2131#[non_exhaustive]
2132#[derive(std::clone::Clone, std::cmp::PartialEq)]
2133pub struct ChatMessageBodyGroupJoin {
2134	/// An identity handle.
2135	pub identity: std::option::Option<crate::model::IdentityHandle>,
2136}
2137impl ChatMessageBodyGroupJoin {
2138	/// An identity handle.
2139	pub fn identity(&self) -> std::option::Option<&crate::model::IdentityHandle> {
2140		self.identity.as_ref()
2141	}
2142}
2143impl std::fmt::Debug for ChatMessageBodyGroupJoin {
2144	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
2145		let mut formatter = f.debug_struct("ChatMessageBodyGroupJoin");
2146		formatter.field("identity", &self.identity);
2147		formatter.finish()
2148	}
2149}
2150/// See [`ChatMessageBodyGroupJoin`](crate::model::ChatMessageBodyGroupJoin)
2151pub mod chat_message_body_group_join {
2152	/// A builder for [`ChatMessageBodyGroupJoin`](crate::model::ChatMessageBodyGroupJoin)
2153	#[non_exhaustive]
2154	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
2155	pub struct Builder {
2156		pub(crate) identity: std::option::Option<crate::model::IdentityHandle>,
2157	}
2158	impl Builder {
2159		/// An identity handle.
2160		pub fn identity(mut self, input: crate::model::IdentityHandle) -> Self {
2161			self.identity = Some(input);
2162			self
2163		}
2164		/// An identity handle.
2165		pub fn set_identity(
2166			mut self,
2167			input: std::option::Option<crate::model::IdentityHandle>,
2168		) -> Self {
2169			self.identity = input;
2170			self
2171		}
2172		/// Consumes the builder and constructs a [`ChatMessageBodyGroupJoin`](crate::model::ChatMessageBodyGroupJoin)
2173		pub fn build(self) -> crate::model::ChatMessageBodyGroupJoin {
2174			crate::model::ChatMessageBodyGroupJoin {
2175				identity: self.identity,
2176			}
2177		}
2178	}
2179}
2180impl ChatMessageBodyGroupJoin {
2181	/// Creates a new builder-style object to manufacture [`ChatMessageBodyGroupJoin`](crate::model::ChatMessageBodyGroupJoin)
2182	pub fn builder() -> crate::model::chat_message_body_group_join::Builder {
2183		crate::model::chat_message_body_group_join::Builder::default()
2184	}
2185}
2186
2187/// `rivet.chat#ChatMessageBody` variant for indicating an identity followed the identity.
2188#[non_exhaustive]
2189#[derive(std::clone::Clone, std::cmp::PartialEq)]
2190pub struct ChatMessageBodyIdentityFollow {}
2191impl std::fmt::Debug for ChatMessageBodyIdentityFollow {
2192	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
2193		let mut formatter = f.debug_struct("ChatMessageBodyIdentityFollow");
2194		formatter.finish()
2195	}
2196}
2197/// See [`ChatMessageBodyIdentityFollow`](crate::model::ChatMessageBodyIdentityFollow)
2198pub mod chat_message_body_identity_follow {
2199	/// A builder for [`ChatMessageBodyIdentityFollow`](crate::model::ChatMessageBodyIdentityFollow)
2200	#[non_exhaustive]
2201	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
2202	pub struct Builder {}
2203	impl Builder {
2204		/// Consumes the builder and constructs a [`ChatMessageBodyIdentityFollow`](crate::model::ChatMessageBodyIdentityFollow)
2205		pub fn build(self) -> crate::model::ChatMessageBodyIdentityFollow {
2206			crate::model::ChatMessageBodyIdentityFollow {}
2207		}
2208	}
2209}
2210impl ChatMessageBodyIdentityFollow {
2211	/// Creates a new builder-style object to manufacture [`ChatMessageBodyIdentityFollow`](crate::model::ChatMessageBodyIdentityFollow)
2212	pub fn builder() -> crate::model::chat_message_body_identity_follow::Builder {
2213		crate::model::chat_message_body_identity_follow::Builder::default()
2214	}
2215}
2216
2217/// `rivet.chat#ChatMessageBody` variant for indicating a new chat was created.
2218#[non_exhaustive]
2219#[derive(std::clone::Clone, std::cmp::PartialEq)]
2220pub struct ChatMessageBodyChatCreate {}
2221impl std::fmt::Debug for ChatMessageBodyChatCreate {
2222	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
2223		let mut formatter = f.debug_struct("ChatMessageBodyChatCreate");
2224		formatter.finish()
2225	}
2226}
2227/// See [`ChatMessageBodyChatCreate`](crate::model::ChatMessageBodyChatCreate)
2228pub mod chat_message_body_chat_create {
2229	/// A builder for [`ChatMessageBodyChatCreate`](crate::model::ChatMessageBodyChatCreate)
2230	#[non_exhaustive]
2231	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
2232	pub struct Builder {}
2233	impl Builder {
2234		/// Consumes the builder and constructs a [`ChatMessageBodyChatCreate`](crate::model::ChatMessageBodyChatCreate)
2235		pub fn build(self) -> crate::model::ChatMessageBodyChatCreate {
2236			crate::model::ChatMessageBodyChatCreate {}
2237		}
2238	}
2239}
2240impl ChatMessageBodyChatCreate {
2241	/// Creates a new builder-style object to manufacture [`ChatMessageBodyChatCreate`](crate::model::ChatMessageBodyChatCreate)
2242	pub fn builder() -> crate::model::chat_message_body_chat_create::Builder {
2243		crate::model::chat_message_body_chat_create::Builder::default()
2244	}
2245}
2246
2247/// `rivet.chat#ChatMessageBody` variant for text messages. Sent by other identities using the chat interface.
2248#[non_exhaustive]
2249#[derive(std::clone::Clone, std::cmp::PartialEq)]
2250pub struct ChatMessageBodyText {
2251	/// An identity handle.
2252	pub sender: std::option::Option<crate::model::IdentityHandle>,
2253	/// The text in the message.
2254	pub body: std::option::Option<std::string::String>,
2255}
2256impl ChatMessageBodyText {
2257	/// An identity handle.
2258	pub fn sender(&self) -> std::option::Option<&crate::model::IdentityHandle> {
2259		self.sender.as_ref()
2260	}
2261	/// The text in the message.
2262	pub fn body(&self) -> std::option::Option<&str> {
2263		self.body.as_deref()
2264	}
2265}
2266impl std::fmt::Debug for ChatMessageBodyText {
2267	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
2268		let mut formatter = f.debug_struct("ChatMessageBodyText");
2269		formatter.field("sender", &self.sender);
2270		formatter.field("body", &self.body);
2271		formatter.finish()
2272	}
2273}
2274/// See [`ChatMessageBodyText`](crate::model::ChatMessageBodyText)
2275pub mod chat_message_body_text {
2276	/// A builder for [`ChatMessageBodyText`](crate::model::ChatMessageBodyText)
2277	#[non_exhaustive]
2278	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
2279	pub struct Builder {
2280		pub(crate) sender: std::option::Option<crate::model::IdentityHandle>,
2281		pub(crate) body: std::option::Option<std::string::String>,
2282	}
2283	impl Builder {
2284		/// An identity handle.
2285		pub fn sender(mut self, input: crate::model::IdentityHandle) -> Self {
2286			self.sender = Some(input);
2287			self
2288		}
2289		/// An identity handle.
2290		pub fn set_sender(
2291			mut self,
2292			input: std::option::Option<crate::model::IdentityHandle>,
2293		) -> Self {
2294			self.sender = input;
2295			self
2296		}
2297		/// The text in the message.
2298		pub fn body(mut self, input: impl Into<std::string::String>) -> Self {
2299			self.body = Some(input.into());
2300			self
2301		}
2302		/// The text in the message.
2303		pub fn set_body(mut self, input: std::option::Option<std::string::String>) -> Self {
2304			self.body = input;
2305			self
2306		}
2307		/// Consumes the builder and constructs a [`ChatMessageBodyText`](crate::model::ChatMessageBodyText)
2308		pub fn build(self) -> crate::model::ChatMessageBodyText {
2309			crate::model::ChatMessageBodyText {
2310				sender: self.sender,
2311				body: self.body,
2312			}
2313		}
2314	}
2315}
2316impl ChatMessageBodyText {
2317	/// Creates a new builder-style object to manufacture [`ChatMessageBodyText`](crate::model::ChatMessageBodyText)
2318	pub fn builder() -> crate::model::chat_message_body_text::Builder {
2319		crate::model::chat_message_body_text::Builder::default()
2320	}
2321}
2322
2323/// Represents which direction to query messages from relative to the given
2324/// timestamp.
2325#[non_exhaustive]
2326#[derive(
2327	std::clone::Clone,
2328	std::cmp::Eq,
2329	std::cmp::Ord,
2330	std::cmp::PartialEq,
2331	std::cmp::PartialOrd,
2332	std::fmt::Debug,
2333	std::hash::Hash,
2334)]
2335pub enum QueryDirection {
2336	/// Query messages after given timestamp.
2337	After,
2338	/// Query messages send before given timestamp.
2339	Before,
2340	/// Query messages before and after the given timestamp. This will return at most `count * 2` messages.
2341	BeforeAndAfter,
2342	/// Unknown contains new variants that have been added since this code was generated.
2343	Unknown(String),
2344}
2345impl std::convert::From<&str> for QueryDirection {
2346	fn from(s: &str) -> Self {
2347		match s {
2348			"after" => QueryDirection::After,
2349			"before" => QueryDirection::Before,
2350			"before_and_after" => QueryDirection::BeforeAndAfter,
2351			other => QueryDirection::Unknown(other.to_owned()),
2352		}
2353	}
2354}
2355impl std::str::FromStr for QueryDirection {
2356	type Err = std::convert::Infallible;
2357
2358	fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
2359		Ok(QueryDirection::from(s))
2360	}
2361}
2362impl QueryDirection {
2363	/// Returns the `&str` value of the enum member.
2364	pub fn as_str(&self) -> &str {
2365		match self {
2366			QueryDirection::After => "after",
2367			QueryDirection::Before => "before",
2368			QueryDirection::BeforeAndAfter => "before_and_after",
2369			QueryDirection::Unknown(s) => s.as_ref(),
2370		}
2371	}
2372	/// Returns all the `&str` values of the enum members.
2373	pub fn values() -> &'static [&'static str] {
2374		&["after", "before", "before_and_after"]
2375	}
2376}
2377impl AsRef<str> for QueryDirection {
2378	fn as_ref(&self) -> &str {
2379		self.as_str()
2380	}
2381}
2382
2383/// Provided by watchable endpoints used in blocking loops.
2384#[non_exhaustive]
2385#[derive(std::clone::Clone, std::cmp::PartialEq)]
2386pub struct WatchResponse {
2387	/// Index indicating the version of the data responded. Pas this to `rivet.common#WatchQuery` to block and wait for the next response.
2388	pub index: std::option::Option<std::string::String>,
2389}
2390impl WatchResponse {
2391	/// Index indicating the version of the data responded. Pas this to `rivet.common#WatchQuery` to block and wait for the next response.
2392	pub fn index(&self) -> std::option::Option<&str> {
2393		self.index.as_deref()
2394	}
2395}
2396impl std::fmt::Debug for WatchResponse {
2397	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
2398		let mut formatter = f.debug_struct("WatchResponse");
2399		formatter.field("index", &self.index);
2400		formatter.finish()
2401	}
2402}
2403/// See [`WatchResponse`](crate::model::WatchResponse)
2404pub mod watch_response {
2405	/// A builder for [`WatchResponse`](crate::model::WatchResponse)
2406	#[non_exhaustive]
2407	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
2408	pub struct Builder {
2409		pub(crate) index: std::option::Option<std::string::String>,
2410	}
2411	impl Builder {
2412		/// Index indicating the version of the data responded. Pas this to `rivet.common#WatchQuery` to block and wait for the next response.
2413		pub fn index(mut self, input: impl Into<std::string::String>) -> Self {
2414			self.index = Some(input.into());
2415			self
2416		}
2417		/// Index indicating the version of the data responded. Pas this to `rivet.common#WatchQuery` to block and wait for the next response.
2418		pub fn set_index(mut self, input: std::option::Option<std::string::String>) -> Self {
2419			self.index = input;
2420			self
2421		}
2422		/// Consumes the builder and constructs a [`WatchResponse`](crate::model::WatchResponse)
2423		pub fn build(self) -> crate::model::WatchResponse {
2424			crate::model::WatchResponse { index: self.index }
2425		}
2426	}
2427}
2428impl WatchResponse {
2429	/// Creates a new builder-style object to manufacture [`WatchResponse`](crate::model::WatchResponse)
2430	pub fn builder() -> crate::model::watch_response::Builder {
2431		crate::model::watch_response::Builder::default()
2432	}
2433}
2434
2435/// The chat typing status of an identity.
2436#[non_exhaustive]
2437#[derive(std::clone::Clone, std::cmp::PartialEq)]
2438pub struct ChatIdentityTypingStatus {
2439	/// An identity handle.
2440	pub identity: std::option::Option<crate::model::IdentityHandle>,
2441	/// Represents a chat typing status.
2442	pub status: std::option::Option<crate::model::ChatTypingStatus>,
2443}
2444impl ChatIdentityTypingStatus {
2445	/// An identity handle.
2446	pub fn identity(&self) -> std::option::Option<&crate::model::IdentityHandle> {
2447		self.identity.as_ref()
2448	}
2449	/// Represents a chat typing status.
2450	pub fn status(&self) -> std::option::Option<&crate::model::ChatTypingStatus> {
2451		self.status.as_ref()
2452	}
2453}
2454impl std::fmt::Debug for ChatIdentityTypingStatus {
2455	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
2456		let mut formatter = f.debug_struct("ChatIdentityTypingStatus");
2457		formatter.field("identity", &self.identity);
2458		formatter.field("status", &self.status);
2459		formatter.finish()
2460	}
2461}
2462/// See [`ChatIdentityTypingStatus`](crate::model::ChatIdentityTypingStatus)
2463pub mod chat_identity_typing_status {
2464	/// A builder for [`ChatIdentityTypingStatus`](crate::model::ChatIdentityTypingStatus)
2465	#[non_exhaustive]
2466	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
2467	pub struct Builder {
2468		pub(crate) identity: std::option::Option<crate::model::IdentityHandle>,
2469		pub(crate) status: std::option::Option<crate::model::ChatTypingStatus>,
2470	}
2471	impl Builder {
2472		/// An identity handle.
2473		pub fn identity(mut self, input: crate::model::IdentityHandle) -> Self {
2474			self.identity = Some(input);
2475			self
2476		}
2477		/// An identity handle.
2478		pub fn set_identity(
2479			mut self,
2480			input: std::option::Option<crate::model::IdentityHandle>,
2481		) -> Self {
2482			self.identity = input;
2483			self
2484		}
2485		/// Represents a chat typing status.
2486		pub fn status(mut self, input: crate::model::ChatTypingStatus) -> Self {
2487			self.status = Some(input);
2488			self
2489		}
2490		/// Represents a chat typing status.
2491		pub fn set_status(
2492			mut self,
2493			input: std::option::Option<crate::model::ChatTypingStatus>,
2494		) -> Self {
2495			self.status = input;
2496			self
2497		}
2498		/// Consumes the builder and constructs a [`ChatIdentityTypingStatus`](crate::model::ChatIdentityTypingStatus)
2499		pub fn build(self) -> crate::model::ChatIdentityTypingStatus {
2500			crate::model::ChatIdentityTypingStatus {
2501				identity: self.identity,
2502				status: self.status,
2503			}
2504		}
2505	}
2506}
2507impl ChatIdentityTypingStatus {
2508	/// Creates a new builder-style object to manufacture [`ChatIdentityTypingStatus`](crate::model::ChatIdentityTypingStatus)
2509	pub fn builder() -> crate::model::chat_identity_typing_status::Builder {
2510		crate::model::chat_identity_typing_status::Builder::default()
2511	}
2512}
2513
2514/// Represents a topic of the given chat thread without the associated handles for the topic.
2515#[non_exhaustive]
2516#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
2517pub enum ChatSimpleTopic {
2518	/// `rivet.chat#ChatSimpleTopic` variant for direct (identity to identity) chats.
2519	Direct(crate::model::ChatSimpleTopicDirect),
2520	/// `rivet.chat#ChatSimpleTopic` variant for groups.
2521	Group(crate::model::ChatSimpleTopicGroup),
2522	/// `rivet.chat#ChatSimpleTopic` variant for parties.
2523	Party(crate::model::ChatSimpleTopicParty),
2524	/// The `Unknown` variant represents cases where new union variant was received. Consider upgrading the SDK to the latest available version.
2525	/// An unknown enum variant
2526	///
2527	/// _Note: If you encounter this error, consider upgrading your SDK to the latest version._
2528	/// The `Unknown` variant represents cases where the server sent a value that wasn't recognized
2529	/// by the client. This can happen when the server adds new functionality, but the client has not been updated.
2530	/// To investigate this, consider turning on debug logging to print the raw HTTP response.
2531	#[non_exhaustive]
2532	Unknown,
2533}
2534impl ChatSimpleTopic {
2535	/// Tries to convert the enum instance into [`Direct`](crate::model::ChatSimpleTopic::Direct), extracting the inner [`ChatSimpleTopicDirect`](crate::model::ChatSimpleTopicDirect).
2536	/// Returns `Err(&Self)` if it can't be converted.
2537	pub fn as_direct(&self) -> std::result::Result<&crate::model::ChatSimpleTopicDirect, &Self> {
2538		if let ChatSimpleTopic::Direct(val) = &self {
2539			Ok(val)
2540		} else {
2541			Err(self)
2542		}
2543	}
2544	/// Returns true if this is a [`Direct`](crate::model::ChatSimpleTopic::Direct).
2545	pub fn is_direct(&self) -> bool {
2546		self.as_direct().is_ok()
2547	}
2548	/// Tries to convert the enum instance into [`Group`](crate::model::ChatSimpleTopic::Group), extracting the inner [`ChatSimpleTopicGroup`](crate::model::ChatSimpleTopicGroup).
2549	/// Returns `Err(&Self)` if it can't be converted.
2550	pub fn as_group(&self) -> std::result::Result<&crate::model::ChatSimpleTopicGroup, &Self> {
2551		if let ChatSimpleTopic::Group(val) = &self {
2552			Ok(val)
2553		} else {
2554			Err(self)
2555		}
2556	}
2557	/// Returns true if this is a [`Group`](crate::model::ChatSimpleTopic::Group).
2558	pub fn is_group(&self) -> bool {
2559		self.as_group().is_ok()
2560	}
2561	/// Tries to convert the enum instance into [`Party`](crate::model::ChatSimpleTopic::Party), extracting the inner [`ChatSimpleTopicParty`](crate::model::ChatSimpleTopicParty).
2562	/// Returns `Err(&Self)` if it can't be converted.
2563	pub fn as_party(&self) -> std::result::Result<&crate::model::ChatSimpleTopicParty, &Self> {
2564		if let ChatSimpleTopic::Party(val) = &self {
2565			Ok(val)
2566		} else {
2567			Err(self)
2568		}
2569	}
2570	/// Returns true if this is a [`Party`](crate::model::ChatSimpleTopic::Party).
2571	pub fn is_party(&self) -> bool {
2572		self.as_party().is_ok()
2573	}
2574	/// Returns true if the enum instance is the `Unknown` variant.
2575	pub fn is_unknown(&self) -> bool {
2576		matches!(self, Self::Unknown)
2577	}
2578}
2579
2580/// `rivet.chat#ChatSimpleTopic` variant for direct (identity to identity) chats.
2581#[non_exhaustive]
2582#[derive(std::clone::Clone, std::cmp::PartialEq)]
2583pub struct ChatSimpleTopicDirect {
2584	/// A universally unique identifier.
2585	pub identity_a_id: std::option::Option<std::string::String>,
2586	/// A universally unique identifier.
2587	pub identity_b_id: std::option::Option<std::string::String>,
2588}
2589impl ChatSimpleTopicDirect {
2590	/// A universally unique identifier.
2591	pub fn identity_a_id(&self) -> std::option::Option<&str> {
2592		self.identity_a_id.as_deref()
2593	}
2594	/// A universally unique identifier.
2595	pub fn identity_b_id(&self) -> std::option::Option<&str> {
2596		self.identity_b_id.as_deref()
2597	}
2598}
2599impl std::fmt::Debug for ChatSimpleTopicDirect {
2600	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
2601		let mut formatter = f.debug_struct("ChatSimpleTopicDirect");
2602		formatter.field("identity_a_id", &self.identity_a_id);
2603		formatter.field("identity_b_id", &self.identity_b_id);
2604		formatter.finish()
2605	}
2606}
2607/// See [`ChatSimpleTopicDirect`](crate::model::ChatSimpleTopicDirect)
2608pub mod chat_simple_topic_direct {
2609	/// A builder for [`ChatSimpleTopicDirect`](crate::model::ChatSimpleTopicDirect)
2610	#[non_exhaustive]
2611	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
2612	pub struct Builder {
2613		pub(crate) identity_a_id: std::option::Option<std::string::String>,
2614		pub(crate) identity_b_id: std::option::Option<std::string::String>,
2615	}
2616	impl Builder {
2617		/// A universally unique identifier.
2618		pub fn identity_a_id(mut self, input: impl Into<std::string::String>) -> Self {
2619			self.identity_a_id = Some(input.into());
2620			self
2621		}
2622		/// A universally unique identifier.
2623		pub fn set_identity_a_id(
2624			mut self,
2625			input: std::option::Option<std::string::String>,
2626		) -> Self {
2627			self.identity_a_id = input;
2628			self
2629		}
2630		/// A universally unique identifier.
2631		pub fn identity_b_id(mut self, input: impl Into<std::string::String>) -> Self {
2632			self.identity_b_id = Some(input.into());
2633			self
2634		}
2635		/// A universally unique identifier.
2636		pub fn set_identity_b_id(
2637			mut self,
2638			input: std::option::Option<std::string::String>,
2639		) -> Self {
2640			self.identity_b_id = input;
2641			self
2642		}
2643		/// Consumes the builder and constructs a [`ChatSimpleTopicDirect`](crate::model::ChatSimpleTopicDirect)
2644		pub fn build(self) -> crate::model::ChatSimpleTopicDirect {
2645			crate::model::ChatSimpleTopicDirect {
2646				identity_a_id: self.identity_a_id,
2647				identity_b_id: self.identity_b_id,
2648			}
2649		}
2650	}
2651}
2652impl ChatSimpleTopicDirect {
2653	/// Creates a new builder-style object to manufacture [`ChatSimpleTopicDirect`](crate::model::ChatSimpleTopicDirect)
2654	pub fn builder() -> crate::model::chat_simple_topic_direct::Builder {
2655		crate::model::chat_simple_topic_direct::Builder::default()
2656	}
2657}
2658
2659/// `rivet.chat#ChatSimpleTopic` variant for parties.
2660#[non_exhaustive]
2661#[derive(std::clone::Clone, std::cmp::PartialEq)]
2662pub struct ChatSimpleTopicParty {
2663	/// A universally unique identifier.
2664	pub party_id: std::option::Option<std::string::String>,
2665}
2666impl ChatSimpleTopicParty {
2667	/// A universally unique identifier.
2668	pub fn party_id(&self) -> std::option::Option<&str> {
2669		self.party_id.as_deref()
2670	}
2671}
2672impl std::fmt::Debug for ChatSimpleTopicParty {
2673	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
2674		let mut formatter = f.debug_struct("ChatSimpleTopicParty");
2675		formatter.field("party_id", &self.party_id);
2676		formatter.finish()
2677	}
2678}
2679/// See [`ChatSimpleTopicParty`](crate::model::ChatSimpleTopicParty)
2680pub mod chat_simple_topic_party {
2681	/// A builder for [`ChatSimpleTopicParty`](crate::model::ChatSimpleTopicParty)
2682	#[non_exhaustive]
2683	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
2684	pub struct Builder {
2685		pub(crate) party_id: std::option::Option<std::string::String>,
2686	}
2687	impl Builder {
2688		/// A universally unique identifier.
2689		pub fn party_id(mut self, input: impl Into<std::string::String>) -> Self {
2690			self.party_id = Some(input.into());
2691			self
2692		}
2693		/// A universally unique identifier.
2694		pub fn set_party_id(mut self, input: std::option::Option<std::string::String>) -> Self {
2695			self.party_id = input;
2696			self
2697		}
2698		/// Consumes the builder and constructs a [`ChatSimpleTopicParty`](crate::model::ChatSimpleTopicParty)
2699		pub fn build(self) -> crate::model::ChatSimpleTopicParty {
2700			crate::model::ChatSimpleTopicParty {
2701				party_id: self.party_id,
2702			}
2703		}
2704	}
2705}
2706impl ChatSimpleTopicParty {
2707	/// Creates a new builder-style object to manufacture [`ChatSimpleTopicParty`](crate::model::ChatSimpleTopicParty)
2708	pub fn builder() -> crate::model::chat_simple_topic_party::Builder {
2709		crate::model::chat_simple_topic_party::Builder::default()
2710	}
2711}
2712
2713/// `rivet.chat#ChatSimpleTopic` variant for groups.
2714#[non_exhaustive]
2715#[derive(std::clone::Clone, std::cmp::PartialEq)]
2716pub struct ChatSimpleTopicGroup {
2717	/// A universally unique identifier.
2718	pub group_id: std::option::Option<std::string::String>,
2719}
2720impl ChatSimpleTopicGroup {
2721	/// A universally unique identifier.
2722	pub fn group_id(&self) -> std::option::Option<&str> {
2723		self.group_id.as_deref()
2724	}
2725}
2726impl std::fmt::Debug for ChatSimpleTopicGroup {
2727	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
2728		let mut formatter = f.debug_struct("ChatSimpleTopicGroup");
2729		formatter.field("group_id", &self.group_id);
2730		formatter.finish()
2731	}
2732}
2733/// See [`ChatSimpleTopicGroup`](crate::model::ChatSimpleTopicGroup)
2734pub mod chat_simple_topic_group {
2735	/// A builder for [`ChatSimpleTopicGroup`](crate::model::ChatSimpleTopicGroup)
2736	#[non_exhaustive]
2737	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
2738	pub struct Builder {
2739		pub(crate) group_id: std::option::Option<std::string::String>,
2740	}
2741	impl Builder {
2742		/// A universally unique identifier.
2743		pub fn group_id(mut self, input: impl Into<std::string::String>) -> Self {
2744			self.group_id = Some(input.into());
2745			self
2746		}
2747		/// A universally unique identifier.
2748		pub fn set_group_id(mut self, input: std::option::Option<std::string::String>) -> Self {
2749			self.group_id = input;
2750			self
2751		}
2752		/// Consumes the builder and constructs a [`ChatSimpleTopicGroup`](crate::model::ChatSimpleTopicGroup)
2753		pub fn build(self) -> crate::model::ChatSimpleTopicGroup {
2754			crate::model::ChatSimpleTopicGroup {
2755				group_id: self.group_id,
2756			}
2757		}
2758	}
2759}
2760impl ChatSimpleTopicGroup {
2761	/// Creates a new builder-style object to manufacture [`ChatSimpleTopicGroup`](crate::model::ChatSimpleTopicGroup)
2762	pub fn builder() -> crate::model::chat_simple_topic_group::Builder {
2763		crate::model::chat_simple_topic_group::Builder::default()
2764	}
2765}