Skip to main content

rivet_identity/
model.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2/// Provided by watchable endpoints used in blocking loops.
3#[non_exhaustive]
4#[derive(std::clone::Clone, std::cmp::PartialEq)]
5pub struct WatchResponse {
6	/// Index indicating the version of the data responded. Pas this to `rivet.common#WatchQuery` to block and wait for the next response.
7	pub index: std::option::Option<std::string::String>,
8}
9impl WatchResponse {
10	/// Index indicating the version of the data responded. Pas this to `rivet.common#WatchQuery` to block and wait for the next response.
11	pub fn index(&self) -> std::option::Option<&str> {
12		self.index.as_deref()
13	}
14}
15impl std::fmt::Debug for WatchResponse {
16	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
17		let mut formatter = f.debug_struct("WatchResponse");
18		formatter.field("index", &self.index);
19		formatter.finish()
20	}
21}
22/// See [`WatchResponse`](crate::model::WatchResponse)
23pub mod watch_response {
24	/// A builder for [`WatchResponse`](crate::model::WatchResponse)
25	#[non_exhaustive]
26	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
27	pub struct Builder {
28		pub(crate) index: std::option::Option<std::string::String>,
29	}
30	impl Builder {
31		/// Index indicating the version of the data responded. Pas this to `rivet.common#WatchQuery` to block and wait for the next response.
32		pub fn index(mut self, input: impl Into<std::string::String>) -> Self {
33			self.index = Some(input.into());
34			self
35		}
36		/// Index indicating the version of the data responded. Pas this to `rivet.common#WatchQuery` to block and wait for the next response.
37		pub fn set_index(mut self, input: std::option::Option<std::string::String>) -> Self {
38			self.index = input;
39			self
40		}
41		/// Consumes the builder and constructs a [`WatchResponse`](crate::model::WatchResponse)
42		pub fn build(self) -> crate::model::WatchResponse {
43			crate::model::WatchResponse { index: self.index }
44		}
45	}
46}
47impl WatchResponse {
48	/// Creates a new builder-style object to manufacture [`WatchResponse`](crate::model::WatchResponse)
49	pub fn builder() -> crate::model::watch_response::Builder {
50		crate::model::watch_response::Builder::default()
51	}
52}
53
54/// An identity handle.
55#[non_exhaustive]
56#[derive(std::clone::Clone, std::cmp::PartialEq)]
57pub struct IdentityHandle {
58	/// A universally unique identifier.
59	pub identity_id: std::option::Option<std::string::String>,
60	/// Represent a resource's readable display name.
61	pub display_name: std::option::Option<std::string::String>,
62	/// 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.
63	pub account_number: std::option::Option<i32>,
64	/// The URL of this identity's avatar image.
65	pub avatar_url: std::option::Option<std::string::String>,
66	/// Information about the identity's current status, party, and active game.
67	pub presence: std::option::Option<crate::model::IdentityPresence>,
68	/// A party handle.
69	pub party: std::option::Option<crate::model::PartyHandle>,
70	/// Whether or not this identity is registered with a linked account.
71	pub is_registered: std::option::Option<bool>,
72	/// External links for an identity.
73	pub external: std::option::Option<crate::model::IdentityExternalLinks>,
74}
75impl IdentityHandle {
76	/// A universally unique identifier.
77	pub fn identity_id(&self) -> std::option::Option<&str> {
78		self.identity_id.as_deref()
79	}
80	/// Represent a resource's readable display name.
81	pub fn display_name(&self) -> std::option::Option<&str> {
82		self.display_name.as_deref()
83	}
84	/// 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.
85	pub fn account_number(&self) -> std::option::Option<i32> {
86		self.account_number
87	}
88	/// The URL of this identity's avatar image.
89	pub fn avatar_url(&self) -> std::option::Option<&str> {
90		self.avatar_url.as_deref()
91	}
92	/// Information about the identity's current status, party, and active game.
93	pub fn presence(&self) -> std::option::Option<&crate::model::IdentityPresence> {
94		self.presence.as_ref()
95	}
96	/// A party handle.
97	pub fn party(&self) -> std::option::Option<&crate::model::PartyHandle> {
98		self.party.as_ref()
99	}
100	/// Whether or not this identity is registered with a linked account.
101	pub fn is_registered(&self) -> std::option::Option<bool> {
102		self.is_registered
103	}
104	/// External links for an identity.
105	pub fn external(&self) -> std::option::Option<&crate::model::IdentityExternalLinks> {
106		self.external.as_ref()
107	}
108}
109impl std::fmt::Debug for IdentityHandle {
110	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
111		let mut formatter = f.debug_struct("IdentityHandle");
112		formatter.field("identity_id", &self.identity_id);
113		formatter.field("display_name", &self.display_name);
114		formatter.field("account_number", &self.account_number);
115		formatter.field("avatar_url", &self.avatar_url);
116		formatter.field("presence", &self.presence);
117		formatter.field("party", &self.party);
118		formatter.field("is_registered", &self.is_registered);
119		formatter.field("external", &self.external);
120		formatter.finish()
121	}
122}
123/// See [`IdentityHandle`](crate::model::IdentityHandle)
124pub mod identity_handle {
125	/// A builder for [`IdentityHandle`](crate::model::IdentityHandle)
126	#[non_exhaustive]
127	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
128	pub struct Builder {
129		pub(crate) identity_id: std::option::Option<std::string::String>,
130		pub(crate) display_name: std::option::Option<std::string::String>,
131		pub(crate) account_number: std::option::Option<i32>,
132		pub(crate) avatar_url: std::option::Option<std::string::String>,
133		pub(crate) presence: std::option::Option<crate::model::IdentityPresence>,
134		pub(crate) party: std::option::Option<crate::model::PartyHandle>,
135		pub(crate) is_registered: std::option::Option<bool>,
136		pub(crate) external: std::option::Option<crate::model::IdentityExternalLinks>,
137	}
138	impl Builder {
139		/// A universally unique identifier.
140		pub fn identity_id(mut self, input: impl Into<std::string::String>) -> Self {
141			self.identity_id = Some(input.into());
142			self
143		}
144		/// A universally unique identifier.
145		pub fn set_identity_id(mut self, input: std::option::Option<std::string::String>) -> Self {
146			self.identity_id = input;
147			self
148		}
149		/// Represent a resource's readable display name.
150		pub fn display_name(mut self, input: impl Into<std::string::String>) -> Self {
151			self.display_name = Some(input.into());
152			self
153		}
154		/// Represent a resource's readable display name.
155		pub fn set_display_name(mut self, input: std::option::Option<std::string::String>) -> Self {
156			self.display_name = input;
157			self
158		}
159		/// 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.
160		pub fn account_number(mut self, input: i32) -> Self {
161			self.account_number = Some(input);
162			self
163		}
164		/// 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.
165		pub fn set_account_number(mut self, input: std::option::Option<i32>) -> Self {
166			self.account_number = input;
167			self
168		}
169		/// The URL of this identity's avatar image.
170		pub fn avatar_url(mut self, input: impl Into<std::string::String>) -> Self {
171			self.avatar_url = Some(input.into());
172			self
173		}
174		/// The URL of this identity's avatar image.
175		pub fn set_avatar_url(mut self, input: std::option::Option<std::string::String>) -> Self {
176			self.avatar_url = input;
177			self
178		}
179		/// Information about the identity's current status, party, and active game.
180		pub fn presence(mut self, input: crate::model::IdentityPresence) -> Self {
181			self.presence = Some(input);
182			self
183		}
184		/// Information about the identity's current status, party, and active game.
185		pub fn set_presence(
186			mut self,
187			input: std::option::Option<crate::model::IdentityPresence>,
188		) -> Self {
189			self.presence = input;
190			self
191		}
192		/// A party handle.
193		pub fn party(mut self, input: crate::model::PartyHandle) -> Self {
194			self.party = Some(input);
195			self
196		}
197		/// A party handle.
198		pub fn set_party(mut self, input: std::option::Option<crate::model::PartyHandle>) -> Self {
199			self.party = input;
200			self
201		}
202		/// Whether or not this identity is registered with a linked account.
203		pub fn is_registered(mut self, input: bool) -> Self {
204			self.is_registered = Some(input);
205			self
206		}
207		/// Whether or not this identity is registered with a linked account.
208		pub fn set_is_registered(mut self, input: std::option::Option<bool>) -> Self {
209			self.is_registered = input;
210			self
211		}
212		/// External links for an identity.
213		pub fn external(mut self, input: crate::model::IdentityExternalLinks) -> Self {
214			self.external = Some(input);
215			self
216		}
217		/// External links for an identity.
218		pub fn set_external(
219			mut self,
220			input: std::option::Option<crate::model::IdentityExternalLinks>,
221		) -> Self {
222			self.external = input;
223			self
224		}
225		/// Consumes the builder and constructs a [`IdentityHandle`](crate::model::IdentityHandle)
226		pub fn build(self) -> crate::model::IdentityHandle {
227			crate::model::IdentityHandle {
228				identity_id: self.identity_id,
229				display_name: self.display_name,
230				account_number: self.account_number,
231				avatar_url: self.avatar_url,
232				presence: self.presence,
233				party: self.party,
234				is_registered: self.is_registered,
235				external: self.external,
236			}
237		}
238	}
239}
240impl IdentityHandle {
241	/// Creates a new builder-style object to manufacture [`IdentityHandle`](crate::model::IdentityHandle)
242	pub fn builder() -> crate::model::identity_handle::Builder {
243		crate::model::identity_handle::Builder::default()
244	}
245}
246
247/// External links for an identity.
248#[non_exhaustive]
249#[derive(std::clone::Clone, std::cmp::PartialEq)]
250pub struct IdentityExternalLinks {
251	/// A link to this identity's profile page.
252	pub profile: std::option::Option<std::string::String>,
253	/// A link to the Rivet settings page.
254	pub settings: std::option::Option<std::string::String>,
255	/// A link to a chat page with the given identity.
256	pub chat: std::option::Option<std::string::String>,
257}
258impl IdentityExternalLinks {
259	/// A link to this identity's profile page.
260	pub fn profile(&self) -> std::option::Option<&str> {
261		self.profile.as_deref()
262	}
263	/// A link to the Rivet settings page.
264	pub fn settings(&self) -> std::option::Option<&str> {
265		self.settings.as_deref()
266	}
267	/// A link to a chat page with the given identity.
268	pub fn chat(&self) -> std::option::Option<&str> {
269		self.chat.as_deref()
270	}
271}
272impl std::fmt::Debug for IdentityExternalLinks {
273	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
274		let mut formatter = f.debug_struct("IdentityExternalLinks");
275		formatter.field("profile", &self.profile);
276		formatter.field("settings", &self.settings);
277		formatter.field("chat", &self.chat);
278		formatter.finish()
279	}
280}
281/// See [`IdentityExternalLinks`](crate::model::IdentityExternalLinks)
282pub mod identity_external_links {
283	/// A builder for [`IdentityExternalLinks`](crate::model::IdentityExternalLinks)
284	#[non_exhaustive]
285	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
286	pub struct Builder {
287		pub(crate) profile: std::option::Option<std::string::String>,
288		pub(crate) settings: std::option::Option<std::string::String>,
289		pub(crate) chat: std::option::Option<std::string::String>,
290	}
291	impl Builder {
292		/// A link to this identity's profile page.
293		pub fn profile(mut self, input: impl Into<std::string::String>) -> Self {
294			self.profile = Some(input.into());
295			self
296		}
297		/// A link to this identity's profile page.
298		pub fn set_profile(mut self, input: std::option::Option<std::string::String>) -> Self {
299			self.profile = input;
300			self
301		}
302		/// A link to the Rivet settings page.
303		pub fn settings(mut self, input: impl Into<std::string::String>) -> Self {
304			self.settings = Some(input.into());
305			self
306		}
307		/// A link to the Rivet settings page.
308		pub fn set_settings(mut self, input: std::option::Option<std::string::String>) -> Self {
309			self.settings = input;
310			self
311		}
312		/// A link to a chat page with the given identity.
313		pub fn chat(mut self, input: impl Into<std::string::String>) -> Self {
314			self.chat = Some(input.into());
315			self
316		}
317		/// A link to a chat page with the given identity.
318		pub fn set_chat(mut self, input: std::option::Option<std::string::String>) -> Self {
319			self.chat = input;
320			self
321		}
322		/// Consumes the builder and constructs a [`IdentityExternalLinks`](crate::model::IdentityExternalLinks)
323		pub fn build(self) -> crate::model::IdentityExternalLinks {
324			crate::model::IdentityExternalLinks {
325				profile: self.profile,
326				settings: self.settings,
327				chat: self.chat,
328			}
329		}
330	}
331}
332impl IdentityExternalLinks {
333	/// Creates a new builder-style object to manufacture [`IdentityExternalLinks`](crate::model::IdentityExternalLinks)
334	pub fn builder() -> crate::model::identity_external_links::Builder {
335		crate::model::identity_external_links::Builder::default()
336	}
337}
338
339/// A party handle.
340#[non_exhaustive]
341#[derive(std::clone::Clone, std::cmp::PartialEq)]
342pub struct PartyHandle {
343	/// A universally unique identifier.
344	pub party_id: std::option::Option<std::string::String>,
345	/// RFC3339 timestamp.
346	pub create_ts: std::option::Option<aws_smithy_types::DateTime>,
347	/// A union representing the activity of a given party.
348	pub activity: std::option::Option<crate::model::PartyActivity>,
349	/// External links for a party.
350	pub external: std::option::Option<crate::model::PartyExternalLinks>,
351}
352impl PartyHandle {
353	/// A universally unique identifier.
354	pub fn party_id(&self) -> std::option::Option<&str> {
355		self.party_id.as_deref()
356	}
357	/// RFC3339 timestamp.
358	pub fn create_ts(&self) -> std::option::Option<&aws_smithy_types::DateTime> {
359		self.create_ts.as_ref()
360	}
361	/// A union representing the activity of a given party.
362	pub fn activity(&self) -> std::option::Option<&crate::model::PartyActivity> {
363		self.activity.as_ref()
364	}
365	/// External links for a party.
366	pub fn external(&self) -> std::option::Option<&crate::model::PartyExternalLinks> {
367		self.external.as_ref()
368	}
369}
370impl std::fmt::Debug for PartyHandle {
371	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
372		let mut formatter = f.debug_struct("PartyHandle");
373		formatter.field("party_id", &self.party_id);
374		formatter.field("create_ts", &self.create_ts);
375		formatter.field("activity", &self.activity);
376		formatter.field("external", &self.external);
377		formatter.finish()
378	}
379}
380/// See [`PartyHandle`](crate::model::PartyHandle)
381pub mod party_handle {
382	/// A builder for [`PartyHandle`](crate::model::PartyHandle)
383	#[non_exhaustive]
384	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
385	pub struct Builder {
386		pub(crate) party_id: std::option::Option<std::string::String>,
387		pub(crate) create_ts: std::option::Option<aws_smithy_types::DateTime>,
388		pub(crate) activity: std::option::Option<crate::model::PartyActivity>,
389		pub(crate) external: std::option::Option<crate::model::PartyExternalLinks>,
390	}
391	impl Builder {
392		/// A universally unique identifier.
393		pub fn party_id(mut self, input: impl Into<std::string::String>) -> Self {
394			self.party_id = Some(input.into());
395			self
396		}
397		/// A universally unique identifier.
398		pub fn set_party_id(mut self, input: std::option::Option<std::string::String>) -> Self {
399			self.party_id = input;
400			self
401		}
402		/// RFC3339 timestamp.
403		pub fn create_ts(mut self, input: aws_smithy_types::DateTime) -> Self {
404			self.create_ts = Some(input);
405			self
406		}
407		/// RFC3339 timestamp.
408		pub fn set_create_ts(
409			mut self,
410			input: std::option::Option<aws_smithy_types::DateTime>,
411		) -> Self {
412			self.create_ts = input;
413			self
414		}
415		/// A union representing the activity of a given party.
416		pub fn activity(mut self, input: crate::model::PartyActivity) -> Self {
417			self.activity = Some(input);
418			self
419		}
420		/// A union representing the activity of a given party.
421		pub fn set_activity(
422			mut self,
423			input: std::option::Option<crate::model::PartyActivity>,
424		) -> Self {
425			self.activity = input;
426			self
427		}
428		/// External links for a party.
429		pub fn external(mut self, input: crate::model::PartyExternalLinks) -> Self {
430			self.external = Some(input);
431			self
432		}
433		/// External links for a party.
434		pub fn set_external(
435			mut self,
436			input: std::option::Option<crate::model::PartyExternalLinks>,
437		) -> Self {
438			self.external = input;
439			self
440		}
441		/// Consumes the builder and constructs a [`PartyHandle`](crate::model::PartyHandle)
442		pub fn build(self) -> crate::model::PartyHandle {
443			crate::model::PartyHandle {
444				party_id: self.party_id,
445				create_ts: self.create_ts,
446				activity: self.activity,
447				external: self.external,
448			}
449		}
450	}
451}
452impl PartyHandle {
453	/// Creates a new builder-style object to manufacture [`PartyHandle`](crate::model::PartyHandle)
454	pub fn builder() -> crate::model::party_handle::Builder {
455		crate::model::party_handle::Builder::default()
456	}
457}
458
459/// External links for a party.
460#[non_exhaustive]
461#[derive(std::clone::Clone, std::cmp::PartialEq)]
462pub struct PartyExternalLinks {
463	/// A link to the given party's chat thread.
464	pub chat: std::option::Option<std::string::String>,
465}
466impl PartyExternalLinks {
467	/// A link to the given party's chat thread.
468	pub fn chat(&self) -> std::option::Option<&str> {
469		self.chat.as_deref()
470	}
471}
472impl std::fmt::Debug for PartyExternalLinks {
473	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
474		let mut formatter = f.debug_struct("PartyExternalLinks");
475		formatter.field("chat", &self.chat);
476		formatter.finish()
477	}
478}
479/// See [`PartyExternalLinks`](crate::model::PartyExternalLinks)
480pub mod party_external_links {
481	/// A builder for [`PartyExternalLinks`](crate::model::PartyExternalLinks)
482	#[non_exhaustive]
483	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
484	pub struct Builder {
485		pub(crate) chat: std::option::Option<std::string::String>,
486	}
487	impl Builder {
488		/// A link to the given party's chat thread.
489		pub fn chat(mut self, input: impl Into<std::string::String>) -> Self {
490			self.chat = Some(input.into());
491			self
492		}
493		/// A link to the given party's chat thread.
494		pub fn set_chat(mut self, input: std::option::Option<std::string::String>) -> Self {
495			self.chat = input;
496			self
497		}
498		/// Consumes the builder and constructs a [`PartyExternalLinks`](crate::model::PartyExternalLinks)
499		pub fn build(self) -> crate::model::PartyExternalLinks {
500			crate::model::PartyExternalLinks { chat: self.chat }
501		}
502	}
503}
504impl PartyExternalLinks {
505	/// Creates a new builder-style object to manufacture [`PartyExternalLinks`](crate::model::PartyExternalLinks)
506	pub fn builder() -> crate::model::party_external_links::Builder {
507		crate::model::party_external_links::Builder::default()
508	}
509}
510
511/// A union representing the activity of a given party.
512#[non_exhaustive]
513#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
514pub enum PartyActivity {
515	/// A party activity denoting that the party is idle.
516	Idle(crate::model::PartyActivityIdle),
517	/// A party activity denoting that the party is currently searching for a lobby.
518	MatchmakerFindingLobby(crate::model::PartyActivityMatchmakerFindingLobby),
519	/// A party activity denoting that the party is currently in a lobby.
520	MatchmakerLobby(crate::model::PartyActivityMatchmakerLobby),
521	/// The `Unknown` variant represents cases where new union variant was received. Consider upgrading the SDK to the latest available version.
522	/// An unknown enum variant
523	///
524	/// _Note: If you encounter this error, consider upgrading your SDK to the latest version._
525	/// The `Unknown` variant represents cases where the server sent a value that wasn't recognized
526	/// by the client. This can happen when the server adds new functionality, but the client has not been updated.
527	/// To investigate this, consider turning on debug logging to print the raw HTTP response.
528	#[non_exhaustive]
529	Unknown,
530}
531impl PartyActivity {
532	/// Tries to convert the enum instance into [`Idle`](crate::model::PartyActivity::Idle), extracting the inner [`PartyActivityIdle`](crate::model::PartyActivityIdle).
533	/// Returns `Err(&Self)` if it can't be converted.
534	pub fn as_idle(&self) -> std::result::Result<&crate::model::PartyActivityIdle, &Self> {
535		if let PartyActivity::Idle(val) = &self {
536			Ok(val)
537		} else {
538			Err(self)
539		}
540	}
541	/// Returns true if this is a [`Idle`](crate::model::PartyActivity::Idle).
542	pub fn is_idle(&self) -> bool {
543		self.as_idle().is_ok()
544	}
545	/// Tries to convert the enum instance into [`MatchmakerFindingLobby`](crate::model::PartyActivity::MatchmakerFindingLobby), extracting the inner [`PartyActivityMatchmakerFindingLobby`](crate::model::PartyActivityMatchmakerFindingLobby).
546	/// Returns `Err(&Self)` if it can't be converted.
547	pub fn as_matchmaker_finding_lobby(
548		&self,
549	) -> std::result::Result<&crate::model::PartyActivityMatchmakerFindingLobby, &Self> {
550		if let PartyActivity::MatchmakerFindingLobby(val) = &self {
551			Ok(val)
552		} else {
553			Err(self)
554		}
555	}
556	/// Returns true if this is a [`MatchmakerFindingLobby`](crate::model::PartyActivity::MatchmakerFindingLobby).
557	pub fn is_matchmaker_finding_lobby(&self) -> bool {
558		self.as_matchmaker_finding_lobby().is_ok()
559	}
560	/// Tries to convert the enum instance into [`MatchmakerLobby`](crate::model::PartyActivity::MatchmakerLobby), extracting the inner [`PartyActivityMatchmakerLobby`](crate::model::PartyActivityMatchmakerLobby).
561	/// Returns `Err(&Self)` if it can't be converted.
562	pub fn as_matchmaker_lobby(
563		&self,
564	) -> std::result::Result<&crate::model::PartyActivityMatchmakerLobby, &Self> {
565		if let PartyActivity::MatchmakerLobby(val) = &self {
566			Ok(val)
567		} else {
568			Err(self)
569		}
570	}
571	/// Returns true if this is a [`MatchmakerLobby`](crate::model::PartyActivity::MatchmakerLobby).
572	pub fn is_matchmaker_lobby(&self) -> bool {
573		self.as_matchmaker_lobby().is_ok()
574	}
575	/// Returns true if the enum instance is the `Unknown` variant.
576	pub fn is_unknown(&self) -> bool {
577		matches!(self, Self::Unknown)
578	}
579}
580
581/// A party activity denoting that the party is currently in a lobby.
582#[non_exhaustive]
583#[derive(std::clone::Clone, std::cmp::PartialEq)]
584pub struct PartyActivityMatchmakerLobby {
585	/// A party lobby.
586	pub lobby: std::option::Option<crate::model::PartyMatchmakerLobby>,
587	/// A game handle.
588	pub game: std::option::Option<crate::model::GameHandle>,
589}
590impl PartyActivityMatchmakerLobby {
591	/// A party lobby.
592	pub fn lobby(&self) -> std::option::Option<&crate::model::PartyMatchmakerLobby> {
593		self.lobby.as_ref()
594	}
595	/// A game handle.
596	pub fn game(&self) -> std::option::Option<&crate::model::GameHandle> {
597		self.game.as_ref()
598	}
599}
600impl std::fmt::Debug for PartyActivityMatchmakerLobby {
601	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
602		let mut formatter = f.debug_struct("PartyActivityMatchmakerLobby");
603		formatter.field("lobby", &self.lobby);
604		formatter.field("game", &self.game);
605		formatter.finish()
606	}
607}
608/// See [`PartyActivityMatchmakerLobby`](crate::model::PartyActivityMatchmakerLobby)
609pub mod party_activity_matchmaker_lobby {
610	/// A builder for [`PartyActivityMatchmakerLobby`](crate::model::PartyActivityMatchmakerLobby)
611	#[non_exhaustive]
612	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
613	pub struct Builder {
614		pub(crate) lobby: std::option::Option<crate::model::PartyMatchmakerLobby>,
615		pub(crate) game: std::option::Option<crate::model::GameHandle>,
616	}
617	impl Builder {
618		/// A party lobby.
619		pub fn lobby(mut self, input: crate::model::PartyMatchmakerLobby) -> Self {
620			self.lobby = Some(input);
621			self
622		}
623		/// A party lobby.
624		pub fn set_lobby(
625			mut self,
626			input: std::option::Option<crate::model::PartyMatchmakerLobby>,
627		) -> Self {
628			self.lobby = input;
629			self
630		}
631		/// A game handle.
632		pub fn game(mut self, input: crate::model::GameHandle) -> Self {
633			self.game = Some(input);
634			self
635		}
636		/// A game handle.
637		pub fn set_game(mut self, input: std::option::Option<crate::model::GameHandle>) -> Self {
638			self.game = input;
639			self
640		}
641		/// Consumes the builder and constructs a [`PartyActivityMatchmakerLobby`](crate::model::PartyActivityMatchmakerLobby)
642		pub fn build(self) -> crate::model::PartyActivityMatchmakerLobby {
643			crate::model::PartyActivityMatchmakerLobby {
644				lobby: self.lobby,
645				game: self.game,
646			}
647		}
648	}
649}
650impl PartyActivityMatchmakerLobby {
651	/// Creates a new builder-style object to manufacture [`PartyActivityMatchmakerLobby`](crate::model::PartyActivityMatchmakerLobby)
652	pub fn builder() -> crate::model::party_activity_matchmaker_lobby::Builder {
653		crate::model::party_activity_matchmaker_lobby::Builder::default()
654	}
655}
656
657/// A game handle.
658#[non_exhaustive]
659#[derive(std::clone::Clone, std::cmp::PartialEq)]
660pub struct GameHandle {
661	/// A universally unique identifier.
662	pub game_id: std::option::Option<std::string::String>,
663	/// 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.
664	pub name_id: std::option::Option<std::string::String>,
665	/// Represent a resource's readable display name.
666	pub display_name: std::option::Option<std::string::String>,
667	/// The URL of this game's logo image.
668	pub logo_url: std::option::Option<std::string::String>,
669	/// The URL of this game's banner image.
670	pub banner_url: std::option::Option<std::string::String>,
671}
672impl GameHandle {
673	/// A universally unique identifier.
674	pub fn game_id(&self) -> std::option::Option<&str> {
675		self.game_id.as_deref()
676	}
677	/// 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.
678	pub fn name_id(&self) -> std::option::Option<&str> {
679		self.name_id.as_deref()
680	}
681	/// Represent a resource's readable display name.
682	pub fn display_name(&self) -> std::option::Option<&str> {
683		self.display_name.as_deref()
684	}
685	/// The URL of this game's logo image.
686	pub fn logo_url(&self) -> std::option::Option<&str> {
687		self.logo_url.as_deref()
688	}
689	/// The URL of this game's banner image.
690	pub fn banner_url(&self) -> std::option::Option<&str> {
691		self.banner_url.as_deref()
692	}
693}
694impl std::fmt::Debug for GameHandle {
695	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
696		let mut formatter = f.debug_struct("GameHandle");
697		formatter.field("game_id", &self.game_id);
698		formatter.field("name_id", &self.name_id);
699		formatter.field("display_name", &self.display_name);
700		formatter.field("logo_url", &self.logo_url);
701		formatter.field("banner_url", &self.banner_url);
702		formatter.finish()
703	}
704}
705/// See [`GameHandle`](crate::model::GameHandle)
706pub mod game_handle {
707	/// A builder for [`GameHandle`](crate::model::GameHandle)
708	#[non_exhaustive]
709	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
710	pub struct Builder {
711		pub(crate) game_id: std::option::Option<std::string::String>,
712		pub(crate) name_id: std::option::Option<std::string::String>,
713		pub(crate) display_name: std::option::Option<std::string::String>,
714		pub(crate) logo_url: std::option::Option<std::string::String>,
715		pub(crate) banner_url: std::option::Option<std::string::String>,
716	}
717	impl Builder {
718		/// A universally unique identifier.
719		pub fn game_id(mut self, input: impl Into<std::string::String>) -> Self {
720			self.game_id = Some(input.into());
721			self
722		}
723		/// A universally unique identifier.
724		pub fn set_game_id(mut self, input: std::option::Option<std::string::String>) -> Self {
725			self.game_id = input;
726			self
727		}
728		/// 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.
729		pub fn name_id(mut self, input: impl Into<std::string::String>) -> Self {
730			self.name_id = Some(input.into());
731			self
732		}
733		/// 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.
734		pub fn set_name_id(mut self, input: std::option::Option<std::string::String>) -> Self {
735			self.name_id = input;
736			self
737		}
738		/// Represent a resource's readable display name.
739		pub fn display_name(mut self, input: impl Into<std::string::String>) -> Self {
740			self.display_name = Some(input.into());
741			self
742		}
743		/// Represent a resource's readable display name.
744		pub fn set_display_name(mut self, input: std::option::Option<std::string::String>) -> Self {
745			self.display_name = input;
746			self
747		}
748		/// The URL of this game's logo image.
749		pub fn logo_url(mut self, input: impl Into<std::string::String>) -> Self {
750			self.logo_url = Some(input.into());
751			self
752		}
753		/// The URL of this game's logo image.
754		pub fn set_logo_url(mut self, input: std::option::Option<std::string::String>) -> Self {
755			self.logo_url = input;
756			self
757		}
758		/// The URL of this game's banner image.
759		pub fn banner_url(mut self, input: impl Into<std::string::String>) -> Self {
760			self.banner_url = Some(input.into());
761			self
762		}
763		/// The URL of this game's banner image.
764		pub fn set_banner_url(mut self, input: std::option::Option<std::string::String>) -> Self {
765			self.banner_url = input;
766			self
767		}
768		/// Consumes the builder and constructs a [`GameHandle`](crate::model::GameHandle)
769		pub fn build(self) -> crate::model::GameHandle {
770			crate::model::GameHandle {
771				game_id: self.game_id,
772				name_id: self.name_id,
773				display_name: self.display_name,
774				logo_url: self.logo_url,
775				banner_url: self.banner_url,
776			}
777		}
778	}
779}
780impl GameHandle {
781	/// Creates a new builder-style object to manufacture [`GameHandle`](crate::model::GameHandle)
782	pub fn builder() -> crate::model::game_handle::Builder {
783		crate::model::game_handle::Builder::default()
784	}
785}
786
787/// A party lobby.
788#[non_exhaustive]
789#[derive(std::clone::Clone, std::cmp::PartialEq)]
790pub struct PartyMatchmakerLobby {
791	/// A universally unique identifier.
792	pub lobby_id: std::option::Option<std::string::String>,
793}
794impl PartyMatchmakerLobby {
795	/// A universally unique identifier.
796	pub fn lobby_id(&self) -> std::option::Option<&str> {
797		self.lobby_id.as_deref()
798	}
799}
800impl std::fmt::Debug for PartyMatchmakerLobby {
801	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
802		let mut formatter = f.debug_struct("PartyMatchmakerLobby");
803		formatter.field("lobby_id", &self.lobby_id);
804		formatter.finish()
805	}
806}
807/// See [`PartyMatchmakerLobby`](crate::model::PartyMatchmakerLobby)
808pub mod party_matchmaker_lobby {
809	/// A builder for [`PartyMatchmakerLobby`](crate::model::PartyMatchmakerLobby)
810	#[non_exhaustive]
811	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
812	pub struct Builder {
813		pub(crate) lobby_id: std::option::Option<std::string::String>,
814	}
815	impl Builder {
816		/// A universally unique identifier.
817		pub fn lobby_id(mut self, input: impl Into<std::string::String>) -> Self {
818			self.lobby_id = Some(input.into());
819			self
820		}
821		/// A universally unique identifier.
822		pub fn set_lobby_id(mut self, input: std::option::Option<std::string::String>) -> Self {
823			self.lobby_id = input;
824			self
825		}
826		/// Consumes the builder and constructs a [`PartyMatchmakerLobby`](crate::model::PartyMatchmakerLobby)
827		pub fn build(self) -> crate::model::PartyMatchmakerLobby {
828			crate::model::PartyMatchmakerLobby {
829				lobby_id: self.lobby_id,
830			}
831		}
832	}
833}
834impl PartyMatchmakerLobby {
835	/// Creates a new builder-style object to manufacture [`PartyMatchmakerLobby`](crate::model::PartyMatchmakerLobby)
836	pub fn builder() -> crate::model::party_matchmaker_lobby::Builder {
837		crate::model::party_matchmaker_lobby::Builder::default()
838	}
839}
840
841/// A party activity denoting that the party is currently searching for a lobby.
842#[non_exhaustive]
843#[derive(std::clone::Clone, std::cmp::PartialEq)]
844pub struct PartyActivityMatchmakerFindingLobby {
845	/// A game handle.
846	pub game: std::option::Option<crate::model::GameHandle>,
847}
848impl PartyActivityMatchmakerFindingLobby {
849	/// A game handle.
850	pub fn game(&self) -> std::option::Option<&crate::model::GameHandle> {
851		self.game.as_ref()
852	}
853}
854impl std::fmt::Debug for PartyActivityMatchmakerFindingLobby {
855	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
856		let mut formatter = f.debug_struct("PartyActivityMatchmakerFindingLobby");
857		formatter.field("game", &self.game);
858		formatter.finish()
859	}
860}
861/// See [`PartyActivityMatchmakerFindingLobby`](crate::model::PartyActivityMatchmakerFindingLobby)
862pub mod party_activity_matchmaker_finding_lobby {
863	/// A builder for [`PartyActivityMatchmakerFindingLobby`](crate::model::PartyActivityMatchmakerFindingLobby)
864	#[non_exhaustive]
865	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
866	pub struct Builder {
867		pub(crate) game: std::option::Option<crate::model::GameHandle>,
868	}
869	impl Builder {
870		/// A game handle.
871		pub fn game(mut self, input: crate::model::GameHandle) -> Self {
872			self.game = Some(input);
873			self
874		}
875		/// A game handle.
876		pub fn set_game(mut self, input: std::option::Option<crate::model::GameHandle>) -> Self {
877			self.game = input;
878			self
879		}
880		/// Consumes the builder and constructs a [`PartyActivityMatchmakerFindingLobby`](crate::model::PartyActivityMatchmakerFindingLobby)
881		pub fn build(self) -> crate::model::PartyActivityMatchmakerFindingLobby {
882			crate::model::PartyActivityMatchmakerFindingLobby { game: self.game }
883		}
884	}
885}
886impl PartyActivityMatchmakerFindingLobby {
887	/// Creates a new builder-style object to manufacture [`PartyActivityMatchmakerFindingLobby`](crate::model::PartyActivityMatchmakerFindingLobby)
888	pub fn builder() -> crate::model::party_activity_matchmaker_finding_lobby::Builder {
889		crate::model::party_activity_matchmaker_finding_lobby::Builder::default()
890	}
891}
892
893/// A party activity denoting that the party is idle.
894#[non_exhaustive]
895#[derive(std::clone::Clone, std::cmp::PartialEq)]
896pub struct PartyActivityIdle {}
897impl std::fmt::Debug for PartyActivityIdle {
898	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
899		let mut formatter = f.debug_struct("PartyActivityIdle");
900		formatter.finish()
901	}
902}
903/// See [`PartyActivityIdle`](crate::model::PartyActivityIdle)
904pub mod party_activity_idle {
905	/// A builder for [`PartyActivityIdle`](crate::model::PartyActivityIdle)
906	#[non_exhaustive]
907	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
908	pub struct Builder {}
909	impl Builder {
910		/// Consumes the builder and constructs a [`PartyActivityIdle`](crate::model::PartyActivityIdle)
911		pub fn build(self) -> crate::model::PartyActivityIdle {
912			crate::model::PartyActivityIdle {}
913		}
914	}
915}
916impl PartyActivityIdle {
917	/// Creates a new builder-style object to manufacture [`PartyActivityIdle`](crate::model::PartyActivityIdle)
918	pub fn builder() -> crate::model::party_activity_idle::Builder {
919		crate::model::party_activity_idle::Builder::default()
920	}
921}
922
923/// Information about the identity's current status, party, and active game.
924#[non_exhaustive]
925#[derive(std::clone::Clone, std::cmp::PartialEq)]
926pub struct IdentityPresence {
927	/// RFC3339 timestamp.
928	pub update_ts: std::option::Option<aws_smithy_types::DateTime>,
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 status: std::option::Option<crate::model::IdentityStatus>,
931	/// The game an identity is currently participating in.
932	pub game_activity: std::option::Option<crate::model::IdentityGameActivity>,
933}
934impl IdentityPresence {
935	/// RFC3339 timestamp.
936	pub fn update_ts(&self) -> std::option::Option<&aws_smithy_types::DateTime> {
937		self.update_ts.as_ref()
938	}
939	/// The current status of an identity. This helps players understand if another player is currently playing or has their game in the background.
940	pub fn status(&self) -> std::option::Option<&crate::model::IdentityStatus> {
941		self.status.as_ref()
942	}
943	/// The game an identity is currently participating in.
944	pub fn game_activity(&self) -> std::option::Option<&crate::model::IdentityGameActivity> {
945		self.game_activity.as_ref()
946	}
947}
948impl std::fmt::Debug for IdentityPresence {
949	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
950		let mut formatter = f.debug_struct("IdentityPresence");
951		formatter.field("update_ts", &self.update_ts);
952		formatter.field("status", &self.status);
953		formatter.field("game_activity", &self.game_activity);
954		formatter.finish()
955	}
956}
957/// See [`IdentityPresence`](crate::model::IdentityPresence)
958pub mod identity_presence {
959	/// A builder for [`IdentityPresence`](crate::model::IdentityPresence)
960	#[non_exhaustive]
961	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
962	pub struct Builder {
963		pub(crate) update_ts: std::option::Option<aws_smithy_types::DateTime>,
964		pub(crate) status: std::option::Option<crate::model::IdentityStatus>,
965		pub(crate) game_activity: std::option::Option<crate::model::IdentityGameActivity>,
966	}
967	impl Builder {
968		/// RFC3339 timestamp.
969		pub fn update_ts(mut self, input: aws_smithy_types::DateTime) -> Self {
970			self.update_ts = Some(input);
971			self
972		}
973		/// RFC3339 timestamp.
974		pub fn set_update_ts(
975			mut self,
976			input: std::option::Option<aws_smithy_types::DateTime>,
977		) -> Self {
978			self.update_ts = input;
979			self
980		}
981		/// The current status of an identity. This helps players understand if another player is currently playing or has their game in the background.
982		pub fn status(mut self, input: crate::model::IdentityStatus) -> Self {
983			self.status = Some(input);
984			self
985		}
986		/// The current status of an identity. This helps players understand if another player is currently playing or has their game in the background.
987		pub fn set_status(
988			mut self,
989			input: std::option::Option<crate::model::IdentityStatus>,
990		) -> Self {
991			self.status = input;
992			self
993		}
994		/// The game an identity is currently participating in.
995		pub fn game_activity(mut self, input: crate::model::IdentityGameActivity) -> Self {
996			self.game_activity = Some(input);
997			self
998		}
999		/// The game an identity is currently participating in.
1000		pub fn set_game_activity(
1001			mut self,
1002			input: std::option::Option<crate::model::IdentityGameActivity>,
1003		) -> Self {
1004			self.game_activity = input;
1005			self
1006		}
1007		/// Consumes the builder and constructs a [`IdentityPresence`](crate::model::IdentityPresence)
1008		pub fn build(self) -> crate::model::IdentityPresence {
1009			crate::model::IdentityPresence {
1010				update_ts: self.update_ts,
1011				status: self.status,
1012				game_activity: self.game_activity,
1013			}
1014		}
1015	}
1016}
1017impl IdentityPresence {
1018	/// Creates a new builder-style object to manufacture [`IdentityPresence`](crate::model::IdentityPresence)
1019	pub fn builder() -> crate::model::identity_presence::Builder {
1020		crate::model::identity_presence::Builder::default()
1021	}
1022}
1023
1024/// The game an identity is currently participating in.
1025#[non_exhaustive]
1026#[derive(std::clone::Clone, std::cmp::PartialEq)]
1027pub struct IdentityGameActivity {
1028	/// A game handle.
1029	pub game: std::option::Option<crate::model::GameHandle>,
1030	/// A short activity message about the current game activity.
1031	pub message: std::option::Option<std::string::String>,
1032	/// JSON data seen by anyone.
1033	pub public_metadata: std::option::Option<aws_smithy_types::Document>,
1034	/// JSON data seen only by the given identity and their mutual followers.
1035	pub mutual_metadata: std::option::Option<aws_smithy_types::Document>,
1036}
1037impl IdentityGameActivity {
1038	/// A game handle.
1039	pub fn game(&self) -> std::option::Option<&crate::model::GameHandle> {
1040		self.game.as_ref()
1041	}
1042	/// A short activity message about the current game activity.
1043	pub fn message(&self) -> std::option::Option<&str> {
1044		self.message.as_deref()
1045	}
1046	/// JSON data seen by anyone.
1047	pub fn public_metadata(&self) -> std::option::Option<&aws_smithy_types::Document> {
1048		self.public_metadata.as_ref()
1049	}
1050	/// JSON data seen only by the given identity and their mutual followers.
1051	pub fn mutual_metadata(&self) -> std::option::Option<&aws_smithy_types::Document> {
1052		self.mutual_metadata.as_ref()
1053	}
1054}
1055impl std::fmt::Debug for IdentityGameActivity {
1056	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
1057		let mut formatter = f.debug_struct("IdentityGameActivity");
1058		formatter.field("game", &self.game);
1059		formatter.field("message", &self.message);
1060		formatter.field("public_metadata", &self.public_metadata);
1061		formatter.field("mutual_metadata", &self.mutual_metadata);
1062		formatter.finish()
1063	}
1064}
1065/// See [`IdentityGameActivity`](crate::model::IdentityGameActivity)
1066pub mod identity_game_activity {
1067	/// A builder for [`IdentityGameActivity`](crate::model::IdentityGameActivity)
1068	#[non_exhaustive]
1069	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
1070	pub struct Builder {
1071		pub(crate) game: std::option::Option<crate::model::GameHandle>,
1072		pub(crate) message: std::option::Option<std::string::String>,
1073		pub(crate) public_metadata: std::option::Option<aws_smithy_types::Document>,
1074		pub(crate) mutual_metadata: std::option::Option<aws_smithy_types::Document>,
1075	}
1076	impl Builder {
1077		/// A game handle.
1078		pub fn game(mut self, input: crate::model::GameHandle) -> Self {
1079			self.game = Some(input);
1080			self
1081		}
1082		/// A game handle.
1083		pub fn set_game(mut self, input: std::option::Option<crate::model::GameHandle>) -> Self {
1084			self.game = input;
1085			self
1086		}
1087		/// A short activity message about the current game activity.
1088		pub fn message(mut self, input: impl Into<std::string::String>) -> Self {
1089			self.message = Some(input.into());
1090			self
1091		}
1092		/// A short activity message about the current game activity.
1093		pub fn set_message(mut self, input: std::option::Option<std::string::String>) -> Self {
1094			self.message = input;
1095			self
1096		}
1097		/// JSON data seen by anyone.
1098		pub fn public_metadata(mut self, input: aws_smithy_types::Document) -> Self {
1099			self.public_metadata = Some(input);
1100			self
1101		}
1102		/// JSON data seen by anyone.
1103		pub fn set_public_metadata(
1104			mut self,
1105			input: std::option::Option<aws_smithy_types::Document>,
1106		) -> Self {
1107			self.public_metadata = input;
1108			self
1109		}
1110		/// JSON data seen only by the given identity and their mutual followers.
1111		pub fn mutual_metadata(mut self, input: aws_smithy_types::Document) -> Self {
1112			self.mutual_metadata = Some(input);
1113			self
1114		}
1115		/// JSON data seen only by the given identity and their mutual followers.
1116		pub fn set_mutual_metadata(
1117			mut self,
1118			input: std::option::Option<aws_smithy_types::Document>,
1119		) -> Self {
1120			self.mutual_metadata = input;
1121			self
1122		}
1123		/// Consumes the builder and constructs a [`IdentityGameActivity`](crate::model::IdentityGameActivity)
1124		pub fn build(self) -> crate::model::IdentityGameActivity {
1125			crate::model::IdentityGameActivity {
1126				game: self.game,
1127				message: self.message,
1128				public_metadata: self.public_metadata,
1129				mutual_metadata: self.mutual_metadata,
1130			}
1131		}
1132	}
1133}
1134impl IdentityGameActivity {
1135	/// Creates a new builder-style object to manufacture [`IdentityGameActivity`](crate::model::IdentityGameActivity)
1136	pub fn builder() -> crate::model::identity_game_activity::Builder {
1137		crate::model::identity_game_activity::Builder::default()
1138	}
1139}
1140
1141/// The current status of an identity. This helps players understand if another
1142/// player is currently playing or has their game in the background.
1143#[non_exhaustive]
1144#[derive(
1145	std::clone::Clone,
1146	std::cmp::Eq,
1147	std::cmp::Ord,
1148	std::cmp::PartialEq,
1149	std::cmp::PartialOrd,
1150	std::fmt::Debug,
1151	std::hash::Hash,
1152)]
1153pub enum IdentityStatus {
1154	#[allow(missing_docs)] // documentation missing in model
1155	Away,
1156	#[allow(missing_docs)] // documentation missing in model
1157	Offline,
1158	#[allow(missing_docs)] // documentation missing in model
1159	Online,
1160	/// Unknown contains new variants that have been added since this code was generated.
1161	Unknown(String),
1162}
1163impl std::convert::From<&str> for IdentityStatus {
1164	fn from(s: &str) -> Self {
1165		match s {
1166			"away" => IdentityStatus::Away,
1167			"offline" => IdentityStatus::Offline,
1168			"online" => IdentityStatus::Online,
1169			other => IdentityStatus::Unknown(other.to_owned()),
1170		}
1171	}
1172}
1173impl std::str::FromStr for IdentityStatus {
1174	type Err = std::convert::Infallible;
1175
1176	fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
1177		Ok(IdentityStatus::from(s))
1178	}
1179}
1180impl IdentityStatus {
1181	/// Returns the `&str` value of the enum member.
1182	pub fn as_str(&self) -> &str {
1183		match self {
1184			IdentityStatus::Away => "away",
1185			IdentityStatus::Offline => "offline",
1186			IdentityStatus::Online => "online",
1187			IdentityStatus::Unknown(s) => s.as_ref(),
1188		}
1189	}
1190	/// Returns all the `&str` values of the enum members.
1191	pub fn values() -> &'static [&'static str] {
1192		&["away", "offline", "online"]
1193	}
1194}
1195impl AsRef<str> for IdentityStatus {
1196	fn as_ref(&self) -> &str {
1197		self.as_str()
1198	}
1199}
1200
1201/// A group summary.
1202#[non_exhaustive]
1203#[derive(std::clone::Clone, std::cmp::PartialEq)]
1204pub struct GroupSummary {
1205	/// A universally unique identifier.
1206	pub group_id: std::option::Option<std::string::String>,
1207	/// Represent a resource's readable display name.
1208	pub display_name: std::option::Option<std::string::String>,
1209	/// The URL of this group's avatar image.
1210	pub avatar_url: std::option::Option<std::string::String>,
1211	/// External links for this group.
1212	pub external: std::option::Option<crate::model::GroupExternalLinks>,
1213	/// Whether or not this group is a developer.
1214	pub is_developer: std::option::Option<bool>,
1215	/// Detailed information about a profile.
1216	pub bio: std::option::Option<std::string::String>,
1217	/// Whether or not the current identity is a member of this group.
1218	pub is_current_identity_member: std::option::Option<bool>,
1219	/// The current publicity value for the given group.
1220	pub publicity: std::option::Option<crate::model::GroupPublicity>,
1221	/// Unsigned 32 bit integer.
1222	pub member_count: std::option::Option<i32>,
1223}
1224impl GroupSummary {
1225	/// A universally unique identifier.
1226	pub fn group_id(&self) -> std::option::Option<&str> {
1227		self.group_id.as_deref()
1228	}
1229	/// Represent a resource's readable display name.
1230	pub fn display_name(&self) -> std::option::Option<&str> {
1231		self.display_name.as_deref()
1232	}
1233	/// The URL of this group's avatar image.
1234	pub fn avatar_url(&self) -> std::option::Option<&str> {
1235		self.avatar_url.as_deref()
1236	}
1237	/// External links for this group.
1238	pub fn external(&self) -> std::option::Option<&crate::model::GroupExternalLinks> {
1239		self.external.as_ref()
1240	}
1241	/// Whether or not this group is a developer.
1242	pub fn is_developer(&self) -> std::option::Option<bool> {
1243		self.is_developer
1244	}
1245	/// Detailed information about a profile.
1246	pub fn bio(&self) -> std::option::Option<&str> {
1247		self.bio.as_deref()
1248	}
1249	/// Whether or not the current identity is a member of this group.
1250	pub fn is_current_identity_member(&self) -> std::option::Option<bool> {
1251		self.is_current_identity_member
1252	}
1253	/// The current publicity value for the given group.
1254	pub fn publicity(&self) -> std::option::Option<&crate::model::GroupPublicity> {
1255		self.publicity.as_ref()
1256	}
1257	/// Unsigned 32 bit integer.
1258	pub fn member_count(&self) -> std::option::Option<i32> {
1259		self.member_count
1260	}
1261}
1262impl std::fmt::Debug for GroupSummary {
1263	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
1264		let mut formatter = f.debug_struct("GroupSummary");
1265		formatter.field("group_id", &self.group_id);
1266		formatter.field("display_name", &self.display_name);
1267		formatter.field("avatar_url", &self.avatar_url);
1268		formatter.field("external", &self.external);
1269		formatter.field("is_developer", &self.is_developer);
1270		formatter.field("bio", &self.bio);
1271		formatter.field(
1272			"is_current_identity_member",
1273			&self.is_current_identity_member,
1274		);
1275		formatter.field("publicity", &self.publicity);
1276		formatter.field("member_count", &self.member_count);
1277		formatter.finish()
1278	}
1279}
1280/// See [`GroupSummary`](crate::model::GroupSummary)
1281pub mod group_summary {
1282	/// A builder for [`GroupSummary`](crate::model::GroupSummary)
1283	#[non_exhaustive]
1284	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
1285	pub struct Builder {
1286		pub(crate) group_id: std::option::Option<std::string::String>,
1287		pub(crate) display_name: std::option::Option<std::string::String>,
1288		pub(crate) avatar_url: std::option::Option<std::string::String>,
1289		pub(crate) external: std::option::Option<crate::model::GroupExternalLinks>,
1290		pub(crate) is_developer: std::option::Option<bool>,
1291		pub(crate) bio: std::option::Option<std::string::String>,
1292		pub(crate) is_current_identity_member: std::option::Option<bool>,
1293		pub(crate) publicity: std::option::Option<crate::model::GroupPublicity>,
1294		pub(crate) member_count: std::option::Option<i32>,
1295	}
1296	impl Builder {
1297		/// A universally unique identifier.
1298		pub fn group_id(mut self, input: impl Into<std::string::String>) -> Self {
1299			self.group_id = Some(input.into());
1300			self
1301		}
1302		/// A universally unique identifier.
1303		pub fn set_group_id(mut self, input: std::option::Option<std::string::String>) -> Self {
1304			self.group_id = input;
1305			self
1306		}
1307		/// Represent a resource's readable display name.
1308		pub fn display_name(mut self, input: impl Into<std::string::String>) -> Self {
1309			self.display_name = Some(input.into());
1310			self
1311		}
1312		/// Represent a resource's readable display name.
1313		pub fn set_display_name(mut self, input: std::option::Option<std::string::String>) -> Self {
1314			self.display_name = input;
1315			self
1316		}
1317		/// The URL of this group's avatar image.
1318		pub fn avatar_url(mut self, input: impl Into<std::string::String>) -> Self {
1319			self.avatar_url = Some(input.into());
1320			self
1321		}
1322		/// The URL of this group's avatar image.
1323		pub fn set_avatar_url(mut self, input: std::option::Option<std::string::String>) -> Self {
1324			self.avatar_url = input;
1325			self
1326		}
1327		/// External links for this group.
1328		pub fn external(mut self, input: crate::model::GroupExternalLinks) -> Self {
1329			self.external = Some(input);
1330			self
1331		}
1332		/// External links for this group.
1333		pub fn set_external(
1334			mut self,
1335			input: std::option::Option<crate::model::GroupExternalLinks>,
1336		) -> Self {
1337			self.external = input;
1338			self
1339		}
1340		/// Whether or not this group is a developer.
1341		pub fn is_developer(mut self, input: bool) -> Self {
1342			self.is_developer = Some(input);
1343			self
1344		}
1345		/// Whether or not this group is a developer.
1346		pub fn set_is_developer(mut self, input: std::option::Option<bool>) -> Self {
1347			self.is_developer = input;
1348			self
1349		}
1350		/// Detailed information about a profile.
1351		pub fn bio(mut self, input: impl Into<std::string::String>) -> Self {
1352			self.bio = Some(input.into());
1353			self
1354		}
1355		/// Detailed information about a profile.
1356		pub fn set_bio(mut self, input: std::option::Option<std::string::String>) -> Self {
1357			self.bio = input;
1358			self
1359		}
1360		/// Whether or not the current identity is a member of this group.
1361		pub fn is_current_identity_member(mut self, input: bool) -> Self {
1362			self.is_current_identity_member = Some(input);
1363			self
1364		}
1365		/// Whether or not the current identity is a member of this group.
1366		pub fn set_is_current_identity_member(mut self, input: std::option::Option<bool>) -> Self {
1367			self.is_current_identity_member = input;
1368			self
1369		}
1370		/// The current publicity value for the given group.
1371		pub fn publicity(mut self, input: crate::model::GroupPublicity) -> Self {
1372			self.publicity = Some(input);
1373			self
1374		}
1375		/// The current publicity value for the given group.
1376		pub fn set_publicity(
1377			mut self,
1378			input: std::option::Option<crate::model::GroupPublicity>,
1379		) -> Self {
1380			self.publicity = input;
1381			self
1382		}
1383		/// Unsigned 32 bit integer.
1384		pub fn member_count(mut self, input: i32) -> Self {
1385			self.member_count = Some(input);
1386			self
1387		}
1388		/// Unsigned 32 bit integer.
1389		pub fn set_member_count(mut self, input: std::option::Option<i32>) -> Self {
1390			self.member_count = input;
1391			self
1392		}
1393		/// Consumes the builder and constructs a [`GroupSummary`](crate::model::GroupSummary)
1394		pub fn build(self) -> crate::model::GroupSummary {
1395			crate::model::GroupSummary {
1396				group_id: self.group_id,
1397				display_name: self.display_name,
1398				avatar_url: self.avatar_url,
1399				external: self.external,
1400				is_developer: self.is_developer,
1401				bio: self.bio,
1402				is_current_identity_member: self.is_current_identity_member,
1403				publicity: self.publicity,
1404				member_count: self.member_count,
1405			}
1406		}
1407	}
1408}
1409impl GroupSummary {
1410	/// Creates a new builder-style object to manufacture [`GroupSummary`](crate::model::GroupSummary)
1411	pub fn builder() -> crate::model::group_summary::Builder {
1412		crate::model::group_summary::Builder::default()
1413	}
1414}
1415
1416/// The current publicity value for the given group.
1417#[non_exhaustive]
1418#[derive(
1419	std::clone::Clone,
1420	std::cmp::Eq,
1421	std::cmp::Ord,
1422	std::cmp::PartialEq,
1423	std::cmp::PartialOrd,
1424	std::fmt::Debug,
1425	std::hash::Hash,
1426)]
1427pub enum GroupPublicity {
1428	#[allow(missing_docs)] // documentation missing in model
1429	Closed,
1430	#[allow(missing_docs)] // documentation missing in model
1431	Open,
1432	/// Unknown contains new variants that have been added since this code was generated.
1433	Unknown(String),
1434}
1435impl std::convert::From<&str> for GroupPublicity {
1436	fn from(s: &str) -> Self {
1437		match s {
1438			"closed" => GroupPublicity::Closed,
1439			"open" => GroupPublicity::Open,
1440			other => GroupPublicity::Unknown(other.to_owned()),
1441		}
1442	}
1443}
1444impl std::str::FromStr for GroupPublicity {
1445	type Err = std::convert::Infallible;
1446
1447	fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
1448		Ok(GroupPublicity::from(s))
1449	}
1450}
1451impl GroupPublicity {
1452	/// Returns the `&str` value of the enum member.
1453	pub fn as_str(&self) -> &str {
1454		match self {
1455			GroupPublicity::Closed => "closed",
1456			GroupPublicity::Open => "open",
1457			GroupPublicity::Unknown(s) => s.as_ref(),
1458		}
1459	}
1460	/// Returns all the `&str` values of the enum members.
1461	pub fn values() -> &'static [&'static str] {
1462		&["closed", "open"]
1463	}
1464}
1465impl AsRef<str> for GroupPublicity {
1466	fn as_ref(&self) -> &str {
1467		self.as_str()
1468	}
1469}
1470
1471/// External links for this group.
1472#[non_exhaustive]
1473#[derive(std::clone::Clone, std::cmp::PartialEq)]
1474pub struct GroupExternalLinks {
1475	/// A link to this group's profile page.
1476	pub profile: std::option::Option<std::string::String>,
1477	/// A link to this group's chat page.
1478	pub chat: std::option::Option<std::string::String>,
1479}
1480impl GroupExternalLinks {
1481	/// A link to this group's profile page.
1482	pub fn profile(&self) -> std::option::Option<&str> {
1483		self.profile.as_deref()
1484	}
1485	/// A link to this group's chat page.
1486	pub fn chat(&self) -> std::option::Option<&str> {
1487		self.chat.as_deref()
1488	}
1489}
1490impl std::fmt::Debug for GroupExternalLinks {
1491	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
1492		let mut formatter = f.debug_struct("GroupExternalLinks");
1493		formatter.field("profile", &self.profile);
1494		formatter.field("chat", &self.chat);
1495		formatter.finish()
1496	}
1497}
1498/// See [`GroupExternalLinks`](crate::model::GroupExternalLinks)
1499pub mod group_external_links {
1500	/// A builder for [`GroupExternalLinks`](crate::model::GroupExternalLinks)
1501	#[non_exhaustive]
1502	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
1503	pub struct Builder {
1504		pub(crate) profile: std::option::Option<std::string::String>,
1505		pub(crate) chat: std::option::Option<std::string::String>,
1506	}
1507	impl Builder {
1508		/// A link to this group's profile page.
1509		pub fn profile(mut self, input: impl Into<std::string::String>) -> Self {
1510			self.profile = Some(input.into());
1511			self
1512		}
1513		/// A link to this group's profile page.
1514		pub fn set_profile(mut self, input: std::option::Option<std::string::String>) -> Self {
1515			self.profile = input;
1516			self
1517		}
1518		/// A link to this group's chat page.
1519		pub fn chat(mut self, input: impl Into<std::string::String>) -> Self {
1520			self.chat = Some(input.into());
1521			self
1522		}
1523		/// A link to this group's chat page.
1524		pub fn set_chat(mut self, input: std::option::Option<std::string::String>) -> Self {
1525			self.chat = input;
1526			self
1527		}
1528		/// Consumes the builder and constructs a [`GroupExternalLinks`](crate::model::GroupExternalLinks)
1529		pub fn build(self) -> crate::model::GroupExternalLinks {
1530			crate::model::GroupExternalLinks {
1531				profile: self.profile,
1532				chat: self.chat,
1533			}
1534		}
1535	}
1536}
1537impl GroupExternalLinks {
1538	/// Creates a new builder-style object to manufacture [`GroupExternalLinks`](crate::model::GroupExternalLinks)
1539	pub fn builder() -> crate::model::group_external_links::Builder {
1540		crate::model::group_external_links::Builder::default()
1541	}
1542}
1543
1544/// A party summary.
1545#[non_exhaustive]
1546#[derive(std::clone::Clone, std::cmp::PartialEq)]
1547pub struct PartySummary {
1548	/// A universally unique identifier.
1549	pub party_id: std::option::Option<std::string::String>,
1550	/// RFC3339 timestamp.
1551	pub create_ts: std::option::Option<aws_smithy_types::DateTime>,
1552	/// A union representing the activity of a given party.
1553	pub activity: std::option::Option<crate::model::PartyActivity>,
1554	/// External links for a party.
1555	pub external: std::option::Option<crate::model::PartyExternalLinks>,
1556	#[allow(missing_docs)] // documentation missing in model
1557	pub publicity: std::option::Option<crate::model::PartyPublicity>,
1558	/// Unsigned 32 bit integer.
1559	pub party_size: std::option::Option<i32>,
1560	/// A list of party members.
1561	pub members: std::option::Option<std::vec::Vec<crate::model::PartyMemberSummary>>,
1562	/// A universally unique identifier.
1563	pub thread_id: std::option::Option<std::string::String>,
1564}
1565impl PartySummary {
1566	/// A universally unique identifier.
1567	pub fn party_id(&self) -> std::option::Option<&str> {
1568		self.party_id.as_deref()
1569	}
1570	/// RFC3339 timestamp.
1571	pub fn create_ts(&self) -> std::option::Option<&aws_smithy_types::DateTime> {
1572		self.create_ts.as_ref()
1573	}
1574	/// A union representing the activity of a given party.
1575	pub fn activity(&self) -> std::option::Option<&crate::model::PartyActivity> {
1576		self.activity.as_ref()
1577	}
1578	/// External links for a party.
1579	pub fn external(&self) -> std::option::Option<&crate::model::PartyExternalLinks> {
1580		self.external.as_ref()
1581	}
1582	#[allow(missing_docs)] // documentation missing in model
1583	pub fn publicity(&self) -> std::option::Option<&crate::model::PartyPublicity> {
1584		self.publicity.as_ref()
1585	}
1586	/// Unsigned 32 bit integer.
1587	pub fn party_size(&self) -> std::option::Option<i32> {
1588		self.party_size
1589	}
1590	/// A list of party members.
1591	pub fn members(&self) -> std::option::Option<&[crate::model::PartyMemberSummary]> {
1592		self.members.as_deref()
1593	}
1594	/// A universally unique identifier.
1595	pub fn thread_id(&self) -> std::option::Option<&str> {
1596		self.thread_id.as_deref()
1597	}
1598}
1599impl std::fmt::Debug for PartySummary {
1600	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
1601		let mut formatter = f.debug_struct("PartySummary");
1602		formatter.field("party_id", &self.party_id);
1603		formatter.field("create_ts", &self.create_ts);
1604		formatter.field("activity", &self.activity);
1605		formatter.field("external", &self.external);
1606		formatter.field("publicity", &self.publicity);
1607		formatter.field("party_size", &self.party_size);
1608		formatter.field("members", &self.members);
1609		formatter.field("thread_id", &self.thread_id);
1610		formatter.finish()
1611	}
1612}
1613/// See [`PartySummary`](crate::model::PartySummary)
1614pub mod party_summary {
1615	/// A builder for [`PartySummary`](crate::model::PartySummary)
1616	#[non_exhaustive]
1617	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
1618	pub struct Builder {
1619		pub(crate) party_id: std::option::Option<std::string::String>,
1620		pub(crate) create_ts: std::option::Option<aws_smithy_types::DateTime>,
1621		pub(crate) activity: std::option::Option<crate::model::PartyActivity>,
1622		pub(crate) external: std::option::Option<crate::model::PartyExternalLinks>,
1623		pub(crate) publicity: std::option::Option<crate::model::PartyPublicity>,
1624		pub(crate) party_size: std::option::Option<i32>,
1625		pub(crate) members: std::option::Option<std::vec::Vec<crate::model::PartyMemberSummary>>,
1626		pub(crate) thread_id: std::option::Option<std::string::String>,
1627	}
1628	impl Builder {
1629		/// A universally unique identifier.
1630		pub fn party_id(mut self, input: impl Into<std::string::String>) -> Self {
1631			self.party_id = Some(input.into());
1632			self
1633		}
1634		/// A universally unique identifier.
1635		pub fn set_party_id(mut self, input: std::option::Option<std::string::String>) -> Self {
1636			self.party_id = input;
1637			self
1638		}
1639		/// RFC3339 timestamp.
1640		pub fn create_ts(mut self, input: aws_smithy_types::DateTime) -> Self {
1641			self.create_ts = Some(input);
1642			self
1643		}
1644		/// RFC3339 timestamp.
1645		pub fn set_create_ts(
1646			mut self,
1647			input: std::option::Option<aws_smithy_types::DateTime>,
1648		) -> Self {
1649			self.create_ts = input;
1650			self
1651		}
1652		/// A union representing the activity of a given party.
1653		pub fn activity(mut self, input: crate::model::PartyActivity) -> Self {
1654			self.activity = Some(input);
1655			self
1656		}
1657		/// A union representing the activity of a given party.
1658		pub fn set_activity(
1659			mut self,
1660			input: std::option::Option<crate::model::PartyActivity>,
1661		) -> Self {
1662			self.activity = input;
1663			self
1664		}
1665		/// External links for a party.
1666		pub fn external(mut self, input: crate::model::PartyExternalLinks) -> Self {
1667			self.external = Some(input);
1668			self
1669		}
1670		/// External links for a party.
1671		pub fn set_external(
1672			mut self,
1673			input: std::option::Option<crate::model::PartyExternalLinks>,
1674		) -> Self {
1675			self.external = input;
1676			self
1677		}
1678		#[allow(missing_docs)] // documentation missing in model
1679		pub fn publicity(mut self, input: crate::model::PartyPublicity) -> Self {
1680			self.publicity = Some(input);
1681			self
1682		}
1683		#[allow(missing_docs)] // documentation missing in model
1684		pub fn set_publicity(
1685			mut self,
1686			input: std::option::Option<crate::model::PartyPublicity>,
1687		) -> Self {
1688			self.publicity = input;
1689			self
1690		}
1691		/// Unsigned 32 bit integer.
1692		pub fn party_size(mut self, input: i32) -> Self {
1693			self.party_size = Some(input);
1694			self
1695		}
1696		/// Unsigned 32 bit integer.
1697		pub fn set_party_size(mut self, input: std::option::Option<i32>) -> Self {
1698			self.party_size = input;
1699			self
1700		}
1701		/// Appends an item to `members`.
1702		///
1703		/// To override the contents of this collection use [`set_members`](Self::set_members).
1704		///
1705		/// A list of party members.
1706		pub fn members(mut self, input: crate::model::PartyMemberSummary) -> Self {
1707			let mut v = self.members.unwrap_or_default();
1708			v.push(input);
1709			self.members = Some(v);
1710			self
1711		}
1712		/// A list of party members.
1713		pub fn set_members(
1714			mut self,
1715			input: std::option::Option<std::vec::Vec<crate::model::PartyMemberSummary>>,
1716		) -> Self {
1717			self.members = input;
1718			self
1719		}
1720		/// A universally unique identifier.
1721		pub fn thread_id(mut self, input: impl Into<std::string::String>) -> Self {
1722			self.thread_id = Some(input.into());
1723			self
1724		}
1725		/// A universally unique identifier.
1726		pub fn set_thread_id(mut self, input: std::option::Option<std::string::String>) -> Self {
1727			self.thread_id = input;
1728			self
1729		}
1730		/// Consumes the builder and constructs a [`PartySummary`](crate::model::PartySummary)
1731		pub fn build(self) -> crate::model::PartySummary {
1732			crate::model::PartySummary {
1733				party_id: self.party_id,
1734				create_ts: self.create_ts,
1735				activity: self.activity,
1736				external: self.external,
1737				publicity: self.publicity,
1738				party_size: self.party_size,
1739				members: self.members,
1740				thread_id: self.thread_id,
1741			}
1742		}
1743	}
1744}
1745impl PartySummary {
1746	/// Creates a new builder-style object to manufacture [`PartySummary`](crate::model::PartySummary)
1747	pub fn builder() -> crate::model::party_summary::Builder {
1748		crate::model::party_summary::Builder::default()
1749	}
1750}
1751
1752/// A party member summary.
1753#[non_exhaustive]
1754#[derive(std::clone::Clone, std::cmp::PartialEq)]
1755pub struct PartyMemberSummary {
1756	/// An identity handle.
1757	pub identity: std::option::Option<crate::model::IdentityHandle>,
1758	/// Whether or not this party member is the leader of the given party.
1759	pub is_leader: std::option::Option<bool>,
1760	/// RFC3339 timestamp.
1761	pub join_ts: std::option::Option<aws_smithy_types::DateTime>,
1762	/// A union representing the current state of a party member.
1763	pub state: std::option::Option<crate::model::PartyMemberState>,
1764}
1765impl PartyMemberSummary {
1766	/// An identity handle.
1767	pub fn identity(&self) -> std::option::Option<&crate::model::IdentityHandle> {
1768		self.identity.as_ref()
1769	}
1770	/// Whether or not this party member is the leader of the given party.
1771	pub fn is_leader(&self) -> std::option::Option<bool> {
1772		self.is_leader
1773	}
1774	/// RFC3339 timestamp.
1775	pub fn join_ts(&self) -> std::option::Option<&aws_smithy_types::DateTime> {
1776		self.join_ts.as_ref()
1777	}
1778	/// A union representing the current state of a party member.
1779	pub fn state(&self) -> std::option::Option<&crate::model::PartyMemberState> {
1780		self.state.as_ref()
1781	}
1782}
1783impl std::fmt::Debug for PartyMemberSummary {
1784	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
1785		let mut formatter = f.debug_struct("PartyMemberSummary");
1786		formatter.field("identity", &self.identity);
1787		formatter.field("is_leader", &self.is_leader);
1788		formatter.field("join_ts", &self.join_ts);
1789		formatter.field("state", &self.state);
1790		formatter.finish()
1791	}
1792}
1793/// See [`PartyMemberSummary`](crate::model::PartyMemberSummary)
1794pub mod party_member_summary {
1795	/// A builder for [`PartyMemberSummary`](crate::model::PartyMemberSummary)
1796	#[non_exhaustive]
1797	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
1798	pub struct Builder {
1799		pub(crate) identity: std::option::Option<crate::model::IdentityHandle>,
1800		pub(crate) is_leader: std::option::Option<bool>,
1801		pub(crate) join_ts: std::option::Option<aws_smithy_types::DateTime>,
1802		pub(crate) state: std::option::Option<crate::model::PartyMemberState>,
1803	}
1804	impl Builder {
1805		/// An identity handle.
1806		pub fn identity(mut self, input: crate::model::IdentityHandle) -> Self {
1807			self.identity = Some(input);
1808			self
1809		}
1810		/// An identity handle.
1811		pub fn set_identity(
1812			mut self,
1813			input: std::option::Option<crate::model::IdentityHandle>,
1814		) -> Self {
1815			self.identity = input;
1816			self
1817		}
1818		/// Whether or not this party member is the leader of the given party.
1819		pub fn is_leader(mut self, input: bool) -> Self {
1820			self.is_leader = Some(input);
1821			self
1822		}
1823		/// Whether or not this party member is the leader of the given party.
1824		pub fn set_is_leader(mut self, input: std::option::Option<bool>) -> Self {
1825			self.is_leader = input;
1826			self
1827		}
1828		/// RFC3339 timestamp.
1829		pub fn join_ts(mut self, input: aws_smithy_types::DateTime) -> Self {
1830			self.join_ts = Some(input);
1831			self
1832		}
1833		/// RFC3339 timestamp.
1834		pub fn set_join_ts(
1835			mut self,
1836			input: std::option::Option<aws_smithy_types::DateTime>,
1837		) -> Self {
1838			self.join_ts = input;
1839			self
1840		}
1841		/// A union representing the current state of a party member.
1842		pub fn state(mut self, input: crate::model::PartyMemberState) -> Self {
1843			self.state = Some(input);
1844			self
1845		}
1846		/// A union representing the current state of a party member.
1847		pub fn set_state(
1848			mut self,
1849			input: std::option::Option<crate::model::PartyMemberState>,
1850		) -> Self {
1851			self.state = input;
1852			self
1853		}
1854		/// Consumes the builder and constructs a [`PartyMemberSummary`](crate::model::PartyMemberSummary)
1855		pub fn build(self) -> crate::model::PartyMemberSummary {
1856			crate::model::PartyMemberSummary {
1857				identity: self.identity,
1858				is_leader: self.is_leader,
1859				join_ts: self.join_ts,
1860				state: self.state,
1861			}
1862		}
1863	}
1864}
1865impl PartyMemberSummary {
1866	/// Creates a new builder-style object to manufacture [`PartyMemberSummary`](crate::model::PartyMemberSummary)
1867	pub fn builder() -> crate::model::party_member_summary::Builder {
1868		crate::model::party_member_summary::Builder::default()
1869	}
1870}
1871
1872/// A union representing the current state of a party member.
1873#[non_exhaustive]
1874#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
1875pub enum PartyMemberState {
1876	/// A party member state denoting that the member is idle.
1877	Idle(crate::model::PartyMemberStateIdle),
1878	/// A party member state denoting that the member is currently searching for a lobby.
1879	MatchmakerFindingLobby(crate::model::PartyMemberStateMatchmakerFindingLobby),
1880	/// A party member state denoting that the member is in a lobby.
1881	MatchmakerLobby(crate::model::PartyMemberStateMatchmakerLobby),
1882	/// A party member state denoting that the member is currently waiting to start matchmaking.
1883	MatchmakerPending(crate::model::PartyMemberStateMatchmakerPending),
1884	/// The `Unknown` variant represents cases where new union variant was received. Consider upgrading the SDK to the latest available version.
1885	/// An unknown enum variant
1886	///
1887	/// _Note: If you encounter this error, consider upgrading your SDK to the latest version._
1888	/// The `Unknown` variant represents cases where the server sent a value that wasn't recognized
1889	/// by the client. This can happen when the server adds new functionality, but the client has not been updated.
1890	/// To investigate this, consider turning on debug logging to print the raw HTTP response.
1891	#[non_exhaustive]
1892	Unknown,
1893}
1894impl PartyMemberState {
1895	/// Tries to convert the enum instance into [`Idle`](crate::model::PartyMemberState::Idle), extracting the inner [`PartyMemberStateIdle`](crate::model::PartyMemberStateIdle).
1896	/// Returns `Err(&Self)` if it can't be converted.
1897	pub fn as_idle(&self) -> std::result::Result<&crate::model::PartyMemberStateIdle, &Self> {
1898		if let PartyMemberState::Idle(val) = &self {
1899			Ok(val)
1900		} else {
1901			Err(self)
1902		}
1903	}
1904	/// Returns true if this is a [`Idle`](crate::model::PartyMemberState::Idle).
1905	pub fn is_idle(&self) -> bool {
1906		self.as_idle().is_ok()
1907	}
1908	/// Tries to convert the enum instance into [`MatchmakerFindingLobby`](crate::model::PartyMemberState::MatchmakerFindingLobby), extracting the inner [`PartyMemberStateMatchmakerFindingLobby`](crate::model::PartyMemberStateMatchmakerFindingLobby).
1909	/// Returns `Err(&Self)` if it can't be converted.
1910	pub fn as_matchmaker_finding_lobby(
1911		&self,
1912	) -> std::result::Result<&crate::model::PartyMemberStateMatchmakerFindingLobby, &Self> {
1913		if let PartyMemberState::MatchmakerFindingLobby(val) = &self {
1914			Ok(val)
1915		} else {
1916			Err(self)
1917		}
1918	}
1919	/// Returns true if this is a [`MatchmakerFindingLobby`](crate::model::PartyMemberState::MatchmakerFindingLobby).
1920	pub fn is_matchmaker_finding_lobby(&self) -> bool {
1921		self.as_matchmaker_finding_lobby().is_ok()
1922	}
1923	/// Tries to convert the enum instance into [`MatchmakerLobby`](crate::model::PartyMemberState::MatchmakerLobby), extracting the inner [`PartyMemberStateMatchmakerLobby`](crate::model::PartyMemberStateMatchmakerLobby).
1924	/// Returns `Err(&Self)` if it can't be converted.
1925	pub fn as_matchmaker_lobby(
1926		&self,
1927	) -> std::result::Result<&crate::model::PartyMemberStateMatchmakerLobby, &Self> {
1928		if let PartyMemberState::MatchmakerLobby(val) = &self {
1929			Ok(val)
1930		} else {
1931			Err(self)
1932		}
1933	}
1934	/// Returns true if this is a [`MatchmakerLobby`](crate::model::PartyMemberState::MatchmakerLobby).
1935	pub fn is_matchmaker_lobby(&self) -> bool {
1936		self.as_matchmaker_lobby().is_ok()
1937	}
1938	/// Tries to convert the enum instance into [`MatchmakerPending`](crate::model::PartyMemberState::MatchmakerPending), extracting the inner [`PartyMemberStateMatchmakerPending`](crate::model::PartyMemberStateMatchmakerPending).
1939	/// Returns `Err(&Self)` if it can't be converted.
1940	pub fn as_matchmaker_pending(
1941		&self,
1942	) -> std::result::Result<&crate::model::PartyMemberStateMatchmakerPending, &Self> {
1943		if let PartyMemberState::MatchmakerPending(val) = &self {
1944			Ok(val)
1945		} else {
1946			Err(self)
1947		}
1948	}
1949	/// Returns true if this is a [`MatchmakerPending`](crate::model::PartyMemberState::MatchmakerPending).
1950	pub fn is_matchmaker_pending(&self) -> bool {
1951		self.as_matchmaker_pending().is_ok()
1952	}
1953	/// Returns true if the enum instance is the `Unknown` variant.
1954	pub fn is_unknown(&self) -> bool {
1955		matches!(self, Self::Unknown)
1956	}
1957}
1958
1959/// A party member state denoting that the member is in a lobby.
1960#[non_exhaustive]
1961#[derive(std::clone::Clone, std::cmp::PartialEq)]
1962pub struct PartyMemberStateMatchmakerLobby {
1963	/// A universally unique identifier.
1964	pub player_id: std::option::Option<std::string::String>,
1965}
1966impl PartyMemberStateMatchmakerLobby {
1967	/// A universally unique identifier.
1968	pub fn player_id(&self) -> std::option::Option<&str> {
1969		self.player_id.as_deref()
1970	}
1971}
1972impl std::fmt::Debug for PartyMemberStateMatchmakerLobby {
1973	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
1974		let mut formatter = f.debug_struct("PartyMemberStateMatchmakerLobby");
1975		formatter.field("player_id", &self.player_id);
1976		formatter.finish()
1977	}
1978}
1979/// See [`PartyMemberStateMatchmakerLobby`](crate::model::PartyMemberStateMatchmakerLobby)
1980pub mod party_member_state_matchmaker_lobby {
1981	/// A builder for [`PartyMemberStateMatchmakerLobby`](crate::model::PartyMemberStateMatchmakerLobby)
1982	#[non_exhaustive]
1983	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
1984	pub struct Builder {
1985		pub(crate) player_id: std::option::Option<std::string::String>,
1986	}
1987	impl Builder {
1988		/// A universally unique identifier.
1989		pub fn player_id(mut self, input: impl Into<std::string::String>) -> Self {
1990			self.player_id = Some(input.into());
1991			self
1992		}
1993		/// A universally unique identifier.
1994		pub fn set_player_id(mut self, input: std::option::Option<std::string::String>) -> Self {
1995			self.player_id = input;
1996			self
1997		}
1998		/// Consumes the builder and constructs a [`PartyMemberStateMatchmakerLobby`](crate::model::PartyMemberStateMatchmakerLobby)
1999		pub fn build(self) -> crate::model::PartyMemberStateMatchmakerLobby {
2000			crate::model::PartyMemberStateMatchmakerLobby {
2001				player_id: self.player_id,
2002			}
2003		}
2004	}
2005}
2006impl PartyMemberStateMatchmakerLobby {
2007	/// Creates a new builder-style object to manufacture [`PartyMemberStateMatchmakerLobby`](crate::model::PartyMemberStateMatchmakerLobby)
2008	pub fn builder() -> crate::model::party_member_state_matchmaker_lobby::Builder {
2009		crate::model::party_member_state_matchmaker_lobby::Builder::default()
2010	}
2011}
2012
2013/// A party member state denoting that the member is currently searching for a lobby.
2014#[non_exhaustive]
2015#[derive(std::clone::Clone, std::cmp::PartialEq)]
2016pub struct PartyMemberStateMatchmakerFindingLobby {}
2017impl std::fmt::Debug for PartyMemberStateMatchmakerFindingLobby {
2018	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
2019		let mut formatter = f.debug_struct("PartyMemberStateMatchmakerFindingLobby");
2020		formatter.finish()
2021	}
2022}
2023/// See [`PartyMemberStateMatchmakerFindingLobby`](crate::model::PartyMemberStateMatchmakerFindingLobby)
2024pub mod party_member_state_matchmaker_finding_lobby {
2025	/// A builder for [`PartyMemberStateMatchmakerFindingLobby`](crate::model::PartyMemberStateMatchmakerFindingLobby)
2026	#[non_exhaustive]
2027	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
2028	pub struct Builder {}
2029	impl Builder {
2030		/// Consumes the builder and constructs a [`PartyMemberStateMatchmakerFindingLobby`](crate::model::PartyMemberStateMatchmakerFindingLobby)
2031		pub fn build(self) -> crate::model::PartyMemberStateMatchmakerFindingLobby {
2032			crate::model::PartyMemberStateMatchmakerFindingLobby {}
2033		}
2034	}
2035}
2036impl PartyMemberStateMatchmakerFindingLobby {
2037	/// Creates a new builder-style object to manufacture [`PartyMemberStateMatchmakerFindingLobby`](crate::model::PartyMemberStateMatchmakerFindingLobby)
2038	pub fn builder() -> crate::model::party_member_state_matchmaker_finding_lobby::Builder {
2039		crate::model::party_member_state_matchmaker_finding_lobby::Builder::default()
2040	}
2041}
2042
2043/// A party member state denoting that the member is currently waiting to start matchmaking.
2044#[non_exhaustive]
2045#[derive(std::clone::Clone, std::cmp::PartialEq)]
2046pub struct PartyMemberStateMatchmakerPending {}
2047impl std::fmt::Debug for PartyMemberStateMatchmakerPending {
2048	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
2049		let mut formatter = f.debug_struct("PartyMemberStateMatchmakerPending");
2050		formatter.finish()
2051	}
2052}
2053/// See [`PartyMemberStateMatchmakerPending`](crate::model::PartyMemberStateMatchmakerPending)
2054pub mod party_member_state_matchmaker_pending {
2055	/// A builder for [`PartyMemberStateMatchmakerPending`](crate::model::PartyMemberStateMatchmakerPending)
2056	#[non_exhaustive]
2057	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
2058	pub struct Builder {}
2059	impl Builder {
2060		/// Consumes the builder and constructs a [`PartyMemberStateMatchmakerPending`](crate::model::PartyMemberStateMatchmakerPending)
2061		pub fn build(self) -> crate::model::PartyMemberStateMatchmakerPending {
2062			crate::model::PartyMemberStateMatchmakerPending {}
2063		}
2064	}
2065}
2066impl PartyMemberStateMatchmakerPending {
2067	/// Creates a new builder-style object to manufacture [`PartyMemberStateMatchmakerPending`](crate::model::PartyMemberStateMatchmakerPending)
2068	pub fn builder() -> crate::model::party_member_state_matchmaker_pending::Builder {
2069		crate::model::party_member_state_matchmaker_pending::Builder::default()
2070	}
2071}
2072
2073/// A party member state denoting that the member is idle.
2074#[non_exhaustive]
2075#[derive(std::clone::Clone, std::cmp::PartialEq)]
2076pub struct PartyMemberStateIdle {}
2077impl std::fmt::Debug for PartyMemberStateIdle {
2078	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
2079		let mut formatter = f.debug_struct("PartyMemberStateIdle");
2080		formatter.finish()
2081	}
2082}
2083/// See [`PartyMemberStateIdle`](crate::model::PartyMemberStateIdle)
2084pub mod party_member_state_idle {
2085	/// A builder for [`PartyMemberStateIdle`](crate::model::PartyMemberStateIdle)
2086	#[non_exhaustive]
2087	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
2088	pub struct Builder {}
2089	impl Builder {
2090		/// Consumes the builder and constructs a [`PartyMemberStateIdle`](crate::model::PartyMemberStateIdle)
2091		pub fn build(self) -> crate::model::PartyMemberStateIdle {
2092			crate::model::PartyMemberStateIdle {}
2093		}
2094	}
2095}
2096impl PartyMemberStateIdle {
2097	/// Creates a new builder-style object to manufacture [`PartyMemberStateIdle`](crate::model::PartyMemberStateIdle)
2098	pub fn builder() -> crate::model::party_member_state_idle::Builder {
2099		crate::model::party_member_state_idle::Builder::default()
2100	}
2101}
2102
2103#[allow(missing_docs)] // documentation missing in model
2104#[non_exhaustive]
2105#[derive(std::clone::Clone, std::cmp::PartialEq)]
2106pub struct PartyPublicity {
2107	#[allow(missing_docs)] // documentation missing in model
2108	pub public: std::option::Option<crate::model::PartyPublicityLevel>,
2109	#[allow(missing_docs)] // documentation missing in model
2110	pub mutual_followers: std::option::Option<crate::model::PartyPublicityLevel>,
2111	#[allow(missing_docs)] // documentation missing in model
2112	pub groups: std::option::Option<crate::model::PartyPublicityLevel>,
2113}
2114impl PartyPublicity {
2115	#[allow(missing_docs)] // documentation missing in model
2116	pub fn public(&self) -> std::option::Option<&crate::model::PartyPublicityLevel> {
2117		self.public.as_ref()
2118	}
2119	#[allow(missing_docs)] // documentation missing in model
2120	pub fn mutual_followers(&self) -> std::option::Option<&crate::model::PartyPublicityLevel> {
2121		self.mutual_followers.as_ref()
2122	}
2123	#[allow(missing_docs)] // documentation missing in model
2124	pub fn groups(&self) -> std::option::Option<&crate::model::PartyPublicityLevel> {
2125		self.groups.as_ref()
2126	}
2127}
2128impl std::fmt::Debug for PartyPublicity {
2129	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
2130		let mut formatter = f.debug_struct("PartyPublicity");
2131		formatter.field("public", &self.public);
2132		formatter.field("mutual_followers", &self.mutual_followers);
2133		formatter.field("groups", &self.groups);
2134		formatter.finish()
2135	}
2136}
2137/// See [`PartyPublicity`](crate::model::PartyPublicity)
2138pub mod party_publicity {
2139	/// A builder for [`PartyPublicity`](crate::model::PartyPublicity)
2140	#[non_exhaustive]
2141	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
2142	pub struct Builder {
2143		pub(crate) public: std::option::Option<crate::model::PartyPublicityLevel>,
2144		pub(crate) mutual_followers: std::option::Option<crate::model::PartyPublicityLevel>,
2145		pub(crate) groups: std::option::Option<crate::model::PartyPublicityLevel>,
2146	}
2147	impl Builder {
2148		#[allow(missing_docs)] // documentation missing in model
2149		pub fn public(mut self, input: crate::model::PartyPublicityLevel) -> Self {
2150			self.public = Some(input);
2151			self
2152		}
2153		#[allow(missing_docs)] // documentation missing in model
2154		pub fn set_public(
2155			mut self,
2156			input: std::option::Option<crate::model::PartyPublicityLevel>,
2157		) -> Self {
2158			self.public = input;
2159			self
2160		}
2161		#[allow(missing_docs)] // documentation missing in model
2162		pub fn mutual_followers(mut self, input: crate::model::PartyPublicityLevel) -> Self {
2163			self.mutual_followers = Some(input);
2164			self
2165		}
2166		#[allow(missing_docs)] // documentation missing in model
2167		pub fn set_mutual_followers(
2168			mut self,
2169			input: std::option::Option<crate::model::PartyPublicityLevel>,
2170		) -> Self {
2171			self.mutual_followers = input;
2172			self
2173		}
2174		#[allow(missing_docs)] // documentation missing in model
2175		pub fn groups(mut self, input: crate::model::PartyPublicityLevel) -> Self {
2176			self.groups = Some(input);
2177			self
2178		}
2179		#[allow(missing_docs)] // documentation missing in model
2180		pub fn set_groups(
2181			mut self,
2182			input: std::option::Option<crate::model::PartyPublicityLevel>,
2183		) -> Self {
2184			self.groups = input;
2185			self
2186		}
2187		/// Consumes the builder and constructs a [`PartyPublicity`](crate::model::PartyPublicity)
2188		pub fn build(self) -> crate::model::PartyPublicity {
2189			crate::model::PartyPublicity {
2190				public: self.public,
2191				mutual_followers: self.mutual_followers,
2192				groups: self.groups,
2193			}
2194		}
2195	}
2196}
2197impl PartyPublicity {
2198	/// Creates a new builder-style object to manufacture [`PartyPublicity`](crate::model::PartyPublicity)
2199	pub fn builder() -> crate::model::party_publicity::Builder {
2200		crate::model::party_publicity::Builder::default()
2201	}
2202}
2203
2204#[allow(missing_docs)] // documentation missing in model
2205#[non_exhaustive]
2206#[derive(
2207	std::clone::Clone,
2208	std::cmp::Eq,
2209	std::cmp::Ord,
2210	std::cmp::PartialEq,
2211	std::cmp::PartialOrd,
2212	std::fmt::Debug,
2213	std::hash::Hash,
2214)]
2215pub enum PartyPublicityLevel {
2216	#[allow(missing_docs)] // documentation missing in model
2217	Join,
2218	#[allow(missing_docs)] // documentation missing in model
2219	None,
2220	#[allow(missing_docs)] // documentation missing in model
2221	View,
2222	/// Unknown contains new variants that have been added since this code was generated.
2223	Unknown(String),
2224}
2225impl std::convert::From<&str> for PartyPublicityLevel {
2226	fn from(s: &str) -> Self {
2227		match s {
2228			"join" => PartyPublicityLevel::Join,
2229			"none" => PartyPublicityLevel::None,
2230			"view" => PartyPublicityLevel::View,
2231			other => PartyPublicityLevel::Unknown(other.to_owned()),
2232		}
2233	}
2234}
2235impl std::str::FromStr for PartyPublicityLevel {
2236	type Err = std::convert::Infallible;
2237
2238	fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
2239		Ok(PartyPublicityLevel::from(s))
2240	}
2241}
2242impl PartyPublicityLevel {
2243	/// Returns the `&str` value of the enum member.
2244	pub fn as_str(&self) -> &str {
2245		match self {
2246			PartyPublicityLevel::Join => "join",
2247			PartyPublicityLevel::None => "none",
2248			PartyPublicityLevel::View => "view",
2249			PartyPublicityLevel::Unknown(s) => s.as_ref(),
2250		}
2251	}
2252	/// Returns all the `&str` values of the enum members.
2253	pub fn values() -> &'static [&'static str] {
2254		&["join", "none", "view"]
2255	}
2256}
2257impl AsRef<str> for PartyPublicityLevel {
2258	fn as_ref(&self) -> &str {
2259		self.as_str()
2260	}
2261}
2262
2263#[allow(missing_docs)] // documentation missing in model
2264#[non_exhaustive]
2265#[derive(std::clone::Clone, std::cmp::PartialEq)]
2266pub struct GetGameLinkNewIdentity {
2267	/// See `rivet.api.identity#SetupIdentityOutput$identity_token`.
2268	pub identity_token: std::option::Option<std::string::String>,
2269	/// See `rivet.api.identity#SetupIdentityOutput$identity_token_expire_ts`.
2270	pub identity_token_expire_ts: std::option::Option<aws_smithy_types::DateTime>,
2271	/// See `rivet.api.identity#SetupIdentityOutput$identity`.
2272	pub identity: std::option::Option<crate::model::IdentityProfile>,
2273}
2274impl GetGameLinkNewIdentity {
2275	/// See `rivet.api.identity#SetupIdentityOutput$identity_token`.
2276	pub fn identity_token(&self) -> std::option::Option<&str> {
2277		self.identity_token.as_deref()
2278	}
2279	/// See `rivet.api.identity#SetupIdentityOutput$identity_token_expire_ts`.
2280	pub fn identity_token_expire_ts(&self) -> std::option::Option<&aws_smithy_types::DateTime> {
2281		self.identity_token_expire_ts.as_ref()
2282	}
2283	/// See `rivet.api.identity#SetupIdentityOutput$identity`.
2284	pub fn identity(&self) -> std::option::Option<&crate::model::IdentityProfile> {
2285		self.identity.as_ref()
2286	}
2287}
2288impl std::fmt::Debug for GetGameLinkNewIdentity {
2289	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
2290		let mut formatter = f.debug_struct("GetGameLinkNewIdentity");
2291		formatter.field("identity_token", &"*** Sensitive Data Redacted ***");
2292		formatter.field("identity_token_expire_ts", &self.identity_token_expire_ts);
2293		formatter.field("identity", &self.identity);
2294		formatter.finish()
2295	}
2296}
2297/// See [`GetGameLinkNewIdentity`](crate::model::GetGameLinkNewIdentity)
2298pub mod get_game_link_new_identity {
2299	/// A builder for [`GetGameLinkNewIdentity`](crate::model::GetGameLinkNewIdentity)
2300	#[non_exhaustive]
2301	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
2302	pub struct Builder {
2303		pub(crate) identity_token: std::option::Option<std::string::String>,
2304		pub(crate) identity_token_expire_ts: std::option::Option<aws_smithy_types::DateTime>,
2305		pub(crate) identity: std::option::Option<crate::model::IdentityProfile>,
2306	}
2307	impl Builder {
2308		/// See `rivet.api.identity#SetupIdentityOutput$identity_token`.
2309		pub fn identity_token(mut self, input: impl Into<std::string::String>) -> Self {
2310			self.identity_token = Some(input.into());
2311			self
2312		}
2313		/// See `rivet.api.identity#SetupIdentityOutput$identity_token`.
2314		pub fn set_identity_token(
2315			mut self,
2316			input: std::option::Option<std::string::String>,
2317		) -> Self {
2318			self.identity_token = input;
2319			self
2320		}
2321		/// See `rivet.api.identity#SetupIdentityOutput$identity_token_expire_ts`.
2322		pub fn identity_token_expire_ts(mut self, input: aws_smithy_types::DateTime) -> Self {
2323			self.identity_token_expire_ts = Some(input);
2324			self
2325		}
2326		/// See `rivet.api.identity#SetupIdentityOutput$identity_token_expire_ts`.
2327		pub fn set_identity_token_expire_ts(
2328			mut self,
2329			input: std::option::Option<aws_smithy_types::DateTime>,
2330		) -> Self {
2331			self.identity_token_expire_ts = input;
2332			self
2333		}
2334		/// See `rivet.api.identity#SetupIdentityOutput$identity`.
2335		pub fn identity(mut self, input: crate::model::IdentityProfile) -> Self {
2336			self.identity = Some(input);
2337			self
2338		}
2339		/// See `rivet.api.identity#SetupIdentityOutput$identity`.
2340		pub fn set_identity(
2341			mut self,
2342			input: std::option::Option<crate::model::IdentityProfile>,
2343		) -> Self {
2344			self.identity = input;
2345			self
2346		}
2347		/// Consumes the builder and constructs a [`GetGameLinkNewIdentity`](crate::model::GetGameLinkNewIdentity)
2348		pub fn build(self) -> crate::model::GetGameLinkNewIdentity {
2349			crate::model::GetGameLinkNewIdentity {
2350				identity_token: self.identity_token,
2351				identity_token_expire_ts: self.identity_token_expire_ts,
2352				identity: self.identity,
2353			}
2354		}
2355	}
2356}
2357impl GetGameLinkNewIdentity {
2358	/// Creates a new builder-style object to manufacture [`GetGameLinkNewIdentity`](crate::model::GetGameLinkNewIdentity)
2359	pub fn builder() -> crate::model::get_game_link_new_identity::Builder {
2360		crate::model::get_game_link_new_identity::Builder::default()
2361	}
2362}
2363
2364/// An identity profile.
2365#[non_exhaustive]
2366#[derive(std::clone::Clone, std::cmp::PartialEq)]
2367pub struct IdentityProfile {
2368	/// A universally unique identifier.
2369	pub identity_id: std::option::Option<std::string::String>,
2370	/// Represent a resource's readable display name.
2371	pub display_name: std::option::Option<std::string::String>,
2372	/// 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.
2373	pub account_number: std::option::Option<i32>,
2374	/// The URL of this identity's avatar image.
2375	pub avatar_url: std::option::Option<std::string::String>,
2376	/// Information about the identity's current status, party, and active game.
2377	pub presence: std::option::Option<crate::model::IdentityPresence>,
2378	/// A party summary.
2379	pub party: std::option::Option<crate::model::PartySummary>,
2380	/// Whether or not this identity is registered with a linked account.
2381	pub is_registered: std::option::Option<bool>,
2382	/// External links for an identity.
2383	pub external: std::option::Option<crate::model::IdentityExternalLinks>,
2384	/// Whether or not this identity is an admin.
2385	pub is_admin: std::option::Option<bool>,
2386	/// Whether or not this game user has been linked through the Rivet dashboard.
2387	pub is_game_linked: std::option::Option<bool>,
2388	/// The state of the given identity's developer status.
2389	pub dev_state: std::option::Option<crate::model::IdentityDevState>,
2390	/// Unsigned 32 bit integer.
2391	pub follower_count: std::option::Option<i32>,
2392	/// Unsigned 32 bit integer.
2393	pub following_count: std::option::Option<i32>,
2394	/// Whether or not the requestee's identity is following this identity.
2395	pub following: std::option::Option<bool>,
2396	/// Whether or not this identity following the requestee's identity.
2397	pub is_following_me: std::option::Option<bool>,
2398	/// Whether or not this identity is both followng and is followed by the requestee's identity.
2399	pub is_mutual_following: std::option::Option<bool>,
2400	/// RFC3339 timestamp.
2401	pub join_ts: std::option::Option<aws_smithy_types::DateTime>,
2402	/// Detailed information about a profile.
2403	pub bio: std::option::Option<std::string::String>,
2404	/// A list of an identity's linked accounts.
2405	pub linked_accounts: std::option::Option<std::vec::Vec<crate::model::IdentityLinkedAccount>>,
2406	/// A list of groups that the given identity is in.
2407	pub groups: std::option::Option<std::vec::Vec<crate::model::IdentityGroup>>,
2408	/// A list of game statistic summaries.
2409	pub games: std::option::Option<std::vec::Vec<crate::model::GameStatSummary>>,
2410}
2411impl IdentityProfile {
2412	/// A universally unique identifier.
2413	pub fn identity_id(&self) -> std::option::Option<&str> {
2414		self.identity_id.as_deref()
2415	}
2416	/// Represent a resource's readable display name.
2417	pub fn display_name(&self) -> std::option::Option<&str> {
2418		self.display_name.as_deref()
2419	}
2420	/// 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.
2421	pub fn account_number(&self) -> std::option::Option<i32> {
2422		self.account_number
2423	}
2424	/// The URL of this identity's avatar image.
2425	pub fn avatar_url(&self) -> std::option::Option<&str> {
2426		self.avatar_url.as_deref()
2427	}
2428	/// Information about the identity's current status, party, and active game.
2429	pub fn presence(&self) -> std::option::Option<&crate::model::IdentityPresence> {
2430		self.presence.as_ref()
2431	}
2432	/// A party summary.
2433	pub fn party(&self) -> std::option::Option<&crate::model::PartySummary> {
2434		self.party.as_ref()
2435	}
2436	/// Whether or not this identity is registered with a linked account.
2437	pub fn is_registered(&self) -> std::option::Option<bool> {
2438		self.is_registered
2439	}
2440	/// External links for an identity.
2441	pub fn external(&self) -> std::option::Option<&crate::model::IdentityExternalLinks> {
2442		self.external.as_ref()
2443	}
2444	/// Whether or not this identity is an admin.
2445	pub fn is_admin(&self) -> std::option::Option<bool> {
2446		self.is_admin
2447	}
2448	/// Whether or not this game user has been linked through the Rivet dashboard.
2449	pub fn is_game_linked(&self) -> std::option::Option<bool> {
2450		self.is_game_linked
2451	}
2452	/// The state of the given identity's developer status.
2453	pub fn dev_state(&self) -> std::option::Option<&crate::model::IdentityDevState> {
2454		self.dev_state.as_ref()
2455	}
2456	/// Unsigned 32 bit integer.
2457	pub fn follower_count(&self) -> std::option::Option<i32> {
2458		self.follower_count
2459	}
2460	/// Unsigned 32 bit integer.
2461	pub fn following_count(&self) -> std::option::Option<i32> {
2462		self.following_count
2463	}
2464	/// Whether or not the requestee's identity is following this identity.
2465	pub fn following(&self) -> std::option::Option<bool> {
2466		self.following
2467	}
2468	/// Whether or not this identity following the requestee's identity.
2469	pub fn is_following_me(&self) -> std::option::Option<bool> {
2470		self.is_following_me
2471	}
2472	/// Whether or not this identity is both followng and is followed by the requestee's identity.
2473	pub fn is_mutual_following(&self) -> std::option::Option<bool> {
2474		self.is_mutual_following
2475	}
2476	/// RFC3339 timestamp.
2477	pub fn join_ts(&self) -> std::option::Option<&aws_smithy_types::DateTime> {
2478		self.join_ts.as_ref()
2479	}
2480	/// Detailed information about a profile.
2481	pub fn bio(&self) -> std::option::Option<&str> {
2482		self.bio.as_deref()
2483	}
2484	/// A list of an identity's linked accounts.
2485	pub fn linked_accounts(&self) -> std::option::Option<&[crate::model::IdentityLinkedAccount]> {
2486		self.linked_accounts.as_deref()
2487	}
2488	/// A list of groups that the given identity is in.
2489	pub fn groups(&self) -> std::option::Option<&[crate::model::IdentityGroup]> {
2490		self.groups.as_deref()
2491	}
2492	/// A list of game statistic summaries.
2493	pub fn games(&self) -> std::option::Option<&[crate::model::GameStatSummary]> {
2494		self.games.as_deref()
2495	}
2496}
2497impl std::fmt::Debug for IdentityProfile {
2498	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
2499		let mut formatter = f.debug_struct("IdentityProfile");
2500		formatter.field("identity_id", &self.identity_id);
2501		formatter.field("display_name", &self.display_name);
2502		formatter.field("account_number", &self.account_number);
2503		formatter.field("avatar_url", &self.avatar_url);
2504		formatter.field("presence", &self.presence);
2505		formatter.field("party", &self.party);
2506		formatter.field("is_registered", &self.is_registered);
2507		formatter.field("external", &self.external);
2508		formatter.field("is_admin", &self.is_admin);
2509		formatter.field("is_game_linked", &self.is_game_linked);
2510		formatter.field("dev_state", &self.dev_state);
2511		formatter.field("follower_count", &self.follower_count);
2512		formatter.field("following_count", &self.following_count);
2513		formatter.field("following", &self.following);
2514		formatter.field("is_following_me", &self.is_following_me);
2515		formatter.field("is_mutual_following", &self.is_mutual_following);
2516		formatter.field("join_ts", &self.join_ts);
2517		formatter.field("bio", &self.bio);
2518		formatter.field("linked_accounts", &"*** Sensitive Data Redacted ***");
2519		formatter.field("groups", &self.groups);
2520		formatter.field("games", &self.games);
2521		formatter.finish()
2522	}
2523}
2524/// See [`IdentityProfile`](crate::model::IdentityProfile)
2525pub mod identity_profile {
2526	/// A builder for [`IdentityProfile`](crate::model::IdentityProfile)
2527	#[non_exhaustive]
2528	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
2529	pub struct Builder {
2530		pub(crate) identity_id: std::option::Option<std::string::String>,
2531		pub(crate) display_name: std::option::Option<std::string::String>,
2532		pub(crate) account_number: std::option::Option<i32>,
2533		pub(crate) avatar_url: std::option::Option<std::string::String>,
2534		pub(crate) presence: std::option::Option<crate::model::IdentityPresence>,
2535		pub(crate) party: std::option::Option<crate::model::PartySummary>,
2536		pub(crate) is_registered: std::option::Option<bool>,
2537		pub(crate) external: std::option::Option<crate::model::IdentityExternalLinks>,
2538		pub(crate) is_admin: std::option::Option<bool>,
2539		pub(crate) is_game_linked: std::option::Option<bool>,
2540		pub(crate) dev_state: std::option::Option<crate::model::IdentityDevState>,
2541		pub(crate) follower_count: std::option::Option<i32>,
2542		pub(crate) following_count: std::option::Option<i32>,
2543		pub(crate) following: std::option::Option<bool>,
2544		pub(crate) is_following_me: std::option::Option<bool>,
2545		pub(crate) is_mutual_following: std::option::Option<bool>,
2546		pub(crate) join_ts: std::option::Option<aws_smithy_types::DateTime>,
2547		pub(crate) bio: std::option::Option<std::string::String>,
2548		pub(crate) linked_accounts:
2549			std::option::Option<std::vec::Vec<crate::model::IdentityLinkedAccount>>,
2550		pub(crate) groups: std::option::Option<std::vec::Vec<crate::model::IdentityGroup>>,
2551		pub(crate) games: std::option::Option<std::vec::Vec<crate::model::GameStatSummary>>,
2552	}
2553	impl Builder {
2554		/// A universally unique identifier.
2555		pub fn identity_id(mut self, input: impl Into<std::string::String>) -> Self {
2556			self.identity_id = Some(input.into());
2557			self
2558		}
2559		/// A universally unique identifier.
2560		pub fn set_identity_id(mut self, input: std::option::Option<std::string::String>) -> Self {
2561			self.identity_id = input;
2562			self
2563		}
2564		/// Represent a resource's readable display name.
2565		pub fn display_name(mut self, input: impl Into<std::string::String>) -> Self {
2566			self.display_name = Some(input.into());
2567			self
2568		}
2569		/// Represent a resource's readable display name.
2570		pub fn set_display_name(mut self, input: std::option::Option<std::string::String>) -> Self {
2571			self.display_name = input;
2572			self
2573		}
2574		/// 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.
2575		pub fn account_number(mut self, input: i32) -> Self {
2576			self.account_number = Some(input);
2577			self
2578		}
2579		/// 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.
2580		pub fn set_account_number(mut self, input: std::option::Option<i32>) -> Self {
2581			self.account_number = input;
2582			self
2583		}
2584		/// The URL of this identity's avatar image.
2585		pub fn avatar_url(mut self, input: impl Into<std::string::String>) -> Self {
2586			self.avatar_url = Some(input.into());
2587			self
2588		}
2589		/// The URL of this identity's avatar image.
2590		pub fn set_avatar_url(mut self, input: std::option::Option<std::string::String>) -> Self {
2591			self.avatar_url = input;
2592			self
2593		}
2594		/// Information about the identity's current status, party, and active game.
2595		pub fn presence(mut self, input: crate::model::IdentityPresence) -> Self {
2596			self.presence = Some(input);
2597			self
2598		}
2599		/// Information about the identity's current status, party, and active game.
2600		pub fn set_presence(
2601			mut self,
2602			input: std::option::Option<crate::model::IdentityPresence>,
2603		) -> Self {
2604			self.presence = input;
2605			self
2606		}
2607		/// A party summary.
2608		pub fn party(mut self, input: crate::model::PartySummary) -> Self {
2609			self.party = Some(input);
2610			self
2611		}
2612		/// A party summary.
2613		pub fn set_party(mut self, input: std::option::Option<crate::model::PartySummary>) -> Self {
2614			self.party = input;
2615			self
2616		}
2617		/// Whether or not this identity is registered with a linked account.
2618		pub fn is_registered(mut self, input: bool) -> Self {
2619			self.is_registered = Some(input);
2620			self
2621		}
2622		/// Whether or not this identity is registered with a linked account.
2623		pub fn set_is_registered(mut self, input: std::option::Option<bool>) -> Self {
2624			self.is_registered = input;
2625			self
2626		}
2627		/// External links for an identity.
2628		pub fn external(mut self, input: crate::model::IdentityExternalLinks) -> Self {
2629			self.external = Some(input);
2630			self
2631		}
2632		/// External links for an identity.
2633		pub fn set_external(
2634			mut self,
2635			input: std::option::Option<crate::model::IdentityExternalLinks>,
2636		) -> Self {
2637			self.external = input;
2638			self
2639		}
2640		/// Whether or not this identity is an admin.
2641		pub fn is_admin(mut self, input: bool) -> Self {
2642			self.is_admin = Some(input);
2643			self
2644		}
2645		/// Whether or not this identity is an admin.
2646		pub fn set_is_admin(mut self, input: std::option::Option<bool>) -> Self {
2647			self.is_admin = input;
2648			self
2649		}
2650		/// Whether or not this game user has been linked through the Rivet dashboard.
2651		pub fn is_game_linked(mut self, input: bool) -> Self {
2652			self.is_game_linked = Some(input);
2653			self
2654		}
2655		/// Whether or not this game user has been linked through the Rivet dashboard.
2656		pub fn set_is_game_linked(mut self, input: std::option::Option<bool>) -> Self {
2657			self.is_game_linked = input;
2658			self
2659		}
2660		/// The state of the given identity's developer status.
2661		pub fn dev_state(mut self, input: crate::model::IdentityDevState) -> Self {
2662			self.dev_state = Some(input);
2663			self
2664		}
2665		/// The state of the given identity's developer status.
2666		pub fn set_dev_state(
2667			mut self,
2668			input: std::option::Option<crate::model::IdentityDevState>,
2669		) -> Self {
2670			self.dev_state = input;
2671			self
2672		}
2673		/// Unsigned 32 bit integer.
2674		pub fn follower_count(mut self, input: i32) -> Self {
2675			self.follower_count = Some(input);
2676			self
2677		}
2678		/// Unsigned 32 bit integer.
2679		pub fn set_follower_count(mut self, input: std::option::Option<i32>) -> Self {
2680			self.follower_count = input;
2681			self
2682		}
2683		/// Unsigned 32 bit integer.
2684		pub fn following_count(mut self, input: i32) -> Self {
2685			self.following_count = Some(input);
2686			self
2687		}
2688		/// Unsigned 32 bit integer.
2689		pub fn set_following_count(mut self, input: std::option::Option<i32>) -> Self {
2690			self.following_count = input;
2691			self
2692		}
2693		/// Whether or not the requestee's identity is following this identity.
2694		pub fn following(mut self, input: bool) -> Self {
2695			self.following = Some(input);
2696			self
2697		}
2698		/// Whether or not the requestee's identity is following this identity.
2699		pub fn set_following(mut self, input: std::option::Option<bool>) -> Self {
2700			self.following = input;
2701			self
2702		}
2703		/// Whether or not this identity following the requestee's identity.
2704		pub fn is_following_me(mut self, input: bool) -> Self {
2705			self.is_following_me = Some(input);
2706			self
2707		}
2708		/// Whether or not this identity following the requestee's identity.
2709		pub fn set_is_following_me(mut self, input: std::option::Option<bool>) -> Self {
2710			self.is_following_me = input;
2711			self
2712		}
2713		/// Whether or not this identity is both followng and is followed by the requestee's identity.
2714		pub fn is_mutual_following(mut self, input: bool) -> Self {
2715			self.is_mutual_following = Some(input);
2716			self
2717		}
2718		/// Whether or not this identity is both followng and is followed by the requestee's identity.
2719		pub fn set_is_mutual_following(mut self, input: std::option::Option<bool>) -> Self {
2720			self.is_mutual_following = input;
2721			self
2722		}
2723		/// RFC3339 timestamp.
2724		pub fn join_ts(mut self, input: aws_smithy_types::DateTime) -> Self {
2725			self.join_ts = Some(input);
2726			self
2727		}
2728		/// RFC3339 timestamp.
2729		pub fn set_join_ts(
2730			mut self,
2731			input: std::option::Option<aws_smithy_types::DateTime>,
2732		) -> Self {
2733			self.join_ts = input;
2734			self
2735		}
2736		/// Detailed information about a profile.
2737		pub fn bio(mut self, input: impl Into<std::string::String>) -> Self {
2738			self.bio = Some(input.into());
2739			self
2740		}
2741		/// Detailed information about a profile.
2742		pub fn set_bio(mut self, input: std::option::Option<std::string::String>) -> Self {
2743			self.bio = input;
2744			self
2745		}
2746		/// Appends an item to `linked_accounts`.
2747		///
2748		/// To override the contents of this collection use [`set_linked_accounts`](Self::set_linked_accounts).
2749		///
2750		/// A list of an identity's linked accounts.
2751		pub fn linked_accounts(mut self, input: crate::model::IdentityLinkedAccount) -> Self {
2752			let mut v = self.linked_accounts.unwrap_or_default();
2753			v.push(input);
2754			self.linked_accounts = Some(v);
2755			self
2756		}
2757		/// A list of an identity's linked accounts.
2758		pub fn set_linked_accounts(
2759			mut self,
2760			input: std::option::Option<std::vec::Vec<crate::model::IdentityLinkedAccount>>,
2761		) -> Self {
2762			self.linked_accounts = input;
2763			self
2764		}
2765		/// Appends an item to `groups`.
2766		///
2767		/// To override the contents of this collection use [`set_groups`](Self::set_groups).
2768		///
2769		/// A list of groups that the given identity is in.
2770		pub fn groups(mut self, input: crate::model::IdentityGroup) -> Self {
2771			let mut v = self.groups.unwrap_or_default();
2772			v.push(input);
2773			self.groups = Some(v);
2774			self
2775		}
2776		/// A list of groups that the given identity is in.
2777		pub fn set_groups(
2778			mut self,
2779			input: std::option::Option<std::vec::Vec<crate::model::IdentityGroup>>,
2780		) -> Self {
2781			self.groups = input;
2782			self
2783		}
2784		/// Appends an item to `games`.
2785		///
2786		/// To override the contents of this collection use [`set_games`](Self::set_games).
2787		///
2788		/// A list of game statistic summaries.
2789		pub fn games(mut self, input: crate::model::GameStatSummary) -> Self {
2790			let mut v = self.games.unwrap_or_default();
2791			v.push(input);
2792			self.games = Some(v);
2793			self
2794		}
2795		/// A list of game statistic summaries.
2796		pub fn set_games(
2797			mut self,
2798			input: std::option::Option<std::vec::Vec<crate::model::GameStatSummary>>,
2799		) -> Self {
2800			self.games = input;
2801			self
2802		}
2803		/// Consumes the builder and constructs a [`IdentityProfile`](crate::model::IdentityProfile)
2804		pub fn build(self) -> crate::model::IdentityProfile {
2805			crate::model::IdentityProfile {
2806				identity_id: self.identity_id,
2807				display_name: self.display_name,
2808				account_number: self.account_number,
2809				avatar_url: self.avatar_url,
2810				presence: self.presence,
2811				party: self.party,
2812				is_registered: self.is_registered,
2813				external: self.external,
2814				is_admin: self.is_admin,
2815				is_game_linked: self.is_game_linked,
2816				dev_state: self.dev_state,
2817				follower_count: self.follower_count,
2818				following_count: self.following_count,
2819				following: self.following,
2820				is_following_me: self.is_following_me,
2821				is_mutual_following: self.is_mutual_following,
2822				join_ts: self.join_ts,
2823				bio: self.bio,
2824				linked_accounts: self.linked_accounts,
2825				groups: self.groups,
2826				games: self.games,
2827			}
2828		}
2829	}
2830}
2831impl IdentityProfile {
2832	/// Creates a new builder-style object to manufacture [`IdentityProfile`](crate::model::IdentityProfile)
2833	pub fn builder() -> crate::model::identity_profile::Builder {
2834		crate::model::identity_profile::Builder::default()
2835	}
2836}
2837
2838/// A game statistic summary.
2839#[non_exhaustive]
2840#[derive(std::clone::Clone, std::cmp::PartialEq)]
2841pub struct GameStatSummary {
2842	/// A game handle.
2843	pub game: std::option::Option<crate::model::GameHandle>,
2844	/// A list of game statistics.
2845	pub stats: std::option::Option<std::vec::Vec<crate::model::GameStat>>,
2846}
2847impl GameStatSummary {
2848	/// A game handle.
2849	pub fn game(&self) -> std::option::Option<&crate::model::GameHandle> {
2850		self.game.as_ref()
2851	}
2852	/// A list of game statistics.
2853	pub fn stats(&self) -> std::option::Option<&[crate::model::GameStat]> {
2854		self.stats.as_deref()
2855	}
2856}
2857impl std::fmt::Debug for GameStatSummary {
2858	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
2859		let mut formatter = f.debug_struct("GameStatSummary");
2860		formatter.field("game", &self.game);
2861		formatter.field("stats", &self.stats);
2862		formatter.finish()
2863	}
2864}
2865/// See [`GameStatSummary`](crate::model::GameStatSummary)
2866pub mod game_stat_summary {
2867	/// A builder for [`GameStatSummary`](crate::model::GameStatSummary)
2868	#[non_exhaustive]
2869	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
2870	pub struct Builder {
2871		pub(crate) game: std::option::Option<crate::model::GameHandle>,
2872		pub(crate) stats: std::option::Option<std::vec::Vec<crate::model::GameStat>>,
2873	}
2874	impl Builder {
2875		/// A game handle.
2876		pub fn game(mut self, input: crate::model::GameHandle) -> Self {
2877			self.game = Some(input);
2878			self
2879		}
2880		/// A game handle.
2881		pub fn set_game(mut self, input: std::option::Option<crate::model::GameHandle>) -> Self {
2882			self.game = input;
2883			self
2884		}
2885		/// Appends an item to `stats`.
2886		///
2887		/// To override the contents of this collection use [`set_stats`](Self::set_stats).
2888		///
2889		/// A list of game statistics.
2890		pub fn stats(mut self, input: crate::model::GameStat) -> Self {
2891			let mut v = self.stats.unwrap_or_default();
2892			v.push(input);
2893			self.stats = Some(v);
2894			self
2895		}
2896		/// A list of game statistics.
2897		pub fn set_stats(
2898			mut self,
2899			input: std::option::Option<std::vec::Vec<crate::model::GameStat>>,
2900		) -> Self {
2901			self.stats = input;
2902			self
2903		}
2904		/// Consumes the builder and constructs a [`GameStatSummary`](crate::model::GameStatSummary)
2905		pub fn build(self) -> crate::model::GameStatSummary {
2906			crate::model::GameStatSummary {
2907				game: self.game,
2908				stats: self.stats,
2909			}
2910		}
2911	}
2912}
2913impl GameStatSummary {
2914	/// Creates a new builder-style object to manufacture [`GameStatSummary`](crate::model::GameStatSummary)
2915	pub fn builder() -> crate::model::game_stat_summary::Builder {
2916		crate::model::game_stat_summary::Builder::default()
2917	}
2918}
2919
2920/// A game statistic.
2921#[non_exhaustive]
2922#[derive(std::clone::Clone, std::cmp::PartialEq)]
2923pub struct GameStat {
2924	/// A game statistic config.
2925	pub config: std::option::Option<crate::model::GameStatConfig>,
2926	/// A single overall value of the given statistic.
2927	pub overall_value: std::option::Option<f32>,
2928}
2929impl GameStat {
2930	/// A game statistic config.
2931	pub fn config(&self) -> std::option::Option<&crate::model::GameStatConfig> {
2932		self.config.as_ref()
2933	}
2934	/// A single overall value of the given statistic.
2935	pub fn overall_value(&self) -> std::option::Option<f32> {
2936		self.overall_value
2937	}
2938}
2939impl std::fmt::Debug for GameStat {
2940	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
2941		let mut formatter = f.debug_struct("GameStat");
2942		formatter.field("config", &self.config);
2943		formatter.field("overall_value", &self.overall_value);
2944		formatter.finish()
2945	}
2946}
2947/// See [`GameStat`](crate::model::GameStat)
2948pub mod game_stat {
2949	/// A builder for [`GameStat`](crate::model::GameStat)
2950	#[non_exhaustive]
2951	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
2952	pub struct Builder {
2953		pub(crate) config: std::option::Option<crate::model::GameStatConfig>,
2954		pub(crate) overall_value: std::option::Option<f32>,
2955	}
2956	impl Builder {
2957		/// A game statistic config.
2958		pub fn config(mut self, input: crate::model::GameStatConfig) -> Self {
2959			self.config = Some(input);
2960			self
2961		}
2962		/// A game statistic config.
2963		pub fn set_config(
2964			mut self,
2965			input: std::option::Option<crate::model::GameStatConfig>,
2966		) -> Self {
2967			self.config = input;
2968			self
2969		}
2970		/// A single overall value of the given statistic.
2971		pub fn overall_value(mut self, input: f32) -> Self {
2972			self.overall_value = Some(input);
2973			self
2974		}
2975		/// A single overall value of the given statistic.
2976		pub fn set_overall_value(mut self, input: std::option::Option<f32>) -> Self {
2977			self.overall_value = input;
2978			self
2979		}
2980		/// Consumes the builder and constructs a [`GameStat`](crate::model::GameStat)
2981		pub fn build(self) -> crate::model::GameStat {
2982			crate::model::GameStat {
2983				config: self.config,
2984				overall_value: self.overall_value,
2985			}
2986		}
2987	}
2988}
2989impl GameStat {
2990	/// Creates a new builder-style object to manufacture [`GameStat`](crate::model::GameStat)
2991	pub fn builder() -> crate::model::game_stat::Builder {
2992		crate::model::game_stat::Builder::default()
2993	}
2994}
2995
2996/// A game statistic config.
2997#[non_exhaustive]
2998#[derive(std::clone::Clone, std::cmp::PartialEq)]
2999pub struct GameStatConfig {
3000	/// A universally unique identifier.
3001	pub record_id: std::option::Option<std::string::String>,
3002	/// A universally unique identifier.
3003	pub icon_id: std::option::Option<std::string::String>,
3004	/// A value denoting the format method of a game statistic.
3005	pub format: std::option::Option<crate::model::GameStatFormatMethod>,
3006	/// A value denoting the aggregation method of a game statistic.
3007	pub aggregation: std::option::Option<crate::model::GameStatAggregationMethod>,
3008	/// A value denoting the sorting method of a game statistic.
3009	pub sorting: std::option::Option<crate::model::GameStatSortingMethod>,
3010	/// Unsigned 32 bit integer.
3011	pub priority: std::option::Option<i32>,
3012	/// Represent a resource's readable display name.
3013	pub display_name: std::option::Option<std::string::String>,
3014	/// A string appended to the end of a singular game statistic's value. Example: 1 **dollar**.
3015	pub postfix_singular: std::option::Option<std::string::String>,
3016	/// A string appended to the end of a game statistic's value that is not exactly 1. Example: 45 **dollars**.
3017	pub postfix_plural: std::option::Option<std::string::String>,
3018	/// A string appended to the beginning of a singular game statistic's value. Example: **value** 1.
3019	pub prefix_singular: std::option::Option<std::string::String>,
3020	/// A string prepended to the beginning of a game statistic's value that is not exactly 1. Example: **values** 45.
3021	pub prefix_plural: std::option::Option<std::string::String>,
3022}
3023impl GameStatConfig {
3024	/// A universally unique identifier.
3025	pub fn record_id(&self) -> std::option::Option<&str> {
3026		self.record_id.as_deref()
3027	}
3028	/// A universally unique identifier.
3029	pub fn icon_id(&self) -> std::option::Option<&str> {
3030		self.icon_id.as_deref()
3031	}
3032	/// A value denoting the format method of a game statistic.
3033	pub fn format(&self) -> std::option::Option<&crate::model::GameStatFormatMethod> {
3034		self.format.as_ref()
3035	}
3036	/// A value denoting the aggregation method of a game statistic.
3037	pub fn aggregation(&self) -> std::option::Option<&crate::model::GameStatAggregationMethod> {
3038		self.aggregation.as_ref()
3039	}
3040	/// A value denoting the sorting method of a game statistic.
3041	pub fn sorting(&self) -> std::option::Option<&crate::model::GameStatSortingMethod> {
3042		self.sorting.as_ref()
3043	}
3044	/// Unsigned 32 bit integer.
3045	pub fn priority(&self) -> std::option::Option<i32> {
3046		self.priority
3047	}
3048	/// Represent a resource's readable display name.
3049	pub fn display_name(&self) -> std::option::Option<&str> {
3050		self.display_name.as_deref()
3051	}
3052	/// A string appended to the end of a singular game statistic's value. Example: 1 **dollar**.
3053	pub fn postfix_singular(&self) -> std::option::Option<&str> {
3054		self.postfix_singular.as_deref()
3055	}
3056	/// A string appended to the end of a game statistic's value that is not exactly 1. Example: 45 **dollars**.
3057	pub fn postfix_plural(&self) -> std::option::Option<&str> {
3058		self.postfix_plural.as_deref()
3059	}
3060	/// A string appended to the beginning of a singular game statistic's value. Example: **value** 1.
3061	pub fn prefix_singular(&self) -> std::option::Option<&str> {
3062		self.prefix_singular.as_deref()
3063	}
3064	/// A string prepended to the beginning of a game statistic's value that is not exactly 1. Example: **values** 45.
3065	pub fn prefix_plural(&self) -> std::option::Option<&str> {
3066		self.prefix_plural.as_deref()
3067	}
3068}
3069impl std::fmt::Debug for GameStatConfig {
3070	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
3071		let mut formatter = f.debug_struct("GameStatConfig");
3072		formatter.field("record_id", &self.record_id);
3073		formatter.field("icon_id", &self.icon_id);
3074		formatter.field("format", &self.format);
3075		formatter.field("aggregation", &self.aggregation);
3076		formatter.field("sorting", &self.sorting);
3077		formatter.field("priority", &self.priority);
3078		formatter.field("display_name", &self.display_name);
3079		formatter.field("postfix_singular", &self.postfix_singular);
3080		formatter.field("postfix_plural", &self.postfix_plural);
3081		formatter.field("prefix_singular", &self.prefix_singular);
3082		formatter.field("prefix_plural", &self.prefix_plural);
3083		formatter.finish()
3084	}
3085}
3086/// See [`GameStatConfig`](crate::model::GameStatConfig)
3087pub mod game_stat_config {
3088	/// A builder for [`GameStatConfig`](crate::model::GameStatConfig)
3089	#[non_exhaustive]
3090	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
3091	pub struct Builder {
3092		pub(crate) record_id: std::option::Option<std::string::String>,
3093		pub(crate) icon_id: std::option::Option<std::string::String>,
3094		pub(crate) format: std::option::Option<crate::model::GameStatFormatMethod>,
3095		pub(crate) aggregation: std::option::Option<crate::model::GameStatAggregationMethod>,
3096		pub(crate) sorting: std::option::Option<crate::model::GameStatSortingMethod>,
3097		pub(crate) priority: std::option::Option<i32>,
3098		pub(crate) display_name: std::option::Option<std::string::String>,
3099		pub(crate) postfix_singular: std::option::Option<std::string::String>,
3100		pub(crate) postfix_plural: std::option::Option<std::string::String>,
3101		pub(crate) prefix_singular: std::option::Option<std::string::String>,
3102		pub(crate) prefix_plural: std::option::Option<std::string::String>,
3103	}
3104	impl Builder {
3105		/// A universally unique identifier.
3106		pub fn record_id(mut self, input: impl Into<std::string::String>) -> Self {
3107			self.record_id = Some(input.into());
3108			self
3109		}
3110		/// A universally unique identifier.
3111		pub fn set_record_id(mut self, input: std::option::Option<std::string::String>) -> Self {
3112			self.record_id = input;
3113			self
3114		}
3115		/// A universally unique identifier.
3116		pub fn icon_id(mut self, input: impl Into<std::string::String>) -> Self {
3117			self.icon_id = Some(input.into());
3118			self
3119		}
3120		/// A universally unique identifier.
3121		pub fn set_icon_id(mut self, input: std::option::Option<std::string::String>) -> Self {
3122			self.icon_id = input;
3123			self
3124		}
3125		/// A value denoting the format method of a game statistic.
3126		pub fn format(mut self, input: crate::model::GameStatFormatMethod) -> Self {
3127			self.format = Some(input);
3128			self
3129		}
3130		/// A value denoting the format method of a game statistic.
3131		pub fn set_format(
3132			mut self,
3133			input: std::option::Option<crate::model::GameStatFormatMethod>,
3134		) -> Self {
3135			self.format = input;
3136			self
3137		}
3138		/// A value denoting the aggregation method of a game statistic.
3139		pub fn aggregation(mut self, input: crate::model::GameStatAggregationMethod) -> Self {
3140			self.aggregation = Some(input);
3141			self
3142		}
3143		/// A value denoting the aggregation method of a game statistic.
3144		pub fn set_aggregation(
3145			mut self,
3146			input: std::option::Option<crate::model::GameStatAggregationMethod>,
3147		) -> Self {
3148			self.aggregation = input;
3149			self
3150		}
3151		/// A value denoting the sorting method of a game statistic.
3152		pub fn sorting(mut self, input: crate::model::GameStatSortingMethod) -> Self {
3153			self.sorting = Some(input);
3154			self
3155		}
3156		/// A value denoting the sorting method of a game statistic.
3157		pub fn set_sorting(
3158			mut self,
3159			input: std::option::Option<crate::model::GameStatSortingMethod>,
3160		) -> Self {
3161			self.sorting = input;
3162			self
3163		}
3164		/// Unsigned 32 bit integer.
3165		pub fn priority(mut self, input: i32) -> Self {
3166			self.priority = Some(input);
3167			self
3168		}
3169		/// Unsigned 32 bit integer.
3170		pub fn set_priority(mut self, input: std::option::Option<i32>) -> Self {
3171			self.priority = input;
3172			self
3173		}
3174		/// Represent a resource's readable display name.
3175		pub fn display_name(mut self, input: impl Into<std::string::String>) -> Self {
3176			self.display_name = Some(input.into());
3177			self
3178		}
3179		/// Represent a resource's readable display name.
3180		pub fn set_display_name(mut self, input: std::option::Option<std::string::String>) -> Self {
3181			self.display_name = input;
3182			self
3183		}
3184		/// A string appended to the end of a singular game statistic's value. Example: 1 **dollar**.
3185		pub fn postfix_singular(mut self, input: impl Into<std::string::String>) -> Self {
3186			self.postfix_singular = Some(input.into());
3187			self
3188		}
3189		/// A string appended to the end of a singular game statistic's value. Example: 1 **dollar**.
3190		pub fn set_postfix_singular(
3191			mut self,
3192			input: std::option::Option<std::string::String>,
3193		) -> Self {
3194			self.postfix_singular = input;
3195			self
3196		}
3197		/// A string appended to the end of a game statistic's value that is not exactly 1. Example: 45 **dollars**.
3198		pub fn postfix_plural(mut self, input: impl Into<std::string::String>) -> Self {
3199			self.postfix_plural = Some(input.into());
3200			self
3201		}
3202		/// A string appended to the end of a game statistic's value that is not exactly 1. Example: 45 **dollars**.
3203		pub fn set_postfix_plural(
3204			mut self,
3205			input: std::option::Option<std::string::String>,
3206		) -> Self {
3207			self.postfix_plural = input;
3208			self
3209		}
3210		/// A string appended to the beginning of a singular game statistic's value. Example: **value** 1.
3211		pub fn prefix_singular(mut self, input: impl Into<std::string::String>) -> Self {
3212			self.prefix_singular = Some(input.into());
3213			self
3214		}
3215		/// A string appended to the beginning of a singular game statistic's value. Example: **value** 1.
3216		pub fn set_prefix_singular(
3217			mut self,
3218			input: std::option::Option<std::string::String>,
3219		) -> Self {
3220			self.prefix_singular = input;
3221			self
3222		}
3223		/// A string prepended to the beginning of a game statistic's value that is not exactly 1. Example: **values** 45.
3224		pub fn prefix_plural(mut self, input: impl Into<std::string::String>) -> Self {
3225			self.prefix_plural = Some(input.into());
3226			self
3227		}
3228		/// A string prepended to the beginning of a game statistic's value that is not exactly 1. Example: **values** 45.
3229		pub fn set_prefix_plural(
3230			mut self,
3231			input: std::option::Option<std::string::String>,
3232		) -> Self {
3233			self.prefix_plural = input;
3234			self
3235		}
3236		/// Consumes the builder and constructs a [`GameStatConfig`](crate::model::GameStatConfig)
3237		pub fn build(self) -> crate::model::GameStatConfig {
3238			crate::model::GameStatConfig {
3239				record_id: self.record_id,
3240				icon_id: self.icon_id,
3241				format: self.format,
3242				aggregation: self.aggregation,
3243				sorting: self.sorting,
3244				priority: self.priority,
3245				display_name: self.display_name,
3246				postfix_singular: self.postfix_singular,
3247				postfix_plural: self.postfix_plural,
3248				prefix_singular: self.prefix_singular,
3249				prefix_plural: self.prefix_plural,
3250			}
3251		}
3252	}
3253}
3254impl GameStatConfig {
3255	/// Creates a new builder-style object to manufacture [`GameStatConfig`](crate::model::GameStatConfig)
3256	pub fn builder() -> crate::model::game_stat_config::Builder {
3257		crate::model::game_stat_config::Builder::default()
3258	}
3259}
3260
3261/// A value denoting the sorting method of a game statistic.
3262#[non_exhaustive]
3263#[derive(
3264	std::clone::Clone,
3265	std::cmp::Eq,
3266	std::cmp::Ord,
3267	std::cmp::PartialEq,
3268	std::cmp::PartialOrd,
3269	std::fmt::Debug,
3270	std::hash::Hash,
3271)]
3272pub enum GameStatSortingMethod {
3273	/// Ascending sorting.
3274	Asc,
3275	/// Descending sorting.
3276	Desc,
3277	/// Unknown contains new variants that have been added since this code was generated.
3278	Unknown(String),
3279}
3280impl std::convert::From<&str> for GameStatSortingMethod {
3281	fn from(s: &str) -> Self {
3282		match s {
3283			"asc" => GameStatSortingMethod::Asc,
3284			"desc" => GameStatSortingMethod::Desc,
3285			other => GameStatSortingMethod::Unknown(other.to_owned()),
3286		}
3287	}
3288}
3289impl std::str::FromStr for GameStatSortingMethod {
3290	type Err = std::convert::Infallible;
3291
3292	fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
3293		Ok(GameStatSortingMethod::from(s))
3294	}
3295}
3296impl GameStatSortingMethod {
3297	/// Returns the `&str` value of the enum member.
3298	pub fn as_str(&self) -> &str {
3299		match self {
3300			GameStatSortingMethod::Asc => "asc",
3301			GameStatSortingMethod::Desc => "desc",
3302			GameStatSortingMethod::Unknown(s) => s.as_ref(),
3303		}
3304	}
3305	/// Returns all the `&str` values of the enum members.
3306	pub fn values() -> &'static [&'static str] {
3307		&["asc", "desc"]
3308	}
3309}
3310impl AsRef<str> for GameStatSortingMethod {
3311	fn as_ref(&self) -> &str {
3312		self.as_str()
3313	}
3314}
3315
3316/// A value denoting the aggregation method of a game statistic.
3317#[non_exhaustive]
3318#[derive(
3319	std::clone::Clone,
3320	std::cmp::Eq,
3321	std::cmp::Ord,
3322	std::cmp::PartialEq,
3323	std::cmp::PartialOrd,
3324	std::fmt::Debug,
3325	std::hash::Hash,
3326)]
3327pub enum GameStatAggregationMethod {
3328	/// Average aggergation.
3329	Average,
3330	/// Maximum value aggregation.
3331	Max,
3332	/// Minimum value aggregation.
3333	Min,
3334	/// Summation aggregation.
3335	Sum,
3336	/// Unknown contains new variants that have been added since this code was generated.
3337	Unknown(String),
3338}
3339impl std::convert::From<&str> for GameStatAggregationMethod {
3340	fn from(s: &str) -> Self {
3341		match s {
3342			"average" => GameStatAggregationMethod::Average,
3343			"max" => GameStatAggregationMethod::Max,
3344			"min" => GameStatAggregationMethod::Min,
3345			"sum" => GameStatAggregationMethod::Sum,
3346			other => GameStatAggregationMethod::Unknown(other.to_owned()),
3347		}
3348	}
3349}
3350impl std::str::FromStr for GameStatAggregationMethod {
3351	type Err = std::convert::Infallible;
3352
3353	fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
3354		Ok(GameStatAggregationMethod::from(s))
3355	}
3356}
3357impl GameStatAggregationMethod {
3358	/// Returns the `&str` value of the enum member.
3359	pub fn as_str(&self) -> &str {
3360		match self {
3361			GameStatAggregationMethod::Average => "average",
3362			GameStatAggregationMethod::Max => "max",
3363			GameStatAggregationMethod::Min => "min",
3364			GameStatAggregationMethod::Sum => "sum",
3365			GameStatAggregationMethod::Unknown(s) => s.as_ref(),
3366		}
3367	}
3368	/// Returns all the `&str` values of the enum members.
3369	pub fn values() -> &'static [&'static str] {
3370		&["average", "max", "min", "sum"]
3371	}
3372}
3373impl AsRef<str> for GameStatAggregationMethod {
3374	fn as_ref(&self) -> &str {
3375		self.as_str()
3376	}
3377}
3378
3379/// A value denoting the format method of a game statistic.
3380#[non_exhaustive]
3381#[derive(
3382	std::clone::Clone,
3383	std::cmp::Eq,
3384	std::cmp::Ord,
3385	std::cmp::PartialEq,
3386	std::cmp::PartialOrd,
3387	std::fmt::Debug,
3388	std::hash::Hash,
3389)]
3390pub enum GameStatFormatMethod {
3391	/// A duration with hundredth-second precision (1d 2h 45m 21.46s).
3392	DurationHundredthSecond,
3393	/// A duration with minute precision (1d 2h 45m).
3394	DurationMinute,
3395	/// A duration with second precision (1d 2h 45m 21s).
3396	DuractionSecond,
3397	/// A float with 1 decimal (1,234.5).
3398	Float1,
3399	/// A float with 2 decimals (1,234.56).
3400	Float2,
3401	/// A float with 3 decimals (1,234.567).
3402	Float3,
3403	/// An integer with no decimals (1,234).
3404	Integer,
3405	/// Unknown contains new variants that have been added since this code was generated.
3406	Unknown(String),
3407}
3408impl std::convert::From<&str> for GameStatFormatMethod {
3409	fn from(s: &str) -> Self {
3410		match s {
3411			"duration_hundredth_second" => GameStatFormatMethod::DurationHundredthSecond,
3412			"duration_minute" => GameStatFormatMethod::DurationMinute,
3413			"duration_second" => GameStatFormatMethod::DuractionSecond,
3414			"float_1" => GameStatFormatMethod::Float1,
3415			"float_2" => GameStatFormatMethod::Float2,
3416			"float_3" => GameStatFormatMethod::Float3,
3417			"integer" => GameStatFormatMethod::Integer,
3418			other => GameStatFormatMethod::Unknown(other.to_owned()),
3419		}
3420	}
3421}
3422impl std::str::FromStr for GameStatFormatMethod {
3423	type Err = std::convert::Infallible;
3424
3425	fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
3426		Ok(GameStatFormatMethod::from(s))
3427	}
3428}
3429impl GameStatFormatMethod {
3430	/// Returns the `&str` value of the enum member.
3431	pub fn as_str(&self) -> &str {
3432		match self {
3433			GameStatFormatMethod::DurationHundredthSecond => "duration_hundredth_second",
3434			GameStatFormatMethod::DurationMinute => "duration_minute",
3435			GameStatFormatMethod::DuractionSecond => "duration_second",
3436			GameStatFormatMethod::Float1 => "float_1",
3437			GameStatFormatMethod::Float2 => "float_2",
3438			GameStatFormatMethod::Float3 => "float_3",
3439			GameStatFormatMethod::Integer => "integer",
3440			GameStatFormatMethod::Unknown(s) => s.as_ref(),
3441		}
3442	}
3443	/// Returns all the `&str` values of the enum members.
3444	pub fn values() -> &'static [&'static str] {
3445		&[
3446			"duration_hundredth_second",
3447			"duration_minute",
3448			"duration_second",
3449			"float_1",
3450			"float_2",
3451			"float_3",
3452			"integer",
3453		]
3454	}
3455}
3456impl AsRef<str> for GameStatFormatMethod {
3457	fn as_ref(&self) -> &str {
3458		self.as_str()
3459	}
3460}
3461
3462/// A group that the given identity.
3463#[non_exhaustive]
3464#[derive(std::clone::Clone, std::cmp::PartialEq)]
3465pub struct IdentityGroup {
3466	/// A group handle.
3467	pub group: std::option::Option<crate::model::GroupHandle>,
3468}
3469impl IdentityGroup {
3470	/// A group handle.
3471	pub fn group(&self) -> std::option::Option<&crate::model::GroupHandle> {
3472		self.group.as_ref()
3473	}
3474}
3475impl std::fmt::Debug for IdentityGroup {
3476	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
3477		let mut formatter = f.debug_struct("IdentityGroup");
3478		formatter.field("group", &self.group);
3479		formatter.finish()
3480	}
3481}
3482/// See [`IdentityGroup`](crate::model::IdentityGroup)
3483pub mod identity_group {
3484	/// A builder for [`IdentityGroup`](crate::model::IdentityGroup)
3485	#[non_exhaustive]
3486	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
3487	pub struct Builder {
3488		pub(crate) group: std::option::Option<crate::model::GroupHandle>,
3489	}
3490	impl Builder {
3491		/// A group handle.
3492		pub fn group(mut self, input: crate::model::GroupHandle) -> Self {
3493			self.group = Some(input);
3494			self
3495		}
3496		/// A group handle.
3497		pub fn set_group(mut self, input: std::option::Option<crate::model::GroupHandle>) -> Self {
3498			self.group = input;
3499			self
3500		}
3501		/// Consumes the builder and constructs a [`IdentityGroup`](crate::model::IdentityGroup)
3502		pub fn build(self) -> crate::model::IdentityGroup {
3503			crate::model::IdentityGroup { group: self.group }
3504		}
3505	}
3506}
3507impl IdentityGroup {
3508	/// Creates a new builder-style object to manufacture [`IdentityGroup`](crate::model::IdentityGroup)
3509	pub fn builder() -> crate::model::identity_group::Builder {
3510		crate::model::identity_group::Builder::default()
3511	}
3512}
3513
3514/// A group handle.
3515#[non_exhaustive]
3516#[derive(std::clone::Clone, std::cmp::PartialEq)]
3517pub struct GroupHandle {
3518	/// A universally unique identifier.
3519	pub group_id: std::option::Option<std::string::String>,
3520	/// Represent a resource's readable display name.
3521	pub display_name: std::option::Option<std::string::String>,
3522	/// The URL of this group's avatar image.
3523	pub avatar_url: std::option::Option<std::string::String>,
3524	/// External links for this group.
3525	pub external: std::option::Option<crate::model::GroupExternalLinks>,
3526	/// Whether or not this group is a developer group.
3527	pub is_developer: std::option::Option<bool>,
3528}
3529impl GroupHandle {
3530	/// A universally unique identifier.
3531	pub fn group_id(&self) -> std::option::Option<&str> {
3532		self.group_id.as_deref()
3533	}
3534	/// Represent a resource's readable display name.
3535	pub fn display_name(&self) -> std::option::Option<&str> {
3536		self.display_name.as_deref()
3537	}
3538	/// The URL of this group's avatar image.
3539	pub fn avatar_url(&self) -> std::option::Option<&str> {
3540		self.avatar_url.as_deref()
3541	}
3542	/// External links for this group.
3543	pub fn external(&self) -> std::option::Option<&crate::model::GroupExternalLinks> {
3544		self.external.as_ref()
3545	}
3546	/// Whether or not this group is a developer group.
3547	pub fn is_developer(&self) -> std::option::Option<bool> {
3548		self.is_developer
3549	}
3550}
3551impl std::fmt::Debug for GroupHandle {
3552	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
3553		let mut formatter = f.debug_struct("GroupHandle");
3554		formatter.field("group_id", &self.group_id);
3555		formatter.field("display_name", &self.display_name);
3556		formatter.field("avatar_url", &self.avatar_url);
3557		formatter.field("external", &self.external);
3558		formatter.field("is_developer", &self.is_developer);
3559		formatter.finish()
3560	}
3561}
3562/// See [`GroupHandle`](crate::model::GroupHandle)
3563pub mod group_handle {
3564	/// A builder for [`GroupHandle`](crate::model::GroupHandle)
3565	#[non_exhaustive]
3566	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
3567	pub struct Builder {
3568		pub(crate) group_id: std::option::Option<std::string::String>,
3569		pub(crate) display_name: std::option::Option<std::string::String>,
3570		pub(crate) avatar_url: std::option::Option<std::string::String>,
3571		pub(crate) external: std::option::Option<crate::model::GroupExternalLinks>,
3572		pub(crate) is_developer: std::option::Option<bool>,
3573	}
3574	impl Builder {
3575		/// A universally unique identifier.
3576		pub fn group_id(mut self, input: impl Into<std::string::String>) -> Self {
3577			self.group_id = Some(input.into());
3578			self
3579		}
3580		/// A universally unique identifier.
3581		pub fn set_group_id(mut self, input: std::option::Option<std::string::String>) -> Self {
3582			self.group_id = input;
3583			self
3584		}
3585		/// Represent a resource's readable display name.
3586		pub fn display_name(mut self, input: impl Into<std::string::String>) -> Self {
3587			self.display_name = Some(input.into());
3588			self
3589		}
3590		/// Represent a resource's readable display name.
3591		pub fn set_display_name(mut self, input: std::option::Option<std::string::String>) -> Self {
3592			self.display_name = input;
3593			self
3594		}
3595		/// The URL of this group's avatar image.
3596		pub fn avatar_url(mut self, input: impl Into<std::string::String>) -> Self {
3597			self.avatar_url = Some(input.into());
3598			self
3599		}
3600		/// The URL of this group's avatar image.
3601		pub fn set_avatar_url(mut self, input: std::option::Option<std::string::String>) -> Self {
3602			self.avatar_url = input;
3603			self
3604		}
3605		/// External links for this group.
3606		pub fn external(mut self, input: crate::model::GroupExternalLinks) -> Self {
3607			self.external = Some(input);
3608			self
3609		}
3610		/// External links for this group.
3611		pub fn set_external(
3612			mut self,
3613			input: std::option::Option<crate::model::GroupExternalLinks>,
3614		) -> Self {
3615			self.external = input;
3616			self
3617		}
3618		/// Whether or not this group is a developer group.
3619		pub fn is_developer(mut self, input: bool) -> Self {
3620			self.is_developer = Some(input);
3621			self
3622		}
3623		/// Whether or not this group is a developer group.
3624		pub fn set_is_developer(mut self, input: std::option::Option<bool>) -> Self {
3625			self.is_developer = input;
3626			self
3627		}
3628		/// Consumes the builder and constructs a [`GroupHandle`](crate::model::GroupHandle)
3629		pub fn build(self) -> crate::model::GroupHandle {
3630			crate::model::GroupHandle {
3631				group_id: self.group_id,
3632				display_name: self.display_name,
3633				avatar_url: self.avatar_url,
3634				external: self.external,
3635				is_developer: self.is_developer,
3636			}
3637		}
3638	}
3639}
3640impl GroupHandle {
3641	/// Creates a new builder-style object to manufacture [`GroupHandle`](crate::model::GroupHandle)
3642	pub fn builder() -> crate::model::group_handle::Builder {
3643		crate::model::group_handle::Builder::default()
3644	}
3645}
3646
3647/// A union representing an identity's linked accounts.
3648#[non_exhaustive]
3649#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
3650pub enum IdentityLinkedAccount {
3651	/// An identity's linked email.
3652	Email(crate::model::IdentityEmailLinkedAccount),
3653	/// The `Unknown` variant represents cases where new union variant was received. Consider upgrading the SDK to the latest available version.
3654	/// An unknown enum variant
3655	///
3656	/// _Note: If you encounter this error, consider upgrading your SDK to the latest version._
3657	/// The `Unknown` variant represents cases where the server sent a value that wasn't recognized
3658	/// by the client. This can happen when the server adds new functionality, but the client has not been updated.
3659	/// To investigate this, consider turning on debug logging to print the raw HTTP response.
3660	#[non_exhaustive]
3661	Unknown,
3662}
3663impl IdentityLinkedAccount {
3664	#[allow(irrefutable_let_patterns)]
3665	/// Tries to convert the enum instance into [`Email`](crate::model::IdentityLinkedAccount::Email), extracting the inner [`IdentityEmailLinkedAccount`](crate::model::IdentityEmailLinkedAccount).
3666	/// Returns `Err(&Self)` if it can't be converted.
3667	pub fn as_email(
3668		&self,
3669	) -> std::result::Result<&crate::model::IdentityEmailLinkedAccount, &Self> {
3670		if let IdentityLinkedAccount::Email(val) = &self {
3671			Ok(val)
3672		} else {
3673			Err(self)
3674		}
3675	}
3676	/// Returns true if this is a [`Email`](crate::model::IdentityLinkedAccount::Email).
3677	pub fn is_email(&self) -> bool {
3678		self.as_email().is_ok()
3679	}
3680	/// Returns true if the enum instance is the `Unknown` variant.
3681	pub fn is_unknown(&self) -> bool {
3682		matches!(self, Self::Unknown)
3683	}
3684}
3685
3686/// An identity's linked email.
3687#[non_exhaustive]
3688#[derive(std::clone::Clone, std::cmp::PartialEq)]
3689pub struct IdentityEmailLinkedAccount {
3690	/// A valid email address.
3691	pub email: std::option::Option<std::string::String>,
3692}
3693impl IdentityEmailLinkedAccount {
3694	/// A valid email address.
3695	pub fn email(&self) -> std::option::Option<&str> {
3696		self.email.as_deref()
3697	}
3698}
3699impl std::fmt::Debug for IdentityEmailLinkedAccount {
3700	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
3701		let mut formatter = f.debug_struct("IdentityEmailLinkedAccount");
3702		formatter.field("email", &"*** Sensitive Data Redacted ***");
3703		formatter.finish()
3704	}
3705}
3706/// See [`IdentityEmailLinkedAccount`](crate::model::IdentityEmailLinkedAccount)
3707pub mod identity_email_linked_account {
3708	/// A builder for [`IdentityEmailLinkedAccount`](crate::model::IdentityEmailLinkedAccount)
3709	#[non_exhaustive]
3710	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
3711	pub struct Builder {
3712		pub(crate) email: std::option::Option<std::string::String>,
3713	}
3714	impl Builder {
3715		/// A valid email address.
3716		pub fn email(mut self, input: impl Into<std::string::String>) -> Self {
3717			self.email = Some(input.into());
3718			self
3719		}
3720		/// A valid email address.
3721		pub fn set_email(mut self, input: std::option::Option<std::string::String>) -> Self {
3722			self.email = input;
3723			self
3724		}
3725		/// Consumes the builder and constructs a [`IdentityEmailLinkedAccount`](crate::model::IdentityEmailLinkedAccount)
3726		pub fn build(self) -> crate::model::IdentityEmailLinkedAccount {
3727			crate::model::IdentityEmailLinkedAccount { email: self.email }
3728		}
3729	}
3730}
3731impl IdentityEmailLinkedAccount {
3732	/// Creates a new builder-style object to manufacture [`IdentityEmailLinkedAccount`](crate::model::IdentityEmailLinkedAccount)
3733	pub fn builder() -> crate::model::identity_email_linked_account::Builder {
3734		crate::model::identity_email_linked_account::Builder::default()
3735	}
3736}
3737
3738/// The state of the given identity's developer status.
3739#[non_exhaustive]
3740#[derive(
3741	std::clone::Clone,
3742	std::cmp::Eq,
3743	std::cmp::Ord,
3744	std::cmp::PartialEq,
3745	std::cmp::PartialOrd,
3746	std::fmt::Debug,
3747	std::hash::Hash,
3748)]
3749pub enum IdentityDevState {
3750	#[allow(missing_docs)] // documentation missing in model
3751	Accepted,
3752	#[allow(missing_docs)] // documentation missing in model
3753	Inactive,
3754	#[allow(missing_docs)] // documentation missing in model
3755	Pending,
3756	/// Unknown contains new variants that have been added since this code was generated.
3757	Unknown(String),
3758}
3759impl std::convert::From<&str> for IdentityDevState {
3760	fn from(s: &str) -> Self {
3761		match s {
3762			"accepted" => IdentityDevState::Accepted,
3763			"inactive" => IdentityDevState::Inactive,
3764			"pending" => IdentityDevState::Pending,
3765			other => IdentityDevState::Unknown(other.to_owned()),
3766		}
3767	}
3768}
3769impl std::str::FromStr for IdentityDevState {
3770	type Err = std::convert::Infallible;
3771
3772	fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
3773		Ok(IdentityDevState::from(s))
3774	}
3775}
3776impl IdentityDevState {
3777	/// Returns the `&str` value of the enum member.
3778	pub fn as_str(&self) -> &str {
3779		match self {
3780			IdentityDevState::Accepted => "accepted",
3781			IdentityDevState::Inactive => "inactive",
3782			IdentityDevState::Pending => "pending",
3783			IdentityDevState::Unknown(s) => s.as_ref(),
3784		}
3785	}
3786	/// Returns all the `&str` values of the enum members.
3787	pub fn values() -> &'static [&'static str] {
3788		&["accepted", "inactive", "pending"]
3789	}
3790}
3791impl AsRef<str> for IdentityDevState {
3792	fn as_ref(&self) -> &str {
3793		self.as_str()
3794	}
3795}
3796
3797/// The link status between an identity and a game user.
3798#[non_exhaustive]
3799#[derive(
3800	std::clone::Clone,
3801	std::cmp::Eq,
3802	std::cmp::Ord,
3803	std::cmp::PartialEq,
3804	std::cmp::PartialOrd,
3805	std::fmt::Debug,
3806	std::hash::Hash,
3807)]
3808pub enum GameLinkStatus {
3809	#[allow(missing_docs)] // documentation missing in model
3810	Cancelled,
3811	#[allow(missing_docs)] // documentation missing in model
3812	Complete,
3813	#[allow(missing_docs)] // documentation missing in model
3814	Incomplete,
3815	/// Unknown contains new variants that have been added since this code was generated.
3816	Unknown(String),
3817}
3818impl std::convert::From<&str> for GameLinkStatus {
3819	fn from(s: &str) -> Self {
3820		match s {
3821			"cancelled" => GameLinkStatus::Cancelled,
3822			"complete" => GameLinkStatus::Complete,
3823			"incomplete" => GameLinkStatus::Incomplete,
3824			other => GameLinkStatus::Unknown(other.to_owned()),
3825		}
3826	}
3827}
3828impl std::str::FromStr for GameLinkStatus {
3829	type Err = std::convert::Infallible;
3830
3831	fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
3832		Ok(GameLinkStatus::from(s))
3833	}
3834}
3835impl GameLinkStatus {
3836	/// Returns the `&str` value of the enum member.
3837	pub fn as_str(&self) -> &str {
3838		match self {
3839			GameLinkStatus::Cancelled => "cancelled",
3840			GameLinkStatus::Complete => "complete",
3841			GameLinkStatus::Incomplete => "incomplete",
3842			GameLinkStatus::Unknown(s) => s.as_ref(),
3843		}
3844	}
3845	/// Returns all the `&str` values of the enum members.
3846	pub fn values() -> &'static [&'static str] {
3847		&["cancelled", "complete", "incomplete"]
3848	}
3849}
3850impl AsRef<str> for GameLinkStatus {
3851	fn as_ref(&self) -> &str {
3852		self.as_str()
3853	}
3854}
3855
3856/// An event relevant to the current identity.
3857#[non_exhaustive]
3858#[derive(std::clone::Clone, std::cmp::PartialEq)]
3859pub struct GlobalEvent {
3860	/// RFC3339 timestamp.
3861	pub ts: std::option::Option<aws_smithy_types::DateTime>,
3862	/// Kind of event that occured.
3863	pub kind: std::option::Option<crate::model::GlobalEventKind>,
3864	/// Notifications represent information that should be presented to the user immediately. At the moment, only chat message events have associated notifications. # Display Notifications should be displayed in an unobtrusive manner throughout the entire game. Notifications should disappear after a few seconds if not interacted with. # Interactions If your platform supports it, notifications should be able to be clicked or tapped in order to open the relevant context for the event. For a simple implementation of notification interactions, open `url` in a web browser to present the relevant context. For example, a chat message notification will open the thread the chat message was sent in. For advanced implementations that implement a custom chat UI, use `rivet.api.identity.common#GlobalEvent$kind` to determine what action to take when the notification is interacted with. For example, if the global event kind is `rivet.api.identity.common#GlobalEventChatMessage`, then open the chat UI for the given thread.
3865	pub notification: std::option::Option<crate::model::GlobalEventNotification>,
3866}
3867impl GlobalEvent {
3868	/// RFC3339 timestamp.
3869	pub fn ts(&self) -> std::option::Option<&aws_smithy_types::DateTime> {
3870		self.ts.as_ref()
3871	}
3872	/// Kind of event that occured.
3873	pub fn kind(&self) -> std::option::Option<&crate::model::GlobalEventKind> {
3874		self.kind.as_ref()
3875	}
3876	/// Notifications represent information that should be presented to the user immediately. At the moment, only chat message events have associated notifications. # Display Notifications should be displayed in an unobtrusive manner throughout the entire game. Notifications should disappear after a few seconds if not interacted with. # Interactions If your platform supports it, notifications should be able to be clicked or tapped in order to open the relevant context for the event. For a simple implementation of notification interactions, open `url` in a web browser to present the relevant context. For example, a chat message notification will open the thread the chat message was sent in. For advanced implementations that implement a custom chat UI, use `rivet.api.identity.common#GlobalEvent$kind` to determine what action to take when the notification is interacted with. For example, if the global event kind is `rivet.api.identity.common#GlobalEventChatMessage`, then open the chat UI for the given thread.
3877	pub fn notification(&self) -> std::option::Option<&crate::model::GlobalEventNotification> {
3878		self.notification.as_ref()
3879	}
3880}
3881impl std::fmt::Debug for GlobalEvent {
3882	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
3883		let mut formatter = f.debug_struct("GlobalEvent");
3884		formatter.field("ts", &self.ts);
3885		formatter.field("kind", &self.kind);
3886		formatter.field("notification", &self.notification);
3887		formatter.finish()
3888	}
3889}
3890/// See [`GlobalEvent`](crate::model::GlobalEvent)
3891pub mod global_event {
3892	/// A builder for [`GlobalEvent`](crate::model::GlobalEvent)
3893	#[non_exhaustive]
3894	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
3895	pub struct Builder {
3896		pub(crate) ts: std::option::Option<aws_smithy_types::DateTime>,
3897		pub(crate) kind: std::option::Option<crate::model::GlobalEventKind>,
3898		pub(crate) notification: std::option::Option<crate::model::GlobalEventNotification>,
3899	}
3900	impl Builder {
3901		/// RFC3339 timestamp.
3902		pub fn ts(mut self, input: aws_smithy_types::DateTime) -> Self {
3903			self.ts = Some(input);
3904			self
3905		}
3906		/// RFC3339 timestamp.
3907		pub fn set_ts(mut self, input: std::option::Option<aws_smithy_types::DateTime>) -> Self {
3908			self.ts = input;
3909			self
3910		}
3911		/// Kind of event that occured.
3912		pub fn kind(mut self, input: crate::model::GlobalEventKind) -> Self {
3913			self.kind = Some(input);
3914			self
3915		}
3916		/// Kind of event that occured.
3917		pub fn set_kind(
3918			mut self,
3919			input: std::option::Option<crate::model::GlobalEventKind>,
3920		) -> Self {
3921			self.kind = input;
3922			self
3923		}
3924		/// Notifications represent information that should be presented to the user immediately. At the moment, only chat message events have associated notifications. # Display Notifications should be displayed in an unobtrusive manner throughout the entire game. Notifications should disappear after a few seconds if not interacted with. # Interactions If your platform supports it, notifications should be able to be clicked or tapped in order to open the relevant context for the event. For a simple implementation of notification interactions, open `url` in a web browser to present the relevant context. For example, a chat message notification will open the thread the chat message was sent in. For advanced implementations that implement a custom chat UI, use `rivet.api.identity.common#GlobalEvent$kind` to determine what action to take when the notification is interacted with. For example, if the global event kind is `rivet.api.identity.common#GlobalEventChatMessage`, then open the chat UI for the given thread.
3925		pub fn notification(mut self, input: crate::model::GlobalEventNotification) -> Self {
3926			self.notification = Some(input);
3927			self
3928		}
3929		/// Notifications represent information that should be presented to the user immediately. At the moment, only chat message events have associated notifications. # Display Notifications should be displayed in an unobtrusive manner throughout the entire game. Notifications should disappear after a few seconds if not interacted with. # Interactions If your platform supports it, notifications should be able to be clicked or tapped in order to open the relevant context for the event. For a simple implementation of notification interactions, open `url` in a web browser to present the relevant context. For example, a chat message notification will open the thread the chat message was sent in. For advanced implementations that implement a custom chat UI, use `rivet.api.identity.common#GlobalEvent$kind` to determine what action to take when the notification is interacted with. For example, if the global event kind is `rivet.api.identity.common#GlobalEventChatMessage`, then open the chat UI for the given thread.
3930		pub fn set_notification(
3931			mut self,
3932			input: std::option::Option<crate::model::GlobalEventNotification>,
3933		) -> Self {
3934			self.notification = input;
3935			self
3936		}
3937		/// Consumes the builder and constructs a [`GlobalEvent`](crate::model::GlobalEvent)
3938		pub fn build(self) -> crate::model::GlobalEvent {
3939			crate::model::GlobalEvent {
3940				ts: self.ts,
3941				kind: self.kind,
3942				notification: self.notification,
3943			}
3944		}
3945	}
3946}
3947impl GlobalEvent {
3948	/// Creates a new builder-style object to manufacture [`GlobalEvent`](crate::model::GlobalEvent)
3949	pub fn builder() -> crate::model::global_event::Builder {
3950		crate::model::global_event::Builder::default()
3951	}
3952}
3953
3954/// Notifications represent information that should be presented to the user immediately. At the moment, only chat message events have associated notifications. # Display Notifications should be displayed in an unobtrusive manner throughout the entire game. Notifications should disappear after a few seconds if not interacted with. # Interactions If your platform supports it, notifications should be able to be clicked or tapped in order to open the relevant context for the event. For a simple implementation of notification interactions, open `url` in a web browser to present the relevant context. For example, a chat message notification will open the thread the chat message was sent in. For advanced implementations that implement a custom chat UI, use `rivet.api.identity.common#GlobalEvent$kind` to determine what action to take when the notification is interacted with. For example, if the global event kind is `rivet.api.identity.common#GlobalEventChatMessage`, then open the chat UI for the given thread.
3955#[non_exhaustive]
3956#[derive(std::clone::Clone, std::cmp::PartialEq)]
3957pub struct GlobalEventNotification {
3958	#[allow(missing_docs)] // documentation missing in model
3959	pub title: std::option::Option<std::string::String>,
3960	#[allow(missing_docs)] // documentation missing in model
3961	pub description: std::option::Option<std::string::String>,
3962	/// URL to an image thumbnail that should be shown for this notification.
3963	pub thumbnail_url: std::option::Option<std::string::String>,
3964	/// Rivet Hub URL that holds the relevant context for this notification.
3965	pub url: std::option::Option<std::string::String>,
3966}
3967impl GlobalEventNotification {
3968	#[allow(missing_docs)] // documentation missing in model
3969	pub fn title(&self) -> std::option::Option<&str> {
3970		self.title.as_deref()
3971	}
3972	#[allow(missing_docs)] // documentation missing in model
3973	pub fn description(&self) -> std::option::Option<&str> {
3974		self.description.as_deref()
3975	}
3976	/// URL to an image thumbnail that should be shown for this notification.
3977	pub fn thumbnail_url(&self) -> std::option::Option<&str> {
3978		self.thumbnail_url.as_deref()
3979	}
3980	/// Rivet Hub URL that holds the relevant context for this notification.
3981	pub fn url(&self) -> std::option::Option<&str> {
3982		self.url.as_deref()
3983	}
3984}
3985impl std::fmt::Debug for GlobalEventNotification {
3986	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
3987		let mut formatter = f.debug_struct("GlobalEventNotification");
3988		formatter.field("title", &self.title);
3989		formatter.field("description", &self.description);
3990		formatter.field("thumbnail_url", &self.thumbnail_url);
3991		formatter.field("url", &self.url);
3992		formatter.finish()
3993	}
3994}
3995/// See [`GlobalEventNotification`](crate::model::GlobalEventNotification)
3996pub mod global_event_notification {
3997	/// A builder for [`GlobalEventNotification`](crate::model::GlobalEventNotification)
3998	#[non_exhaustive]
3999	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
4000	pub struct Builder {
4001		pub(crate) title: std::option::Option<std::string::String>,
4002		pub(crate) description: std::option::Option<std::string::String>,
4003		pub(crate) thumbnail_url: std::option::Option<std::string::String>,
4004		pub(crate) url: std::option::Option<std::string::String>,
4005	}
4006	impl Builder {
4007		#[allow(missing_docs)] // documentation missing in model
4008		pub fn title(mut self, input: impl Into<std::string::String>) -> Self {
4009			self.title = Some(input.into());
4010			self
4011		}
4012		#[allow(missing_docs)] // documentation missing in model
4013		pub fn set_title(mut self, input: std::option::Option<std::string::String>) -> Self {
4014			self.title = input;
4015			self
4016		}
4017		#[allow(missing_docs)] // documentation missing in model
4018		pub fn description(mut self, input: impl Into<std::string::String>) -> Self {
4019			self.description = Some(input.into());
4020			self
4021		}
4022		#[allow(missing_docs)] // documentation missing in model
4023		pub fn set_description(mut self, input: std::option::Option<std::string::String>) -> Self {
4024			self.description = input;
4025			self
4026		}
4027		/// URL to an image thumbnail that should be shown for this notification.
4028		pub fn thumbnail_url(mut self, input: impl Into<std::string::String>) -> Self {
4029			self.thumbnail_url = Some(input.into());
4030			self
4031		}
4032		/// URL to an image thumbnail that should be shown for this notification.
4033		pub fn set_thumbnail_url(
4034			mut self,
4035			input: std::option::Option<std::string::String>,
4036		) -> Self {
4037			self.thumbnail_url = input;
4038			self
4039		}
4040		/// Rivet Hub URL that holds the relevant context for this notification.
4041		pub fn url(mut self, input: impl Into<std::string::String>) -> Self {
4042			self.url = Some(input.into());
4043			self
4044		}
4045		/// Rivet Hub URL that holds the relevant context for this notification.
4046		pub fn set_url(mut self, input: std::option::Option<std::string::String>) -> Self {
4047			self.url = input;
4048			self
4049		}
4050		/// Consumes the builder and constructs a [`GlobalEventNotification`](crate::model::GlobalEventNotification)
4051		pub fn build(self) -> crate::model::GlobalEventNotification {
4052			crate::model::GlobalEventNotification {
4053				title: self.title,
4054				description: self.description,
4055				thumbnail_url: self.thumbnail_url,
4056				url: self.url,
4057			}
4058		}
4059	}
4060}
4061impl GlobalEventNotification {
4062	/// Creates a new builder-style object to manufacture [`GlobalEventNotification`](crate::model::GlobalEventNotification)
4063	pub fn builder() -> crate::model::global_event_notification::Builder {
4064		crate::model::global_event_notification::Builder::default()
4065	}
4066}
4067
4068/// Kind of event that occured.
4069#[non_exhaustive]
4070#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
4071pub enum GlobalEventKind {
4072	/// `rivet.api.identity.common#GlobalEventKind` variant for chat messages. Received any time a message is sent to a chat the identity is in.
4073	ChatMessage(crate::model::GlobalEventChatMessage),
4074	/// `rivet.api.identity.common#GlobalEventKind` variant for chat reads. Received any time the last read timestamp is set. Used to update the status of unread indicators on chats.
4075	ChatRead(crate::model::GlobalEventChatRead),
4076	/// `rivet.api.identity.common#GlobalEventKind` variant for a chat thread being removed. Received any time the current identity is no longer able to access the given thread. This can happen if
4077	ChatThreadRemove(crate::model::GlobalEventChatThreadRemove),
4078	/// `rivet.api.identity.common#GlobalEventKind` variant for identity updates. Received any time identity details are changed OR the identity switches.
4079	IdentityUpdate(crate::model::GlobalEventIdentityUpdate),
4080	/// `rivet.api.identity.common#GlobalEventKind` variant for party updates. Received when the identity should be instructed to join a lobby. This needs to be implemented in conjunction with parties in order to force clients to join the same lobby as the party they're in.
4081	MatchmakerLobbyJoin(crate::model::GlobalEventMatchmakerLobbyJoin),
4082	/// `rivet.api.identity.common#GlobalEventKind` variant for party updates. Received any time the identity joins a party, a party is updated, or when the identity leaves a party.
4083	PartyUpdate(crate::model::GlobalEventPartyUpdate),
4084	/// The `Unknown` variant represents cases where new union variant was received. Consider upgrading the SDK to the latest available version.
4085	/// An unknown enum variant
4086	///
4087	/// _Note: If you encounter this error, consider upgrading your SDK to the latest version._
4088	/// The `Unknown` variant represents cases where the server sent a value that wasn't recognized
4089	/// by the client. This can happen when the server adds new functionality, but the client has not been updated.
4090	/// To investigate this, consider turning on debug logging to print the raw HTTP response.
4091	#[non_exhaustive]
4092	Unknown,
4093}
4094impl GlobalEventKind {
4095	/// Tries to convert the enum instance into [`ChatMessage`](crate::model::GlobalEventKind::ChatMessage), extracting the inner [`GlobalEventChatMessage`](crate::model::GlobalEventChatMessage).
4096	/// Returns `Err(&Self)` if it can't be converted.
4097	pub fn as_chat_message(
4098		&self,
4099	) -> std::result::Result<&crate::model::GlobalEventChatMessage, &Self> {
4100		if let GlobalEventKind::ChatMessage(val) = &self {
4101			Ok(val)
4102		} else {
4103			Err(self)
4104		}
4105	}
4106	/// Returns true if this is a [`ChatMessage`](crate::model::GlobalEventKind::ChatMessage).
4107	pub fn is_chat_message(&self) -> bool {
4108		self.as_chat_message().is_ok()
4109	}
4110	/// Tries to convert the enum instance into [`ChatRead`](crate::model::GlobalEventKind::ChatRead), extracting the inner [`GlobalEventChatRead`](crate::model::GlobalEventChatRead).
4111	/// Returns `Err(&Self)` if it can't be converted.
4112	pub fn as_chat_read(&self) -> std::result::Result<&crate::model::GlobalEventChatRead, &Self> {
4113		if let GlobalEventKind::ChatRead(val) = &self {
4114			Ok(val)
4115		} else {
4116			Err(self)
4117		}
4118	}
4119	/// Returns true if this is a [`ChatRead`](crate::model::GlobalEventKind::ChatRead).
4120	pub fn is_chat_read(&self) -> bool {
4121		self.as_chat_read().is_ok()
4122	}
4123	/// Tries to convert the enum instance into [`ChatThreadRemove`](crate::model::GlobalEventKind::ChatThreadRemove), extracting the inner [`GlobalEventChatThreadRemove`](crate::model::GlobalEventChatThreadRemove).
4124	/// Returns `Err(&Self)` if it can't be converted.
4125	pub fn as_chat_thread_remove(
4126		&self,
4127	) -> std::result::Result<&crate::model::GlobalEventChatThreadRemove, &Self> {
4128		if let GlobalEventKind::ChatThreadRemove(val) = &self {
4129			Ok(val)
4130		} else {
4131			Err(self)
4132		}
4133	}
4134	/// Returns true if this is a [`ChatThreadRemove`](crate::model::GlobalEventKind::ChatThreadRemove).
4135	pub fn is_chat_thread_remove(&self) -> bool {
4136		self.as_chat_thread_remove().is_ok()
4137	}
4138	/// Tries to convert the enum instance into [`IdentityUpdate`](crate::model::GlobalEventKind::IdentityUpdate), extracting the inner [`GlobalEventIdentityUpdate`](crate::model::GlobalEventIdentityUpdate).
4139	/// Returns `Err(&Self)` if it can't be converted.
4140	pub fn as_identity_update(
4141		&self,
4142	) -> std::result::Result<&crate::model::GlobalEventIdentityUpdate, &Self> {
4143		if let GlobalEventKind::IdentityUpdate(val) = &self {
4144			Ok(val)
4145		} else {
4146			Err(self)
4147		}
4148	}
4149	/// Returns true if this is a [`IdentityUpdate`](crate::model::GlobalEventKind::IdentityUpdate).
4150	pub fn is_identity_update(&self) -> bool {
4151		self.as_identity_update().is_ok()
4152	}
4153	/// Tries to convert the enum instance into [`MatchmakerLobbyJoin`](crate::model::GlobalEventKind::MatchmakerLobbyJoin), extracting the inner [`GlobalEventMatchmakerLobbyJoin`](crate::model::GlobalEventMatchmakerLobbyJoin).
4154	/// Returns `Err(&Self)` if it can't be converted.
4155	pub fn as_matchmaker_lobby_join(
4156		&self,
4157	) -> std::result::Result<&crate::model::GlobalEventMatchmakerLobbyJoin, &Self> {
4158		if let GlobalEventKind::MatchmakerLobbyJoin(val) = &self {
4159			Ok(val)
4160		} else {
4161			Err(self)
4162		}
4163	}
4164	/// Returns true if this is a [`MatchmakerLobbyJoin`](crate::model::GlobalEventKind::MatchmakerLobbyJoin).
4165	pub fn is_matchmaker_lobby_join(&self) -> bool {
4166		self.as_matchmaker_lobby_join().is_ok()
4167	}
4168	/// Tries to convert the enum instance into [`PartyUpdate`](crate::model::GlobalEventKind::PartyUpdate), extracting the inner [`GlobalEventPartyUpdate`](crate::model::GlobalEventPartyUpdate).
4169	/// Returns `Err(&Self)` if it can't be converted.
4170	pub fn as_party_update(
4171		&self,
4172	) -> std::result::Result<&crate::model::GlobalEventPartyUpdate, &Self> {
4173		if let GlobalEventKind::PartyUpdate(val) = &self {
4174			Ok(val)
4175		} else {
4176			Err(self)
4177		}
4178	}
4179	/// Returns true if this is a [`PartyUpdate`](crate::model::GlobalEventKind::PartyUpdate).
4180	pub fn is_party_update(&self) -> bool {
4181		self.as_party_update().is_ok()
4182	}
4183	/// Returns true if the enum instance is the `Unknown` variant.
4184	pub fn is_unknown(&self) -> bool {
4185		matches!(self, Self::Unknown)
4186	}
4187}
4188
4189/// `rivet.api.identity.common#GlobalEventKind` variant for a chat thread being removed. Received any time the current identity is no longer able to access the given thread. This can happen if
4190#[non_exhaustive]
4191#[derive(std::clone::Clone, std::cmp::PartialEq)]
4192pub struct GlobalEventChatThreadRemove {
4193	/// A universally unique identifier.
4194	pub thread_id: std::option::Option<std::string::String>,
4195}
4196impl GlobalEventChatThreadRemove {
4197	/// A universally unique identifier.
4198	pub fn thread_id(&self) -> std::option::Option<&str> {
4199		self.thread_id.as_deref()
4200	}
4201}
4202impl std::fmt::Debug for GlobalEventChatThreadRemove {
4203	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
4204		let mut formatter = f.debug_struct("GlobalEventChatThreadRemove");
4205		formatter.field("thread_id", &self.thread_id);
4206		formatter.finish()
4207	}
4208}
4209/// See [`GlobalEventChatThreadRemove`](crate::model::GlobalEventChatThreadRemove)
4210pub mod global_event_chat_thread_remove {
4211	/// A builder for [`GlobalEventChatThreadRemove`](crate::model::GlobalEventChatThreadRemove)
4212	#[non_exhaustive]
4213	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
4214	pub struct Builder {
4215		pub(crate) thread_id: std::option::Option<std::string::String>,
4216	}
4217	impl Builder {
4218		/// A universally unique identifier.
4219		pub fn thread_id(mut self, input: impl Into<std::string::String>) -> Self {
4220			self.thread_id = Some(input.into());
4221			self
4222		}
4223		/// A universally unique identifier.
4224		pub fn set_thread_id(mut self, input: std::option::Option<std::string::String>) -> Self {
4225			self.thread_id = input;
4226			self
4227		}
4228		/// Consumes the builder and constructs a [`GlobalEventChatThreadRemove`](crate::model::GlobalEventChatThreadRemove)
4229		pub fn build(self) -> crate::model::GlobalEventChatThreadRemove {
4230			crate::model::GlobalEventChatThreadRemove {
4231				thread_id: self.thread_id,
4232			}
4233		}
4234	}
4235}
4236impl GlobalEventChatThreadRemove {
4237	/// Creates a new builder-style object to manufacture [`GlobalEventChatThreadRemove`](crate::model::GlobalEventChatThreadRemove)
4238	pub fn builder() -> crate::model::global_event_chat_thread_remove::Builder {
4239		crate::model::global_event_chat_thread_remove::Builder::default()
4240	}
4241}
4242
4243/// `rivet.api.identity.common#GlobalEventKind` variant for party updates. Received when the identity should be instructed to join a lobby. This needs to be implemented in conjunction with parties in order to force clients to join the same lobby as the party they're in.
4244#[non_exhaustive]
4245#[derive(std::clone::Clone, std::cmp::PartialEq)]
4246pub struct GlobalEventMatchmakerLobbyJoin {
4247	/// A matchmaker lobby.
4248	pub lobby: std::option::Option<crate::model::MatchmakerLobbyJoinInfo>,
4249}
4250impl GlobalEventMatchmakerLobbyJoin {
4251	/// A matchmaker lobby.
4252	pub fn lobby(&self) -> std::option::Option<&crate::model::MatchmakerLobbyJoinInfo> {
4253		self.lobby.as_ref()
4254	}
4255}
4256impl std::fmt::Debug for GlobalEventMatchmakerLobbyJoin {
4257	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
4258		let mut formatter = f.debug_struct("GlobalEventMatchmakerLobbyJoin");
4259		formatter.field("lobby", &self.lobby);
4260		formatter.finish()
4261	}
4262}
4263/// See [`GlobalEventMatchmakerLobbyJoin`](crate::model::GlobalEventMatchmakerLobbyJoin)
4264pub mod global_event_matchmaker_lobby_join {
4265	/// A builder for [`GlobalEventMatchmakerLobbyJoin`](crate::model::GlobalEventMatchmakerLobbyJoin)
4266	#[non_exhaustive]
4267	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
4268	pub struct Builder {
4269		pub(crate) lobby: std::option::Option<crate::model::MatchmakerLobbyJoinInfo>,
4270	}
4271	impl Builder {
4272		/// A matchmaker lobby.
4273		pub fn lobby(mut self, input: crate::model::MatchmakerLobbyJoinInfo) -> Self {
4274			self.lobby = Some(input);
4275			self
4276		}
4277		/// A matchmaker lobby.
4278		pub fn set_lobby(
4279			mut self,
4280			input: std::option::Option<crate::model::MatchmakerLobbyJoinInfo>,
4281		) -> Self {
4282			self.lobby = input;
4283			self
4284		}
4285		/// Consumes the builder and constructs a [`GlobalEventMatchmakerLobbyJoin`](crate::model::GlobalEventMatchmakerLobbyJoin)
4286		pub fn build(self) -> crate::model::GlobalEventMatchmakerLobbyJoin {
4287			crate::model::GlobalEventMatchmakerLobbyJoin { lobby: self.lobby }
4288		}
4289	}
4290}
4291impl GlobalEventMatchmakerLobbyJoin {
4292	/// Creates a new builder-style object to manufacture [`GlobalEventMatchmakerLobbyJoin`](crate::model::GlobalEventMatchmakerLobbyJoin)
4293	pub fn builder() -> crate::model::global_event_matchmaker_lobby_join::Builder {
4294		crate::model::global_event_matchmaker_lobby_join::Builder::default()
4295	}
4296}
4297
4298/// A matchmaker lobby.
4299#[non_exhaustive]
4300#[derive(std::clone::Clone, std::cmp::PartialEq)]
4301pub struct MatchmakerLobbyJoinInfo {
4302	/// A universally unique identifier.
4303	pub lobby_id: std::option::Option<std::string::String>,
4304	/// A matchmaker lobby region.
4305	pub region: std::option::Option<crate::model::MatchmakerLobbyJoinInfoRegion>,
4306	/// A list of lobby ports.
4307	pub ports: std::option::Option<
4308		std::collections::HashMap<std::string::String, crate::model::MatchmakerLobbyJoinInfoPort>,
4309	>,
4310	/// A matchmaker lobby player.
4311	pub player: std::option::Option<crate::model::MatchmakerLobbyJoinInfoPlayer>,
4312}
4313impl MatchmakerLobbyJoinInfo {
4314	/// A universally unique identifier.
4315	pub fn lobby_id(&self) -> std::option::Option<&str> {
4316		self.lobby_id.as_deref()
4317	}
4318	/// A matchmaker lobby region.
4319	pub fn region(&self) -> std::option::Option<&crate::model::MatchmakerLobbyJoinInfoRegion> {
4320		self.region.as_ref()
4321	}
4322	/// A list of lobby ports.
4323	pub fn ports(
4324		&self,
4325	) -> std::option::Option<
4326		&std::collections::HashMap<std::string::String, crate::model::MatchmakerLobbyJoinInfoPort>,
4327	> {
4328		self.ports.as_ref()
4329	}
4330	/// A matchmaker lobby player.
4331	pub fn player(&self) -> std::option::Option<&crate::model::MatchmakerLobbyJoinInfoPlayer> {
4332		self.player.as_ref()
4333	}
4334}
4335impl std::fmt::Debug for MatchmakerLobbyJoinInfo {
4336	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
4337		let mut formatter = f.debug_struct("MatchmakerLobbyJoinInfo");
4338		formatter.field("lobby_id", &self.lobby_id);
4339		formatter.field("region", &self.region);
4340		formatter.field("ports", &self.ports);
4341		formatter.field("player", &self.player);
4342		formatter.finish()
4343	}
4344}
4345/// See [`MatchmakerLobbyJoinInfo`](crate::model::MatchmakerLobbyJoinInfo)
4346pub mod matchmaker_lobby_join_info {
4347	/// A builder for [`MatchmakerLobbyJoinInfo`](crate::model::MatchmakerLobbyJoinInfo)
4348	#[non_exhaustive]
4349	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
4350	pub struct Builder {
4351		pub(crate) lobby_id: std::option::Option<std::string::String>,
4352		pub(crate) region: std::option::Option<crate::model::MatchmakerLobbyJoinInfoRegion>,
4353		pub(crate) ports: std::option::Option<
4354			std::collections::HashMap<
4355				std::string::String,
4356				crate::model::MatchmakerLobbyJoinInfoPort,
4357			>,
4358		>,
4359		pub(crate) player: std::option::Option<crate::model::MatchmakerLobbyJoinInfoPlayer>,
4360	}
4361	impl Builder {
4362		/// A universally unique identifier.
4363		pub fn lobby_id(mut self, input: impl Into<std::string::String>) -> Self {
4364			self.lobby_id = Some(input.into());
4365			self
4366		}
4367		/// A universally unique identifier.
4368		pub fn set_lobby_id(mut self, input: std::option::Option<std::string::String>) -> Self {
4369			self.lobby_id = input;
4370			self
4371		}
4372		/// A matchmaker lobby region.
4373		pub fn region(mut self, input: crate::model::MatchmakerLobbyJoinInfoRegion) -> Self {
4374			self.region = Some(input);
4375			self
4376		}
4377		/// A matchmaker lobby region.
4378		pub fn set_region(
4379			mut self,
4380			input: std::option::Option<crate::model::MatchmakerLobbyJoinInfoRegion>,
4381		) -> Self {
4382			self.region = input;
4383			self
4384		}
4385		/// Adds a key-value pair to `ports`.
4386		///
4387		/// To override the contents of this collection use [`set_ports`](Self::set_ports).
4388		///
4389		/// A list of lobby ports.
4390		pub fn ports(
4391			mut self,
4392			k: impl Into<std::string::String>,
4393			v: crate::model::MatchmakerLobbyJoinInfoPort,
4394		) -> Self {
4395			let mut hash_map = self.ports.unwrap_or_default();
4396			hash_map.insert(k.into(), v);
4397			self.ports = Some(hash_map);
4398			self
4399		}
4400		/// A list of lobby ports.
4401		pub fn set_ports(
4402			mut self,
4403			input: std::option::Option<
4404				std::collections::HashMap<
4405					std::string::String,
4406					crate::model::MatchmakerLobbyJoinInfoPort,
4407				>,
4408			>,
4409		) -> Self {
4410			self.ports = input;
4411			self
4412		}
4413		/// A matchmaker lobby player.
4414		pub fn player(mut self, input: crate::model::MatchmakerLobbyJoinInfoPlayer) -> Self {
4415			self.player = Some(input);
4416			self
4417		}
4418		/// A matchmaker lobby player.
4419		pub fn set_player(
4420			mut self,
4421			input: std::option::Option<crate::model::MatchmakerLobbyJoinInfoPlayer>,
4422		) -> Self {
4423			self.player = input;
4424			self
4425		}
4426		/// Consumes the builder and constructs a [`MatchmakerLobbyJoinInfo`](crate::model::MatchmakerLobbyJoinInfo)
4427		pub fn build(self) -> crate::model::MatchmakerLobbyJoinInfo {
4428			crate::model::MatchmakerLobbyJoinInfo {
4429				lobby_id: self.lobby_id,
4430				region: self.region,
4431				ports: self.ports,
4432				player: self.player,
4433			}
4434		}
4435	}
4436}
4437impl MatchmakerLobbyJoinInfo {
4438	/// Creates a new builder-style object to manufacture [`MatchmakerLobbyJoinInfo`](crate::model::MatchmakerLobbyJoinInfo)
4439	pub fn builder() -> crate::model::matchmaker_lobby_join_info::Builder {
4440		crate::model::matchmaker_lobby_join_info::Builder::default()
4441	}
4442}
4443
4444/// A matchmaker lobby player.
4445#[non_exhaustive]
4446#[derive(std::clone::Clone, std::cmp::PartialEq)]
4447pub struct MatchmakerLobbyJoinInfoPlayer {
4448	/// Pass this token through the socket to the lobby server. The lobby server will validate this token with `rivet.api.matchmaker#PlayerConnected$player_token`.
4449	pub token: std::option::Option<std::string::String>,
4450}
4451impl MatchmakerLobbyJoinInfoPlayer {
4452	/// Pass this token through the socket to the lobby server. The lobby server will validate this token with `rivet.api.matchmaker#PlayerConnected$player_token`.
4453	pub fn token(&self) -> std::option::Option<&str> {
4454		self.token.as_deref()
4455	}
4456}
4457impl std::fmt::Debug for MatchmakerLobbyJoinInfoPlayer {
4458	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
4459		let mut formatter = f.debug_struct("MatchmakerLobbyJoinInfoPlayer");
4460		formatter.field("token", &"*** Sensitive Data Redacted ***");
4461		formatter.finish()
4462	}
4463}
4464/// See [`MatchmakerLobbyJoinInfoPlayer`](crate::model::MatchmakerLobbyJoinInfoPlayer)
4465pub mod matchmaker_lobby_join_info_player {
4466	/// A builder for [`MatchmakerLobbyJoinInfoPlayer`](crate::model::MatchmakerLobbyJoinInfoPlayer)
4467	#[non_exhaustive]
4468	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
4469	pub struct Builder {
4470		pub(crate) token: std::option::Option<std::string::String>,
4471	}
4472	impl Builder {
4473		/// Pass this token through the socket to the lobby server. The lobby server will validate this token with `rivet.api.matchmaker#PlayerConnected$player_token`.
4474		pub fn token(mut self, input: impl Into<std::string::String>) -> Self {
4475			self.token = Some(input.into());
4476			self
4477		}
4478		/// Pass this token through the socket to the lobby server. The lobby server will validate this token with `rivet.api.matchmaker#PlayerConnected$player_token`.
4479		pub fn set_token(mut self, input: std::option::Option<std::string::String>) -> Self {
4480			self.token = input;
4481			self
4482		}
4483		/// Consumes the builder and constructs a [`MatchmakerLobbyJoinInfoPlayer`](crate::model::MatchmakerLobbyJoinInfoPlayer)
4484		pub fn build(self) -> crate::model::MatchmakerLobbyJoinInfoPlayer {
4485			crate::model::MatchmakerLobbyJoinInfoPlayer { token: self.token }
4486		}
4487	}
4488}
4489impl MatchmakerLobbyJoinInfoPlayer {
4490	/// Creates a new builder-style object to manufacture [`MatchmakerLobbyJoinInfoPlayer`](crate::model::MatchmakerLobbyJoinInfoPlayer)
4491	pub fn builder() -> crate::model::matchmaker_lobby_join_info_player::Builder {
4492		crate::model::matchmaker_lobby_join_info_player::Builder::default()
4493	}
4494}
4495
4496/// A matchmaker lobby port. Configured by `rivet.cloud#LobbyGroupRuntimeDockerPort$label`.
4497#[non_exhaustive]
4498#[derive(std::clone::Clone, std::cmp::PartialEq)]
4499pub struct MatchmakerLobbyJoinInfoPort {
4500	/// The host for the given port. Will be null if using a port range.
4501	pub host: std::option::Option<std::string::String>,
4502	/// The hostname for the given port.
4503	pub hostname: std::option::Option<std::string::String>,
4504	/// The port number for this lobby. Will be null if using a port range.
4505	pub port: std::option::Option<i32>,
4506	/// The port range for this lobby.
4507	pub port_range: std::option::Option<crate::model::MatchmakerLobbyJoinInfoPortRange>,
4508	/// Wether or not this lobby port uses TLS. You cannot mix a non-TLS and TLS ports.
4509	pub is_tls: std::option::Option<bool>,
4510}
4511impl MatchmakerLobbyJoinInfoPort {
4512	/// The host for the given port. Will be null if using a port range.
4513	pub fn host(&self) -> std::option::Option<&str> {
4514		self.host.as_deref()
4515	}
4516	/// The hostname for the given port.
4517	pub fn hostname(&self) -> std::option::Option<&str> {
4518		self.hostname.as_deref()
4519	}
4520	/// The port number for this lobby. Will be null if using a port range.
4521	pub fn port(&self) -> std::option::Option<i32> {
4522		self.port
4523	}
4524	/// The port range for this lobby.
4525	pub fn port_range(
4526		&self,
4527	) -> std::option::Option<&crate::model::MatchmakerLobbyJoinInfoPortRange> {
4528		self.port_range.as_ref()
4529	}
4530	/// Wether or not this lobby port uses TLS. You cannot mix a non-TLS and TLS ports.
4531	pub fn is_tls(&self) -> std::option::Option<bool> {
4532		self.is_tls
4533	}
4534}
4535impl std::fmt::Debug for MatchmakerLobbyJoinInfoPort {
4536	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
4537		let mut formatter = f.debug_struct("MatchmakerLobbyJoinInfoPort");
4538		formatter.field("host", &self.host);
4539		formatter.field("hostname", &self.hostname);
4540		formatter.field("port", &self.port);
4541		formatter.field("port_range", &self.port_range);
4542		formatter.field("is_tls", &self.is_tls);
4543		formatter.finish()
4544	}
4545}
4546/// See [`MatchmakerLobbyJoinInfoPort`](crate::model::MatchmakerLobbyJoinInfoPort)
4547pub mod matchmaker_lobby_join_info_port {
4548	/// A builder for [`MatchmakerLobbyJoinInfoPort`](crate::model::MatchmakerLobbyJoinInfoPort)
4549	#[non_exhaustive]
4550	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
4551	pub struct Builder {
4552		pub(crate) host: std::option::Option<std::string::String>,
4553		pub(crate) hostname: std::option::Option<std::string::String>,
4554		pub(crate) port: std::option::Option<i32>,
4555		pub(crate) port_range: std::option::Option<crate::model::MatchmakerLobbyJoinInfoPortRange>,
4556		pub(crate) is_tls: std::option::Option<bool>,
4557	}
4558	impl Builder {
4559		/// The host for the given port. Will be null if using a port range.
4560		pub fn host(mut self, input: impl Into<std::string::String>) -> Self {
4561			self.host = Some(input.into());
4562			self
4563		}
4564		/// The host for the given port. Will be null if using a port range.
4565		pub fn set_host(mut self, input: std::option::Option<std::string::String>) -> Self {
4566			self.host = input;
4567			self
4568		}
4569		/// The hostname for the given port.
4570		pub fn hostname(mut self, input: impl Into<std::string::String>) -> Self {
4571			self.hostname = Some(input.into());
4572			self
4573		}
4574		/// The hostname for the given port.
4575		pub fn set_hostname(mut self, input: std::option::Option<std::string::String>) -> Self {
4576			self.hostname = input;
4577			self
4578		}
4579		/// The port number for this lobby. Will be null if using a port range.
4580		pub fn port(mut self, input: i32) -> Self {
4581			self.port = Some(input);
4582			self
4583		}
4584		/// The port number for this lobby. Will be null if using a port range.
4585		pub fn set_port(mut self, input: std::option::Option<i32>) -> Self {
4586			self.port = input;
4587			self
4588		}
4589		/// The port range for this lobby.
4590		pub fn port_range(mut self, input: crate::model::MatchmakerLobbyJoinInfoPortRange) -> Self {
4591			self.port_range = Some(input);
4592			self
4593		}
4594		/// The port range for this lobby.
4595		pub fn set_port_range(
4596			mut self,
4597			input: std::option::Option<crate::model::MatchmakerLobbyJoinInfoPortRange>,
4598		) -> Self {
4599			self.port_range = input;
4600			self
4601		}
4602		/// Wether or not this lobby port uses TLS. You cannot mix a non-TLS and TLS ports.
4603		pub fn is_tls(mut self, input: bool) -> Self {
4604			self.is_tls = Some(input);
4605			self
4606		}
4607		/// Wether or not this lobby port uses TLS. You cannot mix a non-TLS and TLS ports.
4608		pub fn set_is_tls(mut self, input: std::option::Option<bool>) -> Self {
4609			self.is_tls = input;
4610			self
4611		}
4612		/// Consumes the builder and constructs a [`MatchmakerLobbyJoinInfoPort`](crate::model::MatchmakerLobbyJoinInfoPort)
4613		pub fn build(self) -> crate::model::MatchmakerLobbyJoinInfoPort {
4614			crate::model::MatchmakerLobbyJoinInfoPort {
4615				host: self.host,
4616				hostname: self.hostname,
4617				port: self.port,
4618				port_range: self.port_range,
4619				is_tls: self.is_tls,
4620			}
4621		}
4622	}
4623}
4624impl MatchmakerLobbyJoinInfoPort {
4625	/// Creates a new builder-style object to manufacture [`MatchmakerLobbyJoinInfoPort`](crate::model::MatchmakerLobbyJoinInfoPort)
4626	pub fn builder() -> crate::model::matchmaker_lobby_join_info_port::Builder {
4627		crate::model::matchmaker_lobby_join_info_port::Builder::default()
4628	}
4629}
4630
4631/// Inclusive range of ports that can be connected to.
4632#[non_exhaustive]
4633#[derive(std::clone::Clone, std::cmp::PartialEq)]
4634pub struct MatchmakerLobbyJoinInfoPortRange {
4635	/// Minimum port that can be connected to. Inclusive range.
4636	pub min: std::option::Option<i32>,
4637	/// Maximum port that can be connected to. Inclusive range.
4638	pub max: std::option::Option<i32>,
4639}
4640impl MatchmakerLobbyJoinInfoPortRange {
4641	/// Minimum port that can be connected to. Inclusive range.
4642	pub fn min(&self) -> std::option::Option<i32> {
4643		self.min
4644	}
4645	/// Maximum port that can be connected to. Inclusive range.
4646	pub fn max(&self) -> std::option::Option<i32> {
4647		self.max
4648	}
4649}
4650impl std::fmt::Debug for MatchmakerLobbyJoinInfoPortRange {
4651	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
4652		let mut formatter = f.debug_struct("MatchmakerLobbyJoinInfoPortRange");
4653		formatter.field("min", &self.min);
4654		formatter.field("max", &self.max);
4655		formatter.finish()
4656	}
4657}
4658/// See [`MatchmakerLobbyJoinInfoPortRange`](crate::model::MatchmakerLobbyJoinInfoPortRange)
4659pub mod matchmaker_lobby_join_info_port_range {
4660	/// A builder for [`MatchmakerLobbyJoinInfoPortRange`](crate::model::MatchmakerLobbyJoinInfoPortRange)
4661	#[non_exhaustive]
4662	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
4663	pub struct Builder {
4664		pub(crate) min: std::option::Option<i32>,
4665		pub(crate) max: std::option::Option<i32>,
4666	}
4667	impl Builder {
4668		/// Minimum port that can be connected to. Inclusive range.
4669		pub fn min(mut self, input: i32) -> Self {
4670			self.min = Some(input);
4671			self
4672		}
4673		/// Minimum port that can be connected to. Inclusive range.
4674		pub fn set_min(mut self, input: std::option::Option<i32>) -> Self {
4675			self.min = input;
4676			self
4677		}
4678		/// Maximum port that can be connected to. Inclusive range.
4679		pub fn max(mut self, input: i32) -> Self {
4680			self.max = Some(input);
4681			self
4682		}
4683		/// Maximum port that can be connected to. Inclusive range.
4684		pub fn set_max(mut self, input: std::option::Option<i32>) -> Self {
4685			self.max = input;
4686			self
4687		}
4688		/// Consumes the builder and constructs a [`MatchmakerLobbyJoinInfoPortRange`](crate::model::MatchmakerLobbyJoinInfoPortRange)
4689		pub fn build(self) -> crate::model::MatchmakerLobbyJoinInfoPortRange {
4690			crate::model::MatchmakerLobbyJoinInfoPortRange {
4691				min: self.min,
4692				max: self.max,
4693			}
4694		}
4695	}
4696}
4697impl MatchmakerLobbyJoinInfoPortRange {
4698	/// Creates a new builder-style object to manufacture [`MatchmakerLobbyJoinInfoPortRange`](crate::model::MatchmakerLobbyJoinInfoPortRange)
4699	pub fn builder() -> crate::model::matchmaker_lobby_join_info_port_range::Builder {
4700		crate::model::matchmaker_lobby_join_info_port_range::Builder::default()
4701	}
4702}
4703
4704/// A matchmaker lobby region.
4705#[non_exhaustive]
4706#[derive(std::clone::Clone, std::cmp::PartialEq)]
4707pub struct MatchmakerLobbyJoinInfoRegion {
4708	/// 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.
4709	pub region_id: std::option::Option<std::string::String>,
4710	/// Represent a resource's readable display name.
4711	pub display_name: std::option::Option<std::string::String>,
4712}
4713impl MatchmakerLobbyJoinInfoRegion {
4714	/// 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.
4715	pub fn region_id(&self) -> std::option::Option<&str> {
4716		self.region_id.as_deref()
4717	}
4718	/// Represent a resource's readable display name.
4719	pub fn display_name(&self) -> std::option::Option<&str> {
4720		self.display_name.as_deref()
4721	}
4722}
4723impl std::fmt::Debug for MatchmakerLobbyJoinInfoRegion {
4724	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
4725		let mut formatter = f.debug_struct("MatchmakerLobbyJoinInfoRegion");
4726		formatter.field("region_id", &self.region_id);
4727		formatter.field("display_name", &self.display_name);
4728		formatter.finish()
4729	}
4730}
4731/// See [`MatchmakerLobbyJoinInfoRegion`](crate::model::MatchmakerLobbyJoinInfoRegion)
4732pub mod matchmaker_lobby_join_info_region {
4733	/// A builder for [`MatchmakerLobbyJoinInfoRegion`](crate::model::MatchmakerLobbyJoinInfoRegion)
4734	#[non_exhaustive]
4735	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
4736	pub struct Builder {
4737		pub(crate) region_id: std::option::Option<std::string::String>,
4738		pub(crate) display_name: std::option::Option<std::string::String>,
4739	}
4740	impl Builder {
4741		/// 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.
4742		pub fn region_id(mut self, input: impl Into<std::string::String>) -> Self {
4743			self.region_id = Some(input.into());
4744			self
4745		}
4746		/// 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.
4747		pub fn set_region_id(mut self, input: std::option::Option<std::string::String>) -> Self {
4748			self.region_id = input;
4749			self
4750		}
4751		/// Represent a resource's readable display name.
4752		pub fn display_name(mut self, input: impl Into<std::string::String>) -> Self {
4753			self.display_name = Some(input.into());
4754			self
4755		}
4756		/// Represent a resource's readable display name.
4757		pub fn set_display_name(mut self, input: std::option::Option<std::string::String>) -> Self {
4758			self.display_name = input;
4759			self
4760		}
4761		/// Consumes the builder and constructs a [`MatchmakerLobbyJoinInfoRegion`](crate::model::MatchmakerLobbyJoinInfoRegion)
4762		pub fn build(self) -> crate::model::MatchmakerLobbyJoinInfoRegion {
4763			crate::model::MatchmakerLobbyJoinInfoRegion {
4764				region_id: self.region_id,
4765				display_name: self.display_name,
4766			}
4767		}
4768	}
4769}
4770impl MatchmakerLobbyJoinInfoRegion {
4771	/// Creates a new builder-style object to manufacture [`MatchmakerLobbyJoinInfoRegion`](crate::model::MatchmakerLobbyJoinInfoRegion)
4772	pub fn builder() -> crate::model::matchmaker_lobby_join_info_region::Builder {
4773		crate::model::matchmaker_lobby_join_info_region::Builder::default()
4774	}
4775}
4776
4777/// `rivet.api.identity.common#GlobalEventKind` variant for identity updates. Received any time identity details are changed OR the identity switches.
4778#[non_exhaustive]
4779#[derive(std::clone::Clone, std::cmp::PartialEq)]
4780pub struct GlobalEventIdentityUpdate {
4781	/// An identity profile.
4782	pub identity: std::option::Option<crate::model::IdentityProfile>,
4783}
4784impl GlobalEventIdentityUpdate {
4785	/// An identity profile.
4786	pub fn identity(&self) -> std::option::Option<&crate::model::IdentityProfile> {
4787		self.identity.as_ref()
4788	}
4789}
4790impl std::fmt::Debug for GlobalEventIdentityUpdate {
4791	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
4792		let mut formatter = f.debug_struct("GlobalEventIdentityUpdate");
4793		formatter.field("identity", &self.identity);
4794		formatter.finish()
4795	}
4796}
4797/// See [`GlobalEventIdentityUpdate`](crate::model::GlobalEventIdentityUpdate)
4798pub mod global_event_identity_update {
4799	/// A builder for [`GlobalEventIdentityUpdate`](crate::model::GlobalEventIdentityUpdate)
4800	#[non_exhaustive]
4801	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
4802	pub struct Builder {
4803		pub(crate) identity: std::option::Option<crate::model::IdentityProfile>,
4804	}
4805	impl Builder {
4806		/// An identity profile.
4807		pub fn identity(mut self, input: crate::model::IdentityProfile) -> Self {
4808			self.identity = Some(input);
4809			self
4810		}
4811		/// An identity profile.
4812		pub fn set_identity(
4813			mut self,
4814			input: std::option::Option<crate::model::IdentityProfile>,
4815		) -> Self {
4816			self.identity = input;
4817			self
4818		}
4819		/// Consumes the builder and constructs a [`GlobalEventIdentityUpdate`](crate::model::GlobalEventIdentityUpdate)
4820		pub fn build(self) -> crate::model::GlobalEventIdentityUpdate {
4821			crate::model::GlobalEventIdentityUpdate {
4822				identity: self.identity,
4823			}
4824		}
4825	}
4826}
4827impl GlobalEventIdentityUpdate {
4828	/// Creates a new builder-style object to manufacture [`GlobalEventIdentityUpdate`](crate::model::GlobalEventIdentityUpdate)
4829	pub fn builder() -> crate::model::global_event_identity_update::Builder {
4830		crate::model::global_event_identity_update::Builder::default()
4831	}
4832}
4833
4834/// `rivet.api.identity.common#GlobalEventKind` variant for party updates. Received any time the identity joins a party, a party is updated, or when the identity leaves a party.
4835#[non_exhaustive]
4836#[derive(std::clone::Clone, std::cmp::PartialEq)]
4837pub struct GlobalEventPartyUpdate {
4838	/// If null, the identity left the party.
4839	pub party: std::option::Option<crate::model::PartySummary>,
4840}
4841impl GlobalEventPartyUpdate {
4842	/// If null, the identity left the party.
4843	pub fn party(&self) -> std::option::Option<&crate::model::PartySummary> {
4844		self.party.as_ref()
4845	}
4846}
4847impl std::fmt::Debug for GlobalEventPartyUpdate {
4848	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
4849		let mut formatter = f.debug_struct("GlobalEventPartyUpdate");
4850		formatter.field("party", &self.party);
4851		formatter.finish()
4852	}
4853}
4854/// See [`GlobalEventPartyUpdate`](crate::model::GlobalEventPartyUpdate)
4855pub mod global_event_party_update {
4856	/// A builder for [`GlobalEventPartyUpdate`](crate::model::GlobalEventPartyUpdate)
4857	#[non_exhaustive]
4858	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
4859	pub struct Builder {
4860		pub(crate) party: std::option::Option<crate::model::PartySummary>,
4861	}
4862	impl Builder {
4863		/// If null, the identity left the party.
4864		pub fn party(mut self, input: crate::model::PartySummary) -> Self {
4865			self.party = Some(input);
4866			self
4867		}
4868		/// If null, the identity left the party.
4869		pub fn set_party(mut self, input: std::option::Option<crate::model::PartySummary>) -> Self {
4870			self.party = input;
4871			self
4872		}
4873		/// Consumes the builder and constructs a [`GlobalEventPartyUpdate`](crate::model::GlobalEventPartyUpdate)
4874		pub fn build(self) -> crate::model::GlobalEventPartyUpdate {
4875			crate::model::GlobalEventPartyUpdate { party: self.party }
4876		}
4877	}
4878}
4879impl GlobalEventPartyUpdate {
4880	/// Creates a new builder-style object to manufacture [`GlobalEventPartyUpdate`](crate::model::GlobalEventPartyUpdate)
4881	pub fn builder() -> crate::model::global_event_party_update::Builder {
4882		crate::model::global_event_party_update::Builder::default()
4883	}
4884}
4885
4886/// `rivet.api.identity.common#GlobalEventKind` variant for chat reads. Received any time the last read timestamp is set. Used to update the status of unread indicators on chats.
4887#[non_exhaustive]
4888#[derive(std::clone::Clone, std::cmp::PartialEq)]
4889pub struct GlobalEventChatRead {
4890	/// A universally unique identifier.
4891	pub thread_id: std::option::Option<std::string::String>,
4892	/// RFC3339 timestamp.
4893	pub read_ts: std::option::Option<aws_smithy_types::DateTime>,
4894}
4895impl GlobalEventChatRead {
4896	/// A universally unique identifier.
4897	pub fn thread_id(&self) -> std::option::Option<&str> {
4898		self.thread_id.as_deref()
4899	}
4900	/// RFC3339 timestamp.
4901	pub fn read_ts(&self) -> std::option::Option<&aws_smithy_types::DateTime> {
4902		self.read_ts.as_ref()
4903	}
4904}
4905impl std::fmt::Debug for GlobalEventChatRead {
4906	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
4907		let mut formatter = f.debug_struct("GlobalEventChatRead");
4908		formatter.field("thread_id", &self.thread_id);
4909		formatter.field("read_ts", &self.read_ts);
4910		formatter.finish()
4911	}
4912}
4913/// See [`GlobalEventChatRead`](crate::model::GlobalEventChatRead)
4914pub mod global_event_chat_read {
4915	/// A builder for [`GlobalEventChatRead`](crate::model::GlobalEventChatRead)
4916	#[non_exhaustive]
4917	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
4918	pub struct Builder {
4919		pub(crate) thread_id: std::option::Option<std::string::String>,
4920		pub(crate) read_ts: std::option::Option<aws_smithy_types::DateTime>,
4921	}
4922	impl Builder {
4923		/// A universally unique identifier.
4924		pub fn thread_id(mut self, input: impl Into<std::string::String>) -> Self {
4925			self.thread_id = Some(input.into());
4926			self
4927		}
4928		/// A universally unique identifier.
4929		pub fn set_thread_id(mut self, input: std::option::Option<std::string::String>) -> Self {
4930			self.thread_id = input;
4931			self
4932		}
4933		/// RFC3339 timestamp.
4934		pub fn read_ts(mut self, input: aws_smithy_types::DateTime) -> Self {
4935			self.read_ts = Some(input);
4936			self
4937		}
4938		/// RFC3339 timestamp.
4939		pub fn set_read_ts(
4940			mut self,
4941			input: std::option::Option<aws_smithy_types::DateTime>,
4942		) -> Self {
4943			self.read_ts = input;
4944			self
4945		}
4946		/// Consumes the builder and constructs a [`GlobalEventChatRead`](crate::model::GlobalEventChatRead)
4947		pub fn build(self) -> crate::model::GlobalEventChatRead {
4948			crate::model::GlobalEventChatRead {
4949				thread_id: self.thread_id,
4950				read_ts: self.read_ts,
4951			}
4952		}
4953	}
4954}
4955impl GlobalEventChatRead {
4956	/// Creates a new builder-style object to manufacture [`GlobalEventChatRead`](crate::model::GlobalEventChatRead)
4957	pub fn builder() -> crate::model::global_event_chat_read::Builder {
4958		crate::model::global_event_chat_read::Builder::default()
4959	}
4960}
4961
4962/// `rivet.api.identity.common#GlobalEventKind` variant for chat messages. Received any time a message is sent to a chat the identity is in.
4963#[non_exhaustive]
4964#[derive(std::clone::Clone, std::cmp::PartialEq)]
4965pub struct GlobalEventChatMessage {
4966	/// A chat thread.
4967	pub thread: std::option::Option<crate::model::ChatThread>,
4968}
4969impl GlobalEventChatMessage {
4970	/// A chat thread.
4971	pub fn thread(&self) -> std::option::Option<&crate::model::ChatThread> {
4972		self.thread.as_ref()
4973	}
4974}
4975impl std::fmt::Debug for GlobalEventChatMessage {
4976	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
4977		let mut formatter = f.debug_struct("GlobalEventChatMessage");
4978		formatter.field("thread", &self.thread);
4979		formatter.finish()
4980	}
4981}
4982/// See [`GlobalEventChatMessage`](crate::model::GlobalEventChatMessage)
4983pub mod global_event_chat_message {
4984	/// A builder for [`GlobalEventChatMessage`](crate::model::GlobalEventChatMessage)
4985	#[non_exhaustive]
4986	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
4987	pub struct Builder {
4988		pub(crate) thread: std::option::Option<crate::model::ChatThread>,
4989	}
4990	impl Builder {
4991		/// A chat thread.
4992		pub fn thread(mut self, input: crate::model::ChatThread) -> Self {
4993			self.thread = Some(input);
4994			self
4995		}
4996		/// A chat thread.
4997		pub fn set_thread(mut self, input: std::option::Option<crate::model::ChatThread>) -> Self {
4998			self.thread = input;
4999			self
5000		}
5001		/// Consumes the builder and constructs a [`GlobalEventChatMessage`](crate::model::GlobalEventChatMessage)
5002		pub fn build(self) -> crate::model::GlobalEventChatMessage {
5003			crate::model::GlobalEventChatMessage {
5004				thread: self.thread,
5005			}
5006		}
5007	}
5008}
5009impl GlobalEventChatMessage {
5010	/// Creates a new builder-style object to manufacture [`GlobalEventChatMessage`](crate::model::GlobalEventChatMessage)
5011	pub fn builder() -> crate::model::global_event_chat_message::Builder {
5012		crate::model::global_event_chat_message::Builder::default()
5013	}
5014}
5015
5016/// A chat thread.
5017#[non_exhaustive]
5018#[derive(std::clone::Clone, std::cmp::PartialEq)]
5019pub struct ChatThread {
5020	/// A universally unique identifier.
5021	pub thread_id: std::option::Option<std::string::String>,
5022	/// RFC3339 timestamp.
5023	pub create_ts: std::option::Option<aws_smithy_types::DateTime>,
5024	/// Represents the topic of the given chat thread.
5025	pub topic: std::option::Option<crate::model::ChatTopic>,
5026	/// A chat message.
5027	pub tail_message: std::option::Option<crate::model::ChatMessage>,
5028	/// RFC3339 timestamp.
5029	pub last_read_ts: std::option::Option<aws_smithy_types::DateTime>,
5030	/// Unsigned 64 bit integer.
5031	pub unread_count: std::option::Option<i64>,
5032	/// External links for a chat thread.
5033	pub external: std::option::Option<crate::model::ChatThreadExternalLinks>,
5034}
5035impl ChatThread {
5036	/// A universally unique identifier.
5037	pub fn thread_id(&self) -> std::option::Option<&str> {
5038		self.thread_id.as_deref()
5039	}
5040	/// RFC3339 timestamp.
5041	pub fn create_ts(&self) -> std::option::Option<&aws_smithy_types::DateTime> {
5042		self.create_ts.as_ref()
5043	}
5044	/// Represents the topic of the given chat thread.
5045	pub fn topic(&self) -> std::option::Option<&crate::model::ChatTopic> {
5046		self.topic.as_ref()
5047	}
5048	/// A chat message.
5049	pub fn tail_message(&self) -> std::option::Option<&crate::model::ChatMessage> {
5050		self.tail_message.as_ref()
5051	}
5052	/// RFC3339 timestamp.
5053	pub fn last_read_ts(&self) -> std::option::Option<&aws_smithy_types::DateTime> {
5054		self.last_read_ts.as_ref()
5055	}
5056	/// Unsigned 64 bit integer.
5057	pub fn unread_count(&self) -> std::option::Option<i64> {
5058		self.unread_count
5059	}
5060	/// External links for a chat thread.
5061	pub fn external(&self) -> std::option::Option<&crate::model::ChatThreadExternalLinks> {
5062		self.external.as_ref()
5063	}
5064}
5065impl std::fmt::Debug for ChatThread {
5066	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
5067		let mut formatter = f.debug_struct("ChatThread");
5068		formatter.field("thread_id", &self.thread_id);
5069		formatter.field("create_ts", &self.create_ts);
5070		formatter.field("topic", &self.topic);
5071		formatter.field("tail_message", &self.tail_message);
5072		formatter.field("last_read_ts", &self.last_read_ts);
5073		formatter.field("unread_count", &self.unread_count);
5074		formatter.field("external", &self.external);
5075		formatter.finish()
5076	}
5077}
5078/// See [`ChatThread`](crate::model::ChatThread)
5079pub mod chat_thread {
5080	/// A builder for [`ChatThread`](crate::model::ChatThread)
5081	#[non_exhaustive]
5082	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
5083	pub struct Builder {
5084		pub(crate) thread_id: std::option::Option<std::string::String>,
5085		pub(crate) create_ts: std::option::Option<aws_smithy_types::DateTime>,
5086		pub(crate) topic: std::option::Option<crate::model::ChatTopic>,
5087		pub(crate) tail_message: std::option::Option<crate::model::ChatMessage>,
5088		pub(crate) last_read_ts: std::option::Option<aws_smithy_types::DateTime>,
5089		pub(crate) unread_count: std::option::Option<i64>,
5090		pub(crate) external: std::option::Option<crate::model::ChatThreadExternalLinks>,
5091	}
5092	impl Builder {
5093		/// A universally unique identifier.
5094		pub fn thread_id(mut self, input: impl Into<std::string::String>) -> Self {
5095			self.thread_id = Some(input.into());
5096			self
5097		}
5098		/// A universally unique identifier.
5099		pub fn set_thread_id(mut self, input: std::option::Option<std::string::String>) -> Self {
5100			self.thread_id = input;
5101			self
5102		}
5103		/// RFC3339 timestamp.
5104		pub fn create_ts(mut self, input: aws_smithy_types::DateTime) -> Self {
5105			self.create_ts = Some(input);
5106			self
5107		}
5108		/// RFC3339 timestamp.
5109		pub fn set_create_ts(
5110			mut self,
5111			input: std::option::Option<aws_smithy_types::DateTime>,
5112		) -> Self {
5113			self.create_ts = input;
5114			self
5115		}
5116		/// Represents the topic of the given chat thread.
5117		pub fn topic(mut self, input: crate::model::ChatTopic) -> Self {
5118			self.topic = Some(input);
5119			self
5120		}
5121		/// Represents the topic of the given chat thread.
5122		pub fn set_topic(mut self, input: std::option::Option<crate::model::ChatTopic>) -> Self {
5123			self.topic = input;
5124			self
5125		}
5126		/// A chat message.
5127		pub fn tail_message(mut self, input: crate::model::ChatMessage) -> Self {
5128			self.tail_message = Some(input);
5129			self
5130		}
5131		/// A chat message.
5132		pub fn set_tail_message(
5133			mut self,
5134			input: std::option::Option<crate::model::ChatMessage>,
5135		) -> Self {
5136			self.tail_message = input;
5137			self
5138		}
5139		/// RFC3339 timestamp.
5140		pub fn last_read_ts(mut self, input: aws_smithy_types::DateTime) -> Self {
5141			self.last_read_ts = Some(input);
5142			self
5143		}
5144		/// RFC3339 timestamp.
5145		pub fn set_last_read_ts(
5146			mut self,
5147			input: std::option::Option<aws_smithy_types::DateTime>,
5148		) -> Self {
5149			self.last_read_ts = input;
5150			self
5151		}
5152		/// Unsigned 64 bit integer.
5153		pub fn unread_count(mut self, input: i64) -> Self {
5154			self.unread_count = Some(input);
5155			self
5156		}
5157		/// Unsigned 64 bit integer.
5158		pub fn set_unread_count(mut self, input: std::option::Option<i64>) -> Self {
5159			self.unread_count = input;
5160			self
5161		}
5162		/// External links for a chat thread.
5163		pub fn external(mut self, input: crate::model::ChatThreadExternalLinks) -> Self {
5164			self.external = Some(input);
5165			self
5166		}
5167		/// External links for a chat thread.
5168		pub fn set_external(
5169			mut self,
5170			input: std::option::Option<crate::model::ChatThreadExternalLinks>,
5171		) -> Self {
5172			self.external = input;
5173			self
5174		}
5175		/// Consumes the builder and constructs a [`ChatThread`](crate::model::ChatThread)
5176		pub fn build(self) -> crate::model::ChatThread {
5177			crate::model::ChatThread {
5178				thread_id: self.thread_id,
5179				create_ts: self.create_ts,
5180				topic: self.topic,
5181				tail_message: self.tail_message,
5182				last_read_ts: self.last_read_ts,
5183				unread_count: self.unread_count,
5184				external: self.external,
5185			}
5186		}
5187	}
5188}
5189impl ChatThread {
5190	/// Creates a new builder-style object to manufacture [`ChatThread`](crate::model::ChatThread)
5191	pub fn builder() -> crate::model::chat_thread::Builder {
5192		crate::model::chat_thread::Builder::default()
5193	}
5194}
5195
5196/// External links for a chat thread.
5197#[non_exhaustive]
5198#[derive(std::clone::Clone, std::cmp::PartialEq)]
5199pub struct ChatThreadExternalLinks {
5200	/// A link to opening the chat thread.
5201	pub chat: std::option::Option<std::string::String>,
5202}
5203impl ChatThreadExternalLinks {
5204	/// A link to opening the chat thread.
5205	pub fn chat(&self) -> std::option::Option<&str> {
5206		self.chat.as_deref()
5207	}
5208}
5209impl std::fmt::Debug for ChatThreadExternalLinks {
5210	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
5211		let mut formatter = f.debug_struct("ChatThreadExternalLinks");
5212		formatter.field("chat", &self.chat);
5213		formatter.finish()
5214	}
5215}
5216/// See [`ChatThreadExternalLinks`](crate::model::ChatThreadExternalLinks)
5217pub mod chat_thread_external_links {
5218	/// A builder for [`ChatThreadExternalLinks`](crate::model::ChatThreadExternalLinks)
5219	#[non_exhaustive]
5220	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
5221	pub struct Builder {
5222		pub(crate) chat: std::option::Option<std::string::String>,
5223	}
5224	impl Builder {
5225		/// A link to opening the chat thread.
5226		pub fn chat(mut self, input: impl Into<std::string::String>) -> Self {
5227			self.chat = Some(input.into());
5228			self
5229		}
5230		/// A link to opening the chat thread.
5231		pub fn set_chat(mut self, input: std::option::Option<std::string::String>) -> Self {
5232			self.chat = input;
5233			self
5234		}
5235		/// Consumes the builder and constructs a [`ChatThreadExternalLinks`](crate::model::ChatThreadExternalLinks)
5236		pub fn build(self) -> crate::model::ChatThreadExternalLinks {
5237			crate::model::ChatThreadExternalLinks { chat: self.chat }
5238		}
5239	}
5240}
5241impl ChatThreadExternalLinks {
5242	/// Creates a new builder-style object to manufacture [`ChatThreadExternalLinks`](crate::model::ChatThreadExternalLinks)
5243	pub fn builder() -> crate::model::chat_thread_external_links::Builder {
5244		crate::model::chat_thread_external_links::Builder::default()
5245	}
5246}
5247
5248/// A chat message.
5249#[non_exhaustive]
5250#[derive(std::clone::Clone, std::cmp::PartialEq)]
5251pub struct ChatMessage {
5252	/// A universally unique identifier.
5253	pub chat_message_id: std::option::Option<std::string::String>,
5254	/// A universally unique identifier.
5255	pub thread_id: std::option::Option<std::string::String>,
5256	/// RFC3339 timestamp.
5257	pub send_ts: std::option::Option<aws_smithy_types::DateTime>,
5258	/// Represents types of chat message bodies.
5259	pub body: std::option::Option<crate::model::ChatMessageBody>,
5260}
5261impl ChatMessage {
5262	/// A universally unique identifier.
5263	pub fn chat_message_id(&self) -> std::option::Option<&str> {
5264		self.chat_message_id.as_deref()
5265	}
5266	/// A universally unique identifier.
5267	pub fn thread_id(&self) -> std::option::Option<&str> {
5268		self.thread_id.as_deref()
5269	}
5270	/// RFC3339 timestamp.
5271	pub fn send_ts(&self) -> std::option::Option<&aws_smithy_types::DateTime> {
5272		self.send_ts.as_ref()
5273	}
5274	/// Represents types of chat message bodies.
5275	pub fn body(&self) -> std::option::Option<&crate::model::ChatMessageBody> {
5276		self.body.as_ref()
5277	}
5278}
5279impl std::fmt::Debug for ChatMessage {
5280	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
5281		let mut formatter = f.debug_struct("ChatMessage");
5282		formatter.field("chat_message_id", &self.chat_message_id);
5283		formatter.field("thread_id", &self.thread_id);
5284		formatter.field("send_ts", &self.send_ts);
5285		formatter.field("body", &self.body);
5286		formatter.finish()
5287	}
5288}
5289/// See [`ChatMessage`](crate::model::ChatMessage)
5290pub mod chat_message {
5291	/// A builder for [`ChatMessage`](crate::model::ChatMessage)
5292	#[non_exhaustive]
5293	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
5294	pub struct Builder {
5295		pub(crate) chat_message_id: std::option::Option<std::string::String>,
5296		pub(crate) thread_id: std::option::Option<std::string::String>,
5297		pub(crate) send_ts: std::option::Option<aws_smithy_types::DateTime>,
5298		pub(crate) body: std::option::Option<crate::model::ChatMessageBody>,
5299	}
5300	impl Builder {
5301		/// A universally unique identifier.
5302		pub fn chat_message_id(mut self, input: impl Into<std::string::String>) -> Self {
5303			self.chat_message_id = Some(input.into());
5304			self
5305		}
5306		/// A universally unique identifier.
5307		pub fn set_chat_message_id(
5308			mut self,
5309			input: std::option::Option<std::string::String>,
5310		) -> Self {
5311			self.chat_message_id = input;
5312			self
5313		}
5314		/// A universally unique identifier.
5315		pub fn thread_id(mut self, input: impl Into<std::string::String>) -> Self {
5316			self.thread_id = Some(input.into());
5317			self
5318		}
5319		/// A universally unique identifier.
5320		pub fn set_thread_id(mut self, input: std::option::Option<std::string::String>) -> Self {
5321			self.thread_id = input;
5322			self
5323		}
5324		/// RFC3339 timestamp.
5325		pub fn send_ts(mut self, input: aws_smithy_types::DateTime) -> Self {
5326			self.send_ts = Some(input);
5327			self
5328		}
5329		/// RFC3339 timestamp.
5330		pub fn set_send_ts(
5331			mut self,
5332			input: std::option::Option<aws_smithy_types::DateTime>,
5333		) -> Self {
5334			self.send_ts = input;
5335			self
5336		}
5337		/// Represents types of chat message bodies.
5338		pub fn body(mut self, input: crate::model::ChatMessageBody) -> Self {
5339			self.body = Some(input);
5340			self
5341		}
5342		/// Represents types of chat message bodies.
5343		pub fn set_body(
5344			mut self,
5345			input: std::option::Option<crate::model::ChatMessageBody>,
5346		) -> Self {
5347			self.body = input;
5348			self
5349		}
5350		/// Consumes the builder and constructs a [`ChatMessage`](crate::model::ChatMessage)
5351		pub fn build(self) -> crate::model::ChatMessage {
5352			crate::model::ChatMessage {
5353				chat_message_id: self.chat_message_id,
5354				thread_id: self.thread_id,
5355				send_ts: self.send_ts,
5356				body: self.body,
5357			}
5358		}
5359	}
5360}
5361impl ChatMessage {
5362	/// Creates a new builder-style object to manufacture [`ChatMessage`](crate::model::ChatMessage)
5363	pub fn builder() -> crate::model::chat_message::Builder {
5364		crate::model::chat_message::Builder::default()
5365	}
5366}
5367
5368/// Represents types of chat message bodies.
5369#[non_exhaustive]
5370#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
5371pub enum ChatMessageBody {
5372	/// `rivet.chat#ChatMessageBody` variant for indicating a new chat was created.
5373	ChatCreate(crate::model::ChatMessageBodyChatCreate),
5374	/// `rivet.chat#ChatMessageBody` variant for indicating an identity joined the group.
5375	GroupJoin(crate::model::ChatMessageBodyGroupJoin),
5376	/// `rivet.chat#ChatMessageBody` variant for indicating an identity left the group.
5377	GroupLeave(crate::model::ChatMessageBodyGroupLeave),
5378	/// `rivet.chat#ChatMessageBody` variant for indicating an identity followed the identity.
5379	IdentityFollow(crate::model::ChatMessageBodyIdentityFollow),
5380	/// `rivet.chat#ChatMessageBody` variant for indicating a change in the party's current activity.
5381	PartyActivityChange(crate::model::ChatMessageBodyPartyActivityChange),
5382	/// `rivet.chat#ChatMessageBody` variant holding an a party invitation.
5383	PartyInvite(crate::model::ChatMessageBodyPartyInvite),
5384	/// `rivet.chat#ChatMessageBody` variant for indicating an identity joined the party.
5385	PartyJoin(crate::model::ChatMessageBodyPartyJoin),
5386	/// `rivet.chat#ChatMessageBody` variant for indicating an identity requesting to join your party.
5387	PartyJoinRequest(crate::model::ChatMessageBodyPartyJoinRequest),
5388	/// `rivet.chat#ChatMessageBody` variant for indicating an identity left the party.
5389	PartyLeave(crate::model::ChatMessageBodyPartyLeave),
5390	/// `rivet.chat#ChatMessageBody` variant for text messages. Sent by other identities using the chat interface.
5391	Text(crate::model::ChatMessageBodyText),
5392	/// The `Unknown` variant represents cases where new union variant was received. Consider upgrading the SDK to the latest available version.
5393	/// An unknown enum variant
5394	///
5395	/// _Note: If you encounter this error, consider upgrading your SDK to the latest version._
5396	/// The `Unknown` variant represents cases where the server sent a value that wasn't recognized
5397	/// by the client. This can happen when the server adds new functionality, but the client has not been updated.
5398	/// To investigate this, consider turning on debug logging to print the raw HTTP response.
5399	#[non_exhaustive]
5400	Unknown,
5401}
5402impl ChatMessageBody {
5403	/// Tries to convert the enum instance into [`ChatCreate`](crate::model::ChatMessageBody::ChatCreate), extracting the inner [`ChatMessageBodyChatCreate`](crate::model::ChatMessageBodyChatCreate).
5404	/// Returns `Err(&Self)` if it can't be converted.
5405	pub fn as_chat_create(
5406		&self,
5407	) -> std::result::Result<&crate::model::ChatMessageBodyChatCreate, &Self> {
5408		if let ChatMessageBody::ChatCreate(val) = &self {
5409			Ok(val)
5410		} else {
5411			Err(self)
5412		}
5413	}
5414	/// Returns true if this is a [`ChatCreate`](crate::model::ChatMessageBody::ChatCreate).
5415	pub fn is_chat_create(&self) -> bool {
5416		self.as_chat_create().is_ok()
5417	}
5418	/// Tries to convert the enum instance into [`GroupJoin`](crate::model::ChatMessageBody::GroupJoin), extracting the inner [`ChatMessageBodyGroupJoin`](crate::model::ChatMessageBodyGroupJoin).
5419	/// Returns `Err(&Self)` if it can't be converted.
5420	pub fn as_group_join(
5421		&self,
5422	) -> std::result::Result<&crate::model::ChatMessageBodyGroupJoin, &Self> {
5423		if let ChatMessageBody::GroupJoin(val) = &self {
5424			Ok(val)
5425		} else {
5426			Err(self)
5427		}
5428	}
5429	/// Returns true if this is a [`GroupJoin`](crate::model::ChatMessageBody::GroupJoin).
5430	pub fn is_group_join(&self) -> bool {
5431		self.as_group_join().is_ok()
5432	}
5433	/// Tries to convert the enum instance into [`GroupLeave`](crate::model::ChatMessageBody::GroupLeave), extracting the inner [`ChatMessageBodyGroupLeave`](crate::model::ChatMessageBodyGroupLeave).
5434	/// Returns `Err(&Self)` if it can't be converted.
5435	pub fn as_group_leave(
5436		&self,
5437	) -> std::result::Result<&crate::model::ChatMessageBodyGroupLeave, &Self> {
5438		if let ChatMessageBody::GroupLeave(val) = &self {
5439			Ok(val)
5440		} else {
5441			Err(self)
5442		}
5443	}
5444	/// Returns true if this is a [`GroupLeave`](crate::model::ChatMessageBody::GroupLeave).
5445	pub fn is_group_leave(&self) -> bool {
5446		self.as_group_leave().is_ok()
5447	}
5448	/// Tries to convert the enum instance into [`IdentityFollow`](crate::model::ChatMessageBody::IdentityFollow), extracting the inner [`ChatMessageBodyIdentityFollow`](crate::model::ChatMessageBodyIdentityFollow).
5449	/// Returns `Err(&Self)` if it can't be converted.
5450	pub fn as_identity_follow(
5451		&self,
5452	) -> std::result::Result<&crate::model::ChatMessageBodyIdentityFollow, &Self> {
5453		if let ChatMessageBody::IdentityFollow(val) = &self {
5454			Ok(val)
5455		} else {
5456			Err(self)
5457		}
5458	}
5459	/// Returns true if this is a [`IdentityFollow`](crate::model::ChatMessageBody::IdentityFollow).
5460	pub fn is_identity_follow(&self) -> bool {
5461		self.as_identity_follow().is_ok()
5462	}
5463	/// Tries to convert the enum instance into [`PartyActivityChange`](crate::model::ChatMessageBody::PartyActivityChange), extracting the inner [`ChatMessageBodyPartyActivityChange`](crate::model::ChatMessageBodyPartyActivityChange).
5464	/// Returns `Err(&Self)` if it can't be converted.
5465	pub fn as_party_activity_change(
5466		&self,
5467	) -> std::result::Result<&crate::model::ChatMessageBodyPartyActivityChange, &Self> {
5468		if let ChatMessageBody::PartyActivityChange(val) = &self {
5469			Ok(val)
5470		} else {
5471			Err(self)
5472		}
5473	}
5474	/// Returns true if this is a [`PartyActivityChange`](crate::model::ChatMessageBody::PartyActivityChange).
5475	pub fn is_party_activity_change(&self) -> bool {
5476		self.as_party_activity_change().is_ok()
5477	}
5478	/// Tries to convert the enum instance into [`PartyInvite`](crate::model::ChatMessageBody::PartyInvite), extracting the inner [`ChatMessageBodyPartyInvite`](crate::model::ChatMessageBodyPartyInvite).
5479	/// Returns `Err(&Self)` if it can't be converted.
5480	pub fn as_party_invite(
5481		&self,
5482	) -> std::result::Result<&crate::model::ChatMessageBodyPartyInvite, &Self> {
5483		if let ChatMessageBody::PartyInvite(val) = &self {
5484			Ok(val)
5485		} else {
5486			Err(self)
5487		}
5488	}
5489	/// Returns true if this is a [`PartyInvite`](crate::model::ChatMessageBody::PartyInvite).
5490	pub fn is_party_invite(&self) -> bool {
5491		self.as_party_invite().is_ok()
5492	}
5493	/// Tries to convert the enum instance into [`PartyJoin`](crate::model::ChatMessageBody::PartyJoin), extracting the inner [`ChatMessageBodyPartyJoin`](crate::model::ChatMessageBodyPartyJoin).
5494	/// Returns `Err(&Self)` if it can't be converted.
5495	pub fn as_party_join(
5496		&self,
5497	) -> std::result::Result<&crate::model::ChatMessageBodyPartyJoin, &Self> {
5498		if let ChatMessageBody::PartyJoin(val) = &self {
5499			Ok(val)
5500		} else {
5501			Err(self)
5502		}
5503	}
5504	/// Returns true if this is a [`PartyJoin`](crate::model::ChatMessageBody::PartyJoin).
5505	pub fn is_party_join(&self) -> bool {
5506		self.as_party_join().is_ok()
5507	}
5508	/// Tries to convert the enum instance into [`PartyJoinRequest`](crate::model::ChatMessageBody::PartyJoinRequest), extracting the inner [`ChatMessageBodyPartyJoinRequest`](crate::model::ChatMessageBodyPartyJoinRequest).
5509	/// Returns `Err(&Self)` if it can't be converted.
5510	pub fn as_party_join_request(
5511		&self,
5512	) -> std::result::Result<&crate::model::ChatMessageBodyPartyJoinRequest, &Self> {
5513		if let ChatMessageBody::PartyJoinRequest(val) = &self {
5514			Ok(val)
5515		} else {
5516			Err(self)
5517		}
5518	}
5519	/// Returns true if this is a [`PartyJoinRequest`](crate::model::ChatMessageBody::PartyJoinRequest).
5520	pub fn is_party_join_request(&self) -> bool {
5521		self.as_party_join_request().is_ok()
5522	}
5523	/// Tries to convert the enum instance into [`PartyLeave`](crate::model::ChatMessageBody::PartyLeave), extracting the inner [`ChatMessageBodyPartyLeave`](crate::model::ChatMessageBodyPartyLeave).
5524	/// Returns `Err(&Self)` if it can't be converted.
5525	pub fn as_party_leave(
5526		&self,
5527	) -> std::result::Result<&crate::model::ChatMessageBodyPartyLeave, &Self> {
5528		if let ChatMessageBody::PartyLeave(val) = &self {
5529			Ok(val)
5530		} else {
5531			Err(self)
5532		}
5533	}
5534	/// Returns true if this is a [`PartyLeave`](crate::model::ChatMessageBody::PartyLeave).
5535	pub fn is_party_leave(&self) -> bool {
5536		self.as_party_leave().is_ok()
5537	}
5538	/// Tries to convert the enum instance into [`Text`](crate::model::ChatMessageBody::Text), extracting the inner [`ChatMessageBodyText`](crate::model::ChatMessageBodyText).
5539	/// Returns `Err(&Self)` if it can't be converted.
5540	pub fn as_text(&self) -> std::result::Result<&crate::model::ChatMessageBodyText, &Self> {
5541		if let ChatMessageBody::Text(val) = &self {
5542			Ok(val)
5543		} else {
5544			Err(self)
5545		}
5546	}
5547	/// Returns true if this is a [`Text`](crate::model::ChatMessageBody::Text).
5548	pub fn is_text(&self) -> bool {
5549		self.as_text().is_ok()
5550	}
5551	/// Returns true if the enum instance is the `Unknown` variant.
5552	pub fn is_unknown(&self) -> bool {
5553		matches!(self, Self::Unknown)
5554	}
5555}
5556
5557/// `rivet.chat#ChatMessageBody` variant for indicating a change in the party's current activity.
5558#[non_exhaustive]
5559#[derive(std::clone::Clone, std::cmp::PartialEq)]
5560pub struct ChatMessageBodyPartyActivityChange {}
5561impl std::fmt::Debug for ChatMessageBodyPartyActivityChange {
5562	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
5563		let mut formatter = f.debug_struct("ChatMessageBodyPartyActivityChange");
5564		formatter.finish()
5565	}
5566}
5567/// See [`ChatMessageBodyPartyActivityChange`](crate::model::ChatMessageBodyPartyActivityChange)
5568pub mod chat_message_body_party_activity_change {
5569	/// A builder for [`ChatMessageBodyPartyActivityChange`](crate::model::ChatMessageBodyPartyActivityChange)
5570	#[non_exhaustive]
5571	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
5572	pub struct Builder {}
5573	impl Builder {
5574		/// Consumes the builder and constructs a [`ChatMessageBodyPartyActivityChange`](crate::model::ChatMessageBodyPartyActivityChange)
5575		pub fn build(self) -> crate::model::ChatMessageBodyPartyActivityChange {
5576			crate::model::ChatMessageBodyPartyActivityChange {}
5577		}
5578	}
5579}
5580impl ChatMessageBodyPartyActivityChange {
5581	/// Creates a new builder-style object to manufacture [`ChatMessageBodyPartyActivityChange`](crate::model::ChatMessageBodyPartyActivityChange)
5582	pub fn builder() -> crate::model::chat_message_body_party_activity_change::Builder {
5583		crate::model::chat_message_body_party_activity_change::Builder::default()
5584	}
5585}
5586
5587/// `rivet.chat#ChatMessageBody` variant for indicating an identity left the party.
5588#[non_exhaustive]
5589#[derive(std::clone::Clone, std::cmp::PartialEq)]
5590pub struct ChatMessageBodyPartyLeave {
5591	/// An identity handle.
5592	pub identity: std::option::Option<crate::model::IdentityHandle>,
5593}
5594impl ChatMessageBodyPartyLeave {
5595	/// An identity handle.
5596	pub fn identity(&self) -> std::option::Option<&crate::model::IdentityHandle> {
5597		self.identity.as_ref()
5598	}
5599}
5600impl std::fmt::Debug for ChatMessageBodyPartyLeave {
5601	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
5602		let mut formatter = f.debug_struct("ChatMessageBodyPartyLeave");
5603		formatter.field("identity", &self.identity);
5604		formatter.finish()
5605	}
5606}
5607/// See [`ChatMessageBodyPartyLeave`](crate::model::ChatMessageBodyPartyLeave)
5608pub mod chat_message_body_party_leave {
5609	/// A builder for [`ChatMessageBodyPartyLeave`](crate::model::ChatMessageBodyPartyLeave)
5610	#[non_exhaustive]
5611	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
5612	pub struct Builder {
5613		pub(crate) identity: std::option::Option<crate::model::IdentityHandle>,
5614	}
5615	impl Builder {
5616		/// An identity handle.
5617		pub fn identity(mut self, input: crate::model::IdentityHandle) -> Self {
5618			self.identity = Some(input);
5619			self
5620		}
5621		/// An identity handle.
5622		pub fn set_identity(
5623			mut self,
5624			input: std::option::Option<crate::model::IdentityHandle>,
5625		) -> Self {
5626			self.identity = input;
5627			self
5628		}
5629		/// Consumes the builder and constructs a [`ChatMessageBodyPartyLeave`](crate::model::ChatMessageBodyPartyLeave)
5630		pub fn build(self) -> crate::model::ChatMessageBodyPartyLeave {
5631			crate::model::ChatMessageBodyPartyLeave {
5632				identity: self.identity,
5633			}
5634		}
5635	}
5636}
5637impl ChatMessageBodyPartyLeave {
5638	/// Creates a new builder-style object to manufacture [`ChatMessageBodyPartyLeave`](crate::model::ChatMessageBodyPartyLeave)
5639	pub fn builder() -> crate::model::chat_message_body_party_leave::Builder {
5640		crate::model::chat_message_body_party_leave::Builder::default()
5641	}
5642}
5643
5644/// `rivet.chat#ChatMessageBody` variant for indicating an identity joined the party.
5645#[non_exhaustive]
5646#[derive(std::clone::Clone, std::cmp::PartialEq)]
5647pub struct ChatMessageBodyPartyJoin {
5648	/// An identity handle.
5649	pub identity: std::option::Option<crate::model::IdentityHandle>,
5650}
5651impl ChatMessageBodyPartyJoin {
5652	/// An identity handle.
5653	pub fn identity(&self) -> std::option::Option<&crate::model::IdentityHandle> {
5654		self.identity.as_ref()
5655	}
5656}
5657impl std::fmt::Debug for ChatMessageBodyPartyJoin {
5658	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
5659		let mut formatter = f.debug_struct("ChatMessageBodyPartyJoin");
5660		formatter.field("identity", &self.identity);
5661		formatter.finish()
5662	}
5663}
5664/// See [`ChatMessageBodyPartyJoin`](crate::model::ChatMessageBodyPartyJoin)
5665pub mod chat_message_body_party_join {
5666	/// A builder for [`ChatMessageBodyPartyJoin`](crate::model::ChatMessageBodyPartyJoin)
5667	#[non_exhaustive]
5668	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
5669	pub struct Builder {
5670		pub(crate) identity: std::option::Option<crate::model::IdentityHandle>,
5671	}
5672	impl Builder {
5673		/// An identity handle.
5674		pub fn identity(mut self, input: crate::model::IdentityHandle) -> Self {
5675			self.identity = Some(input);
5676			self
5677		}
5678		/// An identity handle.
5679		pub fn set_identity(
5680			mut self,
5681			input: std::option::Option<crate::model::IdentityHandle>,
5682		) -> Self {
5683			self.identity = input;
5684			self
5685		}
5686		/// Consumes the builder and constructs a [`ChatMessageBodyPartyJoin`](crate::model::ChatMessageBodyPartyJoin)
5687		pub fn build(self) -> crate::model::ChatMessageBodyPartyJoin {
5688			crate::model::ChatMessageBodyPartyJoin {
5689				identity: self.identity,
5690			}
5691		}
5692	}
5693}
5694impl ChatMessageBodyPartyJoin {
5695	/// Creates a new builder-style object to manufacture [`ChatMessageBodyPartyJoin`](crate::model::ChatMessageBodyPartyJoin)
5696	pub fn builder() -> crate::model::chat_message_body_party_join::Builder {
5697		crate::model::chat_message_body_party_join::Builder::default()
5698	}
5699}
5700
5701/// `rivet.chat#ChatMessageBody` variant for indicating an identity requesting to join your party.
5702#[non_exhaustive]
5703#[derive(std::clone::Clone, std::cmp::PartialEq)]
5704pub struct ChatMessageBodyPartyJoinRequest {
5705	/// An identity handle.
5706	pub sender: std::option::Option<crate::model::IdentityHandle>,
5707}
5708impl ChatMessageBodyPartyJoinRequest {
5709	/// An identity handle.
5710	pub fn sender(&self) -> std::option::Option<&crate::model::IdentityHandle> {
5711		self.sender.as_ref()
5712	}
5713}
5714impl std::fmt::Debug for ChatMessageBodyPartyJoinRequest {
5715	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
5716		let mut formatter = f.debug_struct("ChatMessageBodyPartyJoinRequest");
5717		formatter.field("sender", &self.sender);
5718		formatter.finish()
5719	}
5720}
5721/// See [`ChatMessageBodyPartyJoinRequest`](crate::model::ChatMessageBodyPartyJoinRequest)
5722pub mod chat_message_body_party_join_request {
5723	/// A builder for [`ChatMessageBodyPartyJoinRequest`](crate::model::ChatMessageBodyPartyJoinRequest)
5724	#[non_exhaustive]
5725	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
5726	pub struct Builder {
5727		pub(crate) sender: std::option::Option<crate::model::IdentityHandle>,
5728	}
5729	impl Builder {
5730		/// An identity handle.
5731		pub fn sender(mut self, input: crate::model::IdentityHandle) -> Self {
5732			self.sender = Some(input);
5733			self
5734		}
5735		/// An identity handle.
5736		pub fn set_sender(
5737			mut self,
5738			input: std::option::Option<crate::model::IdentityHandle>,
5739		) -> Self {
5740			self.sender = input;
5741			self
5742		}
5743		/// Consumes the builder and constructs a [`ChatMessageBodyPartyJoinRequest`](crate::model::ChatMessageBodyPartyJoinRequest)
5744		pub fn build(self) -> crate::model::ChatMessageBodyPartyJoinRequest {
5745			crate::model::ChatMessageBodyPartyJoinRequest {
5746				sender: self.sender,
5747			}
5748		}
5749	}
5750}
5751impl ChatMessageBodyPartyJoinRequest {
5752	/// Creates a new builder-style object to manufacture [`ChatMessageBodyPartyJoinRequest`](crate::model::ChatMessageBodyPartyJoinRequest)
5753	pub fn builder() -> crate::model::chat_message_body_party_join_request::Builder {
5754		crate::model::chat_message_body_party_join_request::Builder::default()
5755	}
5756}
5757
5758/// `rivet.chat#ChatMessageBody` variant holding an a party invitation.
5759#[non_exhaustive]
5760#[derive(std::clone::Clone, std::cmp::PartialEq)]
5761pub struct ChatMessageBodyPartyInvite {
5762	/// An identity handle.
5763	pub sender: std::option::Option<crate::model::IdentityHandle>,
5764	/// A party handle.
5765	pub party: std::option::Option<crate::model::PartyHandle>,
5766	/// 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.
5767	pub invite_token: std::option::Option<std::string::String>,
5768}
5769impl ChatMessageBodyPartyInvite {
5770	/// An identity handle.
5771	pub fn sender(&self) -> std::option::Option<&crate::model::IdentityHandle> {
5772		self.sender.as_ref()
5773	}
5774	/// A party handle.
5775	pub fn party(&self) -> std::option::Option<&crate::model::PartyHandle> {
5776		self.party.as_ref()
5777	}
5778	/// 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.
5779	pub fn invite_token(&self) -> std::option::Option<&str> {
5780		self.invite_token.as_deref()
5781	}
5782}
5783impl std::fmt::Debug for ChatMessageBodyPartyInvite {
5784	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
5785		let mut formatter = f.debug_struct("ChatMessageBodyPartyInvite");
5786		formatter.field("sender", &self.sender);
5787		formatter.field("party", &self.party);
5788		formatter.field("invite_token", &"*** Sensitive Data Redacted ***");
5789		formatter.finish()
5790	}
5791}
5792/// See [`ChatMessageBodyPartyInvite`](crate::model::ChatMessageBodyPartyInvite)
5793pub mod chat_message_body_party_invite {
5794	/// A builder for [`ChatMessageBodyPartyInvite`](crate::model::ChatMessageBodyPartyInvite)
5795	#[non_exhaustive]
5796	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
5797	pub struct Builder {
5798		pub(crate) sender: std::option::Option<crate::model::IdentityHandle>,
5799		pub(crate) party: std::option::Option<crate::model::PartyHandle>,
5800		pub(crate) invite_token: std::option::Option<std::string::String>,
5801	}
5802	impl Builder {
5803		/// An identity handle.
5804		pub fn sender(mut self, input: crate::model::IdentityHandle) -> Self {
5805			self.sender = Some(input);
5806			self
5807		}
5808		/// An identity handle.
5809		pub fn set_sender(
5810			mut self,
5811			input: std::option::Option<crate::model::IdentityHandle>,
5812		) -> Self {
5813			self.sender = input;
5814			self
5815		}
5816		/// A party handle.
5817		pub fn party(mut self, input: crate::model::PartyHandle) -> Self {
5818			self.party = Some(input);
5819			self
5820		}
5821		/// A party handle.
5822		pub fn set_party(mut self, input: std::option::Option<crate::model::PartyHandle>) -> Self {
5823			self.party = input;
5824			self
5825		}
5826		/// 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.
5827		pub fn invite_token(mut self, input: impl Into<std::string::String>) -> Self {
5828			self.invite_token = Some(input.into());
5829			self
5830		}
5831		/// 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.
5832		pub fn set_invite_token(mut self, input: std::option::Option<std::string::String>) -> Self {
5833			self.invite_token = input;
5834			self
5835		}
5836		/// Consumes the builder and constructs a [`ChatMessageBodyPartyInvite`](crate::model::ChatMessageBodyPartyInvite)
5837		pub fn build(self) -> crate::model::ChatMessageBodyPartyInvite {
5838			crate::model::ChatMessageBodyPartyInvite {
5839				sender: self.sender,
5840				party: self.party,
5841				invite_token: self.invite_token,
5842			}
5843		}
5844	}
5845}
5846impl ChatMessageBodyPartyInvite {
5847	/// Creates a new builder-style object to manufacture [`ChatMessageBodyPartyInvite`](crate::model::ChatMessageBodyPartyInvite)
5848	pub fn builder() -> crate::model::chat_message_body_party_invite::Builder {
5849		crate::model::chat_message_body_party_invite::Builder::default()
5850	}
5851}
5852
5853/// `rivet.chat#ChatMessageBody` variant for indicating an identity left the group.
5854#[non_exhaustive]
5855#[derive(std::clone::Clone, std::cmp::PartialEq)]
5856pub struct ChatMessageBodyGroupLeave {
5857	/// An identity handle.
5858	pub identity: std::option::Option<crate::model::IdentityHandle>,
5859}
5860impl ChatMessageBodyGroupLeave {
5861	/// An identity handle.
5862	pub fn identity(&self) -> std::option::Option<&crate::model::IdentityHandle> {
5863		self.identity.as_ref()
5864	}
5865}
5866impl std::fmt::Debug for ChatMessageBodyGroupLeave {
5867	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
5868		let mut formatter = f.debug_struct("ChatMessageBodyGroupLeave");
5869		formatter.field("identity", &self.identity);
5870		formatter.finish()
5871	}
5872}
5873/// See [`ChatMessageBodyGroupLeave`](crate::model::ChatMessageBodyGroupLeave)
5874pub mod chat_message_body_group_leave {
5875	/// A builder for [`ChatMessageBodyGroupLeave`](crate::model::ChatMessageBodyGroupLeave)
5876	#[non_exhaustive]
5877	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
5878	pub struct Builder {
5879		pub(crate) identity: std::option::Option<crate::model::IdentityHandle>,
5880	}
5881	impl Builder {
5882		/// An identity handle.
5883		pub fn identity(mut self, input: crate::model::IdentityHandle) -> Self {
5884			self.identity = Some(input);
5885			self
5886		}
5887		/// An identity handle.
5888		pub fn set_identity(
5889			mut self,
5890			input: std::option::Option<crate::model::IdentityHandle>,
5891		) -> Self {
5892			self.identity = input;
5893			self
5894		}
5895		/// Consumes the builder and constructs a [`ChatMessageBodyGroupLeave`](crate::model::ChatMessageBodyGroupLeave)
5896		pub fn build(self) -> crate::model::ChatMessageBodyGroupLeave {
5897			crate::model::ChatMessageBodyGroupLeave {
5898				identity: self.identity,
5899			}
5900		}
5901	}
5902}
5903impl ChatMessageBodyGroupLeave {
5904	/// Creates a new builder-style object to manufacture [`ChatMessageBodyGroupLeave`](crate::model::ChatMessageBodyGroupLeave)
5905	pub fn builder() -> crate::model::chat_message_body_group_leave::Builder {
5906		crate::model::chat_message_body_group_leave::Builder::default()
5907	}
5908}
5909
5910/// `rivet.chat#ChatMessageBody` variant for indicating an identity joined the group.
5911#[non_exhaustive]
5912#[derive(std::clone::Clone, std::cmp::PartialEq)]
5913pub struct ChatMessageBodyGroupJoin {
5914	/// An identity handle.
5915	pub identity: std::option::Option<crate::model::IdentityHandle>,
5916}
5917impl ChatMessageBodyGroupJoin {
5918	/// An identity handle.
5919	pub fn identity(&self) -> std::option::Option<&crate::model::IdentityHandle> {
5920		self.identity.as_ref()
5921	}
5922}
5923impl std::fmt::Debug for ChatMessageBodyGroupJoin {
5924	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
5925		let mut formatter = f.debug_struct("ChatMessageBodyGroupJoin");
5926		formatter.field("identity", &self.identity);
5927		formatter.finish()
5928	}
5929}
5930/// See [`ChatMessageBodyGroupJoin`](crate::model::ChatMessageBodyGroupJoin)
5931pub mod chat_message_body_group_join {
5932	/// A builder for [`ChatMessageBodyGroupJoin`](crate::model::ChatMessageBodyGroupJoin)
5933	#[non_exhaustive]
5934	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
5935	pub struct Builder {
5936		pub(crate) identity: std::option::Option<crate::model::IdentityHandle>,
5937	}
5938	impl Builder {
5939		/// An identity handle.
5940		pub fn identity(mut self, input: crate::model::IdentityHandle) -> Self {
5941			self.identity = Some(input);
5942			self
5943		}
5944		/// An identity handle.
5945		pub fn set_identity(
5946			mut self,
5947			input: std::option::Option<crate::model::IdentityHandle>,
5948		) -> Self {
5949			self.identity = input;
5950			self
5951		}
5952		/// Consumes the builder and constructs a [`ChatMessageBodyGroupJoin`](crate::model::ChatMessageBodyGroupJoin)
5953		pub fn build(self) -> crate::model::ChatMessageBodyGroupJoin {
5954			crate::model::ChatMessageBodyGroupJoin {
5955				identity: self.identity,
5956			}
5957		}
5958	}
5959}
5960impl ChatMessageBodyGroupJoin {
5961	/// Creates a new builder-style object to manufacture [`ChatMessageBodyGroupJoin`](crate::model::ChatMessageBodyGroupJoin)
5962	pub fn builder() -> crate::model::chat_message_body_group_join::Builder {
5963		crate::model::chat_message_body_group_join::Builder::default()
5964	}
5965}
5966
5967/// `rivet.chat#ChatMessageBody` variant for indicating an identity followed the identity.
5968#[non_exhaustive]
5969#[derive(std::clone::Clone, std::cmp::PartialEq)]
5970pub struct ChatMessageBodyIdentityFollow {}
5971impl std::fmt::Debug for ChatMessageBodyIdentityFollow {
5972	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
5973		let mut formatter = f.debug_struct("ChatMessageBodyIdentityFollow");
5974		formatter.finish()
5975	}
5976}
5977/// See [`ChatMessageBodyIdentityFollow`](crate::model::ChatMessageBodyIdentityFollow)
5978pub mod chat_message_body_identity_follow {
5979	/// A builder for [`ChatMessageBodyIdentityFollow`](crate::model::ChatMessageBodyIdentityFollow)
5980	#[non_exhaustive]
5981	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
5982	pub struct Builder {}
5983	impl Builder {
5984		/// Consumes the builder and constructs a [`ChatMessageBodyIdentityFollow`](crate::model::ChatMessageBodyIdentityFollow)
5985		pub fn build(self) -> crate::model::ChatMessageBodyIdentityFollow {
5986			crate::model::ChatMessageBodyIdentityFollow {}
5987		}
5988	}
5989}
5990impl ChatMessageBodyIdentityFollow {
5991	/// Creates a new builder-style object to manufacture [`ChatMessageBodyIdentityFollow`](crate::model::ChatMessageBodyIdentityFollow)
5992	pub fn builder() -> crate::model::chat_message_body_identity_follow::Builder {
5993		crate::model::chat_message_body_identity_follow::Builder::default()
5994	}
5995}
5996
5997/// `rivet.chat#ChatMessageBody` variant for indicating a new chat was created.
5998#[non_exhaustive]
5999#[derive(std::clone::Clone, std::cmp::PartialEq)]
6000pub struct ChatMessageBodyChatCreate {}
6001impl std::fmt::Debug for ChatMessageBodyChatCreate {
6002	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
6003		let mut formatter = f.debug_struct("ChatMessageBodyChatCreate");
6004		formatter.finish()
6005	}
6006}
6007/// See [`ChatMessageBodyChatCreate`](crate::model::ChatMessageBodyChatCreate)
6008pub mod chat_message_body_chat_create {
6009	/// A builder for [`ChatMessageBodyChatCreate`](crate::model::ChatMessageBodyChatCreate)
6010	#[non_exhaustive]
6011	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
6012	pub struct Builder {}
6013	impl Builder {
6014		/// Consumes the builder and constructs a [`ChatMessageBodyChatCreate`](crate::model::ChatMessageBodyChatCreate)
6015		pub fn build(self) -> crate::model::ChatMessageBodyChatCreate {
6016			crate::model::ChatMessageBodyChatCreate {}
6017		}
6018	}
6019}
6020impl ChatMessageBodyChatCreate {
6021	/// Creates a new builder-style object to manufacture [`ChatMessageBodyChatCreate`](crate::model::ChatMessageBodyChatCreate)
6022	pub fn builder() -> crate::model::chat_message_body_chat_create::Builder {
6023		crate::model::chat_message_body_chat_create::Builder::default()
6024	}
6025}
6026
6027/// `rivet.chat#ChatMessageBody` variant for text messages. Sent by other identities using the chat interface.
6028#[non_exhaustive]
6029#[derive(std::clone::Clone, std::cmp::PartialEq)]
6030pub struct ChatMessageBodyText {
6031	/// An identity handle.
6032	pub sender: std::option::Option<crate::model::IdentityHandle>,
6033	/// The text in the message.
6034	pub body: std::option::Option<std::string::String>,
6035}
6036impl ChatMessageBodyText {
6037	/// An identity handle.
6038	pub fn sender(&self) -> std::option::Option<&crate::model::IdentityHandle> {
6039		self.sender.as_ref()
6040	}
6041	/// The text in the message.
6042	pub fn body(&self) -> std::option::Option<&str> {
6043		self.body.as_deref()
6044	}
6045}
6046impl std::fmt::Debug for ChatMessageBodyText {
6047	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
6048		let mut formatter = f.debug_struct("ChatMessageBodyText");
6049		formatter.field("sender", &self.sender);
6050		formatter.field("body", &self.body);
6051		formatter.finish()
6052	}
6053}
6054/// See [`ChatMessageBodyText`](crate::model::ChatMessageBodyText)
6055pub mod chat_message_body_text {
6056	/// A builder for [`ChatMessageBodyText`](crate::model::ChatMessageBodyText)
6057	#[non_exhaustive]
6058	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
6059	pub struct Builder {
6060		pub(crate) sender: std::option::Option<crate::model::IdentityHandle>,
6061		pub(crate) body: std::option::Option<std::string::String>,
6062	}
6063	impl Builder {
6064		/// An identity handle.
6065		pub fn sender(mut self, input: crate::model::IdentityHandle) -> Self {
6066			self.sender = Some(input);
6067			self
6068		}
6069		/// An identity handle.
6070		pub fn set_sender(
6071			mut self,
6072			input: std::option::Option<crate::model::IdentityHandle>,
6073		) -> Self {
6074			self.sender = input;
6075			self
6076		}
6077		/// The text in the message.
6078		pub fn body(mut self, input: impl Into<std::string::String>) -> Self {
6079			self.body = Some(input.into());
6080			self
6081		}
6082		/// The text in the message.
6083		pub fn set_body(mut self, input: std::option::Option<std::string::String>) -> Self {
6084			self.body = input;
6085			self
6086		}
6087		/// Consumes the builder and constructs a [`ChatMessageBodyText`](crate::model::ChatMessageBodyText)
6088		pub fn build(self) -> crate::model::ChatMessageBodyText {
6089			crate::model::ChatMessageBodyText {
6090				sender: self.sender,
6091				body: self.body,
6092			}
6093		}
6094	}
6095}
6096impl ChatMessageBodyText {
6097	/// Creates a new builder-style object to manufacture [`ChatMessageBodyText`](crate::model::ChatMessageBodyText)
6098	pub fn builder() -> crate::model::chat_message_body_text::Builder {
6099		crate::model::chat_message_body_text::Builder::default()
6100	}
6101}
6102
6103/// Represents the topic of the given chat thread.
6104#[non_exhaustive]
6105#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
6106pub enum ChatTopic {
6107	/// `rivet.chat#ChatTopic` variant for direct (identity to identity) chats.
6108	Direct(crate::model::ChatTopicDirect),
6109	/// `rivet.chat#ChatTopic` variant for groups.
6110	Group(crate::model::ChatTopicGroup),
6111	/// `rivet.chat#ChatTopic` variant for parties.
6112	Party(crate::model::ChatTopicParty),
6113	/// The `Unknown` variant represents cases where new union variant was received. Consider upgrading the SDK to the latest available version.
6114	/// An unknown enum variant
6115	///
6116	/// _Note: If you encounter this error, consider upgrading your SDK to the latest version._
6117	/// The `Unknown` variant represents cases where the server sent a value that wasn't recognized
6118	/// by the client. This can happen when the server adds new functionality, but the client has not been updated.
6119	/// To investigate this, consider turning on debug logging to print the raw HTTP response.
6120	#[non_exhaustive]
6121	Unknown,
6122}
6123impl ChatTopic {
6124	/// Tries to convert the enum instance into [`Direct`](crate::model::ChatTopic::Direct), extracting the inner [`ChatTopicDirect`](crate::model::ChatTopicDirect).
6125	/// Returns `Err(&Self)` if it can't be converted.
6126	pub fn as_direct(&self) -> std::result::Result<&crate::model::ChatTopicDirect, &Self> {
6127		if let ChatTopic::Direct(val) = &self {
6128			Ok(val)
6129		} else {
6130			Err(self)
6131		}
6132	}
6133	/// Returns true if this is a [`Direct`](crate::model::ChatTopic::Direct).
6134	pub fn is_direct(&self) -> bool {
6135		self.as_direct().is_ok()
6136	}
6137	/// Tries to convert the enum instance into [`Group`](crate::model::ChatTopic::Group), extracting the inner [`ChatTopicGroup`](crate::model::ChatTopicGroup).
6138	/// Returns `Err(&Self)` if it can't be converted.
6139	pub fn as_group(&self) -> std::result::Result<&crate::model::ChatTopicGroup, &Self> {
6140		if let ChatTopic::Group(val) = &self {
6141			Ok(val)
6142		} else {
6143			Err(self)
6144		}
6145	}
6146	/// Returns true if this is a [`Group`](crate::model::ChatTopic::Group).
6147	pub fn is_group(&self) -> bool {
6148		self.as_group().is_ok()
6149	}
6150	/// Tries to convert the enum instance into [`Party`](crate::model::ChatTopic::Party), extracting the inner [`ChatTopicParty`](crate::model::ChatTopicParty).
6151	/// Returns `Err(&Self)` if it can't be converted.
6152	pub fn as_party(&self) -> std::result::Result<&crate::model::ChatTopicParty, &Self> {
6153		if let ChatTopic::Party(val) = &self {
6154			Ok(val)
6155		} else {
6156			Err(self)
6157		}
6158	}
6159	/// Returns true if this is a [`Party`](crate::model::ChatTopic::Party).
6160	pub fn is_party(&self) -> bool {
6161		self.as_party().is_ok()
6162	}
6163	/// Returns true if the enum instance is the `Unknown` variant.
6164	pub fn is_unknown(&self) -> bool {
6165		matches!(self, Self::Unknown)
6166	}
6167}
6168
6169/// `rivet.chat#ChatTopic` variant for direct (identity to identity) chats.
6170#[non_exhaustive]
6171#[derive(std::clone::Clone, std::cmp::PartialEq)]
6172pub struct ChatTopicDirect {
6173	/// An identity handle.
6174	pub identity_a: std::option::Option<crate::model::IdentityHandle>,
6175	/// An identity handle.
6176	pub identity_b: std::option::Option<crate::model::IdentityHandle>,
6177}
6178impl ChatTopicDirect {
6179	/// An identity handle.
6180	pub fn identity_a(&self) -> std::option::Option<&crate::model::IdentityHandle> {
6181		self.identity_a.as_ref()
6182	}
6183	/// An identity handle.
6184	pub fn identity_b(&self) -> std::option::Option<&crate::model::IdentityHandle> {
6185		self.identity_b.as_ref()
6186	}
6187}
6188impl std::fmt::Debug for ChatTopicDirect {
6189	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
6190		let mut formatter = f.debug_struct("ChatTopicDirect");
6191		formatter.field("identity_a", &self.identity_a);
6192		formatter.field("identity_b", &self.identity_b);
6193		formatter.finish()
6194	}
6195}
6196/// See [`ChatTopicDirect`](crate::model::ChatTopicDirect)
6197pub mod chat_topic_direct {
6198	/// A builder for [`ChatTopicDirect`](crate::model::ChatTopicDirect)
6199	#[non_exhaustive]
6200	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
6201	pub struct Builder {
6202		pub(crate) identity_a: std::option::Option<crate::model::IdentityHandle>,
6203		pub(crate) identity_b: std::option::Option<crate::model::IdentityHandle>,
6204	}
6205	impl Builder {
6206		/// An identity handle.
6207		pub fn identity_a(mut self, input: crate::model::IdentityHandle) -> Self {
6208			self.identity_a = Some(input);
6209			self
6210		}
6211		/// An identity handle.
6212		pub fn set_identity_a(
6213			mut self,
6214			input: std::option::Option<crate::model::IdentityHandle>,
6215		) -> Self {
6216			self.identity_a = input;
6217			self
6218		}
6219		/// An identity handle.
6220		pub fn identity_b(mut self, input: crate::model::IdentityHandle) -> Self {
6221			self.identity_b = Some(input);
6222			self
6223		}
6224		/// An identity handle.
6225		pub fn set_identity_b(
6226			mut self,
6227			input: std::option::Option<crate::model::IdentityHandle>,
6228		) -> Self {
6229			self.identity_b = input;
6230			self
6231		}
6232		/// Consumes the builder and constructs a [`ChatTopicDirect`](crate::model::ChatTopicDirect)
6233		pub fn build(self) -> crate::model::ChatTopicDirect {
6234			crate::model::ChatTopicDirect {
6235				identity_a: self.identity_a,
6236				identity_b: self.identity_b,
6237			}
6238		}
6239	}
6240}
6241impl ChatTopicDirect {
6242	/// Creates a new builder-style object to manufacture [`ChatTopicDirect`](crate::model::ChatTopicDirect)
6243	pub fn builder() -> crate::model::chat_topic_direct::Builder {
6244		crate::model::chat_topic_direct::Builder::default()
6245	}
6246}
6247
6248/// `rivet.chat#ChatTopic` variant for parties.
6249#[non_exhaustive]
6250#[derive(std::clone::Clone, std::cmp::PartialEq)]
6251pub struct ChatTopicParty {
6252	/// A party handle.
6253	pub party: std::option::Option<crate::model::PartyHandle>,
6254}
6255impl ChatTopicParty {
6256	/// A party handle.
6257	pub fn party(&self) -> std::option::Option<&crate::model::PartyHandle> {
6258		self.party.as_ref()
6259	}
6260}
6261impl std::fmt::Debug for ChatTopicParty {
6262	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
6263		let mut formatter = f.debug_struct("ChatTopicParty");
6264		formatter.field("party", &self.party);
6265		formatter.finish()
6266	}
6267}
6268/// See [`ChatTopicParty`](crate::model::ChatTopicParty)
6269pub mod chat_topic_party {
6270	/// A builder for [`ChatTopicParty`](crate::model::ChatTopicParty)
6271	#[non_exhaustive]
6272	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
6273	pub struct Builder {
6274		pub(crate) party: std::option::Option<crate::model::PartyHandle>,
6275	}
6276	impl Builder {
6277		/// A party handle.
6278		pub fn party(mut self, input: crate::model::PartyHandle) -> Self {
6279			self.party = Some(input);
6280			self
6281		}
6282		/// A party handle.
6283		pub fn set_party(mut self, input: std::option::Option<crate::model::PartyHandle>) -> Self {
6284			self.party = input;
6285			self
6286		}
6287		/// Consumes the builder and constructs a [`ChatTopicParty`](crate::model::ChatTopicParty)
6288		pub fn build(self) -> crate::model::ChatTopicParty {
6289			crate::model::ChatTopicParty { party: self.party }
6290		}
6291	}
6292}
6293impl ChatTopicParty {
6294	/// Creates a new builder-style object to manufacture [`ChatTopicParty`](crate::model::ChatTopicParty)
6295	pub fn builder() -> crate::model::chat_topic_party::Builder {
6296		crate::model::chat_topic_party::Builder::default()
6297	}
6298}
6299
6300/// `rivet.chat#ChatTopic` variant for groups.
6301#[non_exhaustive]
6302#[derive(std::clone::Clone, std::cmp::PartialEq)]
6303pub struct ChatTopicGroup {
6304	/// A group handle.
6305	pub group: std::option::Option<crate::model::GroupHandle>,
6306}
6307impl ChatTopicGroup {
6308	/// A group handle.
6309	pub fn group(&self) -> std::option::Option<&crate::model::GroupHandle> {
6310		self.group.as_ref()
6311	}
6312}
6313impl std::fmt::Debug for ChatTopicGroup {
6314	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
6315		let mut formatter = f.debug_struct("ChatTopicGroup");
6316		formatter.field("group", &self.group);
6317		formatter.finish()
6318	}
6319}
6320/// See [`ChatTopicGroup`](crate::model::ChatTopicGroup)
6321pub mod chat_topic_group {
6322	/// A builder for [`ChatTopicGroup`](crate::model::ChatTopicGroup)
6323	#[non_exhaustive]
6324	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
6325	pub struct Builder {
6326		pub(crate) group: std::option::Option<crate::model::GroupHandle>,
6327	}
6328	impl Builder {
6329		/// A group handle.
6330		pub fn group(mut self, input: crate::model::GroupHandle) -> Self {
6331			self.group = Some(input);
6332			self
6333		}
6334		/// A group handle.
6335		pub fn set_group(mut self, input: std::option::Option<crate::model::GroupHandle>) -> Self {
6336			self.group = input;
6337			self
6338		}
6339		/// Consumes the builder and constructs a [`ChatTopicGroup`](crate::model::ChatTopicGroup)
6340		pub fn build(self) -> crate::model::ChatTopicGroup {
6341			crate::model::ChatTopicGroup { group: self.group }
6342		}
6343	}
6344}
6345impl ChatTopicGroup {
6346	/// Creates a new builder-style object to manufacture [`ChatTopicGroup`](crate::model::ChatTopicGroup)
6347	pub fn builder() -> crate::model::chat_topic_group::Builder {
6348		crate::model::chat_topic_group::Builder::default()
6349	}
6350}
6351
6352/// An identity summary.
6353#[non_exhaustive]
6354#[derive(std::clone::Clone, std::cmp::PartialEq)]
6355pub struct IdentitySummary {
6356	/// A universally unique identifier.
6357	pub identity_id: std::option::Option<std::string::String>,
6358	/// Represent a resource's readable display name.
6359	pub display_name: std::option::Option<std::string::String>,
6360	/// 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.
6361	pub account_number: std::option::Option<i32>,
6362	/// The URL of this identity's avatar image.
6363	pub avatar_url: std::option::Option<std::string::String>,
6364	/// Information about the identity's current status, party, and active game.
6365	pub presence: std::option::Option<crate::model::IdentityPresence>,
6366	/// A party handle.
6367	pub party: std::option::Option<crate::model::PartyHandle>,
6368	/// Whether or not this identity is registered with a linked account.
6369	pub is_registered: std::option::Option<bool>,
6370	/// External links for an identity.
6371	pub external: std::option::Option<crate::model::IdentityExternalLinks>,
6372	/// Whether or not the requestee's identity is following this identity.
6373	pub following: std::option::Option<bool>,
6374	/// Whether or not this identity following the requestee's identity.
6375	pub is_following_me: std::option::Option<bool>,
6376	/// Whether or not this identity is both followng and is followed by the requestee's identity.
6377	pub is_mutual_following: std::option::Option<bool>,
6378}
6379impl IdentitySummary {
6380	/// A universally unique identifier.
6381	pub fn identity_id(&self) -> std::option::Option<&str> {
6382		self.identity_id.as_deref()
6383	}
6384	/// Represent a resource's readable display name.
6385	pub fn display_name(&self) -> std::option::Option<&str> {
6386		self.display_name.as_deref()
6387	}
6388	/// 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.
6389	pub fn account_number(&self) -> std::option::Option<i32> {
6390		self.account_number
6391	}
6392	/// The URL of this identity's avatar image.
6393	pub fn avatar_url(&self) -> std::option::Option<&str> {
6394		self.avatar_url.as_deref()
6395	}
6396	/// Information about the identity's current status, party, and active game.
6397	pub fn presence(&self) -> std::option::Option<&crate::model::IdentityPresence> {
6398		self.presence.as_ref()
6399	}
6400	/// A party handle.
6401	pub fn party(&self) -> std::option::Option<&crate::model::PartyHandle> {
6402		self.party.as_ref()
6403	}
6404	/// Whether or not this identity is registered with a linked account.
6405	pub fn is_registered(&self) -> std::option::Option<bool> {
6406		self.is_registered
6407	}
6408	/// External links for an identity.
6409	pub fn external(&self) -> std::option::Option<&crate::model::IdentityExternalLinks> {
6410		self.external.as_ref()
6411	}
6412	/// Whether or not the requestee's identity is following this identity.
6413	pub fn following(&self) -> std::option::Option<bool> {
6414		self.following
6415	}
6416	/// Whether or not this identity following the requestee's identity.
6417	pub fn is_following_me(&self) -> std::option::Option<bool> {
6418		self.is_following_me
6419	}
6420	/// Whether or not this identity is both followng and is followed by the requestee's identity.
6421	pub fn is_mutual_following(&self) -> std::option::Option<bool> {
6422		self.is_mutual_following
6423	}
6424}
6425impl std::fmt::Debug for IdentitySummary {
6426	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
6427		let mut formatter = f.debug_struct("IdentitySummary");
6428		formatter.field("identity_id", &self.identity_id);
6429		formatter.field("display_name", &self.display_name);
6430		formatter.field("account_number", &self.account_number);
6431		formatter.field("avatar_url", &self.avatar_url);
6432		formatter.field("presence", &self.presence);
6433		formatter.field("party", &self.party);
6434		formatter.field("is_registered", &self.is_registered);
6435		formatter.field("external", &self.external);
6436		formatter.field("following", &self.following);
6437		formatter.field("is_following_me", &self.is_following_me);
6438		formatter.field("is_mutual_following", &self.is_mutual_following);
6439		formatter.finish()
6440	}
6441}
6442/// See [`IdentitySummary`](crate::model::IdentitySummary)
6443pub mod identity_summary {
6444	/// A builder for [`IdentitySummary`](crate::model::IdentitySummary)
6445	#[non_exhaustive]
6446	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
6447	pub struct Builder {
6448		pub(crate) identity_id: std::option::Option<std::string::String>,
6449		pub(crate) display_name: std::option::Option<std::string::String>,
6450		pub(crate) account_number: std::option::Option<i32>,
6451		pub(crate) avatar_url: std::option::Option<std::string::String>,
6452		pub(crate) presence: std::option::Option<crate::model::IdentityPresence>,
6453		pub(crate) party: std::option::Option<crate::model::PartyHandle>,
6454		pub(crate) is_registered: std::option::Option<bool>,
6455		pub(crate) external: std::option::Option<crate::model::IdentityExternalLinks>,
6456		pub(crate) following: std::option::Option<bool>,
6457		pub(crate) is_following_me: std::option::Option<bool>,
6458		pub(crate) is_mutual_following: std::option::Option<bool>,
6459	}
6460	impl Builder {
6461		/// A universally unique identifier.
6462		pub fn identity_id(mut self, input: impl Into<std::string::String>) -> Self {
6463			self.identity_id = Some(input.into());
6464			self
6465		}
6466		/// A universally unique identifier.
6467		pub fn set_identity_id(mut self, input: std::option::Option<std::string::String>) -> Self {
6468			self.identity_id = input;
6469			self
6470		}
6471		/// Represent a resource's readable display name.
6472		pub fn display_name(mut self, input: impl Into<std::string::String>) -> Self {
6473			self.display_name = Some(input.into());
6474			self
6475		}
6476		/// Represent a resource's readable display name.
6477		pub fn set_display_name(mut self, input: std::option::Option<std::string::String>) -> Self {
6478			self.display_name = input;
6479			self
6480		}
6481		/// 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.
6482		pub fn account_number(mut self, input: i32) -> Self {
6483			self.account_number = Some(input);
6484			self
6485		}
6486		/// 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.
6487		pub fn set_account_number(mut self, input: std::option::Option<i32>) -> Self {
6488			self.account_number = input;
6489			self
6490		}
6491		/// The URL of this identity's avatar image.
6492		pub fn avatar_url(mut self, input: impl Into<std::string::String>) -> Self {
6493			self.avatar_url = Some(input.into());
6494			self
6495		}
6496		/// The URL of this identity's avatar image.
6497		pub fn set_avatar_url(mut self, input: std::option::Option<std::string::String>) -> Self {
6498			self.avatar_url = input;
6499			self
6500		}
6501		/// Information about the identity's current status, party, and active game.
6502		pub fn presence(mut self, input: crate::model::IdentityPresence) -> Self {
6503			self.presence = Some(input);
6504			self
6505		}
6506		/// Information about the identity's current status, party, and active game.
6507		pub fn set_presence(
6508			mut self,
6509			input: std::option::Option<crate::model::IdentityPresence>,
6510		) -> Self {
6511			self.presence = input;
6512			self
6513		}
6514		/// A party handle.
6515		pub fn party(mut self, input: crate::model::PartyHandle) -> Self {
6516			self.party = Some(input);
6517			self
6518		}
6519		/// A party handle.
6520		pub fn set_party(mut self, input: std::option::Option<crate::model::PartyHandle>) -> Self {
6521			self.party = input;
6522			self
6523		}
6524		/// Whether or not this identity is registered with a linked account.
6525		pub fn is_registered(mut self, input: bool) -> Self {
6526			self.is_registered = Some(input);
6527			self
6528		}
6529		/// Whether or not this identity is registered with a linked account.
6530		pub fn set_is_registered(mut self, input: std::option::Option<bool>) -> Self {
6531			self.is_registered = input;
6532			self
6533		}
6534		/// External links for an identity.
6535		pub fn external(mut self, input: crate::model::IdentityExternalLinks) -> Self {
6536			self.external = Some(input);
6537			self
6538		}
6539		/// External links for an identity.
6540		pub fn set_external(
6541			mut self,
6542			input: std::option::Option<crate::model::IdentityExternalLinks>,
6543		) -> Self {
6544			self.external = input;
6545			self
6546		}
6547		/// Whether or not the requestee's identity is following this identity.
6548		pub fn following(mut self, input: bool) -> Self {
6549			self.following = Some(input);
6550			self
6551		}
6552		/// Whether or not the requestee's identity is following this identity.
6553		pub fn set_following(mut self, input: std::option::Option<bool>) -> Self {
6554			self.following = input;
6555			self
6556		}
6557		/// Whether or not this identity following the requestee's identity.
6558		pub fn is_following_me(mut self, input: bool) -> Self {
6559			self.is_following_me = Some(input);
6560			self
6561		}
6562		/// Whether or not this identity following the requestee's identity.
6563		pub fn set_is_following_me(mut self, input: std::option::Option<bool>) -> Self {
6564			self.is_following_me = input;
6565			self
6566		}
6567		/// Whether or not this identity is both followng and is followed by the requestee's identity.
6568		pub fn is_mutual_following(mut self, input: bool) -> Self {
6569			self.is_mutual_following = Some(input);
6570			self
6571		}
6572		/// Whether or not this identity is both followng and is followed by the requestee's identity.
6573		pub fn set_is_mutual_following(mut self, input: std::option::Option<bool>) -> Self {
6574			self.is_mutual_following = input;
6575			self
6576		}
6577		/// Consumes the builder and constructs a [`IdentitySummary`](crate::model::IdentitySummary)
6578		pub fn build(self) -> crate::model::IdentitySummary {
6579			crate::model::IdentitySummary {
6580				identity_id: self.identity_id,
6581				display_name: self.display_name,
6582				account_number: self.account_number,
6583				avatar_url: self.avatar_url,
6584				presence: self.presence,
6585				party: self.party,
6586				is_registered: self.is_registered,
6587				external: self.external,
6588				following: self.following,
6589				is_following_me: self.is_following_me,
6590				is_mutual_following: self.is_mutual_following,
6591			}
6592		}
6593	}
6594}
6595impl IdentitySummary {
6596	/// Creates a new builder-style object to manufacture [`IdentitySummary`](crate::model::IdentitySummary)
6597	pub fn builder() -> crate::model::identity_summary::Builder {
6598		crate::model::identity_summary::Builder::default()
6599	}
6600}
6601
6602/// A presigned request used to upload files. Upload your file to the given URL via a PUT request.
6603#[non_exhaustive]
6604#[derive(std::clone::Clone, std::cmp::PartialEq)]
6605pub struct UploadPresignedRequest {
6606	/// The name of the file to upload. This is the same as the one given in the upload prepare file.
6607	pub path: std::option::Option<std::string::String>,
6608	/// The URL of the presigned request for which to upload your file to.
6609	pub url: std::option::Option<std::string::String>,
6610}
6611impl UploadPresignedRequest {
6612	/// The name of the file to upload. This is the same as the one given in the upload prepare file.
6613	pub fn path(&self) -> std::option::Option<&str> {
6614		self.path.as_deref()
6615	}
6616	/// The URL of the presigned request for which to upload your file to.
6617	pub fn url(&self) -> std::option::Option<&str> {
6618		self.url.as_deref()
6619	}
6620}
6621impl std::fmt::Debug for UploadPresignedRequest {
6622	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
6623		let mut formatter = f.debug_struct("UploadPresignedRequest");
6624		formatter.field("path", &self.path);
6625		formatter.field("url", &self.url);
6626		formatter.finish()
6627	}
6628}
6629/// See [`UploadPresignedRequest`](crate::model::UploadPresignedRequest)
6630pub mod upload_presigned_request {
6631	/// A builder for [`UploadPresignedRequest`](crate::model::UploadPresignedRequest)
6632	#[non_exhaustive]
6633	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
6634	pub struct Builder {
6635		pub(crate) path: std::option::Option<std::string::String>,
6636		pub(crate) url: std::option::Option<std::string::String>,
6637	}
6638	impl Builder {
6639		/// The name of the file to upload. This is the same as the one given in the upload prepare file.
6640		pub fn path(mut self, input: impl Into<std::string::String>) -> Self {
6641			self.path = Some(input.into());
6642			self
6643		}
6644		/// The name of the file to upload. This is the same as the one given in the upload prepare file.
6645		pub fn set_path(mut self, input: std::option::Option<std::string::String>) -> Self {
6646			self.path = input;
6647			self
6648		}
6649		/// The URL of the presigned request for which to upload your file to.
6650		pub fn url(mut self, input: impl Into<std::string::String>) -> Self {
6651			self.url = Some(input.into());
6652			self
6653		}
6654		/// The URL of the presigned request for which to upload your file to.
6655		pub fn set_url(mut self, input: std::option::Option<std::string::String>) -> Self {
6656			self.url = input;
6657			self
6658		}
6659		/// Consumes the builder and constructs a [`UploadPresignedRequest`](crate::model::UploadPresignedRequest)
6660		pub fn build(self) -> crate::model::UploadPresignedRequest {
6661			crate::model::UploadPresignedRequest {
6662				path: self.path,
6663				url: self.url,
6664			}
6665		}
6666	}
6667}
6668impl UploadPresignedRequest {
6669	/// Creates a new builder-style object to manufacture [`UploadPresignedRequest`](crate::model::UploadPresignedRequest)
6670	pub fn builder() -> crate::model::upload_presigned_request::Builder {
6671		crate::model::upload_presigned_request::Builder::default()
6672	}
6673}
6674
6675/// Information about the identity's current game. This is information that all other identities can see about what the current identity is doing.
6676#[non_exhaustive]
6677#[derive(std::clone::Clone, std::cmp::PartialEq)]
6678pub struct UpdateIdentityGameActivity {
6679	/// A short message about the current game activity.
6680	pub message: std::option::Option<std::string::String>,
6681	/// JSON data seen by anyone.
6682	pub public_metadata: std::option::Option<aws_smithy_types::Document>,
6683	/// JSON data seen only by the given identity and their mutual followers.
6684	pub mutual_metadata: std::option::Option<aws_smithy_types::Document>,
6685}
6686impl UpdateIdentityGameActivity {
6687	/// A short message about the current game activity.
6688	pub fn message(&self) -> std::option::Option<&str> {
6689		self.message.as_deref()
6690	}
6691	/// JSON data seen by anyone.
6692	pub fn public_metadata(&self) -> std::option::Option<&aws_smithy_types::Document> {
6693		self.public_metadata.as_ref()
6694	}
6695	/// JSON data seen only by the given identity and their mutual followers.
6696	pub fn mutual_metadata(&self) -> std::option::Option<&aws_smithy_types::Document> {
6697		self.mutual_metadata.as_ref()
6698	}
6699}
6700impl std::fmt::Debug for UpdateIdentityGameActivity {
6701	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
6702		let mut formatter = f.debug_struct("UpdateIdentityGameActivity");
6703		formatter.field("message", &self.message);
6704		formatter.field("public_metadata", &self.public_metadata);
6705		formatter.field("mutual_metadata", &self.mutual_metadata);
6706		formatter.finish()
6707	}
6708}
6709/// See [`UpdateIdentityGameActivity`](crate::model::UpdateIdentityGameActivity)
6710pub mod update_identity_game_activity {
6711	/// A builder for [`UpdateIdentityGameActivity`](crate::model::UpdateIdentityGameActivity)
6712	#[non_exhaustive]
6713	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
6714	pub struct Builder {
6715		pub(crate) message: std::option::Option<std::string::String>,
6716		pub(crate) public_metadata: std::option::Option<aws_smithy_types::Document>,
6717		pub(crate) mutual_metadata: std::option::Option<aws_smithy_types::Document>,
6718	}
6719	impl Builder {
6720		/// A short message about the current game activity.
6721		pub fn message(mut self, input: impl Into<std::string::String>) -> Self {
6722			self.message = Some(input.into());
6723			self
6724		}
6725		/// A short message about the current game activity.
6726		pub fn set_message(mut self, input: std::option::Option<std::string::String>) -> Self {
6727			self.message = input;
6728			self
6729		}
6730		/// JSON data seen by anyone.
6731		pub fn public_metadata(mut self, input: aws_smithy_types::Document) -> Self {
6732			self.public_metadata = Some(input);
6733			self
6734		}
6735		/// JSON data seen by anyone.
6736		pub fn set_public_metadata(
6737			mut self,
6738			input: std::option::Option<aws_smithy_types::Document>,
6739		) -> Self {
6740			self.public_metadata = input;
6741			self
6742		}
6743		/// JSON data seen only by the given identity and their mutual followers.
6744		pub fn mutual_metadata(mut self, input: aws_smithy_types::Document) -> Self {
6745			self.mutual_metadata = Some(input);
6746			self
6747		}
6748		/// JSON data seen only by the given identity and their mutual followers.
6749		pub fn set_mutual_metadata(
6750			mut self,
6751			input: std::option::Option<aws_smithy_types::Document>,
6752		) -> Self {
6753			self.mutual_metadata = input;
6754			self
6755		}
6756		/// Consumes the builder and constructs a [`UpdateIdentityGameActivity`](crate::model::UpdateIdentityGameActivity)
6757		pub fn build(self) -> crate::model::UpdateIdentityGameActivity {
6758			crate::model::UpdateIdentityGameActivity {
6759				message: self.message,
6760				public_metadata: self.public_metadata,
6761				mutual_metadata: self.mutual_metadata,
6762			}
6763		}
6764	}
6765}
6766impl UpdateIdentityGameActivity {
6767	/// Creates a new builder-style object to manufacture [`UpdateIdentityGameActivity`](crate::model::UpdateIdentityGameActivity)
6768	pub fn builder() -> crate::model::update_identity_game_activity::Builder {
6769		crate::model::update_identity_game_activity::Builder::default()
6770	}
6771}
6772
6773/// An error given by failed content validation.
6774#[non_exhaustive]
6775#[derive(std::clone::Clone, std::cmp::PartialEq)]
6776pub struct ValidationError {
6777	/// A list of strings denoting the origin of a validation error.
6778	pub path: std::option::Option<std::vec::Vec<std::string::String>>,
6779}
6780impl ValidationError {
6781	/// A list of strings denoting the origin of a validation error.
6782	pub fn path(&self) -> std::option::Option<&[std::string::String]> {
6783		self.path.as_deref()
6784	}
6785}
6786impl std::fmt::Debug for ValidationError {
6787	fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
6788		let mut formatter = f.debug_struct("ValidationError");
6789		formatter.field("path", &self.path);
6790		formatter.finish()
6791	}
6792}
6793/// See [`ValidationError`](crate::model::ValidationError)
6794pub mod validation_error {
6795	/// A builder for [`ValidationError`](crate::model::ValidationError)
6796	#[non_exhaustive]
6797	#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
6798	pub struct Builder {
6799		pub(crate) path: std::option::Option<std::vec::Vec<std::string::String>>,
6800	}
6801	impl Builder {
6802		/// Appends an item to `path`.
6803		///
6804		/// To override the contents of this collection use [`set_path`](Self::set_path).
6805		///
6806		/// A list of strings denoting the origin of a validation error.
6807		pub fn path(mut self, input: impl Into<std::string::String>) -> Self {
6808			let mut v = self.path.unwrap_or_default();
6809			v.push(input.into());
6810			self.path = Some(v);
6811			self
6812		}
6813		/// A list of strings denoting the origin of a validation error.
6814		pub fn set_path(
6815			mut self,
6816			input: std::option::Option<std::vec::Vec<std::string::String>>,
6817		) -> Self {
6818			self.path = input;
6819			self
6820		}
6821		/// Consumes the builder and constructs a [`ValidationError`](crate::model::ValidationError)
6822		pub fn build(self) -> crate::model::ValidationError {
6823			crate::model::ValidationError { path: self.path }
6824		}
6825	}
6826}
6827impl ValidationError {
6828	/// Creates a new builder-style object to manufacture [`ValidationError`](crate::model::ValidationError)
6829	pub fn builder() -> crate::model::validation_error::Builder {
6830		crate::model::validation_error::Builder::default()
6831	}
6832}