discord-ferris 0.0.2

discord-ferris is a Discord API Rust library under development 🦀
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
use super::channel::RESTPutAPIChannelPermissionJSONBody;
use super::common::Locale;
use crate::models::payloads::{
    APIBan, APIChannel, APIExtendedInvite, APIGuild, APIGuildIntegration, APIGuildMember,
    APIGuildMembershipScreening, APIGuildOnboarding, APIGuildOnboardingPromptOption,
    APIGuildPreview, APIGuildWelcomeScreen, APIGuildWidget, APIGuildWidgetSettings, APIRole,
    APIRoleColors, APIThreadList, APIVoiceRegion, GuildDefaultMessageNotifications,
    GuildExplicitContentFilter, GuildFeature, GuildMFALevel, GuildSystemChannelFlags,
    GuildVerificationLevel, GuildWidgetStyle,
};
use serde::{Deserialize, Serialize};
use serde_json::Value;

#[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Eq, Hash)]
#[serde(untagged)]
pub enum NumberOrString {
    Number(u64),
    String(String),
}

#[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Eq, Hash)]
#[serde(untagged)]
pub enum SnowflakeOrNumber {
    String(String),
    Number(u64),
}

pub type RESTAPIGuildChannelResolvable = APIChannel;

/**
 * @deprecated Use {@link RESTAPIGuildChannelResolvable} instead
 */
#[deprecated(note = "Use RESTAPIGuildChannelResolvable instead")]
pub type APIGuildChannelResolvable = RESTAPIGuildChannelResolvable;

#[derive(Debug, Clone, Serialize, Deserialize, PartialEq)]
pub struct RESTAPIGuildCreateOverwrite {
    pub id: NumberOrString,
    #[serde(flatten)]
    pub perms: RESTPutAPIChannelPermissionJSONBody,
}

/**
 * @deprecated Use {@link RESTAPIGuildCreateOverwrite} instead
 */
#[deprecated(note = "Use RESTAPIGuildCreateOverwrite instead")]
pub type APIGuildCreateOverwrite = RESTAPIGuildCreateOverwrite;

#[derive(Debug, Clone, Serialize, Deserialize, PartialEq)]
pub struct RESTAPIGuildCreatePartialChannel {
    pub name: String,
    pub id: Option<NumberOrString>,
    pub parent_id: Option<Option<NumberOrString>>,
    pub permission_overwrites: Option<Vec<RESTAPIGuildCreateOverwrite>>,

    // Pick<
    //  RESTAPIGuildChannelResolvable,
    //  'available_tags' | 'bitrate' | 'default_auto_archive_duration' | 'default_forum_layout'
    //  | 'default_reaction_emoji' | 'default_sort_order' | 'default_thread_rate_limit_per_user'
    //  | 'flags' | 'nsfw' | 'position' | 'rate_limit_per_user' | 'rtc_region' | 'topic' | 'type'
    //  | 'user_limit' | 'video_quality_mode'
    // >
    #[serde(skip_serializing_if = "Option::is_none")]
    pub available_tags: Option<Vec<APIGuildOnboardingPromptOption>>, // placeholder: tags type lives under payloads (APIGuildForumTag). Use your actual type here if named differently.
    #[serde(skip_serializing_if = "Option::is_none")]
    pub bitrate: Option<u32>,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub default_auto_archive_duration: Option<u16>,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub default_forum_layout: Option<u8>,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub default_reaction_emoji: Option<Value>,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub default_sort_order: Option<u8>,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub default_thread_rate_limit_per_user: Option<u64>,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub flags: Option<u64>,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub nsfw: Option<bool>,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub position: Option<i32>,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub rate_limit_per_user: Option<u64>,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub rtc_region: Option<String>,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub topic: Option<String>,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub r#type: Option<u8>,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub user_limit: Option<u16>,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub video_quality_mode: Option<u8>,
}

/**
 * @deprecated Use {@link RESTAPIGuildCreatePartialChannel} instead
 */
#[deprecated(note = "Use RESTAPIGuildCreatePartialChannel instead")]
pub type APIGuildCreatePartialChannel = RESTAPIGuildCreatePartialChannel;

