@stream-io/node-sdk 0.4.3 → 0.4.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs.js +692 -340
- package/dist/index.cjs.js.map +1 -1
- package/dist/{index.es.js → index.es.mjs} +693 -342
- package/dist/index.es.mjs.map +1 -0
- package/dist/src/gen/chat/ChatApi.d.ts +28 -2
- package/dist/src/gen/models/index.d.ts +585 -194
- package/dist/src/gen/moderation/ModerationApi.d.ts +5 -1
- package/dist/src/gen/video/CallApi.d.ts +4 -2
- package/dist/src/gen/video/VideoApi.d.ts +10 -2
- package/package.json +3 -3
- package/src/gen/chat/ChatApi.ts +225 -2
- package/src/gen/model-decoders/index.ts +330 -136
- package/src/gen/models/index.ts +1007 -293
- package/src/gen/moderation/ModerationApi.ts +51 -5
- package/src/gen/video/CallApi.ts +19 -2
- package/src/gen/video/VideoApi.ts +57 -2
- package/dist/index.es.js.map +0 -1
|
@@ -38,9 +38,9 @@ decoders.ActionLog = (input?: Record<string, any>) => {
|
|
|
38
38
|
|
|
39
39
|
review_queue_item: { type: 'ReviewQueueItem', isSingle: true },
|
|
40
40
|
|
|
41
|
-
target_user: { type: '
|
|
41
|
+
target_user: { type: 'User', isSingle: true },
|
|
42
42
|
|
|
43
|
-
user: { type: '
|
|
43
|
+
user: { type: 'User', isSingle: true },
|
|
44
44
|
};
|
|
45
45
|
return decode(typeMappings, input);
|
|
46
46
|
};
|
|
@@ -86,9 +86,9 @@ decoders.Ban = (input?: Record<string, any>) => {
|
|
|
86
86
|
|
|
87
87
|
channel: { type: 'Channel', isSingle: true },
|
|
88
88
|
|
|
89
|
-
created_by: { type: '
|
|
89
|
+
created_by: { type: 'User', isSingle: true },
|
|
90
90
|
|
|
91
|
-
target: { type: '
|
|
91
|
+
target: { type: 'User', isSingle: true },
|
|
92
92
|
};
|
|
93
93
|
return decode(typeMappings, input);
|
|
94
94
|
};
|
|
@@ -238,6 +238,36 @@ decoders.CallTypeResponse = (input?: Record<string, any>) => {
|
|
|
238
238
|
return decode(typeMappings, input);
|
|
239
239
|
};
|
|
240
240
|
|
|
241
|
+
decoders.CampaignResponse = (input?: Record<string, any>) => {
|
|
242
|
+
const typeMappings: TypeMapping = {
|
|
243
|
+
created_at: { type: 'DatetimeType', isSingle: true },
|
|
244
|
+
|
|
245
|
+
updated_at: { type: 'DatetimeType', isSingle: true },
|
|
246
|
+
|
|
247
|
+
segments: { type: 'Segment', isSingle: false },
|
|
248
|
+
|
|
249
|
+
users: { type: 'UserResponse', isSingle: false },
|
|
250
|
+
|
|
251
|
+
stats: { type: 'CampaignStatsResponse', isSingle: true },
|
|
252
|
+
|
|
253
|
+
scheduled_for: { type: 'DatetimeType', isSingle: true },
|
|
254
|
+
|
|
255
|
+
stop_at: { type: 'DatetimeType', isSingle: true },
|
|
256
|
+
|
|
257
|
+
sender: { type: 'UserResponse', isSingle: true },
|
|
258
|
+
};
|
|
259
|
+
return decode(typeMappings, input);
|
|
260
|
+
};
|
|
261
|
+
|
|
262
|
+
decoders.CampaignStatsResponse = (input?: Record<string, any>) => {
|
|
263
|
+
const typeMappings: TypeMapping = {
|
|
264
|
+
stats_completed_at: { type: 'DatetimeType', isSingle: true },
|
|
265
|
+
|
|
266
|
+
stats_started_at: { type: 'DatetimeType', isSingle: true },
|
|
267
|
+
};
|
|
268
|
+
return decode(typeMappings, input);
|
|
269
|
+
};
|
|
270
|
+
|
|
241
271
|
decoders.Channel = (input?: Record<string, any>) => {
|
|
242
272
|
const typeMappings: TypeMapping = {
|
|
243
273
|
created_at: { type: 'DatetimeType', isSingle: true },
|
|
@@ -254,11 +284,9 @@ decoders.Channel = (input?: Record<string, any>) => {
|
|
|
254
284
|
|
|
255
285
|
config: { type: 'ChannelConfig', isSingle: true },
|
|
256
286
|
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
created_by: { type: 'UserObject', isSingle: true },
|
|
287
|
+
created_by: { type: 'User', isSingle: true },
|
|
260
288
|
|
|
261
|
-
truncated_by: { type: '
|
|
289
|
+
truncated_by: { type: 'User', isSingle: true },
|
|
262
290
|
};
|
|
263
291
|
return decode(typeMappings, input);
|
|
264
292
|
};
|
|
@@ -289,6 +317,8 @@ decoders.ChannelMember = (input?: Record<string, any>) => {
|
|
|
289
317
|
|
|
290
318
|
updated_at: { type: 'DatetimeType', isSingle: true },
|
|
291
319
|
|
|
320
|
+
archived_at: { type: 'DatetimeType', isSingle: true },
|
|
321
|
+
|
|
292
322
|
ban_expires: { type: 'DatetimeType', isSingle: true },
|
|
293
323
|
|
|
294
324
|
deleted_at: { type: 'DatetimeType', isSingle: true },
|
|
@@ -297,7 +327,9 @@ decoders.ChannelMember = (input?: Record<string, any>) => {
|
|
|
297
327
|
|
|
298
328
|
invite_rejected_at: { type: 'DatetimeType', isSingle: true },
|
|
299
329
|
|
|
300
|
-
|
|
330
|
+
pinned_at: { type: 'DatetimeType', isSingle: true },
|
|
331
|
+
|
|
332
|
+
user: { type: 'UserResponse', isSingle: true },
|
|
301
333
|
};
|
|
302
334
|
return decode(typeMappings, input);
|
|
303
335
|
};
|
|
@@ -308,6 +340,8 @@ decoders.ChannelMemberResponse = (input?: Record<string, any>) => {
|
|
|
308
340
|
|
|
309
341
|
updated_at: { type: 'DatetimeType', isSingle: true },
|
|
310
342
|
|
|
343
|
+
archived_at: { type: 'DatetimeType', isSingle: true },
|
|
344
|
+
|
|
311
345
|
ban_expires: { type: 'DatetimeType', isSingle: true },
|
|
312
346
|
|
|
313
347
|
deleted_at: { type: 'DatetimeType', isSingle: true },
|
|
@@ -316,6 +350,8 @@ decoders.ChannelMemberResponse = (input?: Record<string, any>) => {
|
|
|
316
350
|
|
|
317
351
|
invite_rejected_at: { type: 'DatetimeType', isSingle: true },
|
|
318
352
|
|
|
353
|
+
pinned_at: { type: 'DatetimeType', isSingle: true },
|
|
354
|
+
|
|
319
355
|
user: { type: 'UserResponse', isSingle: true },
|
|
320
356
|
};
|
|
321
357
|
return decode(typeMappings, input);
|
|
@@ -331,7 +367,7 @@ decoders.ChannelMute = (input?: Record<string, any>) => {
|
|
|
331
367
|
|
|
332
368
|
channel: { type: 'ChannelResponse', isSingle: true },
|
|
333
369
|
|
|
334
|
-
user: { type: '
|
|
370
|
+
user: { type: 'UserResponse', isSingle: true },
|
|
335
371
|
};
|
|
336
372
|
return decode(typeMappings, input);
|
|
337
373
|
};
|
|
@@ -356,9 +392,9 @@ decoders.ChannelResponse = (input?: Record<string, any>) => {
|
|
|
356
392
|
|
|
357
393
|
config: { type: 'ChannelConfigWithInfo', isSingle: true },
|
|
358
394
|
|
|
359
|
-
created_by: { type: '
|
|
395
|
+
created_by: { type: 'UserResponse', isSingle: true },
|
|
360
396
|
|
|
361
|
-
truncated_by: { type: '
|
|
397
|
+
truncated_by: { type: 'UserResponse', isSingle: true },
|
|
362
398
|
};
|
|
363
399
|
return decode(typeMappings, input);
|
|
364
400
|
};
|
|
@@ -371,7 +407,7 @@ decoders.ChannelStateResponse = (input?: Record<string, any>) => {
|
|
|
371
407
|
|
|
372
408
|
pinned_messages: { type: 'MessageResponse', isSingle: false },
|
|
373
409
|
|
|
374
|
-
threads: { type: '
|
|
410
|
+
threads: { type: 'ThreadStateResponse', isSingle: false },
|
|
375
411
|
|
|
376
412
|
hide_messages_before: { type: 'DatetimeType', isSingle: true },
|
|
377
413
|
|
|
@@ -396,7 +432,7 @@ decoders.ChannelStateResponseFields = (input?: Record<string, any>) => {
|
|
|
396
432
|
|
|
397
433
|
pinned_messages: { type: 'MessageResponse', isSingle: false },
|
|
398
434
|
|
|
399
|
-
threads: { type: '
|
|
435
|
+
threads: { type: 'ThreadStateResponse', isSingle: false },
|
|
400
436
|
|
|
401
437
|
hide_messages_before: { type: 'DatetimeType', isSingle: true },
|
|
402
438
|
|
|
@@ -445,8 +481,6 @@ decoders.ConfigResponse = (input?: Record<string, any>) => {
|
|
|
445
481
|
created_at: { type: 'DatetimeType', isSingle: true },
|
|
446
482
|
|
|
447
483
|
updated_at: { type: 'DatetimeType', isSingle: true },
|
|
448
|
-
|
|
449
|
-
velocity_filter_config: { type: 'VelocityFilterConfig', isSingle: true },
|
|
450
484
|
};
|
|
451
485
|
return decode(typeMappings, input);
|
|
452
486
|
};
|
|
@@ -541,6 +575,13 @@ decoders.Device = (input?: Record<string, any>) => {
|
|
|
541
575
|
return decode(typeMappings, input);
|
|
542
576
|
};
|
|
543
577
|
|
|
578
|
+
decoders.DeviceResponse = (input?: Record<string, any>) => {
|
|
579
|
+
const typeMappings: TypeMapping = {
|
|
580
|
+
created_at: { type: 'DatetimeType', isSingle: true },
|
|
581
|
+
};
|
|
582
|
+
return decode(typeMappings, input);
|
|
583
|
+
};
|
|
584
|
+
|
|
544
585
|
decoders.EgressRTMPResponse = (input?: Record<string, any>) => {
|
|
545
586
|
const typeMappings: TypeMapping = {
|
|
546
587
|
started_at: { type: 'DatetimeType', isSingle: true },
|
|
@@ -548,6 +589,55 @@ decoders.EgressRTMPResponse = (input?: Record<string, any>) => {
|
|
|
548
589
|
return decode(typeMappings, input);
|
|
549
590
|
};
|
|
550
591
|
|
|
592
|
+
decoders.EntityCreator = (input?: Record<string, any>) => {
|
|
593
|
+
const typeMappings: TypeMapping = {
|
|
594
|
+
ban_expires: { type: 'DatetimeType', isSingle: true },
|
|
595
|
+
|
|
596
|
+
created_at: { type: 'DatetimeType', isSingle: true },
|
|
597
|
+
|
|
598
|
+
deactivated_at: { type: 'DatetimeType', isSingle: true },
|
|
599
|
+
|
|
600
|
+
deleted_at: { type: 'DatetimeType', isSingle: true },
|
|
601
|
+
|
|
602
|
+
last_active: { type: 'DatetimeType', isSingle: true },
|
|
603
|
+
|
|
604
|
+
last_engaged_at: { type: 'DatetimeType', isSingle: true },
|
|
605
|
+
|
|
606
|
+
revoke_tokens_issued_before: { type: 'DatetimeType', isSingle: true },
|
|
607
|
+
|
|
608
|
+
updated_at: { type: 'DatetimeType', isSingle: true },
|
|
609
|
+
|
|
610
|
+
push_notifications: { type: 'PushNotificationSettings', isSingle: true },
|
|
611
|
+
};
|
|
612
|
+
return decode(typeMappings, input);
|
|
613
|
+
};
|
|
614
|
+
|
|
615
|
+
decoders.EntityCreatorResponse = (input?: Record<string, any>) => {
|
|
616
|
+
const typeMappings: TypeMapping = {
|
|
617
|
+
created_at: { type: 'DatetimeType', isSingle: true },
|
|
618
|
+
|
|
619
|
+
updated_at: { type: 'DatetimeType', isSingle: true },
|
|
620
|
+
|
|
621
|
+
devices: { type: 'DeviceResponse', isSingle: false },
|
|
622
|
+
|
|
623
|
+
ban_expires: { type: 'DatetimeType', isSingle: true },
|
|
624
|
+
|
|
625
|
+
deactivated_at: { type: 'DatetimeType', isSingle: true },
|
|
626
|
+
|
|
627
|
+
deleted_at: { type: 'DatetimeType', isSingle: true },
|
|
628
|
+
|
|
629
|
+
last_active: { type: 'DatetimeType', isSingle: true },
|
|
630
|
+
|
|
631
|
+
revoke_tokens_issued_before: { type: 'DatetimeType', isSingle: true },
|
|
632
|
+
|
|
633
|
+
push_notifications: {
|
|
634
|
+
type: 'PushNotificationSettingsResponse',
|
|
635
|
+
isSingle: true,
|
|
636
|
+
},
|
|
637
|
+
};
|
|
638
|
+
return decode(typeMappings, input);
|
|
639
|
+
};
|
|
640
|
+
|
|
551
641
|
decoders.EventResponse = (input?: Record<string, any>) => {
|
|
552
642
|
const typeMappings: TypeMapping = {
|
|
553
643
|
event: { type: 'WSEvent', isSingle: true },
|
|
@@ -557,9 +647,9 @@ decoders.EventResponse = (input?: Record<string, any>) => {
|
|
|
557
647
|
|
|
558
648
|
decoders.ExportUserResponse = (input?: Record<string, any>) => {
|
|
559
649
|
const typeMappings: TypeMapping = {
|
|
560
|
-
messages: { type: '
|
|
650
|
+
messages: { type: 'MessageResponse', isSingle: false },
|
|
561
651
|
|
|
562
|
-
reactions: { type: '
|
|
652
|
+
reactions: { type: 'ReactionResponse', isSingle: false },
|
|
563
653
|
|
|
564
654
|
user: { type: 'UserResponse', isSingle: true },
|
|
565
655
|
};
|
|
@@ -572,7 +662,18 @@ decoders.Flag2 = (input?: Record<string, any>) => {
|
|
|
572
662
|
|
|
573
663
|
updated_at: { type: 'DatetimeType', isSingle: true },
|
|
574
664
|
|
|
575
|
-
user: { type: '
|
|
665
|
+
user: { type: 'User', isSingle: true },
|
|
666
|
+
};
|
|
667
|
+
return decode(typeMappings, input);
|
|
668
|
+
};
|
|
669
|
+
|
|
670
|
+
decoders.Flag2Response = (input?: Record<string, any>) => {
|
|
671
|
+
const typeMappings: TypeMapping = {
|
|
672
|
+
created_at: { type: 'DatetimeType', isSingle: true },
|
|
673
|
+
|
|
674
|
+
updated_at: { type: 'DatetimeType', isSingle: true },
|
|
675
|
+
|
|
676
|
+
user: { type: 'UserResponse', isSingle: true },
|
|
576
677
|
};
|
|
577
678
|
return decode(typeMappings, input);
|
|
578
679
|
};
|
|
@@ -599,7 +700,7 @@ decoders.FullUserResponse = (input?: Record<string, any>) => {
|
|
|
599
700
|
|
|
600
701
|
channel_mutes: { type: 'ChannelMute', isSingle: false },
|
|
601
702
|
|
|
602
|
-
devices: { type: '
|
|
703
|
+
devices: { type: 'DeviceResponse', isSingle: false },
|
|
603
704
|
|
|
604
705
|
mutes: { type: 'UserMuteResponse', isSingle: false },
|
|
605
706
|
|
|
@@ -658,6 +759,13 @@ decoders.GetCallTypeResponse = (input?: Record<string, any>) => {
|
|
|
658
759
|
return decode(typeMappings, input);
|
|
659
760
|
};
|
|
660
761
|
|
|
762
|
+
decoders.GetCampaignResponse = (input?: Record<string, any>) => {
|
|
763
|
+
const typeMappings: TypeMapping = {
|
|
764
|
+
campaign: { type: 'CampaignResponse', isSingle: true },
|
|
765
|
+
};
|
|
766
|
+
return decode(typeMappings, input);
|
|
767
|
+
};
|
|
768
|
+
|
|
661
769
|
decoders.GetChannelTypeResponse = (input?: Record<string, any>) => {
|
|
662
770
|
const typeMappings: TypeMapping = {
|
|
663
771
|
created_at: { type: 'DatetimeType', isSingle: true },
|
|
@@ -703,7 +811,7 @@ decoders.GetImportResponse = (input?: Record<string, any>) => {
|
|
|
703
811
|
|
|
704
812
|
decoders.GetManyMessagesResponse = (input?: Record<string, any>) => {
|
|
705
813
|
const typeMappings: TypeMapping = {
|
|
706
|
-
messages: { type: '
|
|
814
|
+
messages: { type: 'MessageResponse', isSingle: false },
|
|
707
815
|
};
|
|
708
816
|
return decode(typeMappings, input);
|
|
709
817
|
};
|
|
@@ -740,9 +848,16 @@ decoders.GetRepliesResponse = (input?: Record<string, any>) => {
|
|
|
740
848
|
|
|
741
849
|
decoders.GetReviewQueueItemResponse = (input?: Record<string, any>) => {
|
|
742
850
|
const typeMappings: TypeMapping = {
|
|
743
|
-
history: { type: '
|
|
851
|
+
history: { type: 'ReviewQueueItemResponse', isSingle: false },
|
|
744
852
|
|
|
745
|
-
item: { type: '
|
|
853
|
+
item: { type: 'ReviewQueueItemResponse', isSingle: true },
|
|
854
|
+
};
|
|
855
|
+
return decode(typeMappings, input);
|
|
856
|
+
};
|
|
857
|
+
|
|
858
|
+
decoders.GetSegmentResponse = (input?: Record<string, any>) => {
|
|
859
|
+
const typeMappings: TypeMapping = {
|
|
860
|
+
segment: { type: 'SegmentResponse', isSingle: true },
|
|
746
861
|
};
|
|
747
862
|
return decode(typeMappings, input);
|
|
748
863
|
};
|
|
@@ -829,7 +944,7 @@ decoders.ListCommandsResponse = (input?: Record<string, any>) => {
|
|
|
829
944
|
|
|
830
945
|
decoders.ListDevicesResponse = (input?: Record<string, any>) => {
|
|
831
946
|
const typeMappings: TypeMapping = {
|
|
832
|
-
devices: { type: '
|
|
947
|
+
devices: { type: 'DeviceResponse', isSingle: false },
|
|
833
948
|
};
|
|
834
949
|
return decode(typeMappings, input);
|
|
835
950
|
};
|
|
@@ -904,7 +1019,7 @@ decoders.Message = (input?: Record<string, any>) => {
|
|
|
904
1019
|
|
|
905
1020
|
latest_reactions: { type: 'Reaction', isSingle: false },
|
|
906
1021
|
|
|
907
|
-
mentioned_users: { type: '
|
|
1022
|
+
mentioned_users: { type: 'User', isSingle: false },
|
|
908
1023
|
|
|
909
1024
|
own_reactions: { type: 'Reaction', isSingle: false },
|
|
910
1025
|
|
|
@@ -918,15 +1033,15 @@ decoders.Message = (input?: Record<string, any>) => {
|
|
|
918
1033
|
|
|
919
1034
|
pinned_at: { type: 'DatetimeType', isSingle: true },
|
|
920
1035
|
|
|
921
|
-
thread_participants: { type: '
|
|
1036
|
+
thread_participants: { type: 'User', isSingle: false },
|
|
922
1037
|
|
|
923
|
-
pinned_by: { type: '
|
|
1038
|
+
pinned_by: { type: 'User', isSingle: true },
|
|
924
1039
|
|
|
925
1040
|
poll: { type: 'Poll', isSingle: true },
|
|
926
1041
|
|
|
927
1042
|
quoted_message: { type: 'Message', isSingle: true },
|
|
928
1043
|
|
|
929
|
-
user: { type: '
|
|
1044
|
+
user: { type: 'User', isSingle: true },
|
|
930
1045
|
};
|
|
931
1046
|
return decode(typeMappings, input);
|
|
932
1047
|
};
|
|
@@ -980,7 +1095,7 @@ decoders.MessageReadEvent = (input?: Record<string, any>) => {
|
|
|
980
1095
|
|
|
981
1096
|
thread: { type: 'ThreadResponse', isSingle: true },
|
|
982
1097
|
|
|
983
|
-
user: { type: '
|
|
1098
|
+
user: { type: 'UserResponse', isSingle: true },
|
|
984
1099
|
};
|
|
985
1100
|
return decode(typeMappings, input);
|
|
986
1101
|
};
|
|
@@ -1011,9 +1126,9 @@ decoders.MessageResponse = (input?: Record<string, any>) => {
|
|
|
1011
1126
|
|
|
1012
1127
|
pinned_by: { type: 'UserResponse', isSingle: true },
|
|
1013
1128
|
|
|
1014
|
-
poll: { type: '
|
|
1129
|
+
poll: { type: 'PollResponseData', isSingle: true },
|
|
1015
1130
|
|
|
1016
|
-
quoted_message: { type: '
|
|
1131
|
+
quoted_message: { type: 'MessageResponse', isSingle: true },
|
|
1017
1132
|
|
|
1018
1133
|
reaction_groups: { type: 'ReactionGroupResponse', isSingle: false },
|
|
1019
1134
|
};
|
|
@@ -1048,9 +1163,9 @@ decoders.MessageWithChannelResponse = (input?: Record<string, any>) => {
|
|
|
1048
1163
|
|
|
1049
1164
|
pinned_by: { type: 'UserResponse', isSingle: true },
|
|
1050
1165
|
|
|
1051
|
-
poll: { type: '
|
|
1166
|
+
poll: { type: 'PollResponseData', isSingle: true },
|
|
1052
1167
|
|
|
1053
|
-
quoted_message: { type: '
|
|
1168
|
+
quoted_message: { type: 'MessageResponse', isSingle: true },
|
|
1054
1169
|
|
|
1055
1170
|
reaction_groups: { type: 'ReactionGroupResponse', isSingle: false },
|
|
1056
1171
|
};
|
|
@@ -1059,6 +1174,8 @@ decoders.MessageWithChannelResponse = (input?: Record<string, any>) => {
|
|
|
1059
1174
|
|
|
1060
1175
|
decoders.ModerationUsageStats = (input?: Record<string, any>) => {
|
|
1061
1176
|
const typeMappings: TypeMapping = {
|
|
1177
|
+
reference_date: { type: 'DatetimeType', isSingle: true },
|
|
1178
|
+
|
|
1062
1179
|
updated_at: { type: 'DatetimeType', isSingle: true },
|
|
1063
1180
|
};
|
|
1064
1181
|
return decode(typeMappings, input);
|
|
@@ -1109,11 +1226,41 @@ decoders.OwnUser = (input?: Record<string, any>) => {
|
|
|
1109
1226
|
|
|
1110
1227
|
last_active: { type: 'DatetimeType', isSingle: true },
|
|
1111
1228
|
|
|
1229
|
+
last_engaged_at: { type: 'DatetimeType', isSingle: true },
|
|
1230
|
+
|
|
1112
1231
|
push_notifications: { type: 'PushNotificationSettings', isSingle: true },
|
|
1113
1232
|
};
|
|
1114
1233
|
return decode(typeMappings, input);
|
|
1115
1234
|
};
|
|
1116
1235
|
|
|
1236
|
+
decoders.OwnUserResponse = (input?: Record<string, any>) => {
|
|
1237
|
+
const typeMappings: TypeMapping = {
|
|
1238
|
+
created_at: { type: 'DatetimeType', isSingle: true },
|
|
1239
|
+
|
|
1240
|
+
updated_at: { type: 'DatetimeType', isSingle: true },
|
|
1241
|
+
|
|
1242
|
+
channel_mutes: { type: 'ChannelMute', isSingle: false },
|
|
1243
|
+
|
|
1244
|
+
devices: { type: 'DeviceResponse', isSingle: false },
|
|
1245
|
+
|
|
1246
|
+
mutes: { type: 'UserMuteResponse', isSingle: false },
|
|
1247
|
+
|
|
1248
|
+
deactivated_at: { type: 'DatetimeType', isSingle: true },
|
|
1249
|
+
|
|
1250
|
+
deleted_at: { type: 'DatetimeType', isSingle: true },
|
|
1251
|
+
|
|
1252
|
+
last_active: { type: 'DatetimeType', isSingle: true },
|
|
1253
|
+
|
|
1254
|
+
revoke_tokens_issued_before: { type: 'DatetimeType', isSingle: true },
|
|
1255
|
+
|
|
1256
|
+
push_notifications: {
|
|
1257
|
+
type: 'PushNotificationSettingsResponse',
|
|
1258
|
+
isSingle: true,
|
|
1259
|
+
},
|
|
1260
|
+
};
|
|
1261
|
+
return decode(typeMappings, input);
|
|
1262
|
+
};
|
|
1263
|
+
|
|
1117
1264
|
decoders.PendingMessageResponse = (input?: Record<string, any>) => {
|
|
1118
1265
|
const typeMappings: TypeMapping = {
|
|
1119
1266
|
channel: { type: 'ChannelResponse', isSingle: true },
|
|
@@ -1135,7 +1282,7 @@ decoders.Poll = (input?: Record<string, any>) => {
|
|
|
1135
1282
|
|
|
1136
1283
|
own_votes: { type: 'PollVote', isSingle: false },
|
|
1137
1284
|
|
|
1138
|
-
created_by: { type: '
|
|
1285
|
+
created_by: { type: 'User', isSingle: true },
|
|
1139
1286
|
};
|
|
1140
1287
|
return decode(typeMappings, input);
|
|
1141
1288
|
};
|
|
@@ -1153,6 +1300,8 @@ decoders.PollResponseData = (input?: Record<string, any>) => {
|
|
|
1153
1300
|
|
|
1154
1301
|
updated_at: { type: 'DatetimeType', isSingle: true },
|
|
1155
1302
|
|
|
1303
|
+
latest_answers: { type: 'PollVoteResponseData', isSingle: false },
|
|
1304
|
+
|
|
1156
1305
|
own_votes: { type: 'PollVoteResponseData', isSingle: false },
|
|
1157
1306
|
|
|
1158
1307
|
created_by: { type: 'UserResponse', isSingle: true },
|
|
@@ -1166,7 +1315,7 @@ decoders.PollVote = (input?: Record<string, any>) => {
|
|
|
1166
1315
|
|
|
1167
1316
|
updated_at: { type: 'DatetimeType', isSingle: true },
|
|
1168
1317
|
|
|
1169
|
-
user: { type: '
|
|
1318
|
+
user: { type: 'User', isSingle: true },
|
|
1170
1319
|
};
|
|
1171
1320
|
return decode(typeMappings, input);
|
|
1172
1321
|
};
|
|
@@ -1267,6 +1416,13 @@ decoders.QueryCallsResponse = (input?: Record<string, any>) => {
|
|
|
1267
1416
|
return decode(typeMappings, input);
|
|
1268
1417
|
};
|
|
1269
1418
|
|
|
1419
|
+
decoders.QueryCampaignsResponse = (input?: Record<string, any>) => {
|
|
1420
|
+
const typeMappings: TypeMapping = {
|
|
1421
|
+
campaigns: { type: 'CampaignResponse', isSingle: false },
|
|
1422
|
+
};
|
|
1423
|
+
return decode(typeMappings, input);
|
|
1424
|
+
};
|
|
1425
|
+
|
|
1270
1426
|
decoders.QueryChannelsResponse = (input?: Record<string, any>) => {
|
|
1271
1427
|
const typeMappings: TypeMapping = {
|
|
1272
1428
|
channels: { type: 'ChannelStateResponseFields', isSingle: false },
|
|
@@ -1306,9 +1462,16 @@ decoders.QueryMessageHistoryResponse = (input?: Record<string, any>) => {
|
|
|
1306
1462
|
return decode(typeMappings, input);
|
|
1307
1463
|
};
|
|
1308
1464
|
|
|
1465
|
+
decoders.QueryModerationConfigsResponse = (input?: Record<string, any>) => {
|
|
1466
|
+
const typeMappings: TypeMapping = {
|
|
1467
|
+
configs: { type: 'ConfigResponse', isSingle: false },
|
|
1468
|
+
};
|
|
1469
|
+
return decode(typeMappings, input);
|
|
1470
|
+
};
|
|
1471
|
+
|
|
1309
1472
|
decoders.QueryModerationLogsResponse = (input?: Record<string, any>) => {
|
|
1310
1473
|
const typeMappings: TypeMapping = {
|
|
1311
|
-
|
|
1474
|
+
logs: { type: 'ActionLogResponse', isSingle: false },
|
|
1312
1475
|
};
|
|
1313
1476
|
return decode(typeMappings, input);
|
|
1314
1477
|
};
|
|
@@ -1329,7 +1492,21 @@ decoders.QueryReactionsResponse = (input?: Record<string, any>) => {
|
|
|
1329
1492
|
|
|
1330
1493
|
decoders.QueryReviewQueueResponse = (input?: Record<string, any>) => {
|
|
1331
1494
|
const typeMappings: TypeMapping = {
|
|
1332
|
-
items: { type: '
|
|
1495
|
+
items: { type: 'ReviewQueueItemResponse', isSingle: false },
|
|
1496
|
+
};
|
|
1497
|
+
return decode(typeMappings, input);
|
|
1498
|
+
};
|
|
1499
|
+
|
|
1500
|
+
decoders.QuerySegmentTargetsResponse = (input?: Record<string, any>) => {
|
|
1501
|
+
const typeMappings: TypeMapping = {
|
|
1502
|
+
targets: { type: 'SegmentTargetResponse', isSingle: false },
|
|
1503
|
+
};
|
|
1504
|
+
return decode(typeMappings, input);
|
|
1505
|
+
};
|
|
1506
|
+
|
|
1507
|
+
decoders.QuerySegmentsResponse = (input?: Record<string, any>) => {
|
|
1508
|
+
const typeMappings: TypeMapping = {
|
|
1509
|
+
segments: { type: 'SegmentResponse', isSingle: false },
|
|
1333
1510
|
};
|
|
1334
1511
|
return decode(typeMappings, input);
|
|
1335
1512
|
};
|
|
@@ -1361,7 +1538,7 @@ decoders.Reaction = (input?: Record<string, any>) => {
|
|
|
1361
1538
|
|
|
1362
1539
|
updated_at: { type: 'DatetimeType', isSingle: true },
|
|
1363
1540
|
|
|
1364
|
-
user: { type: '
|
|
1541
|
+
user: { type: 'User', isSingle: true },
|
|
1365
1542
|
};
|
|
1366
1543
|
return decode(typeMappings, input);
|
|
1367
1544
|
};
|
|
@@ -1402,15 +1579,6 @@ decoders.ReactivateUserResponse = (input?: Record<string, any>) => {
|
|
|
1402
1579
|
return decode(typeMappings, input);
|
|
1403
1580
|
};
|
|
1404
1581
|
|
|
1405
|
-
decoders.Read = (input?: Record<string, any>) => {
|
|
1406
|
-
const typeMappings: TypeMapping = {
|
|
1407
|
-
last_read: { type: 'DatetimeType', isSingle: true },
|
|
1408
|
-
|
|
1409
|
-
user: { type: 'UserObject', isSingle: true },
|
|
1410
|
-
};
|
|
1411
|
-
return decode(typeMappings, input);
|
|
1412
|
-
};
|
|
1413
|
-
|
|
1414
1582
|
decoders.ReadStateResponse = (input?: Record<string, any>) => {
|
|
1415
1583
|
const typeMappings: TypeMapping = {
|
|
1416
1584
|
last_read: { type: 'DatetimeType', isSingle: true },
|
|
@@ -1436,9 +1604,9 @@ decoders.ReviewQueueItem = (input?: Record<string, any>) => {
|
|
|
1436
1604
|
|
|
1437
1605
|
reviewed_at: { type: 'NullTime', isSingle: true },
|
|
1438
1606
|
|
|
1439
|
-
assigned_to: { type: '
|
|
1607
|
+
assigned_to: { type: 'User', isSingle: true },
|
|
1440
1608
|
|
|
1441
|
-
entity_creator: { type: '
|
|
1609
|
+
entity_creator: { type: 'EntityCreator', isSingle: true },
|
|
1442
1610
|
|
|
1443
1611
|
feeds_v2_reaction: { type: 'Reaction', isSingle: true },
|
|
1444
1612
|
|
|
@@ -1447,6 +1615,33 @@ decoders.ReviewQueueItem = (input?: Record<string, any>) => {
|
|
|
1447
1615
|
return decode(typeMappings, input);
|
|
1448
1616
|
};
|
|
1449
1617
|
|
|
1618
|
+
decoders.ReviewQueueItemResponse = (input?: Record<string, any>) => {
|
|
1619
|
+
const typeMappings: TypeMapping = {
|
|
1620
|
+
created_at: { type: 'DatetimeType', isSingle: true },
|
|
1621
|
+
|
|
1622
|
+
updated_at: { type: 'DatetimeType', isSingle: true },
|
|
1623
|
+
|
|
1624
|
+
actions: { type: 'ActionLogResponse', isSingle: false },
|
|
1625
|
+
|
|
1626
|
+
bans: { type: 'Ban', isSingle: false },
|
|
1627
|
+
|
|
1628
|
+
flags: { type: 'Flag2Response', isSingle: false },
|
|
1629
|
+
|
|
1630
|
+
completed_at: { type: 'DatetimeType', isSingle: true },
|
|
1631
|
+
|
|
1632
|
+
reviewed_at: { type: 'DatetimeType', isSingle: true },
|
|
1633
|
+
|
|
1634
|
+
assigned_to: { type: 'UserResponse', isSingle: true },
|
|
1635
|
+
|
|
1636
|
+
entity_creator: { type: 'EntityCreatorResponse', isSingle: true },
|
|
1637
|
+
|
|
1638
|
+
feeds_v2_reaction: { type: 'Reaction', isSingle: true },
|
|
1639
|
+
|
|
1640
|
+
message: { type: 'MessageResponse', isSingle: true },
|
|
1641
|
+
};
|
|
1642
|
+
return decode(typeMappings, input);
|
|
1643
|
+
};
|
|
1644
|
+
|
|
1450
1645
|
decoders.Role = (input?: Record<string, any>) => {
|
|
1451
1646
|
const typeMappings: TypeMapping = {
|
|
1452
1647
|
created_at: { type: 'DatetimeType', isSingle: true },
|
|
@@ -1469,13 +1664,13 @@ decoders.SearchResultMessage = (input?: Record<string, any>) => {
|
|
|
1469
1664
|
|
|
1470
1665
|
updated_at: { type: 'DatetimeType', isSingle: true },
|
|
1471
1666
|
|
|
1472
|
-
latest_reactions: { type: '
|
|
1667
|
+
latest_reactions: { type: 'ReactionResponse', isSingle: false },
|
|
1473
1668
|
|
|
1474
|
-
mentioned_users: { type: '
|
|
1669
|
+
mentioned_users: { type: 'UserResponse', isSingle: false },
|
|
1475
1670
|
|
|
1476
|
-
own_reactions: { type: '
|
|
1671
|
+
own_reactions: { type: 'ReactionResponse', isSingle: false },
|
|
1477
1672
|
|
|
1478
|
-
|
|
1673
|
+
user: { type: 'UserResponse', isSingle: true },
|
|
1479
1674
|
|
|
1480
1675
|
deleted_at: { type: 'DatetimeType', isSingle: true },
|
|
1481
1676
|
|
|
@@ -1485,17 +1680,46 @@ decoders.SearchResultMessage = (input?: Record<string, any>) => {
|
|
|
1485
1680
|
|
|
1486
1681
|
pinned_at: { type: 'DatetimeType', isSingle: true },
|
|
1487
1682
|
|
|
1488
|
-
thread_participants: { type: '
|
|
1683
|
+
thread_participants: { type: 'UserResponse', isSingle: false },
|
|
1489
1684
|
|
|
1490
1685
|
channel: { type: 'ChannelResponse', isSingle: true },
|
|
1491
1686
|
|
|
1492
|
-
pinned_by: { type: '
|
|
1687
|
+
pinned_by: { type: 'UserResponse', isSingle: true },
|
|
1493
1688
|
|
|
1494
|
-
poll: { type: '
|
|
1689
|
+
poll: { type: 'PollResponseData', isSingle: true },
|
|
1495
1690
|
|
|
1496
|
-
quoted_message: { type: '
|
|
1691
|
+
quoted_message: { type: 'MessageResponse', isSingle: true },
|
|
1497
1692
|
|
|
1498
|
-
|
|
1693
|
+
reaction_groups: { type: 'ReactionGroupResponse', isSingle: false },
|
|
1694
|
+
};
|
|
1695
|
+
return decode(typeMappings, input);
|
|
1696
|
+
};
|
|
1697
|
+
|
|
1698
|
+
decoders.Segment = (input?: Record<string, any>) => {
|
|
1699
|
+
const typeMappings: TypeMapping = {
|
|
1700
|
+
created_at: { type: 'DatetimeType', isSingle: true },
|
|
1701
|
+
|
|
1702
|
+
updated_at: { type: 'DatetimeType', isSingle: true },
|
|
1703
|
+
|
|
1704
|
+
deleted_at: { type: 'DatetimeType', isSingle: true },
|
|
1705
|
+
};
|
|
1706
|
+
return decode(typeMappings, input);
|
|
1707
|
+
};
|
|
1708
|
+
|
|
1709
|
+
decoders.SegmentResponse = (input?: Record<string, any>) => {
|
|
1710
|
+
const typeMappings: TypeMapping = {
|
|
1711
|
+
created_at: { type: 'DatetimeType', isSingle: true },
|
|
1712
|
+
|
|
1713
|
+
deleted_at: { type: 'DatetimeType', isSingle: true },
|
|
1714
|
+
|
|
1715
|
+
updated_at: { type: 'DatetimeType', isSingle: true },
|
|
1716
|
+
};
|
|
1717
|
+
return decode(typeMappings, input);
|
|
1718
|
+
};
|
|
1719
|
+
|
|
1720
|
+
decoders.SegmentTargetResponse = (input?: Record<string, any>) => {
|
|
1721
|
+
const typeMappings: TypeMapping = {
|
|
1722
|
+
created_at: { type: 'DatetimeType', isSingle: true },
|
|
1499
1723
|
};
|
|
1500
1724
|
return decode(typeMappings, input);
|
|
1501
1725
|
};
|
|
@@ -1516,6 +1740,13 @@ decoders.SendReactionResponse = (input?: Record<string, any>) => {
|
|
|
1516
1740
|
return decode(typeMappings, input);
|
|
1517
1741
|
};
|
|
1518
1742
|
|
|
1743
|
+
decoders.StartCampaignResponse = (input?: Record<string, any>) => {
|
|
1744
|
+
const typeMappings: TypeMapping = {
|
|
1745
|
+
campaign: { type: 'CampaignResponse', isSingle: true },
|
|
1746
|
+
};
|
|
1747
|
+
return decode(typeMappings, input);
|
|
1748
|
+
};
|
|
1749
|
+
|
|
1519
1750
|
decoders.StopLiveResponse = (input?: Record<string, any>) => {
|
|
1520
1751
|
const typeMappings: TypeMapping = {
|
|
1521
1752
|
call: { type: 'CallResponse', isSingle: true },
|
|
@@ -1540,7 +1771,7 @@ decoders.ThreadParticipant = (input?: Record<string, any>) => {
|
|
|
1540
1771
|
|
|
1541
1772
|
left_thread_at: { type: 'DatetimeType', isSingle: true },
|
|
1542
1773
|
|
|
1543
|
-
user: { type: '
|
|
1774
|
+
user: { type: 'UserResponse', isSingle: true },
|
|
1544
1775
|
};
|
|
1545
1776
|
return decode(typeMappings, input);
|
|
1546
1777
|
};
|
|
@@ -1559,34 +1790,9 @@ decoders.ThreadResponse = (input?: Record<string, any>) => {
|
|
|
1559
1790
|
|
|
1560
1791
|
channel: { type: 'ChannelResponse', isSingle: true },
|
|
1561
1792
|
|
|
1562
|
-
created_by: { type: '
|
|
1563
|
-
|
|
1564
|
-
parent_message: { type: 'Message', isSingle: true },
|
|
1565
|
-
};
|
|
1566
|
-
return decode(typeMappings, input);
|
|
1567
|
-
};
|
|
1568
|
-
|
|
1569
|
-
decoders.ThreadState = (input?: Record<string, any>) => {
|
|
1570
|
-
const typeMappings: TypeMapping = {
|
|
1571
|
-
created_at: { type: 'DatetimeType', isSingle: true },
|
|
1572
|
-
|
|
1573
|
-
updated_at: { type: 'DatetimeType', isSingle: true },
|
|
1574
|
-
|
|
1575
|
-
latest_replies: { type: 'Message', isSingle: false },
|
|
1576
|
-
|
|
1577
|
-
deleted_at: { type: 'DatetimeType', isSingle: true },
|
|
1578
|
-
|
|
1579
|
-
last_message_at: { type: 'DatetimeType', isSingle: true },
|
|
1580
|
-
|
|
1581
|
-
read: { type: 'Read', isSingle: false },
|
|
1582
|
-
|
|
1583
|
-
thread_participants: { type: 'ThreadParticipant', isSingle: false },
|
|
1584
|
-
|
|
1585
|
-
channel: { type: 'Channel', isSingle: true },
|
|
1586
|
-
|
|
1587
|
-
created_by: { type: 'UserObject', isSingle: true },
|
|
1793
|
+
created_by: { type: 'UserResponse', isSingle: true },
|
|
1588
1794
|
|
|
1589
|
-
parent_message: { type: '
|
|
1795
|
+
parent_message: { type: 'MessageResponse', isSingle: true },
|
|
1590
1796
|
};
|
|
1591
1797
|
return decode(typeMappings, input);
|
|
1592
1798
|
};
|
|
@@ -1603,7 +1809,7 @@ decoders.ThreadStateResponse = (input?: Record<string, any>) => {
|
|
|
1603
1809
|
|
|
1604
1810
|
last_message_at: { type: 'DatetimeType', isSingle: true },
|
|
1605
1811
|
|
|
1606
|
-
read: { type: '
|
|
1812
|
+
read: { type: 'ReadStateResponse', isSingle: false },
|
|
1607
1813
|
|
|
1608
1814
|
thread_participants: { type: 'ThreadParticipant', isSingle: false },
|
|
1609
1815
|
|
|
@@ -1611,7 +1817,7 @@ decoders.ThreadStateResponse = (input?: Record<string, any>) => {
|
|
|
1611
1817
|
|
|
1612
1818
|
created_by: { type: 'UserResponse', isSingle: true },
|
|
1613
1819
|
|
|
1614
|
-
parent_message: { type: '
|
|
1820
|
+
parent_message: { type: 'MessageResponse', isSingle: true },
|
|
1615
1821
|
};
|
|
1616
1822
|
return decode(typeMappings, input);
|
|
1617
1823
|
};
|
|
@@ -1695,7 +1901,7 @@ decoders.UpdateChannelResponse = (input?: Record<string, any>) => {
|
|
|
1695
1901
|
|
|
1696
1902
|
channel: { type: 'ChannelResponse', isSingle: true },
|
|
1697
1903
|
|
|
1698
|
-
message: { type: '
|
|
1904
|
+
message: { type: 'MessageResponse', isSingle: true },
|
|
1699
1905
|
};
|
|
1700
1906
|
return decode(typeMappings, input);
|
|
1701
1907
|
};
|
|
@@ -1725,14 +1931,14 @@ decoders.UpdateMemberPartialResponse = (input?: Record<string, any>) => {
|
|
|
1725
1931
|
|
|
1726
1932
|
decoders.UpdateMessagePartialResponse = (input?: Record<string, any>) => {
|
|
1727
1933
|
const typeMappings: TypeMapping = {
|
|
1728
|
-
message: { type: '
|
|
1934
|
+
message: { type: 'MessageResponse', isSingle: true },
|
|
1729
1935
|
};
|
|
1730
1936
|
return decode(typeMappings, input);
|
|
1731
1937
|
};
|
|
1732
1938
|
|
|
1733
1939
|
decoders.UpdateMessageResponse = (input?: Record<string, any>) => {
|
|
1734
1940
|
const typeMappings: TypeMapping = {
|
|
1735
|
-
message: { type: '
|
|
1941
|
+
message: { type: 'MessageResponse', isSingle: true },
|
|
1736
1942
|
};
|
|
1737
1943
|
return decode(typeMappings, input);
|
|
1738
1944
|
};
|
|
@@ -1774,6 +1980,29 @@ decoders.UpsertPushProviderResponse = (input?: Record<string, any>) => {
|
|
|
1774
1980
|
return decode(typeMappings, input);
|
|
1775
1981
|
};
|
|
1776
1982
|
|
|
1983
|
+
decoders.User = (input?: Record<string, any>) => {
|
|
1984
|
+
const typeMappings: TypeMapping = {
|
|
1985
|
+
ban_expires: { type: 'DatetimeType', isSingle: true },
|
|
1986
|
+
|
|
1987
|
+
created_at: { type: 'DatetimeType', isSingle: true },
|
|
1988
|
+
|
|
1989
|
+
deactivated_at: { type: 'DatetimeType', isSingle: true },
|
|
1990
|
+
|
|
1991
|
+
deleted_at: { type: 'DatetimeType', isSingle: true },
|
|
1992
|
+
|
|
1993
|
+
last_active: { type: 'DatetimeType', isSingle: true },
|
|
1994
|
+
|
|
1995
|
+
last_engaged_at: { type: 'DatetimeType', isSingle: true },
|
|
1996
|
+
|
|
1997
|
+
revoke_tokens_issued_before: { type: 'DatetimeType', isSingle: true },
|
|
1998
|
+
|
|
1999
|
+
updated_at: { type: 'DatetimeType', isSingle: true },
|
|
2000
|
+
|
|
2001
|
+
push_notifications: { type: 'PushNotificationSettings', isSingle: true },
|
|
2002
|
+
};
|
|
2003
|
+
return decode(typeMappings, input);
|
|
2004
|
+
};
|
|
2005
|
+
|
|
1777
2006
|
decoders.UserBlock = (input?: Record<string, any>) => {
|
|
1778
2007
|
const typeMappings: TypeMapping = {
|
|
1779
2008
|
created_at: { type: 'DatetimeType', isSingle: true },
|
|
@@ -1789,9 +2018,9 @@ decoders.UserMute = (input?: Record<string, any>) => {
|
|
|
1789
2018
|
|
|
1790
2019
|
expires: { type: 'DatetimeType', isSingle: true },
|
|
1791
2020
|
|
|
1792
|
-
target: { type: '
|
|
2021
|
+
target: { type: 'User', isSingle: true },
|
|
1793
2022
|
|
|
1794
|
-
user: { type: '
|
|
2023
|
+
user: { type: 'User', isSingle: true },
|
|
1795
2024
|
};
|
|
1796
2025
|
return decode(typeMappings, input);
|
|
1797
2026
|
};
|
|
@@ -1811,34 +2040,13 @@ decoders.UserMuteResponse = (input?: Record<string, any>) => {
|
|
|
1811
2040
|
return decode(typeMappings, input);
|
|
1812
2041
|
};
|
|
1813
2042
|
|
|
1814
|
-
decoders.UserObject = (input?: Record<string, any>) => {
|
|
1815
|
-
const typeMappings: TypeMapping = {
|
|
1816
|
-
ban_expires: { type: 'DatetimeType', isSingle: true },
|
|
1817
|
-
|
|
1818
|
-
created_at: { type: 'DatetimeType', isSingle: true },
|
|
1819
|
-
|
|
1820
|
-
deactivated_at: { type: 'DatetimeType', isSingle: true },
|
|
1821
|
-
|
|
1822
|
-
deleted_at: { type: 'DatetimeType', isSingle: true },
|
|
1823
|
-
|
|
1824
|
-
last_active: { type: 'DatetimeType', isSingle: true },
|
|
1825
|
-
|
|
1826
|
-
revoke_tokens_issued_before: { type: 'DatetimeType', isSingle: true },
|
|
1827
|
-
|
|
1828
|
-
updated_at: { type: 'DatetimeType', isSingle: true },
|
|
1829
|
-
|
|
1830
|
-
push_notifications: { type: 'PushNotificationSettings', isSingle: true },
|
|
1831
|
-
};
|
|
1832
|
-
return decode(typeMappings, input);
|
|
1833
|
-
};
|
|
1834
|
-
|
|
1835
2043
|
decoders.UserResponse = (input?: Record<string, any>) => {
|
|
1836
2044
|
const typeMappings: TypeMapping = {
|
|
1837
2045
|
created_at: { type: 'DatetimeType', isSingle: true },
|
|
1838
2046
|
|
|
1839
2047
|
updated_at: { type: 'DatetimeType', isSingle: true },
|
|
1840
2048
|
|
|
1841
|
-
devices: { type: '
|
|
2049
|
+
devices: { type: 'DeviceResponse', isSingle: false },
|
|
1842
2050
|
|
|
1843
2051
|
ban_expires: { type: 'DatetimeType', isSingle: true },
|
|
1844
2052
|
|
|
@@ -1858,43 +2066,29 @@ decoders.UserResponse = (input?: Record<string, any>) => {
|
|
|
1858
2066
|
return decode(typeMappings, input);
|
|
1859
2067
|
};
|
|
1860
2068
|
|
|
1861
|
-
decoders.VelocityFilterConfig = (input?: Record<string, any>) => {
|
|
1862
|
-
const typeMappings: TypeMapping = {
|
|
1863
|
-
rule: { type: 'VelocityFilterConfigRule', isSingle: false },
|
|
1864
|
-
};
|
|
1865
|
-
return decode(typeMappings, input);
|
|
1866
|
-
};
|
|
1867
|
-
|
|
1868
|
-
decoders.VelocityFilterConfigRule = (input?: Record<string, any>) => {
|
|
1869
|
-
const typeMappings: TypeMapping = {
|
|
1870
|
-
timeout: { type: 'DatetimeType', isSingle: true },
|
|
1871
|
-
};
|
|
1872
|
-
return decode(typeMappings, input);
|
|
1873
|
-
};
|
|
1874
|
-
|
|
1875
2069
|
decoders.WSEvent = (input?: Record<string, any>) => {
|
|
1876
2070
|
const typeMappings: TypeMapping = {
|
|
1877
2071
|
created_at: { type: 'DatetimeType', isSingle: true },
|
|
1878
2072
|
|
|
1879
2073
|
channel: { type: 'ChannelResponse', isSingle: true },
|
|
1880
2074
|
|
|
1881
|
-
created_by: { type: '
|
|
2075
|
+
created_by: { type: 'UserResponse', isSingle: true },
|
|
1882
2076
|
|
|
1883
|
-
me: { type: '
|
|
2077
|
+
me: { type: 'OwnUserResponse', isSingle: true },
|
|
1884
2078
|
|
|
1885
2079
|
member: { type: 'ChannelMember', isSingle: true },
|
|
1886
2080
|
|
|
1887
|
-
message: { type: '
|
|
2081
|
+
message: { type: 'MessageResponse', isSingle: true },
|
|
1888
2082
|
|
|
1889
|
-
poll: { type: '
|
|
2083
|
+
poll: { type: 'PollResponseData', isSingle: true },
|
|
1890
2084
|
|
|
1891
|
-
poll_vote: { type: '
|
|
2085
|
+
poll_vote: { type: 'PollVoteResponseData', isSingle: true },
|
|
1892
2086
|
|
|
1893
|
-
reaction: { type: '
|
|
2087
|
+
reaction: { type: 'ReactionResponse', isSingle: true },
|
|
1894
2088
|
|
|
1895
2089
|
thread: { type: 'ThreadResponse', isSingle: true },
|
|
1896
2090
|
|
|
1897
|
-
user: { type: '
|
|
2091
|
+
user: { type: 'UserResponse', isSingle: true },
|
|
1898
2092
|
};
|
|
1899
2093
|
return decode(typeMappings, input);
|
|
1900
2094
|
};
|