1use super::{errors::*, *};
2
3#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4#[serde(tag = "type")]
5#[non_exhaustive]
6pub enum ApiCreateMyAddressResponse {
7 #[serde(rename = "userContactLinkCreated")]
9 UserContactLinkCreated(UserContactLinkCreatedResponse),
10 #[serde(rename = "chatCmdError")]
12 ChatCmdError(ChatCmdErrorResponse),
13 #[serde(untagged)]
14 Undocumented(JsonObject),
15}
16
17impl ApiCreateMyAddressResponse {
18 pub fn user_contact_link_created(&self) -> Option<&UserContactLinkCreatedResponse> {
19 if let Self::UserContactLinkCreated(ret) = self {
20 Some(ret)
21 } else {
22 None
23 }
24 }
25
26 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
27 if let Self::ChatCmdError(ret) = self {
28 Some(ret)
29 } else {
30 None
31 }
32 }
33
34 pub fn undocumented(&self) -> Option<&JsonObject> {
35 if let Self::Undocumented(ret) = self {
36 Some(ret)
37 } else {
38 None
39 }
40 }
41}
42
43#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
44#[serde(tag = "type")]
45#[non_exhaustive]
46pub enum ApiDeleteMyAddressResponse {
47 #[serde(rename = "userContactLinkDeleted")]
49 UserContactLinkDeleted(UserContactLinkDeletedResponse),
50 #[serde(rename = "chatCmdError")]
52 ChatCmdError(ChatCmdErrorResponse),
53 #[serde(untagged)]
54 Undocumented(JsonObject),
55}
56
57impl ApiDeleteMyAddressResponse {
58 pub fn user_contact_link_deleted(&self) -> Option<&UserContactLinkDeletedResponse> {
59 if let Self::UserContactLinkDeleted(ret) = self {
60 Some(ret)
61 } else {
62 None
63 }
64 }
65
66 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
67 if let Self::ChatCmdError(ret) = self {
68 Some(ret)
69 } else {
70 None
71 }
72 }
73
74 pub fn undocumented(&self) -> Option<&JsonObject> {
75 if let Self::Undocumented(ret) = self {
76 Some(ret)
77 } else {
78 None
79 }
80 }
81}
82
83#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
84#[serde(tag = "type")]
85#[non_exhaustive]
86pub enum ApiShowMyAddressResponse {
87 #[serde(rename = "userContactLink")]
89 UserContactLink(UserContactLinkResponse),
90 #[serde(rename = "chatCmdError")]
92 ChatCmdError(ChatCmdErrorResponse),
93 #[serde(untagged)]
94 Undocumented(JsonObject),
95}
96
97impl ApiShowMyAddressResponse {
98 pub fn user_contact_link(&self) -> Option<&UserContactLinkResponse> {
99 if let Self::UserContactLink(ret) = self {
100 Some(ret)
101 } else {
102 None
103 }
104 }
105
106 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
107 if let Self::ChatCmdError(ret) = self {
108 Some(ret)
109 } else {
110 None
111 }
112 }
113
114 pub fn undocumented(&self) -> Option<&JsonObject> {
115 if let Self::Undocumented(ret) = self {
116 Some(ret)
117 } else {
118 None
119 }
120 }
121}
122
123#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
124#[serde(tag = "type")]
125#[non_exhaustive]
126pub enum ApiSetProfileAddressResponse {
127 #[serde(rename = "userProfileUpdated")]
129 UserProfileUpdated(UserProfileUpdatedResponse),
130 #[serde(rename = "chatCmdError")]
132 ChatCmdError(ChatCmdErrorResponse),
133 #[serde(untagged)]
134 Undocumented(JsonObject),
135}
136
137impl ApiSetProfileAddressResponse {
138 pub fn user_profile_updated(&self) -> Option<&UserProfileUpdatedResponse> {
139 if let Self::UserProfileUpdated(ret) = self {
140 Some(ret)
141 } else {
142 None
143 }
144 }
145
146 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
147 if let Self::ChatCmdError(ret) = self {
148 Some(ret)
149 } else {
150 None
151 }
152 }
153
154 pub fn undocumented(&self) -> Option<&JsonObject> {
155 if let Self::Undocumented(ret) = self {
156 Some(ret)
157 } else {
158 None
159 }
160 }
161}
162
163#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
164#[serde(tag = "type")]
165#[non_exhaustive]
166pub enum ApiSetAddressSettingsResponse {
167 #[serde(rename = "userContactLinkUpdated")]
169 UserContactLinkUpdated(UserContactLinkUpdatedResponse),
170 #[serde(rename = "chatCmdError")]
172 ChatCmdError(ChatCmdErrorResponse),
173 #[serde(untagged)]
174 Undocumented(JsonObject),
175}
176
177impl ApiSetAddressSettingsResponse {
178 pub fn user_contact_link_updated(&self) -> Option<&UserContactLinkUpdatedResponse> {
179 if let Self::UserContactLinkUpdated(ret) = self {
180 Some(ret)
181 } else {
182 None
183 }
184 }
185
186 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
187 if let Self::ChatCmdError(ret) = self {
188 Some(ret)
189 } else {
190 None
191 }
192 }
193
194 pub fn undocumented(&self) -> Option<&JsonObject> {
195 if let Self::Undocumented(ret) = self {
196 Some(ret)
197 } else {
198 None
199 }
200 }
201}
202
203#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
204#[serde(tag = "type")]
205#[non_exhaustive]
206pub enum ApiSendMessagesResponse {
207 #[serde(rename = "newChatItems")]
209 NewChatItems(NewChatItemsResponse),
210 #[serde(rename = "chatCmdError")]
212 ChatCmdError(ChatCmdErrorResponse),
213 #[serde(untagged)]
214 Undocumented(JsonObject),
215}
216
217impl ApiSendMessagesResponse {
218 pub fn new_chat_items(&self) -> Option<&NewChatItemsResponse> {
219 if let Self::NewChatItems(ret) = self {
220 Some(ret)
221 } else {
222 None
223 }
224 }
225
226 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
227 if let Self::ChatCmdError(ret) = self {
228 Some(ret)
229 } else {
230 None
231 }
232 }
233
234 pub fn undocumented(&self) -> Option<&JsonObject> {
235 if let Self::Undocumented(ret) = self {
236 Some(ret)
237 } else {
238 None
239 }
240 }
241}
242
243#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
244#[serde(tag = "type")]
245#[non_exhaustive]
246pub enum ApiUpdateChatItemResponse {
247 #[serde(rename = "chatItemUpdated")]
249 ChatItemUpdated(ChatItemUpdatedResponse),
250 #[serde(rename = "chatItemNotChanged")]
252 ChatItemNotChanged(ChatItemNotChangedResponse),
253 #[serde(rename = "chatCmdError")]
255 ChatCmdError(ChatCmdErrorResponse),
256 #[serde(untagged)]
257 Undocumented(JsonObject),
258}
259
260impl ApiUpdateChatItemResponse {
261 pub fn chat_item_updated(&self) -> Option<&ChatItemUpdatedResponse> {
262 if let Self::ChatItemUpdated(ret) = self {
263 Some(ret)
264 } else {
265 None
266 }
267 }
268
269 pub fn chat_item_not_changed(&self) -> Option<&ChatItemNotChangedResponse> {
270 if let Self::ChatItemNotChanged(ret) = self {
271 Some(ret)
272 } else {
273 None
274 }
275 }
276
277 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
278 if let Self::ChatCmdError(ret) = self {
279 Some(ret)
280 } else {
281 None
282 }
283 }
284
285 pub fn undocumented(&self) -> Option<&JsonObject> {
286 if let Self::Undocumented(ret) = self {
287 Some(ret)
288 } else {
289 None
290 }
291 }
292}
293
294#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
295#[serde(tag = "type")]
296#[non_exhaustive]
297pub enum ApiDeleteChatItemResponse {
298 #[serde(rename = "chatItemsDeleted")]
300 ChatItemsDeleted(ChatItemsDeletedResponse),
301 #[serde(rename = "chatCmdError")]
303 ChatCmdError(ChatCmdErrorResponse),
304 #[serde(untagged)]
305 Undocumented(JsonObject),
306}
307
308impl ApiDeleteChatItemResponse {
309 pub fn chat_items_deleted(&self) -> Option<&ChatItemsDeletedResponse> {
310 if let Self::ChatItemsDeleted(ret) = self {
311 Some(ret)
312 } else {
313 None
314 }
315 }
316
317 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
318 if let Self::ChatCmdError(ret) = self {
319 Some(ret)
320 } else {
321 None
322 }
323 }
324
325 pub fn undocumented(&self) -> Option<&JsonObject> {
326 if let Self::Undocumented(ret) = self {
327 Some(ret)
328 } else {
329 None
330 }
331 }
332}
333
334#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
335#[serde(tag = "type")]
336#[non_exhaustive]
337pub enum ApiDeleteMemberChatItemResponse {
338 #[serde(rename = "chatItemsDeleted")]
340 ChatItemsDeleted(ChatItemsDeletedResponse),
341 #[serde(rename = "chatCmdError")]
343 ChatCmdError(ChatCmdErrorResponse),
344 #[serde(untagged)]
345 Undocumented(JsonObject),
346}
347
348impl ApiDeleteMemberChatItemResponse {
349 pub fn chat_items_deleted(&self) -> Option<&ChatItemsDeletedResponse> {
350 if let Self::ChatItemsDeleted(ret) = self {
351 Some(ret)
352 } else {
353 None
354 }
355 }
356
357 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
358 if let Self::ChatCmdError(ret) = self {
359 Some(ret)
360 } else {
361 None
362 }
363 }
364
365 pub fn undocumented(&self) -> Option<&JsonObject> {
366 if let Self::Undocumented(ret) = self {
367 Some(ret)
368 } else {
369 None
370 }
371 }
372}
373
374#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
375#[serde(tag = "type")]
376#[non_exhaustive]
377pub enum ApiChatItemReactionResponse {
378 #[serde(rename = "chatItemReaction")]
380 ChatItemReaction(ChatItemReactionResponse),
381 #[serde(rename = "chatCmdError")]
383 ChatCmdError(ChatCmdErrorResponse),
384 #[serde(untagged)]
385 Undocumented(JsonObject),
386}
387
388impl ApiChatItemReactionResponse {
389 pub fn chat_item_reaction(&self) -> Option<&ChatItemReactionResponse> {
390 if let Self::ChatItemReaction(ret) = self {
391 Some(ret)
392 } else {
393 None
394 }
395 }
396
397 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
398 if let Self::ChatCmdError(ret) = self {
399 Some(ret)
400 } else {
401 None
402 }
403 }
404
405 pub fn undocumented(&self) -> Option<&JsonObject> {
406 if let Self::Undocumented(ret) = self {
407 Some(ret)
408 } else {
409 None
410 }
411 }
412}
413
414#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
415#[serde(tag = "type")]
416#[non_exhaustive]
417pub enum ReceiveFileResponse {
418 #[serde(rename = "rcvFileAccepted")]
420 RcvFileAccepted(RcvFileAcceptedResponse),
421 #[serde(rename = "rcvFileAcceptedSndCancelled")]
423 RcvFileAcceptedSndCancelled(RcvFileAcceptedSndCancelledResponse),
424 #[serde(rename = "chatCmdError")]
426 ChatCmdError(ChatCmdErrorResponse),
427 #[serde(untagged)]
428 Undocumented(JsonObject),
429}
430
431impl ReceiveFileResponse {
432 pub fn rcv_file_accepted(&self) -> Option<&RcvFileAcceptedResponse> {
433 if let Self::RcvFileAccepted(ret) = self {
434 Some(ret)
435 } else {
436 None
437 }
438 }
439
440 pub fn rcv_file_accepted_snd_cancelled(&self) -> Option<&RcvFileAcceptedSndCancelledResponse> {
441 if let Self::RcvFileAcceptedSndCancelled(ret) = self {
442 Some(ret)
443 } else {
444 None
445 }
446 }
447
448 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
449 if let Self::ChatCmdError(ret) = self {
450 Some(ret)
451 } else {
452 None
453 }
454 }
455
456 pub fn undocumented(&self) -> Option<&JsonObject> {
457 if let Self::Undocumented(ret) = self {
458 Some(ret)
459 } else {
460 None
461 }
462 }
463}
464
465#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
466#[serde(tag = "type")]
467#[non_exhaustive]
468pub enum CancelFileResponse {
469 #[serde(rename = "sndFileCancelled")]
471 SndFileCancelled(SndFileCancelledResponse),
472 #[serde(rename = "rcvFileCancelled")]
474 RcvFileCancelled(RcvFileCancelledResponse),
475 #[serde(rename = "chatCmdError")]
477 ChatCmdError(ChatCmdErrorResponse),
478 #[serde(untagged)]
479 Undocumented(JsonObject),
480}
481
482impl CancelFileResponse {
483 pub fn snd_file_cancelled(&self) -> Option<&SndFileCancelledResponse> {
484 if let Self::SndFileCancelled(ret) = self {
485 Some(ret)
486 } else {
487 None
488 }
489 }
490
491 pub fn rcv_file_cancelled(&self) -> Option<&RcvFileCancelledResponse> {
492 if let Self::RcvFileCancelled(ret) = self {
493 Some(ret)
494 } else {
495 None
496 }
497 }
498
499 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
500 if let Self::ChatCmdError(ret) = self {
501 Some(ret)
502 } else {
503 None
504 }
505 }
506
507 pub fn undocumented(&self) -> Option<&JsonObject> {
508 if let Self::Undocumented(ret) = self {
509 Some(ret)
510 } else {
511 None
512 }
513 }
514}
515
516#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
517#[serde(tag = "type")]
518#[non_exhaustive]
519pub enum ApiAddMemberResponse {
520 #[serde(rename = "sentGroupInvitation")]
522 SentGroupInvitation(SentGroupInvitationResponse),
523 #[serde(rename = "chatCmdError")]
525 ChatCmdError(ChatCmdErrorResponse),
526 #[serde(untagged)]
527 Undocumented(JsonObject),
528}
529
530impl ApiAddMemberResponse {
531 pub fn sent_group_invitation(&self) -> Option<&SentGroupInvitationResponse> {
532 if let Self::SentGroupInvitation(ret) = self {
533 Some(ret)
534 } else {
535 None
536 }
537 }
538
539 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
540 if let Self::ChatCmdError(ret) = self {
541 Some(ret)
542 } else {
543 None
544 }
545 }
546
547 pub fn undocumented(&self) -> Option<&JsonObject> {
548 if let Self::Undocumented(ret) = self {
549 Some(ret)
550 } else {
551 None
552 }
553 }
554}
555
556#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
557#[serde(tag = "type")]
558#[non_exhaustive]
559pub enum ApiJoinGroupResponse {
560 #[serde(rename = "userAcceptedGroupSent")]
562 UserAcceptedGroupSent(UserAcceptedGroupSentResponse),
563 #[serde(rename = "chatCmdError")]
565 ChatCmdError(ChatCmdErrorResponse),
566 #[serde(untagged)]
567 Undocumented(JsonObject),
568}
569
570impl ApiJoinGroupResponse {
571 pub fn user_accepted_group_sent(&self) -> Option<&UserAcceptedGroupSentResponse> {
572 if let Self::UserAcceptedGroupSent(ret) = self {
573 Some(ret)
574 } else {
575 None
576 }
577 }
578
579 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
580 if let Self::ChatCmdError(ret) = self {
581 Some(ret)
582 } else {
583 None
584 }
585 }
586
587 pub fn undocumented(&self) -> Option<&JsonObject> {
588 if let Self::Undocumented(ret) = self {
589 Some(ret)
590 } else {
591 None
592 }
593 }
594}
595
596#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
597#[serde(tag = "type")]
598#[non_exhaustive]
599pub enum ApiAcceptMemberResponse {
600 #[serde(rename = "memberAccepted")]
602 MemberAccepted(MemberAcceptedResponse),
603 #[serde(rename = "chatCmdError")]
605 ChatCmdError(ChatCmdErrorResponse),
606 #[serde(untagged)]
607 Undocumented(JsonObject),
608}
609
610impl ApiAcceptMemberResponse {
611 pub fn member_accepted(&self) -> Option<&MemberAcceptedResponse> {
612 if let Self::MemberAccepted(ret) = self {
613 Some(ret)
614 } else {
615 None
616 }
617 }
618
619 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
620 if let Self::ChatCmdError(ret) = self {
621 Some(ret)
622 } else {
623 None
624 }
625 }
626
627 pub fn undocumented(&self) -> Option<&JsonObject> {
628 if let Self::Undocumented(ret) = self {
629 Some(ret)
630 } else {
631 None
632 }
633 }
634}
635
636#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
637#[serde(tag = "type")]
638#[non_exhaustive]
639pub enum ApiMembersRoleResponse {
640 #[serde(rename = "membersRoleUser")]
642 MembersRoleUser(MembersRoleUserResponse),
643 #[serde(rename = "chatCmdError")]
645 ChatCmdError(ChatCmdErrorResponse),
646 #[serde(untagged)]
647 Undocumented(JsonObject),
648}
649
650impl ApiMembersRoleResponse {
651 pub fn members_role_user(&self) -> Option<&MembersRoleUserResponse> {
652 if let Self::MembersRoleUser(ret) = self {
653 Some(ret)
654 } else {
655 None
656 }
657 }
658
659 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
660 if let Self::ChatCmdError(ret) = self {
661 Some(ret)
662 } else {
663 None
664 }
665 }
666
667 pub fn undocumented(&self) -> Option<&JsonObject> {
668 if let Self::Undocumented(ret) = self {
669 Some(ret)
670 } else {
671 None
672 }
673 }
674}
675
676#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
677#[serde(tag = "type")]
678#[non_exhaustive]
679pub enum ApiBlockMembersForAllResponse {
680 #[serde(rename = "membersBlockedForAllUser")]
682 MembersBlockedForAllUser(MembersBlockedForAllUserResponse),
683 #[serde(rename = "chatCmdError")]
685 ChatCmdError(ChatCmdErrorResponse),
686 #[serde(untagged)]
687 Undocumented(JsonObject),
688}
689
690impl ApiBlockMembersForAllResponse {
691 pub fn members_blocked_for_all_user(&self) -> Option<&MembersBlockedForAllUserResponse> {
692 if let Self::MembersBlockedForAllUser(ret) = self {
693 Some(ret)
694 } else {
695 None
696 }
697 }
698
699 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
700 if let Self::ChatCmdError(ret) = self {
701 Some(ret)
702 } else {
703 None
704 }
705 }
706
707 pub fn undocumented(&self) -> Option<&JsonObject> {
708 if let Self::Undocumented(ret) = self {
709 Some(ret)
710 } else {
711 None
712 }
713 }
714}
715
716#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
717#[serde(tag = "type")]
718#[non_exhaustive]
719pub enum ApiRemoveMembersResponse {
720 #[serde(rename = "userDeletedMembers")]
722 UserDeletedMembers(UserDeletedMembersResponse),
723 #[serde(rename = "chatCmdError")]
725 ChatCmdError(ChatCmdErrorResponse),
726 #[serde(untagged)]
727 Undocumented(JsonObject),
728}
729
730impl ApiRemoveMembersResponse {
731 pub fn user_deleted_members(&self) -> Option<&UserDeletedMembersResponse> {
732 if let Self::UserDeletedMembers(ret) = self {
733 Some(ret)
734 } else {
735 None
736 }
737 }
738
739 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
740 if let Self::ChatCmdError(ret) = self {
741 Some(ret)
742 } else {
743 None
744 }
745 }
746
747 pub fn undocumented(&self) -> Option<&JsonObject> {
748 if let Self::Undocumented(ret) = self {
749 Some(ret)
750 } else {
751 None
752 }
753 }
754}
755
756#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
757#[serde(tag = "type")]
758#[non_exhaustive]
759pub enum ApiLeaveGroupResponse {
760 #[serde(rename = "leftMemberUser")]
762 LeftMemberUser(LeftMemberUserResponse),
763 #[serde(rename = "chatCmdError")]
765 ChatCmdError(ChatCmdErrorResponse),
766 #[serde(untagged)]
767 Undocumented(JsonObject),
768}
769
770impl ApiLeaveGroupResponse {
771 pub fn left_member_user(&self) -> Option<&LeftMemberUserResponse> {
772 if let Self::LeftMemberUser(ret) = self {
773 Some(ret)
774 } else {
775 None
776 }
777 }
778
779 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
780 if let Self::ChatCmdError(ret) = self {
781 Some(ret)
782 } else {
783 None
784 }
785 }
786
787 pub fn undocumented(&self) -> Option<&JsonObject> {
788 if let Self::Undocumented(ret) = self {
789 Some(ret)
790 } else {
791 None
792 }
793 }
794}
795
796#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
797#[serde(tag = "type")]
798#[non_exhaustive]
799pub enum ApiListMembersResponse {
800 #[serde(rename = "groupMembers")]
802 GroupMembers(GroupMembersResponse),
803 #[serde(rename = "chatCmdError")]
805 ChatCmdError(ChatCmdErrorResponse),
806 #[serde(untagged)]
807 Undocumented(JsonObject),
808}
809
810impl ApiListMembersResponse {
811 pub fn group_members(&self) -> Option<&GroupMembersResponse> {
812 if let Self::GroupMembers(ret) = self {
813 Some(ret)
814 } else {
815 None
816 }
817 }
818
819 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
820 if let Self::ChatCmdError(ret) = self {
821 Some(ret)
822 } else {
823 None
824 }
825 }
826
827 pub fn undocumented(&self) -> Option<&JsonObject> {
828 if let Self::Undocumented(ret) = self {
829 Some(ret)
830 } else {
831 None
832 }
833 }
834}
835
836#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
837#[serde(tag = "type")]
838#[non_exhaustive]
839pub enum ApiNewGroupResponse {
840 #[serde(rename = "groupCreated")]
842 GroupCreated(GroupCreatedResponse),
843 #[serde(rename = "chatCmdError")]
845 ChatCmdError(ChatCmdErrorResponse),
846 #[serde(untagged)]
847 Undocumented(JsonObject),
848}
849
850impl ApiNewGroupResponse {
851 pub fn group_created(&self) -> Option<&GroupCreatedResponse> {
852 if let Self::GroupCreated(ret) = self {
853 Some(ret)
854 } else {
855 None
856 }
857 }
858
859 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
860 if let Self::ChatCmdError(ret) = self {
861 Some(ret)
862 } else {
863 None
864 }
865 }
866
867 pub fn undocumented(&self) -> Option<&JsonObject> {
868 if let Self::Undocumented(ret) = self {
869 Some(ret)
870 } else {
871 None
872 }
873 }
874}
875
876#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
877#[serde(tag = "type")]
878#[non_exhaustive]
879pub enum ApiUpdateGroupProfileResponse {
880 #[serde(rename = "groupUpdated")]
882 GroupUpdated(GroupUpdatedResponse),
883 #[serde(rename = "chatCmdError")]
885 ChatCmdError(ChatCmdErrorResponse),
886 #[serde(untagged)]
887 Undocumented(JsonObject),
888}
889
890impl ApiUpdateGroupProfileResponse {
891 pub fn group_updated(&self) -> Option<&GroupUpdatedResponse> {
892 if let Self::GroupUpdated(ret) = self {
893 Some(ret)
894 } else {
895 None
896 }
897 }
898
899 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
900 if let Self::ChatCmdError(ret) = self {
901 Some(ret)
902 } else {
903 None
904 }
905 }
906
907 pub fn undocumented(&self) -> Option<&JsonObject> {
908 if let Self::Undocumented(ret) = self {
909 Some(ret)
910 } else {
911 None
912 }
913 }
914}
915
916#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
917#[serde(tag = "type")]
918#[non_exhaustive]
919pub enum ApiCreateGroupLinkResponse {
920 #[serde(rename = "groupLinkCreated")]
922 GroupLinkCreated(GroupLinkCreatedResponse),
923 #[serde(rename = "chatCmdError")]
925 ChatCmdError(ChatCmdErrorResponse),
926 #[serde(untagged)]
927 Undocumented(JsonObject),
928}
929
930impl ApiCreateGroupLinkResponse {
931 pub fn group_link_created(&self) -> Option<&GroupLinkCreatedResponse> {
932 if let Self::GroupLinkCreated(ret) = self {
933 Some(ret)
934 } else {
935 None
936 }
937 }
938
939 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
940 if let Self::ChatCmdError(ret) = self {
941 Some(ret)
942 } else {
943 None
944 }
945 }
946
947 pub fn undocumented(&self) -> Option<&JsonObject> {
948 if let Self::Undocumented(ret) = self {
949 Some(ret)
950 } else {
951 None
952 }
953 }
954}
955
956#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
957#[serde(tag = "type")]
958#[non_exhaustive]
959pub enum ApiGroupLinkMemberRoleResponse {
960 #[serde(rename = "groupLink")]
962 GroupLink(GroupLinkResponse),
963 #[serde(rename = "chatCmdError")]
965 ChatCmdError(ChatCmdErrorResponse),
966 #[serde(untagged)]
967 Undocumented(JsonObject),
968}
969
970impl ApiGroupLinkMemberRoleResponse {
971 pub fn group_link(&self) -> Option<&GroupLinkResponse> {
972 if let Self::GroupLink(ret) = self {
973 Some(ret)
974 } else {
975 None
976 }
977 }
978
979 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
980 if let Self::ChatCmdError(ret) = self {
981 Some(ret)
982 } else {
983 None
984 }
985 }
986
987 pub fn undocumented(&self) -> Option<&JsonObject> {
988 if let Self::Undocumented(ret) = self {
989 Some(ret)
990 } else {
991 None
992 }
993 }
994}
995
996#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
997#[serde(tag = "type")]
998#[non_exhaustive]
999pub enum ApiDeleteGroupLinkResponse {
1000 #[serde(rename = "groupLinkDeleted")]
1002 GroupLinkDeleted(GroupLinkDeletedResponse),
1003 #[serde(rename = "chatCmdError")]
1005 ChatCmdError(ChatCmdErrorResponse),
1006 #[serde(untagged)]
1007 Undocumented(JsonObject),
1008}
1009
1010impl ApiDeleteGroupLinkResponse {
1011 pub fn group_link_deleted(&self) -> Option<&GroupLinkDeletedResponse> {
1012 if let Self::GroupLinkDeleted(ret) = self {
1013 Some(ret)
1014 } else {
1015 None
1016 }
1017 }
1018
1019 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
1020 if let Self::ChatCmdError(ret) = self {
1021 Some(ret)
1022 } else {
1023 None
1024 }
1025 }
1026
1027 pub fn undocumented(&self) -> Option<&JsonObject> {
1028 if let Self::Undocumented(ret) = self {
1029 Some(ret)
1030 } else {
1031 None
1032 }
1033 }
1034}
1035
1036#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1037#[serde(tag = "type")]
1038#[non_exhaustive]
1039pub enum ApiGetGroupLinkResponse {
1040 #[serde(rename = "groupLink")]
1042 GroupLink(GroupLinkResponse),
1043 #[serde(rename = "chatCmdError")]
1045 ChatCmdError(ChatCmdErrorResponse),
1046 #[serde(untagged)]
1047 Undocumented(JsonObject),
1048}
1049
1050impl ApiGetGroupLinkResponse {
1051 pub fn group_link(&self) -> Option<&GroupLinkResponse> {
1052 if let Self::GroupLink(ret) = self {
1053 Some(ret)
1054 } else {
1055 None
1056 }
1057 }
1058
1059 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
1060 if let Self::ChatCmdError(ret) = self {
1061 Some(ret)
1062 } else {
1063 None
1064 }
1065 }
1066
1067 pub fn undocumented(&self) -> Option<&JsonObject> {
1068 if let Self::Undocumented(ret) = self {
1069 Some(ret)
1070 } else {
1071 None
1072 }
1073 }
1074}
1075
1076#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1077#[serde(tag = "type")]
1078#[non_exhaustive]
1079pub enum ApiAddContactResponse {
1080 #[serde(rename = "invitation")]
1082 Invitation(InvitationResponse),
1083 #[serde(rename = "chatCmdError")]
1085 ChatCmdError(ChatCmdErrorResponse),
1086 #[serde(untagged)]
1087 Undocumented(JsonObject),
1088}
1089
1090impl ApiAddContactResponse {
1091 pub fn invitation(&self) -> Option<&InvitationResponse> {
1092 if let Self::Invitation(ret) = self {
1093 Some(ret)
1094 } else {
1095 None
1096 }
1097 }
1098
1099 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
1100 if let Self::ChatCmdError(ret) = self {
1101 Some(ret)
1102 } else {
1103 None
1104 }
1105 }
1106
1107 pub fn undocumented(&self) -> Option<&JsonObject> {
1108 if let Self::Undocumented(ret) = self {
1109 Some(ret)
1110 } else {
1111 None
1112 }
1113 }
1114}
1115
1116#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1117#[serde(tag = "type")]
1118#[non_exhaustive]
1119pub enum ApiConnectPlanResponse {
1120 #[serde(rename = "connectionPlan")]
1122 ConnectionPlan(ConnectionPlanResponse),
1123 #[serde(rename = "chatCmdError")]
1125 ChatCmdError(ChatCmdErrorResponse),
1126 #[serde(untagged)]
1127 Undocumented(JsonObject),
1128}
1129
1130impl ApiConnectPlanResponse {
1131 pub fn connection_plan(&self) -> Option<&ConnectionPlanResponse> {
1132 if let Self::ConnectionPlan(ret) = self {
1133 Some(ret)
1134 } else {
1135 None
1136 }
1137 }
1138
1139 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
1140 if let Self::ChatCmdError(ret) = self {
1141 Some(ret)
1142 } else {
1143 None
1144 }
1145 }
1146
1147 pub fn undocumented(&self) -> Option<&JsonObject> {
1148 if let Self::Undocumented(ret) = self {
1149 Some(ret)
1150 } else {
1151 None
1152 }
1153 }
1154}
1155
1156#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1157#[serde(tag = "type")]
1158#[non_exhaustive]
1159pub enum ApiConnectResponse {
1160 #[serde(rename = "sentConfirmation")]
1162 SentConfirmation(SentConfirmationResponse),
1163 #[serde(rename = "contactAlreadyExists")]
1165 ContactAlreadyExists(ContactAlreadyExistsResponse),
1166 #[serde(rename = "sentInvitation")]
1168 SentInvitation(SentInvitationResponse),
1169 #[serde(rename = "chatCmdError")]
1171 ChatCmdError(ChatCmdErrorResponse),
1172 #[serde(untagged)]
1173 Undocumented(JsonObject),
1174}
1175
1176impl ApiConnectResponse {
1177 pub fn sent_confirmation(&self) -> Option<&SentConfirmationResponse> {
1178 if let Self::SentConfirmation(ret) = self {
1179 Some(ret)
1180 } else {
1181 None
1182 }
1183 }
1184
1185 pub fn contact_already_exists(&self) -> Option<&ContactAlreadyExistsResponse> {
1186 if let Self::ContactAlreadyExists(ret) = self {
1187 Some(ret)
1188 } else {
1189 None
1190 }
1191 }
1192
1193 pub fn sent_invitation(&self) -> Option<&SentInvitationResponse> {
1194 if let Self::SentInvitation(ret) = self {
1195 Some(ret)
1196 } else {
1197 None
1198 }
1199 }
1200
1201 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
1202 if let Self::ChatCmdError(ret) = self {
1203 Some(ret)
1204 } else {
1205 None
1206 }
1207 }
1208
1209 pub fn undocumented(&self) -> Option<&JsonObject> {
1210 if let Self::Undocumented(ret) = self {
1211 Some(ret)
1212 } else {
1213 None
1214 }
1215 }
1216}
1217
1218#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1219#[serde(tag = "type")]
1220#[non_exhaustive]
1221pub enum ConnectResponse {
1222 #[serde(rename = "sentConfirmation")]
1224 SentConfirmation(SentConfirmationResponse),
1225 #[serde(rename = "contactAlreadyExists")]
1227 ContactAlreadyExists(ContactAlreadyExistsResponse),
1228 #[serde(rename = "sentInvitation")]
1230 SentInvitation(SentInvitationResponse),
1231 #[serde(rename = "chatCmdError")]
1233 ChatCmdError(ChatCmdErrorResponse),
1234 #[serde(untagged)]
1235 Undocumented(JsonObject),
1236}
1237
1238impl ConnectResponse {
1239 pub fn sent_confirmation(&self) -> Option<&SentConfirmationResponse> {
1240 if let Self::SentConfirmation(ret) = self {
1241 Some(ret)
1242 } else {
1243 None
1244 }
1245 }
1246
1247 pub fn contact_already_exists(&self) -> Option<&ContactAlreadyExistsResponse> {
1248 if let Self::ContactAlreadyExists(ret) = self {
1249 Some(ret)
1250 } else {
1251 None
1252 }
1253 }
1254
1255 pub fn sent_invitation(&self) -> Option<&SentInvitationResponse> {
1256 if let Self::SentInvitation(ret) = self {
1257 Some(ret)
1258 } else {
1259 None
1260 }
1261 }
1262
1263 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
1264 if let Self::ChatCmdError(ret) = self {
1265 Some(ret)
1266 } else {
1267 None
1268 }
1269 }
1270
1271 pub fn undocumented(&self) -> Option<&JsonObject> {
1272 if let Self::Undocumented(ret) = self {
1273 Some(ret)
1274 } else {
1275 None
1276 }
1277 }
1278}
1279
1280#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1281#[serde(tag = "type")]
1282#[non_exhaustive]
1283pub enum ApiAcceptContactResponse {
1284 #[serde(rename = "acceptingContactRequest")]
1286 AcceptingContactRequest(AcceptingContactRequestResponse),
1287 #[serde(rename = "chatCmdError")]
1289 ChatCmdError(ChatCmdErrorResponse),
1290 #[serde(untagged)]
1291 Undocumented(JsonObject),
1292}
1293
1294impl ApiAcceptContactResponse {
1295 pub fn accepting_contact_request(&self) -> Option<&AcceptingContactRequestResponse> {
1296 if let Self::AcceptingContactRequest(ret) = self {
1297 Some(ret)
1298 } else {
1299 None
1300 }
1301 }
1302
1303 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
1304 if let Self::ChatCmdError(ret) = self {
1305 Some(ret)
1306 } else {
1307 None
1308 }
1309 }
1310
1311 pub fn undocumented(&self) -> Option<&JsonObject> {
1312 if let Self::Undocumented(ret) = self {
1313 Some(ret)
1314 } else {
1315 None
1316 }
1317 }
1318}
1319
1320#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1321#[serde(tag = "type")]
1322#[non_exhaustive]
1323pub enum ApiRejectContactResponse {
1324 #[serde(rename = "contactRequestRejected")]
1326 ContactRequestRejected(ContactRequestRejectedResponse),
1327 #[serde(rename = "chatCmdError")]
1329 ChatCmdError(ChatCmdErrorResponse),
1330 #[serde(untagged)]
1331 Undocumented(JsonObject),
1332}
1333
1334impl ApiRejectContactResponse {
1335 pub fn contact_request_rejected(&self) -> Option<&ContactRequestRejectedResponse> {
1336 if let Self::ContactRequestRejected(ret) = self {
1337 Some(ret)
1338 } else {
1339 None
1340 }
1341 }
1342
1343 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
1344 if let Self::ChatCmdError(ret) = self {
1345 Some(ret)
1346 } else {
1347 None
1348 }
1349 }
1350
1351 pub fn undocumented(&self) -> Option<&JsonObject> {
1352 if let Self::Undocumented(ret) = self {
1353 Some(ret)
1354 } else {
1355 None
1356 }
1357 }
1358}
1359
1360#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1361#[serde(tag = "type")]
1362#[non_exhaustive]
1363pub enum ApiListContactsResponse {
1364 #[serde(rename = "contactsList")]
1366 ContactsList(ContactsListResponse),
1367 #[serde(rename = "chatCmdError")]
1369 ChatCmdError(ChatCmdErrorResponse),
1370 #[serde(untagged)]
1371 Undocumented(JsonObject),
1372}
1373
1374impl ApiListContactsResponse {
1375 pub fn contacts_list(&self) -> Option<&ContactsListResponse> {
1376 if let Self::ContactsList(ret) = self {
1377 Some(ret)
1378 } else {
1379 None
1380 }
1381 }
1382
1383 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
1384 if let Self::ChatCmdError(ret) = self {
1385 Some(ret)
1386 } else {
1387 None
1388 }
1389 }
1390
1391 pub fn undocumented(&self) -> Option<&JsonObject> {
1392 if let Self::Undocumented(ret) = self {
1393 Some(ret)
1394 } else {
1395 None
1396 }
1397 }
1398}
1399
1400#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1401#[serde(tag = "type")]
1402#[non_exhaustive]
1403pub enum ApiListGroupsResponse {
1404 #[serde(rename = "groupsList")]
1406 GroupsList(GroupsListResponse),
1407 #[serde(rename = "chatCmdError")]
1409 ChatCmdError(ChatCmdErrorResponse),
1410 #[serde(untagged)]
1411 Undocumented(JsonObject),
1412}
1413
1414impl ApiListGroupsResponse {
1415 pub fn groups_list(&self) -> Option<&GroupsListResponse> {
1416 if let Self::GroupsList(ret) = self {
1417 Some(ret)
1418 } else {
1419 None
1420 }
1421 }
1422
1423 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
1424 if let Self::ChatCmdError(ret) = self {
1425 Some(ret)
1426 } else {
1427 None
1428 }
1429 }
1430
1431 pub fn undocumented(&self) -> Option<&JsonObject> {
1432 if let Self::Undocumented(ret) = self {
1433 Some(ret)
1434 } else {
1435 None
1436 }
1437 }
1438}
1439
1440#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1441#[serde(tag = "type")]
1442#[non_exhaustive]
1443pub enum ApiDeleteChatResponse {
1444 #[serde(rename = "contactDeleted")]
1446 ContactDeleted(ContactDeletedResponse),
1447 #[serde(rename = "contactConnectionDeleted")]
1449 ContactConnectionDeleted(ContactConnectionDeletedResponse),
1450 #[serde(rename = "groupDeletedUser")]
1452 GroupDeletedUser(GroupDeletedUserResponse),
1453 #[serde(rename = "chatCmdError")]
1455 ChatCmdError(ChatCmdErrorResponse),
1456 #[serde(untagged)]
1457 Undocumented(JsonObject),
1458}
1459
1460impl ApiDeleteChatResponse {
1461 pub fn contact_deleted(&self) -> Option<&ContactDeletedResponse> {
1462 if let Self::ContactDeleted(ret) = self {
1463 Some(ret)
1464 } else {
1465 None
1466 }
1467 }
1468
1469 pub fn contact_connection_deleted(&self) -> Option<&ContactConnectionDeletedResponse> {
1470 if let Self::ContactConnectionDeleted(ret) = self {
1471 Some(ret)
1472 } else {
1473 None
1474 }
1475 }
1476
1477 pub fn group_deleted_user(&self) -> Option<&GroupDeletedUserResponse> {
1478 if let Self::GroupDeletedUser(ret) = self {
1479 Some(ret)
1480 } else {
1481 None
1482 }
1483 }
1484
1485 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
1486 if let Self::ChatCmdError(ret) = self {
1487 Some(ret)
1488 } else {
1489 None
1490 }
1491 }
1492
1493 pub fn undocumented(&self) -> Option<&JsonObject> {
1494 if let Self::Undocumented(ret) = self {
1495 Some(ret)
1496 } else {
1497 None
1498 }
1499 }
1500}
1501
1502#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1503#[serde(tag = "type")]
1504#[non_exhaustive]
1505pub enum ShowActiveUserResponse {
1506 #[serde(rename = "activeUser")]
1508 ActiveUser(ActiveUserResponse),
1509 #[serde(rename = "chatCmdError")]
1511 ChatCmdError(ChatCmdErrorResponse),
1512 #[serde(untagged)]
1513 Undocumented(JsonObject),
1514}
1515
1516impl ShowActiveUserResponse {
1517 pub fn active_user(&self) -> Option<&ActiveUserResponse> {
1518 if let Self::ActiveUser(ret) = self {
1519 Some(ret)
1520 } else {
1521 None
1522 }
1523 }
1524
1525 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
1526 if let Self::ChatCmdError(ret) = self {
1527 Some(ret)
1528 } else {
1529 None
1530 }
1531 }
1532
1533 pub fn undocumented(&self) -> Option<&JsonObject> {
1534 if let Self::Undocumented(ret) = self {
1535 Some(ret)
1536 } else {
1537 None
1538 }
1539 }
1540}
1541
1542#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1543#[serde(tag = "type")]
1544#[non_exhaustive]
1545pub enum CreateActiveUserResponse {
1546 #[serde(rename = "activeUser")]
1548 ActiveUser(ActiveUserResponse),
1549 #[serde(rename = "chatCmdError")]
1551 ChatCmdError(ChatCmdErrorResponse),
1552 #[serde(untagged)]
1553 Undocumented(JsonObject),
1554}
1555
1556impl CreateActiveUserResponse {
1557 pub fn active_user(&self) -> Option<&ActiveUserResponse> {
1558 if let Self::ActiveUser(ret) = self {
1559 Some(ret)
1560 } else {
1561 None
1562 }
1563 }
1564
1565 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
1566 if let Self::ChatCmdError(ret) = self {
1567 Some(ret)
1568 } else {
1569 None
1570 }
1571 }
1572
1573 pub fn undocumented(&self) -> Option<&JsonObject> {
1574 if let Self::Undocumented(ret) = self {
1575 Some(ret)
1576 } else {
1577 None
1578 }
1579 }
1580}
1581
1582#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1583#[serde(tag = "type")]
1584#[non_exhaustive]
1585pub enum ListUsersResponse {
1586 #[serde(rename = "usersList")]
1588 UsersList(UsersListResponse),
1589 #[serde(rename = "chatCmdError")]
1591 ChatCmdError(ChatCmdErrorResponse),
1592 #[serde(untagged)]
1593 Undocumented(JsonObject),
1594}
1595
1596impl ListUsersResponse {
1597 pub fn users_list(&self) -> Option<&UsersListResponse> {
1598 if let Self::UsersList(ret) = self {
1599 Some(ret)
1600 } else {
1601 None
1602 }
1603 }
1604
1605 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
1606 if let Self::ChatCmdError(ret) = self {
1607 Some(ret)
1608 } else {
1609 None
1610 }
1611 }
1612
1613 pub fn undocumented(&self) -> Option<&JsonObject> {
1614 if let Self::Undocumented(ret) = self {
1615 Some(ret)
1616 } else {
1617 None
1618 }
1619 }
1620}
1621
1622#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1623#[serde(tag = "type")]
1624#[non_exhaustive]
1625pub enum ApiSetActiveUserResponse {
1626 #[serde(rename = "activeUser")]
1628 ActiveUser(ActiveUserResponse),
1629 #[serde(rename = "chatCmdError")]
1631 ChatCmdError(ChatCmdErrorResponse),
1632 #[serde(untagged)]
1633 Undocumented(JsonObject),
1634}
1635
1636impl ApiSetActiveUserResponse {
1637 pub fn active_user(&self) -> Option<&ActiveUserResponse> {
1638 if let Self::ActiveUser(ret) = self {
1639 Some(ret)
1640 } else {
1641 None
1642 }
1643 }
1644
1645 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
1646 if let Self::ChatCmdError(ret) = self {
1647 Some(ret)
1648 } else {
1649 None
1650 }
1651 }
1652
1653 pub fn undocumented(&self) -> Option<&JsonObject> {
1654 if let Self::Undocumented(ret) = self {
1655 Some(ret)
1656 } else {
1657 None
1658 }
1659 }
1660}
1661
1662#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1663#[serde(tag = "type")]
1664#[non_exhaustive]
1665pub enum ApiDeleteUserResponse {
1666 #[serde(rename = "cmdOk")]
1668 CmdOk(CmdOkResponse),
1669 #[serde(rename = "chatCmdError")]
1671 ChatCmdError(ChatCmdErrorResponse),
1672 #[serde(untagged)]
1673 Undocumented(JsonObject),
1674}
1675
1676impl ApiDeleteUserResponse {
1677 pub fn cmd_ok(&self) -> Option<&CmdOkResponse> {
1678 if let Self::CmdOk(ret) = self {
1679 Some(ret)
1680 } else {
1681 None
1682 }
1683 }
1684
1685 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
1686 if let Self::ChatCmdError(ret) = self {
1687 Some(ret)
1688 } else {
1689 None
1690 }
1691 }
1692
1693 pub fn undocumented(&self) -> Option<&JsonObject> {
1694 if let Self::Undocumented(ret) = self {
1695 Some(ret)
1696 } else {
1697 None
1698 }
1699 }
1700}
1701
1702#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1703#[serde(tag = "type")]
1704#[non_exhaustive]
1705pub enum ApiUpdateProfileResponse {
1706 #[serde(rename = "userProfileUpdated")]
1708 UserProfileUpdated(UserProfileUpdatedResponse),
1709 #[serde(rename = "userProfileNoChange")]
1711 UserProfileNoChange(UserProfileNoChangeResponse),
1712 #[serde(rename = "chatCmdError")]
1714 ChatCmdError(ChatCmdErrorResponse),
1715 #[serde(untagged)]
1716 Undocumented(JsonObject),
1717}
1718
1719impl ApiUpdateProfileResponse {
1720 pub fn user_profile_updated(&self) -> Option<&UserProfileUpdatedResponse> {
1721 if let Self::UserProfileUpdated(ret) = self {
1722 Some(ret)
1723 } else {
1724 None
1725 }
1726 }
1727
1728 pub fn user_profile_no_change(&self) -> Option<&UserProfileNoChangeResponse> {
1729 if let Self::UserProfileNoChange(ret) = self {
1730 Some(ret)
1731 } else {
1732 None
1733 }
1734 }
1735
1736 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
1737 if let Self::ChatCmdError(ret) = self {
1738 Some(ret)
1739 } else {
1740 None
1741 }
1742 }
1743
1744 pub fn undocumented(&self) -> Option<&JsonObject> {
1745 if let Self::Undocumented(ret) = self {
1746 Some(ret)
1747 } else {
1748 None
1749 }
1750 }
1751}
1752
1753#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1754#[serde(tag = "type")]
1755#[non_exhaustive]
1756pub enum ApiSetContactPrefsResponse {
1757 #[serde(rename = "contactPrefsUpdated")]
1759 ContactPrefsUpdated(ContactPrefsUpdatedResponse),
1760 #[serde(rename = "chatCmdError")]
1762 ChatCmdError(ChatCmdErrorResponse),
1763 #[serde(untagged)]
1764 Undocumented(JsonObject),
1765}
1766
1767impl ApiSetContactPrefsResponse {
1768 pub fn contact_prefs_updated(&self) -> Option<&ContactPrefsUpdatedResponse> {
1769 if let Self::ContactPrefsUpdated(ret) = self {
1770 Some(ret)
1771 } else {
1772 None
1773 }
1774 }
1775
1776 pub fn chat_cmd_error(&self) -> Option<&ChatCmdErrorResponse> {
1777 if let Self::ChatCmdError(ret) = self {
1778 Some(ret)
1779 } else {
1780 None
1781 }
1782 }
1783
1784 pub fn undocumented(&self) -> Option<&JsonObject> {
1785 if let Self::Undocumented(ret) = self {
1786 Some(ret)
1787 } else {
1788 None
1789 }
1790 }
1791}
1792
1793#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1794#[cfg_attr(feature = "bon", derive(::bon::Builder))]
1795#[cfg_attr(feature = "bon", builder(on(String, into)))]
1796pub struct AcceptingContactRequestResponse {
1797 #[serde(rename = "user")]
1798 pub user: User,
1799
1800 #[serde(rename = "contact")]
1801 pub contact: Contact,
1802
1803 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
1804 #[cfg_attr(feature = "bon", builder(default))]
1805 pub undocumented: HashMap<String, JsonObject>,
1806}
1807
1808#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1809#[cfg_attr(feature = "bon", derive(::bon::Builder))]
1810#[cfg_attr(feature = "bon", builder(on(String, into)))]
1811pub struct ActiveUserResponse {
1812 #[serde(rename = "user")]
1813 pub user: User,
1814
1815 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
1816 #[cfg_attr(feature = "bon", builder(default))]
1817 pub undocumented: HashMap<String, JsonObject>,
1818}
1819
1820#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1821#[cfg_attr(feature = "bon", derive(::bon::Builder))]
1822#[cfg_attr(feature = "bon", builder(on(String, into)))]
1823pub struct ChatCmdErrorResponse {
1824 #[serde(rename = "chatError")]
1825 pub chat_error: ChatError,
1826
1827 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
1828 #[cfg_attr(feature = "bon", builder(default))]
1829 pub undocumented: HashMap<String, JsonObject>,
1830}
1831
1832#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1833#[cfg_attr(feature = "bon", derive(::bon::Builder))]
1834#[cfg_attr(feature = "bon", builder(on(String, into)))]
1835pub struct ChatItemNotChangedResponse {
1836 #[serde(rename = "user")]
1837 pub user: User,
1838
1839 #[serde(rename = "chatItem")]
1840 pub chat_item: AChatItem,
1841
1842 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
1843 #[cfg_attr(feature = "bon", builder(default))]
1844 pub undocumented: HashMap<String, JsonObject>,
1845}
1846
1847#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1848#[cfg_attr(feature = "bon", derive(::bon::Builder))]
1849#[cfg_attr(feature = "bon", builder(on(String, into)))]
1850pub struct ChatItemReactionResponse {
1851 #[serde(rename = "user")]
1852 pub user: User,
1853
1854 #[serde(rename = "added")]
1855 pub added: bool,
1856
1857 #[serde(rename = "reaction")]
1858 pub reaction: ACIReaction,
1859
1860 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
1861 #[cfg_attr(feature = "bon", builder(default))]
1862 pub undocumented: HashMap<String, JsonObject>,
1863}
1864
1865#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1866#[cfg_attr(feature = "bon", derive(::bon::Builder))]
1867#[cfg_attr(feature = "bon", builder(on(String, into)))]
1868pub struct ChatItemUpdatedResponse {
1869 #[serde(rename = "user")]
1870 pub user: User,
1871
1872 #[serde(rename = "chatItem")]
1873 pub chat_item: AChatItem,
1874
1875 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
1876 #[cfg_attr(feature = "bon", builder(default))]
1877 pub undocumented: HashMap<String, JsonObject>,
1878}
1879
1880#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1881#[cfg_attr(feature = "bon", derive(::bon::Builder))]
1882#[cfg_attr(feature = "bon", builder(on(String, into)))]
1883pub struct ChatItemsDeletedResponse {
1884 #[serde(rename = "user")]
1885 pub user: User,
1886
1887 #[serde(rename = "chatItemDeletions")]
1888 pub chat_item_deletions: Vec<ChatItemDeletion>,
1889
1890 #[serde(rename = "byUser")]
1891 pub by_user: bool,
1892
1893 #[serde(rename = "timed")]
1894 pub timed: bool,
1895
1896 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
1897 #[cfg_attr(feature = "bon", builder(default))]
1898 pub undocumented: HashMap<String, JsonObject>,
1899}
1900
1901#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1902#[cfg_attr(feature = "bon", derive(::bon::Builder))]
1903#[cfg_attr(feature = "bon", builder(on(String, into)))]
1904pub struct CmdOkResponse {
1905 #[serde(rename = "user_", skip_serializing_if = "Option::is_none")]
1906 pub user: Option<User>,
1907
1908 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
1909 #[cfg_attr(feature = "bon", builder(default))]
1910 pub undocumented: HashMap<String, JsonObject>,
1911}
1912
1913#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1914#[cfg_attr(feature = "bon", derive(::bon::Builder))]
1915#[cfg_attr(feature = "bon", builder(on(String, into)))]
1916pub struct ConnectionPlanResponse {
1917 #[serde(rename = "user")]
1918 pub user: User,
1919
1920 #[serde(rename = "connLink")]
1921 pub conn_link: CreatedConnLink,
1922
1923 #[serde(rename = "connectionPlan")]
1924 pub connection_plan: ConnectionPlan,
1925
1926 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
1927 #[cfg_attr(feature = "bon", builder(default))]
1928 pub undocumented: HashMap<String, JsonObject>,
1929}
1930
1931#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1932#[cfg_attr(feature = "bon", derive(::bon::Builder))]
1933#[cfg_attr(feature = "bon", builder(on(String, into)))]
1934pub struct ContactAlreadyExistsResponse {
1935 #[serde(rename = "user")]
1936 pub user: User,
1937
1938 #[serde(rename = "contact")]
1939 pub contact: Contact,
1940
1941 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
1942 #[cfg_attr(feature = "bon", builder(default))]
1943 pub undocumented: HashMap<String, JsonObject>,
1944}
1945
1946#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1947#[cfg_attr(feature = "bon", derive(::bon::Builder))]
1948#[cfg_attr(feature = "bon", builder(on(String, into)))]
1949pub struct ContactConnectionDeletedResponse {
1950 #[serde(rename = "user")]
1951 pub user: User,
1952
1953 #[serde(rename = "connection")]
1954 pub connection: PendingContactConnection,
1955
1956 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
1957 #[cfg_attr(feature = "bon", builder(default))]
1958 pub undocumented: HashMap<String, JsonObject>,
1959}
1960
1961#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1962#[cfg_attr(feature = "bon", derive(::bon::Builder))]
1963#[cfg_attr(feature = "bon", builder(on(String, into)))]
1964pub struct ContactDeletedResponse {
1965 #[serde(rename = "user")]
1966 pub user: User,
1967
1968 #[serde(rename = "contact")]
1969 pub contact: Contact,
1970
1971 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
1972 #[cfg_attr(feature = "bon", builder(default))]
1973 pub undocumented: HashMap<String, JsonObject>,
1974}
1975
1976#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1977#[cfg_attr(feature = "bon", derive(::bon::Builder))]
1978#[cfg_attr(feature = "bon", builder(on(String, into)))]
1979pub struct ContactPrefsUpdatedResponse {
1980 #[serde(rename = "user")]
1981 pub user: User,
1982
1983 #[serde(rename = "fromContact")]
1984 pub from_contact: Contact,
1985
1986 #[serde(rename = "toContact")]
1987 pub to_contact: Contact,
1988
1989 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
1990 #[cfg_attr(feature = "bon", builder(default))]
1991 pub undocumented: HashMap<String, JsonObject>,
1992}
1993
1994#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1995#[cfg_attr(feature = "bon", derive(::bon::Builder))]
1996#[cfg_attr(feature = "bon", builder(on(String, into)))]
1997pub struct ContactRequestRejectedResponse {
1998 #[serde(rename = "user")]
1999 pub user: User,
2000
2001 #[serde(rename = "contactRequest")]
2002 pub contact_request: UserContactRequest,
2003
2004 #[serde(rename = "contact_", skip_serializing_if = "Option::is_none")]
2005 pub contact: Option<Contact>,
2006
2007 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
2008 #[cfg_attr(feature = "bon", builder(default))]
2009 pub undocumented: HashMap<String, JsonObject>,
2010}
2011
2012#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2013#[cfg_attr(feature = "bon", derive(::bon::Builder))]
2014#[cfg_attr(feature = "bon", builder(on(String, into)))]
2015pub struct ContactsListResponse {
2016 #[serde(rename = "user")]
2017 pub user: User,
2018
2019 #[serde(rename = "contacts")]
2020 pub contacts: Vec<Contact>,
2021
2022 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
2023 #[cfg_attr(feature = "bon", builder(default))]
2024 pub undocumented: HashMap<String, JsonObject>,
2025}
2026
2027#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2028#[cfg_attr(feature = "bon", derive(::bon::Builder))]
2029#[cfg_attr(feature = "bon", builder(on(String, into)))]
2030pub struct GroupCreatedResponse {
2031 #[serde(rename = "user")]
2032 pub user: User,
2033
2034 #[serde(rename = "groupInfo")]
2035 pub group_info: GroupInfo,
2036
2037 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
2038 #[cfg_attr(feature = "bon", builder(default))]
2039 pub undocumented: HashMap<String, JsonObject>,
2040}
2041
2042#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2043#[cfg_attr(feature = "bon", derive(::bon::Builder))]
2044#[cfg_attr(feature = "bon", builder(on(String, into)))]
2045pub struct GroupDeletedUserResponse {
2046 #[serde(rename = "user")]
2047 pub user: User,
2048
2049 #[serde(rename = "groupInfo")]
2050 pub group_info: GroupInfo,
2051
2052 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
2053 #[cfg_attr(feature = "bon", builder(default))]
2054 pub undocumented: HashMap<String, JsonObject>,
2055}
2056
2057#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2058#[cfg_attr(feature = "bon", derive(::bon::Builder))]
2059#[cfg_attr(feature = "bon", builder(on(String, into)))]
2060pub struct GroupLinkCreatedResponse {
2061 #[serde(rename = "user")]
2062 pub user: User,
2063
2064 #[serde(rename = "groupInfo")]
2065 pub group_info: GroupInfo,
2066
2067 #[serde(rename = "groupLink")]
2068 pub group_link: GroupLink,
2069
2070 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
2071 #[cfg_attr(feature = "bon", builder(default))]
2072 pub undocumented: HashMap<String, JsonObject>,
2073}
2074
2075#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2076#[cfg_attr(feature = "bon", derive(::bon::Builder))]
2077#[cfg_attr(feature = "bon", builder(on(String, into)))]
2078pub struct GroupLinkDeletedResponse {
2079 #[serde(rename = "user")]
2080 pub user: User,
2081
2082 #[serde(rename = "groupInfo")]
2083 pub group_info: GroupInfo,
2084
2085 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
2086 #[cfg_attr(feature = "bon", builder(default))]
2087 pub undocumented: HashMap<String, JsonObject>,
2088}
2089
2090#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2091#[cfg_attr(feature = "bon", derive(::bon::Builder))]
2092#[cfg_attr(feature = "bon", builder(on(String, into)))]
2093pub struct GroupLinkResponse {
2094 #[serde(rename = "user")]
2095 pub user: User,
2096
2097 #[serde(rename = "groupInfo")]
2098 pub group_info: GroupInfo,
2099
2100 #[serde(rename = "groupLink")]
2101 pub group_link: GroupLink,
2102
2103 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
2104 #[cfg_attr(feature = "bon", builder(default))]
2105 pub undocumented: HashMap<String, JsonObject>,
2106}
2107
2108#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2109#[cfg_attr(feature = "bon", derive(::bon::Builder))]
2110#[cfg_attr(feature = "bon", builder(on(String, into)))]
2111pub struct GroupMembersResponse {
2112 #[serde(rename = "user")]
2113 pub user: User,
2114
2115 #[serde(rename = "group")]
2116 pub group: Group,
2117
2118 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
2119 #[cfg_attr(feature = "bon", builder(default))]
2120 pub undocumented: HashMap<String, JsonObject>,
2121}
2122
2123#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2124#[cfg_attr(feature = "bon", derive(::bon::Builder))]
2125#[cfg_attr(feature = "bon", builder(on(String, into)))]
2126pub struct GroupUpdatedResponse {
2127 #[serde(rename = "user")]
2128 pub user: User,
2129
2130 #[serde(rename = "fromGroup")]
2131 pub from_group: GroupInfo,
2132
2133 #[serde(rename = "toGroup")]
2134 pub to_group: GroupInfo,
2135
2136 #[serde(rename = "member_", skip_serializing_if = "Option::is_none")]
2137 pub member: Option<GroupMember>,
2138
2139 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
2140 #[cfg_attr(feature = "bon", builder(default))]
2141 pub undocumented: HashMap<String, JsonObject>,
2142}
2143
2144#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2145#[cfg_attr(feature = "bon", derive(::bon::Builder))]
2146#[cfg_attr(feature = "bon", builder(on(String, into)))]
2147pub struct GroupsListResponse {
2148 #[serde(rename = "user")]
2149 pub user: User,
2150
2151 #[serde(rename = "groups")]
2152 pub groups: Vec<GroupInfoSummary>,
2153
2154 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
2155 #[cfg_attr(feature = "bon", builder(default))]
2156 pub undocumented: HashMap<String, JsonObject>,
2157}
2158
2159#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2160#[cfg_attr(feature = "bon", derive(::bon::Builder))]
2161#[cfg_attr(feature = "bon", builder(on(String, into)))]
2162pub struct InvitationResponse {
2163 #[serde(rename = "user")]
2164 pub user: User,
2165
2166 #[serde(rename = "connLinkInvitation")]
2167 pub conn_link_invitation: CreatedConnLink,
2168
2169 #[serde(rename = "connection")]
2170 pub connection: PendingContactConnection,
2171
2172 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
2173 #[cfg_attr(feature = "bon", builder(default))]
2174 pub undocumented: HashMap<String, JsonObject>,
2175}
2176
2177#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2178#[cfg_attr(feature = "bon", derive(::bon::Builder))]
2179#[cfg_attr(feature = "bon", builder(on(String, into)))]
2180pub struct LeftMemberUserResponse {
2181 #[serde(rename = "user")]
2182 pub user: User,
2183
2184 #[serde(rename = "groupInfo")]
2185 pub group_info: GroupInfo,
2186
2187 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
2188 #[cfg_attr(feature = "bon", builder(default))]
2189 pub undocumented: HashMap<String, JsonObject>,
2190}
2191
2192#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2193#[cfg_attr(feature = "bon", derive(::bon::Builder))]
2194#[cfg_attr(feature = "bon", builder(on(String, into)))]
2195pub struct MemberAcceptedResponse {
2196 #[serde(rename = "user")]
2197 pub user: User,
2198
2199 #[serde(rename = "groupInfo")]
2200 pub group_info: GroupInfo,
2201
2202 #[serde(rename = "member")]
2203 pub member: GroupMember,
2204
2205 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
2206 #[cfg_attr(feature = "bon", builder(default))]
2207 pub undocumented: HashMap<String, JsonObject>,
2208}
2209
2210#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2211#[cfg_attr(feature = "bon", derive(::bon::Builder))]
2212#[cfg_attr(feature = "bon", builder(on(String, into)))]
2213pub struct MembersBlockedForAllUserResponse {
2214 #[serde(rename = "user")]
2215 pub user: User,
2216
2217 #[serde(rename = "groupInfo")]
2218 pub group_info: GroupInfo,
2219
2220 #[serde(rename = "members")]
2221 pub members: Vec<GroupMember>,
2222
2223 #[serde(rename = "blocked")]
2224 pub blocked: bool,
2225
2226 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
2227 #[cfg_attr(feature = "bon", builder(default))]
2228 pub undocumented: HashMap<String, JsonObject>,
2229}
2230
2231#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2232#[cfg_attr(feature = "bon", derive(::bon::Builder))]
2233#[cfg_attr(feature = "bon", builder(on(String, into)))]
2234pub struct MembersRoleUserResponse {
2235 #[serde(rename = "user")]
2236 pub user: User,
2237
2238 #[serde(rename = "groupInfo")]
2239 pub group_info: GroupInfo,
2240
2241 #[serde(rename = "members")]
2242 pub members: Vec<GroupMember>,
2243
2244 #[serde(rename = "toRole")]
2245 pub to_role: GroupMemberRole,
2246
2247 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
2248 #[cfg_attr(feature = "bon", builder(default))]
2249 pub undocumented: HashMap<String, JsonObject>,
2250}
2251
2252#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2253#[cfg_attr(feature = "bon", derive(::bon::Builder))]
2254#[cfg_attr(feature = "bon", builder(on(String, into)))]
2255pub struct NewChatItemsResponse {
2256 #[serde(rename = "user")]
2257 pub user: User,
2258
2259 #[serde(rename = "chatItems")]
2260 pub chat_items: Vec<AChatItem>,
2261
2262 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
2263 #[cfg_attr(feature = "bon", builder(default))]
2264 pub undocumented: HashMap<String, JsonObject>,
2265}
2266
2267#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2268#[cfg_attr(feature = "bon", derive(::bon::Builder))]
2269#[cfg_attr(feature = "bon", builder(on(String, into)))]
2270pub struct RcvFileAcceptedResponse {
2271 #[serde(rename = "user")]
2272 pub user: User,
2273
2274 #[serde(rename = "chatItem")]
2275 pub chat_item: AChatItem,
2276
2277 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
2278 #[cfg_attr(feature = "bon", builder(default))]
2279 pub undocumented: HashMap<String, JsonObject>,
2280}
2281
2282#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2283#[cfg_attr(feature = "bon", derive(::bon::Builder))]
2284#[cfg_attr(feature = "bon", builder(on(String, into)))]
2285pub struct RcvFileAcceptedSndCancelledResponse {
2286 #[serde(rename = "user")]
2287 pub user: User,
2288
2289 #[serde(rename = "rcvFileTransfer")]
2290 pub rcv_file_transfer: RcvFileTransfer,
2291
2292 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
2293 #[cfg_attr(feature = "bon", builder(default))]
2294 pub undocumented: HashMap<String, JsonObject>,
2295}
2296
2297#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2298#[cfg_attr(feature = "bon", derive(::bon::Builder))]
2299#[cfg_attr(feature = "bon", builder(on(String, into)))]
2300pub struct RcvFileCancelledResponse {
2301 #[serde(rename = "user")]
2302 pub user: User,
2303
2304 #[serde(rename = "chatItem_", skip_serializing_if = "Option::is_none")]
2305 pub chat_item: Option<AChatItem>,
2306
2307 #[serde(rename = "rcvFileTransfer")]
2308 pub rcv_file_transfer: RcvFileTransfer,
2309
2310 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
2311 #[cfg_attr(feature = "bon", builder(default))]
2312 pub undocumented: HashMap<String, JsonObject>,
2313}
2314
2315#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2316#[cfg_attr(feature = "bon", derive(::bon::Builder))]
2317#[cfg_attr(feature = "bon", builder(on(String, into)))]
2318pub struct SentConfirmationResponse {
2319 #[serde(rename = "user")]
2320 pub user: User,
2321
2322 #[serde(rename = "connection")]
2323 pub connection: PendingContactConnection,
2324
2325 #[serde(rename = "customUserProfile", skip_serializing_if = "Option::is_none")]
2326 pub custom_user_profile: Option<Profile>,
2327
2328 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
2329 #[cfg_attr(feature = "bon", builder(default))]
2330 pub undocumented: HashMap<String, JsonObject>,
2331}
2332
2333#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2334#[cfg_attr(feature = "bon", derive(::bon::Builder))]
2335#[cfg_attr(feature = "bon", builder(on(String, into)))]
2336pub struct SentGroupInvitationResponse {
2337 #[serde(rename = "user")]
2338 pub user: User,
2339
2340 #[serde(rename = "groupInfo")]
2341 pub group_info: GroupInfo,
2342
2343 #[serde(rename = "contact")]
2344 pub contact: Contact,
2345
2346 #[serde(rename = "member")]
2347 pub member: GroupMember,
2348
2349 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
2350 #[cfg_attr(feature = "bon", builder(default))]
2351 pub undocumented: HashMap<String, JsonObject>,
2352}
2353
2354#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2355#[cfg_attr(feature = "bon", derive(::bon::Builder))]
2356#[cfg_attr(feature = "bon", builder(on(String, into)))]
2357pub struct SentInvitationResponse {
2358 #[serde(rename = "user")]
2359 pub user: User,
2360
2361 #[serde(rename = "connection")]
2362 pub connection: PendingContactConnection,
2363
2364 #[serde(rename = "customUserProfile", skip_serializing_if = "Option::is_none")]
2365 pub custom_user_profile: Option<Profile>,
2366
2367 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
2368 #[cfg_attr(feature = "bon", builder(default))]
2369 pub undocumented: HashMap<String, JsonObject>,
2370}
2371
2372#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2373#[cfg_attr(feature = "bon", derive(::bon::Builder))]
2374#[cfg_attr(feature = "bon", builder(on(String, into)))]
2375pub struct SndFileCancelledResponse {
2376 #[serde(rename = "user")]
2377 pub user: User,
2378
2379 #[serde(rename = "chatItem_", skip_serializing_if = "Option::is_none")]
2380 pub chat_item: Option<AChatItem>,
2381
2382 #[serde(rename = "fileTransferMeta")]
2383 pub file_transfer_meta: FileTransferMeta,
2384
2385 #[serde(rename = "sndFileTransfers")]
2386 pub snd_file_transfers: Vec<SndFileTransfer>,
2387
2388 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
2389 #[cfg_attr(feature = "bon", builder(default))]
2390 pub undocumented: HashMap<String, JsonObject>,
2391}
2392
2393#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2394#[cfg_attr(feature = "bon", derive(::bon::Builder))]
2395#[cfg_attr(feature = "bon", builder(on(String, into)))]
2396pub struct UserAcceptedGroupSentResponse {
2397 #[serde(rename = "user")]
2398 pub user: User,
2399
2400 #[serde(rename = "groupInfo")]
2401 pub group_info: GroupInfo,
2402
2403 #[serde(rename = "hostContact", skip_serializing_if = "Option::is_none")]
2404 pub host_contact: Option<Contact>,
2405
2406 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
2407 #[cfg_attr(feature = "bon", builder(default))]
2408 pub undocumented: HashMap<String, JsonObject>,
2409}
2410
2411#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2412#[cfg_attr(feature = "bon", derive(::bon::Builder))]
2413#[cfg_attr(feature = "bon", builder(on(String, into)))]
2414pub struct UserContactLinkCreatedResponse {
2415 #[serde(rename = "user")]
2416 pub user: User,
2417
2418 #[serde(rename = "connLinkContact")]
2419 pub conn_link_contact: CreatedConnLink,
2420
2421 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
2422 #[cfg_attr(feature = "bon", builder(default))]
2423 pub undocumented: HashMap<String, JsonObject>,
2424}
2425
2426#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2427#[cfg_attr(feature = "bon", derive(::bon::Builder))]
2428#[cfg_attr(feature = "bon", builder(on(String, into)))]
2429pub struct UserContactLinkDeletedResponse {
2430 #[serde(rename = "user")]
2431 pub user: User,
2432
2433 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
2434 #[cfg_attr(feature = "bon", builder(default))]
2435 pub undocumented: HashMap<String, JsonObject>,
2436}
2437
2438#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2439#[cfg_attr(feature = "bon", derive(::bon::Builder))]
2440#[cfg_attr(feature = "bon", builder(on(String, into)))]
2441pub struct UserContactLinkResponse {
2442 #[serde(rename = "user")]
2443 pub user: User,
2444
2445 #[serde(rename = "contactLink")]
2446 pub contact_link: UserContactLink,
2447
2448 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
2449 #[cfg_attr(feature = "bon", builder(default))]
2450 pub undocumented: HashMap<String, JsonObject>,
2451}
2452
2453#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2454#[cfg_attr(feature = "bon", derive(::bon::Builder))]
2455#[cfg_attr(feature = "bon", builder(on(String, into)))]
2456pub struct UserContactLinkUpdatedResponse {
2457 #[serde(rename = "user")]
2458 pub user: User,
2459
2460 #[serde(rename = "contactLink")]
2461 pub contact_link: UserContactLink,
2462
2463 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
2464 #[cfg_attr(feature = "bon", builder(default))]
2465 pub undocumented: HashMap<String, JsonObject>,
2466}
2467
2468#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2469#[cfg_attr(feature = "bon", derive(::bon::Builder))]
2470#[cfg_attr(feature = "bon", builder(on(String, into)))]
2471pub struct UserDeletedMembersResponse {
2472 #[serde(rename = "user")]
2473 pub user: User,
2474
2475 #[serde(rename = "groupInfo")]
2476 pub group_info: GroupInfo,
2477
2478 #[serde(rename = "members")]
2479 pub members: Vec<GroupMember>,
2480
2481 #[serde(rename = "withMessages")]
2482 pub with_messages: bool,
2483
2484 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
2485 #[cfg_attr(feature = "bon", builder(default))]
2486 pub undocumented: HashMap<String, JsonObject>,
2487}
2488
2489#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2490#[cfg_attr(feature = "bon", derive(::bon::Builder))]
2491#[cfg_attr(feature = "bon", builder(on(String, into)))]
2492pub struct UserProfileNoChangeResponse {
2493 #[serde(rename = "user")]
2494 pub user: User,
2495
2496 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
2497 #[cfg_attr(feature = "bon", builder(default))]
2498 pub undocumented: HashMap<String, JsonObject>,
2499}
2500
2501#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2502#[cfg_attr(feature = "bon", derive(::bon::Builder))]
2503#[cfg_attr(feature = "bon", builder(on(String, into)))]
2504pub struct UserProfileUpdatedResponse {
2505 #[serde(rename = "user")]
2506 pub user: User,
2507
2508 #[serde(rename = "fromProfile")]
2509 pub from_profile: Profile,
2510
2511 #[serde(rename = "toProfile")]
2512 pub to_profile: Profile,
2513
2514 #[serde(rename = "updateSummary")]
2515 pub update_summary: UserProfileUpdateSummary,
2516
2517 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
2518 #[cfg_attr(feature = "bon", builder(default))]
2519 pub undocumented: HashMap<String, JsonObject>,
2520}
2521
2522#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
2523#[cfg_attr(feature = "bon", derive(::bon::Builder))]
2524#[cfg_attr(feature = "bon", builder(on(String, into)))]
2525pub struct UsersListResponse {
2526 #[serde(rename = "users")]
2527 pub users: Vec<UserInfo>,
2528
2529 #[serde(flatten, skip_serializing_if = "HashMap::is_empty")]
2530 #[cfg_attr(feature = "bon", builder(default))]
2531 pub undocumented: HashMap<String, JsonObject>,
2532}