#[derive(Debug, Clone, Serialize, Deserialize, PartialEq)]
pub struct RESTAPIGuildCreateRole {
    pub id: NumberOrString,

    // Extends RESTPostAPIGuildRoleJSONBody
    /**
     * Name of the role
     *
     * @defaultValue `"new role"`
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub name: Option<Option<String>>,
    /**
     * Bitwise value of the enabled/disabled permissions
     *
     * @defaultValue
     * Default role permissions in guild
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub permissions: Option<Option<String>>,
    /**
     * RGB color value
     *
     * @defaultValue `0`
     * @remarks `color` will still be returned by the API, but using the `colors` field is recommended when doing requests.
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub color: Option<Option<u32>>,
    /**
     * The role's colors
     *
     * @defaultValue `{ "primary_color": 0, "secondary_color": null, "tertiary_color": null }`
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub colors: Option<APIRoleColors>,
    /**
     * Whether the role should be displayed separately in the sidebar
     *
     * @defaultValue `false`
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub hoist: Option<Option<bool>>,
    /**
     * The role's icon image (if the guild has the `ROLE_ICONS` feature)
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub icon: Option<Option<String>>,
    /**
     * The role's unicode emoji as a standard emoji (if the guild has the `ROLE_ICONS` feature)
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub unicode_emoji: Option<Option<String>>,
    /**
     * Whether the role should be mentionable
     *
     * @defaultValue `false`
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub mentionable: Option<Option<bool>>,
}

/**
 * @deprecated Use {@link RESTAPIGuildCreateRole} instead
 */
#[deprecated(note = "Use RESTAPIGuildCreateRole instead")]
pub type APIGuildCreateRole = RESTAPIGuildCreateRole;

/**
 * @see {@link https://discord.com/developers/docs/change-log#guild-create-deprecation}
 * @deprecated
 */
#[derive(Debug, Clone, Serialize, Deserialize, PartialEq)]
pub struct RESTPostAPIGuildsJSONBody {
    /**
     * Name of the guild (2-100 characters)
     */
    pub name: String,
    /**
     * Voice region id
     *
     * @see {@link https://discord.com/developers/docs/resources/voice#voice-region-object}
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub region: Option<String>,
    /**
     * base64 1024x1024 png/jpeg image for the guild icon
     *
     * @see {@link https://discord.com/developers/docs/reference#image-data}
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub icon: Option<String>,
    /**
     * Verification level
     *
     * @see {@link https://discord.com/developers/docs/resources/guild#guild-object-verification-level}
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub verification_level: Option<GuildVerificationLevel>,
    /**
     * Default message notification level
     *
     * @see {@link https://discord.com/developers/docs/resources/guild#guild-object-default-message-notification-level}
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub default_message_notifications: Option<GuildDefaultMessageNotifications>,
    /**
     * Explicit content filter level
     *
     * @see {@link https://discord.com/developers/docs/resources/guild#guild-object-explicit-content-filter-level}
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub explicit_content_filter: Option<GuildExplicitContentFilter>,
    /**
     * New guild roles
     *
     * @remarks
     * When using this parameter, the first member of the array is used to change properties of the guild's `@everyone` role.
     * If you are trying to bootstrap a guild with additional roles, keep this in mind.
     *
     * Also, the required `id` field within each role object is an integer placeholder,
     * and will be replaced by the API upon consumption. Its purpose is to allow you to overwrite a role's permissions
     * in a channel when also passing in channels with the channels array.
     * @see {@link https://discord.com/developers/docs/topics/permissions#role-object}
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub roles: Option<Vec<RESTAPIGuildCreateRole>>,
    /**
     * New guild's channels
     *
     * @remarks
     * When using the channels parameter, the `position` field is ignored, and none of the default channels are created.
     *
     * Also, the `id` field within each channel object may be set to an integer placeholder,
     * and will be replaced by the API upon consumption. Its purpose is to allow you to create `GUILD_CATEGORY` channels
     * by setting the `parent_id` field on any children to the category's id field.
     * Category channels must be listed before any children.
     * @see {@link https://discord.com/developers/docs/resources/channel#channel-object}
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub channels: Option<Vec<RESTAPIGuildCreatePartialChannel>>,
    /**
     * ID for afk channel
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub afk_channel_id: Option<Option<SnowflakeOrNumber>>,
    /**
     * afk timeout in seconds, can be set to: `60`, `300`, `900`, `1800`, `3600`
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub afk_timeout: Option<u32>,
    /**
     * The id of the channel where guild notices such as welcome messages and boost events are posted
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub system_channel_id: Option<Option<SnowflakeOrNumber>>,
    /**
     * System channel flags
     *
     * @see {@link https://discord.com/developers/docs/resources/guild#guild-object-system-channel-flags}
     */
    #[serde(with = "crate::utils::serde::flags_numeric")]
    // #[serde(with = "crate::utils::serde::flags_numeric")]
    pub system_channel_flags: GuildSystemChannelFlags,
    /**
     * Whether the boosts progress bar should be enabled.
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub premium_progress_bar_enabled: Option<bool>,
}

/**
 * @see {@link https://discord.com/developers/docs/change-log#guild-create-deprecation}
 * @deprecated
 */
pub type RESTPostAPIGuildsResult = APIGuild;

/**
 * @see {@link https://discord.com/developers/docs/change-log#guild-create-deprecation}
 * @deprecated
 */
#[derive(Debug, Clone, Serialize, Deserialize, PartialEq)]
pub struct RESTPostAPIGuildsMFAJSONBody {
    /**
     * MFA level
     *
     * @see {@link https://discord.com/developers/docs/resources/guild#guild-object-mfa-level}
     */
    pub level: GuildMFALevel,
}

/**
 * @see {@link https://discord.com/developers/docs/change-log#guild-create-deprecation}
 * @deprecated
 */
pub type RESTPostAPIGuildsMFAResult = RESTPostAPIGuildsMFAJSONBody;

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#get-guild}
 */
#[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Default)]
pub struct RESTGetAPIGuildQuery {
    /**
     * When `true`, will return approximate member and presence counts for the guild
     *
     * @defaultValue `false`
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub with_counts: Option<bool>,
}

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#get-guild}
 */
pub type RESTGetAPIGuildResult = APIGuild;

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#get-guild-preview}
 */
pub type RESTGetAPIGuildPreviewResult = APIGuildPreview;

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#modify-guild}
 */
#[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Default)]
pub struct RESTPatchAPIGuildJSONBody {
    /**
     * New name for the guild (2-100 characters)
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub name: Option<String>,
    /**
     * Voice region id
     *
     * @see {@link https://discord.com/developers/docs/resources/voice#voice-region-object}
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub region: Option<Option<String>>,
    /**
     * Verification level
     *
     * @see {@link https://discord.com/developers/docs/resources/guild#guild-object-verification-level}
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub verification_level: Option<Option<GuildVerificationLevel>>,
    /**
     * Default message notification level
     *
     * @see {@link https://discord.com/developers/docs/resources/guild#guild-object-default-message-notification-level}
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub default_message_notifications: Option<Option<GuildDefaultMessageNotifications>>,
    /**
     * Explicit content filter level
     *
     * @see {@link https://discord.com/developers/docs/resources/guild#guild-object-explicit-content-filter-level}
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub explicit_content_filter: Option<Option<GuildExplicitContentFilter>>,
    /**
     * ID for afk channel
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub afk_channel_id: Option<Option<String>>,
    /**
     * afk timeout in seconds, can be set to: `60`, `300`, `900`, `1800`, `3600`
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub afk_timeout: Option<u32>,
    /**
     * base64 1024x1024 png/jpeg/gif image for the guild icon (can be animated gif when the guild has `ANIMATED_ICON` feature)
     *
     * @see {@link https://discord.com/developers/docs/reference#image-data}
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub icon: Option<Option<String>>,
    /**
     * User id to transfer guild ownership to (must be owner)
     *
     * @deprecated
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub owner_id: Option<String>,
    /**
     * base64 16:9 png/jpeg image for the guild splash (when the guild has `INVITE_SPLASH` feature)
     *
     * @see {@link https://discord.com/developers/docs/reference#image-data}
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub splash: Option<Option<String>>,
    /**
     * base64 png/jpeg image for the guild discovery splash (when the guild has `DISCOVERABLE` feature)
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub discovery_splash: Option<Option<String>>,
    /**
     * base64 16:9 png/jpeg image for the guild banner (when the server has the `BANNER` feature; can be animated gif when the server has the `ANIMATED_BANNER` feature)
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub banner: Option<Option<String>>,
    /**
     * The id of the channel where guild notices such as welcome messages and boost events are posted
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub system_channel_id: Option<Option<String>>,
    /**
     * System channel flags
     *
     * @see {@link https://discord.com/developers/docs/resources/guild#guild-object-system-channel-flags}
     */
    #[serde(with = "crate::utils::serde::flags_numeric")]
    pub system_channel_flags: GuildSystemChannelFlags,
    /**
     * The id of the channel where Community guilds display rules and/or guidelines
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub rules_channel_id: Option<Option<String>>,
    /**
     * The id of the channel where admins and moderators of Community guilds receive notices from Discord
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub public_updates_channel_id: Option<Option<String>>,
    /**
     * The preferred locale of a Community guild used in server discovery and notices from Discord
     *
     * @defaultValue `"en-US"` (if the value is set to `null`)
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub preferred_locale: Option<Option<Locale>>,
    /**
     * Enabled guild features
     *
     * @see {@link https://discord.com/developers/docs/resources/guild#guild-object-guild-features}
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub features: Option<Vec<GuildFeature>>,
    /**
     * The description for the guild
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub description: Option<Option<String>>,
    /**
     * Whether the boosts progress bar should be enabled.
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub premium_progress_bar_enabled: Option<bool>,
    /**
     * The id of the channel where admins and moderators of Community guilds receive safety alerts from Discord
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub safety_alerts_channel_id: Option<Option<String>>,
}

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#modify-guild}
 */
pub type RESTPatchAPIGuildResult = APIGuild;

/**
 * @see {@link https://discord.com/developers/docs/change-log#guild-create-deprecation}
 * @deprecated
 */
pub type RESTDeleteAPIGuildResult = ();

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#get-guild-channels}
 */
pub type RESTGetAPIGuildChannelsResult = Vec<APIChannel>;

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#create-guild-channel}
 */
pub type RESTPostAPIGuildChannelJSONBody = RESTAPIGuildCreatePartialChannel;

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#create-guild-channel}
 */
pub type RESTPostAPIGuildChannelResult = APIChannel;

#[derive(Debug, Clone, Serialize, Deserialize, PartialEq)]
pub struct RESTPatchAPIGuildChannelPositionsJSONBodyItem {
    /**
     * Channel id
     */
    pub id: String,
    /**
     * Sorting position of the channel
     */
    pub position: i32,
    /**
     * Sync channel overwrites with the new parent, when moving to a new `parent_id`
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub lock_permissions: Option<bool>,
    /**
     * The new parent id of this channel
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub parent_id: Option<Option<String>>,
}

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#modify-guild-channel-positions}
 */
pub type RESTPatchAPIGuildChannelPositionsJSONBody =
    Vec<RESTPatchAPIGuildChannelPositionsJSONBodyItem>;

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#modify-guild-channel-positions}
 */
pub type RESTPatchAPIGuildChannelPositionsResult = ();

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#list-active-guild-threads}
 */
pub type RESTGetAPIGuildThreadsResult = APIThreadList;

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#get-guild-member}
 */
pub type RESTGetAPIGuildMemberResult = APIGuildMember;

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#list-guild-members}
 */
#[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Default)]
pub struct RESTGetAPIGuildMembersQuery {
    /**
     * Max number of members to return (1-1000)
     *
     * @defaultValue `1`
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub limit: Option<u16>,
    /**
     * The highest user id in the previous page
     *
     * @defaultValue `0`
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub after: Option<String>,
}

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#list-guild-members}
 */
pub type RESTGetAPIGuildMembersResult = Vec<APIGuildMember>;

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#search-guild-members}
 */
#[derive(Debug, Clone, Serialize, Deserialize, PartialEq)]
pub struct RESTGetAPIGuildMembersSearchQuery {
    /**
     * Query string to match username(s) and nickname(s) against
     */
    pub query: String,
    /**
     * Max number of members to return (1-1000)
     *
     * @defaultValue `1`
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub limit: Option<u16>,
}

pub type RESTGetAPIGuildMembersSearchResult = Vec<APIGuildMember>;

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#add-guild-member}
 */
#[derive(Debug, Clone, Serialize, Deserialize, PartialEq)]
pub struct RESTPutAPIGuildMemberJSONBody {
    /**
     * An oauth2 access token granted with the `guilds.join` to the bot's application for the user you want to add to the guild
     */
    pub access_token: String,
    /**
     * Value to set users nickname to
     *
     * Requires `MANAGE_NICKNAMES` permission
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub nick: Option<String>,
    /**
     * Array of role ids the member is assigned
     *
     * Requires `MANAGE_ROLES` permission
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub roles: Option<Vec<String>>,
    /**
     * Whether the user is muted in voice channels
     *
     * Requires `MUTE_MEMBERS` permission
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub mute: Option<bool>,
    /**
     * Whether the user is deafened in voice channels
     *
     * Requires `DEAFEN_MEMBERS` permission
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub deaf: Option<bool>,
}

pub type RESTPutAPIGuildMemberResult = Option<APIGuildMember>;

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#modify-guild-member}
 */
#[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Default)]
pub struct RESTPatchAPIGuildMemberJSONBody {
    /**
     * Value to set users nickname to
     *
     * Requires `MANAGE_NICKNAMES` permission
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub nick: Option<Option<String>>,
    /**
     * Array of role ids the member is assigned
     *
     * Requires `MANAGE_ROLES` permission
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub roles: Option<Option<Vec<String>>>,
    /**
     * Whether the user is muted in voice channels. Will throw a 400 if the user is not in a voice channel
     *
     * Requires `MUTE_MEMBERS` permission
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub mute: Option<Option<bool>>,
    /**
     * Whether the user is deafened in voice channels. Will throw a 400 if the user is not in a voice channel
     *
     * Requires `DEAFEN_MEMBERS` permission
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub deaf: Option<Option<bool>>,
    /**
     * ID of channel to move user to (if they are connected to voice)
     *
     * Requires `MOVE_MEMBERS` permission
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub channel_id: Option<Option<String>>,
    /**
     * Timestamp of when the time out will be removed; until then, they cannot interact with the guild
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub communication_disabled_until: Option<Option<String>>,
}

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#add-guild-member}
 */
pub type RESTPatchAPIGuildMemberResult = APIGuildMember;

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#modify-current-user-nick}
 * @deprecated Use {@link https://discord.com/developers/docs/resources/guild#modify-current-member | Modify Current Member} instead.
 */
#[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Default)]
pub struct RESTPatchAPICurrentGuildMemberNicknameJSONBody {
    /**
     * Value to set users nickname to
     *
     * Requires `CHANGE_NICKNAME` permission
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub nick: Option<Option<String>>,
}

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#modify-current-member}
 */
#[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Default)]
pub struct RESTPatchAPICurrentGuildMemberJSONBody {
    /**
     * Value to set users nickname to
     *
     * Requires `CHANGE_NICKNAME` permission
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub nick: Option<Option<String>>,
}

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#modify-current-user-nick}
 * @deprecated Use {@link https://discord.com/developers/docs/resources/guild#modify-current-member | Modify Current Member} instead.
 */
pub type RESTPatchAPICurrentGuildMemberNicknameResult =
    RESTPatchAPICurrentGuildMemberNicknameJSONBody;

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#add-guild-member-role}
 */
pub type RESTPutAPIGuildMemberRoleResult = ();

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#remove-guild-member-role}
 */
pub type RESTDeleteAPIGuildMemberRoleResult = ();

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#remove-guild-member}
 */
pub type RESTDeleteAPIGuildMemberResult = ();

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#get-guild-bans}
 */
pub type RESTGetAPIGuildBansResult = Vec<APIBan>;

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#get-guild-bans}
 */
#[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Default)]
pub struct RESTGetAPIGuildBansQuery {
    /**
     * Consider only users before given user id
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub before: Option<String>,
    /**
     * Consider only users after given user id
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub after: Option<String>,
    /**
     * Number of users to return (1-1000)
     *
     * @defaultValue `1000`
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub limit: Option<u16>,
}

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#get-guild-ban}
 */
pub type RESTGetAPIGuildBanResult = APIBan;

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#create-guild-ban}
 */
#[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Default)]
pub struct RESTPutAPIGuildBanJSONBody {
    /**
     * Number of days to delete messages for (0-7)
     *
     * @deprecated Use {@link RESTPutAPIGuildBanJSONBody.delete_message_seconds} instead
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub delete_message_days: Option<u8>,
    /**
     * Number of seconds to delete messages for, between 0 and 604800 (7 days)
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub delete_message_seconds: Option<u32>,
}

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#create-guild-ban}
 */
pub type RESTPutAPIGuildBanResult = ();

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#remove-guild-ban}
 */
pub type RESTDeleteAPIGuildBanResult = ();

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#bulk-guild-ban}
 */
#[derive(Debug, Clone, Serialize, Deserialize, PartialEq)]
pub struct RESTPostAPIGuildBulkBanJSONBody {
    /**
     * List of user ids to ban (max 200)
     */
    pub user_ids: Vec<String>,
    /**
     * Number of seconds to delete messages for, between 0 and 604800 (7 days)
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub delete_message_seconds: Option<u32>,
}

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#bulk-guild-ban}
 */
#[derive(Debug, Clone, Serialize, Deserialize, PartialEq)]
pub struct RESTPostAPIGuildBulkBanResult {
    /**
     * List of user ids, that were successfully banned
     */
    pub banned_users: Vec<String>,
    /**
     * List of user ids, that were not banned
     */
    pub failed_users: Vec<String>,
}

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#get-guild-roles}
 */
pub type RESTGetAPIGuildRolesResult = Vec<APIRole>;

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#create-guild-role}
 */
#[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Default)]
pub struct RESTPostAPIGuildRoleJSONBody {
    /**
     * Name of the role
     *
     * @defaultValue `"new role"`
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub name: Option<Option<String>>,
    /**
     * Bitwise value of the enabled/disabled permissions
     *
     * @defaultValue
     * Default role permissions in guild
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub permissions: Option<Option<String>>,
    /**
     * RGB color value
     *
     * @defaultValue `0`
     * @remarks `color` will still be returned by the API, but using the `colors` field is recommended when doing requests.
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub color: Option<Option<u32>>,
    /**
     * The role's colors
     *
     * @defaultValue `{ "primary_color": 0, "secondary_color": null, "tertiary_color": null }`
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub colors: Option<APIRoleColors>,
    /**
     * Whether the role should be displayed separately in the sidebar
     *
     * @defaultValue `false`
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub hoist: Option<Option<bool>>,
    /**
     * The role's icon image (if the guild has the `ROLE_ICONS` feature)
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub icon: Option<Option<String>>,
    /**
     * The role's unicode emoji as a standard emoji (if the guild has the `ROLE_ICONS` feature)
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub unicode_emoji: Option<Option<String>>,
    /**
     * Whether the role should be mentionable
     *
     * @defaultValue `false`
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub mentionable: Option<Option<bool>>,
}

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#create-guild-role}
 */
pub type RESTPostAPIGuildRoleResult = APIRole;

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#modify-guild-role-positions}
 */
#[derive(Debug, Clone, Serialize, Deserialize, PartialEq)]
pub struct RESTPatchAPIGuildRolePositionsJSONBodyItem {
    /**
     * Role id
     */
    pub id: String,
    /**
     * Sorting position of the role
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub position: Option<i32>,
}

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#modify-guild-role-positions}
 */
pub type RESTPatchAPIGuildRolePositionsJSONBody = Vec<RESTPatchAPIGuildRolePositionsJSONBodyItem>;

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#modify-guild-role-positions}
 */
pub type RESTPatchAPIGuildRolePositionsResult = Vec<APIRole>;

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#modify-guild-role}
 */
#[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Default)]
pub struct RESTPatchAPIGuildRoleJSONBody {
    /**
     * Name of the role
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub name: Option<Option<String>>,
    /**
     * Bitwise value of the enabled/disabled permissions
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub permissions: Option<Option<String>>,
    /**
     * RGB color value
     *
     * @remarks `color` will still be returned by the API, but using the `colors` field is recommended when doing requests.
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub color: Option<Option<u32>>,
    /**
     * The role's colors
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub colors: Option<APIRoleColors>,
    /**
     * Whether the role should be displayed separately in the sidebar
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub hoist: Option<Option<bool>>,
    /**
     * The role's icon image (if the guild has the `ROLE_ICONS` feature)
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub icon: Option<Option<String>>,
    /**
     * The role's unicode emoji as a standard emoji (if the guild has the `ROLE_ICONS` feature)
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub unicode_emoji: Option<Option<String>>,
    /**
     * Whether the role should be mentionable
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub mentionable: Option<Option<bool>>,
}

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#get-guild-role}
 */
pub type RESTGetAPIGuildRoleResult = APIRole;

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#modify-guild-role}
 */
pub type RESTPatchAPIGuildRoleResult = APIRole;

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#delete-guild-role}
 */
pub type RESTDeleteAPIGuildRoleResult = ();

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#get-guild-prune-count}
 */
#[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Default)]
pub struct RESTGetAPIGuildPruneCountQuery {
    /**
     * Number of days to count prune for (1 or more)
     *
     * @defaultValue `7`
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub days: Option<u16>,
    /**
     * Role(s) to include
     *
     * While this is typed as a string, it represents an array of
     * role IDs delimited by commas
     *
     * @see {@link https://discord.com/developers/docs/resources/guild#get-guild-prune-count-query-string-params}
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub include_roles: Option<String>,
}

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#get-guild-prune-count}
 */
#[derive(Debug, Clone, Serialize, Deserialize, PartialEq)]
pub struct RESTGetAPIGuildPruneCountResult {
    pub pruned: i32,
}

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#begin-guild-prune}
 */
#[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Default)]
pub struct RESTPostAPIGuildPruneJSONBody {
    /**
     * Number of days to count prune for (1 or more)
     *
     * @defaultValue `7`
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub days: Option<u16>,
    /**
     * Whether `pruned` is returned, discouraged for large guilds
     *
     * @defaultValue `true`
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub compute_prune_count: Option<bool>,
    /**
     * Role(s) to include
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub include_roles: Option<Vec<String>>,
}

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#begin-guild-prune}
 */
#[derive(Debug, Clone, Serialize, Deserialize, PartialEq)]
pub struct RESTPostAPIGuildPruneResult {
    pub pruned: Option<i32>,
}

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#get-guild-voice-regions}
 */
pub type RESTGetAPIGuildVoiceRegionsResult = Vec<APIVoiceRegion>;

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#get-guild-invites}
 */
pub type RESTGetAPIGuildInvitesResult = Vec<APIExtendedInvite>;

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#get-guild-integrations}
 */
pub type RESTGetAPIGuildIntegrationsResult = Vec<APIGuildIntegration>;

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#delete-guild-integration}
 */
pub type RESTDeleteAPIGuildIntegrationResult = ();

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#get-guild-widget-settings}
 */
pub type RESTGetAPIGuildWidgetSettingsResult = APIGuildWidgetSettings;

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#modify-guild-widget}
 */
pub type RESTPatchAPIGuildWidgetSettingsJSONBody = APIGuildWidgetSettings;

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#modify-guild-widget}
 */
pub type RESTPatchAPIGuildWidgetSettingsResult = APIGuildWidgetSettings;

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#get-guild-widget}
 */
pub type RESTGetAPIGuildWidgetJSONResult = APIGuildWidget;

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#get-guild-vanity-url}
 */
#[derive(Debug, Clone, Serialize, Deserialize, PartialEq)]
pub struct RESTGetAPIGuildVanityUrlResult {
    pub code: Option<String>,
    pub uses: i32,
}

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#get-guild-widget-image}
 */
#[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Default)]
pub struct RESTGetAPIGuildWidgetImageQuery {
    /**
     * Style of the widget image returned
     *
     * @defaultValue `"shield"`
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub style: Option<GuildWidgetStyle>,
}

/**
 * Note: while the return type is `ArrayBuffer`, the expected result is
 * a buffer of sorts (depends if in browser or on node.js/deno).
 */
pub type RESTGetAPIGuildWidgetImageResult = Vec<u8>;

pub type RESTGetAPIGuildMemberVerificationResult = APIGuildMembershipScreening;

#[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Default)]
pub struct RESTPatchAPIGuildMemberVerificationJSONBody {
    /**
     * Whether Membership Screening is enabled
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub enabled: Option<bool>,
    /**
     * Array of field objects serialized in a string
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub form_fields: Option<String>,
    /**
     * The server description to show in the screening form
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub description: Option<Option<String>>,
}

pub type RESTPatchAPIGuildMemberVerificationResult = APIGuildMembershipScreening;

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#get-guild-welcome-screen}
 */
pub type RESTGetAPIGuildWelcomeScreenResult = APIGuildWelcomeScreen;

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#modify-guild-welcome-screen}
 */
#[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Default)]
pub struct RESTPatchAPIGuildWelcomeScreenJSONBody {
    /**
     * Whether the welcome screen is enabled
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub enabled: Option<Option<bool>>,
    #[serde(flatten, skip_serializing_if = "Option::is_none")]
    pub other: Option<Value>,
}

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#modify-guild-welcome-screen}
 */
pub type RESTPatchAPIGuildWelcomeScreenResult = APIGuildWelcomeScreen;

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#get-guild-onboarding}
 */
pub type RESTGetAPIGuildOnboardingResult = APIGuildOnboarding;

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#modify-guild-onboarding}
 */
#[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Default)]
pub struct RESTPutAPIGuildOnboardingJSONBody {
    /**
     * Prompts shown during onboarding and in customize community
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub prompts: Option<Vec<RESTAPIGuildOnboardingPrompt>>,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub default_channel_ids: Option<Vec<String>>,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub enabled: Option<bool>,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub mode: Option<Value>,
}

#[derive(Debug, Clone, Serialize, Deserialize, PartialEq)]
pub struct RESTAPIGuildOnboardingPrompt {
    /**
     * Options available within the prompt
     */
    pub options: Vec<RESTAPIGuildOnboardingPromptOption>,
    pub id: String,
    pub title: String,
}

/**
 * @deprecated Use {@link RESTAPIGuildOnboardingPrompt} instead.
 */
#[deprecated(note = "Use RESTAPIGuildOnboardingPrompt instead.")]
pub type RESTAPIModifyGuildOnboardingPromptData = RESTAPIGuildOnboardingPrompt;

#[derive(Debug, Clone, Serialize, Deserialize, PartialEq)]
pub struct RESTAPIGuildOnboardingPromptOption {
    /**
     * Emoji id
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub emoji_id: Option<Option<String>>,
    /**
     * Emoji name
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub emoji_name: Option<Option<String>>,
    /**
     * Whether this emoji is animated
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub emoji_animated: Option<Option<bool>>,
    pub title: String,
}

/**
 * @deprecated Use {@link RESTAPIGuildOnboardingPromptOption} instead.
 */
#[deprecated(note = "Use RESTAPIGuildOnboardingPromptOption instead.")]
pub type RESTAPIModifyGuildOnboardingPromptOptionData = RESTAPIGuildOnboardingPromptOption;

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#modify-guild-onboarding}
 */
pub type RESTPutAPIGuildOnboardingResult = APIGuildOnboarding;

/**
 * @see {@link https://discord.com/developers/docs/resources/guild#modify-incidents-actions}
 */
#[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Default)]
pub struct RESTPutAPIGuildIncidentActionsJSONBody {
    /**
     * When invites will be enabled again
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub invites_disabled_until: Option<String>,
    /**
     * When direct messages will be enabled again
     */
    #[serde(skip_serializing_if = "Option::is_none")]
    pub dms_disabled_until: Option<String>,
}