@zaflun/lumio-protocol 0.6.0 → 0.9.0
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/CHANGELOG.md +75 -0
- package/dist/index.d.ts +1401 -9
- package/dist/index.js +705 -4
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -53,7 +53,6 @@ declare const extensionConfigSchema: z.ZodObject<{
|
|
|
53
53
|
target: z.ZodEnum<{
|
|
54
54
|
editor: "editor";
|
|
55
55
|
layer: "layer";
|
|
56
|
-
interactive: "interactive";
|
|
57
56
|
}>;
|
|
58
57
|
permissions: z.ZodArray<z.ZodString>;
|
|
59
58
|
settings: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
@@ -70,7 +69,6 @@ declare const initMessageSchema: z.ZodObject<{
|
|
|
70
69
|
target: z.ZodEnum<{
|
|
71
70
|
editor: "editor";
|
|
72
71
|
layer: "layer";
|
|
73
|
-
interactive: "interactive";
|
|
74
72
|
}>;
|
|
75
73
|
permissions: z.ZodArray<z.ZodString>;
|
|
76
74
|
settings: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
@@ -108,7 +106,6 @@ declare const configUpdateMessageSchema: z.ZodObject<{
|
|
|
108
106
|
target: z.ZodOptional<z.ZodEnum<{
|
|
109
107
|
editor: "editor";
|
|
110
108
|
layer: "layer";
|
|
111
|
-
interactive: "interactive";
|
|
112
109
|
}>>;
|
|
113
110
|
permissions: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
114
111
|
settings: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
@@ -192,7 +189,6 @@ declare const lumioMessageSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
192
189
|
target: z.ZodEnum<{
|
|
193
190
|
editor: "editor";
|
|
194
191
|
layer: "layer";
|
|
195
|
-
interactive: "interactive";
|
|
196
192
|
}>;
|
|
197
193
|
permissions: z.ZodArray<z.ZodString>;
|
|
198
194
|
settings: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
@@ -228,7 +224,6 @@ declare const lumioMessageSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
228
224
|
target: z.ZodOptional<z.ZodEnum<{
|
|
229
225
|
editor: "editor";
|
|
230
226
|
layer: "layer";
|
|
231
|
-
interactive: "interactive";
|
|
232
227
|
}>>;
|
|
233
228
|
permissions: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
234
229
|
settings: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
@@ -288,16 +283,20 @@ declare const lumioMessageSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
288
283
|
}, z.core.$strip>], "type">;
|
|
289
284
|
type LumioMessage = z.infer<typeof lumioMessageSchema>;
|
|
290
285
|
|
|
291
|
-
declare const LUMIO_EVENT_TYPES: readonly ["twitch:follower", "twitch:subscribe", "twitch:
|
|
286
|
+
declare const LUMIO_EVENT_TYPES: readonly ["twitch:follower", "twitch:subscribe", "twitch:gift", "twitch:resub", "twitch:cheer", "twitch:raid", "twitch:reward", "twitch:reward_status", "twitch:reward_add", "twitch:reward_update", "twitch:reward_remove", "twitch:hype_train", "twitch:hype_train_end", "twitch:poll", "twitch:poll_end", "twitch:prediction", "twitch:prediction_lock", "twitch:prediction_end", "twitch:goal", "twitch:goal_end", "twitch:ad_break", "twitch:ban", "twitch:unban", "twitch:stream_online", "twitch:stream_offline", "twitch:stream_update", "youtube:subscribe", "youtube:member", "youtube:superchat", "youtube:supersticker", "youtube:gift_membership", "youtube:gift_membership_received", "youtube:poll", "youtube:stream_online", "youtube:stream_offline", "kick:follower", "kick:subscribe", "kick:resub", "kick:gift", "kick:kicks", "kick:reward", "kick:reward_status", "kick:stream_online", "kick:stream_offline", "kick:stream_update", "spotify:track", "spotify:play", "spotify:pause", "spotify:skip", "spotify:volume", "spotify:queue_add", "spotify:device", "spotify:playlist_add", "spotify:playlist_remove", "spotify:playlist_create", "spotify:playlist_edit", "spotify:playlist_delete", "streamelements:tip", "twitch:chat", "youtube:chat", "kick:chat", "chat:message"];
|
|
292
287
|
type LumioEventType = (typeof LUMIO_EVENT_TYPES)[number];
|
|
293
288
|
declare const lumioEventTypeSchema: z.ZodEnum<{
|
|
294
289
|
"twitch:follower": "twitch:follower";
|
|
295
290
|
"twitch:subscribe": "twitch:subscribe";
|
|
296
|
-
"twitch:
|
|
291
|
+
"twitch:gift": "twitch:gift";
|
|
297
292
|
"twitch:resub": "twitch:resub";
|
|
298
293
|
"twitch:cheer": "twitch:cheer";
|
|
299
294
|
"twitch:raid": "twitch:raid";
|
|
300
295
|
"twitch:reward": "twitch:reward";
|
|
296
|
+
"twitch:reward_status": "twitch:reward_status";
|
|
297
|
+
"twitch:reward_add": "twitch:reward_add";
|
|
298
|
+
"twitch:reward_update": "twitch:reward_update";
|
|
299
|
+
"twitch:reward_remove": "twitch:reward_remove";
|
|
301
300
|
"twitch:hype_train": "twitch:hype_train";
|
|
302
301
|
"twitch:hype_train_end": "twitch:hype_train_end";
|
|
303
302
|
"twitch:poll": "twitch:poll";
|
|
@@ -401,6 +400,1310 @@ declare const storageScopeSchema: z.ZodEnum<{
|
|
|
401
400
|
global: "global";
|
|
402
401
|
}>;
|
|
403
402
|
|
|
403
|
+
/**
|
|
404
|
+
* A `chat:moderation_log` frame (`twitch:ban`, `twitch:unban`). It arrives on
|
|
405
|
+
* the chat channel; forwarding it as an extension event is ZAF-3074.
|
|
406
|
+
*/
|
|
407
|
+
declare const moderationLogEntry: z.ZodObject<{
|
|
408
|
+
action: z.ZodString;
|
|
409
|
+
platform: z.ZodString;
|
|
410
|
+
target_user_id: z.ZodNullable<z.ZodString>;
|
|
411
|
+
target_username: z.ZodNullable<z.ZodString>;
|
|
412
|
+
target_display_name: z.ZodNullable<z.ZodString>;
|
|
413
|
+
moderator_name: z.ZodString;
|
|
414
|
+
moderator_login: z.ZodNullable<z.ZodString>;
|
|
415
|
+
reason: z.ZodNullable<z.ZodString>;
|
|
416
|
+
duration_secs: z.ZodNullable<z.ZodNumber>;
|
|
417
|
+
ends_at: z.ZodNullable<z.ZodString>;
|
|
418
|
+
target_message_id: z.ZodNullable<z.ZodString>;
|
|
419
|
+
created_at: z.ZodString;
|
|
420
|
+
}, z.core.$loose>;
|
|
421
|
+
/** A chat message as the backend broadcasts it (`ChatMessageInput`). */
|
|
422
|
+
declare const chatMessagePayloadSchema: z.ZodObject<{
|
|
423
|
+
account_id: z.ZodString;
|
|
424
|
+
platform: z.ZodString;
|
|
425
|
+
channel_name: z.ZodNullable<z.ZodString>;
|
|
426
|
+
user_id: z.ZodNullable<z.ZodString>;
|
|
427
|
+
username: z.ZodString;
|
|
428
|
+
display_name: z.ZodNullable<z.ZodString>;
|
|
429
|
+
avatar_url: z.ZodNullable<z.ZodString>;
|
|
430
|
+
message: z.ZodString;
|
|
431
|
+
/** Platform-specific emote entries. */
|
|
432
|
+
emotes: z.ZodNullable<z.ZodArray<z.ZodUnknown>>;
|
|
433
|
+
/** Twitch GIF fragments `{ id, url, provider, alt }`; absent without a GIF. */
|
|
434
|
+
gifs: z.ZodOptional<z.ZodArray<z.ZodUnknown>>;
|
|
435
|
+
/** Platform-specific badge entries. */
|
|
436
|
+
badges: z.ZodNullable<z.ZodArray<z.ZodUnknown>>;
|
|
437
|
+
color: z.ZodNullable<z.ZodString>;
|
|
438
|
+
is_mod: z.ZodBoolean;
|
|
439
|
+
is_sub: z.ZodBoolean;
|
|
440
|
+
is_vip: z.ZodBoolean;
|
|
441
|
+
sub_tier: z.ZodNullable<z.ZodString>;
|
|
442
|
+
platform_message_id: z.ZodNullable<z.ZodString>;
|
|
443
|
+
lumio_user_id: z.ZodNullable<z.ZodString>;
|
|
444
|
+
reply_parent_msg_id: z.ZodNullable<z.ZodString>;
|
|
445
|
+
reply_parent_username: z.ZodNullable<z.ZodString>;
|
|
446
|
+
reply_parent_login: z.ZodNullable<z.ZodString>;
|
|
447
|
+
reply_parent_message: z.ZodNullable<z.ZodString>;
|
|
448
|
+
created_at: z.ZodNullable<z.ZodString>;
|
|
449
|
+
message_type: z.ZodNullable<z.ZodString>;
|
|
450
|
+
user_treatment: z.ZodNullable<z.ZodString>;
|
|
451
|
+
live_chat_id: z.ZodOptional<z.ZodString>;
|
|
452
|
+
is_shared_chat: z.ZodOptional<z.ZodBoolean>;
|
|
453
|
+
source_channel: z.ZodOptional<z.ZodUnknown>;
|
|
454
|
+
announcement_color: z.ZodOptional<z.ZodUnknown>;
|
|
455
|
+
}, z.core.$loose>;
|
|
456
|
+
/**
|
|
457
|
+
* zod schema for the payload of every event type. `satisfies` makes a
|
|
458
|
+
* `LUMIO_EVENT_TYPES` entry without a schema (or a schema for a type that is
|
|
459
|
+
* not listed) a type error.
|
|
460
|
+
*/
|
|
461
|
+
declare const LUMIO_EVENT_PAYLOAD_SCHEMAS: {
|
|
462
|
+
readonly "twitch:follower": z.ZodObject<{
|
|
463
|
+
followed_at: z.ZodString;
|
|
464
|
+
avatarUrl: z.ZodOptional<z.ZodString>;
|
|
465
|
+
user_id: z.ZodString;
|
|
466
|
+
user_login: z.ZodString;
|
|
467
|
+
user_name: z.ZodString;
|
|
468
|
+
broadcaster_user_id: z.ZodString;
|
|
469
|
+
broadcaster_user_login: z.ZodString;
|
|
470
|
+
broadcaster_user_name: z.ZodString;
|
|
471
|
+
}, z.core.$loose>;
|
|
472
|
+
readonly "twitch:subscribe": z.ZodObject<{
|
|
473
|
+
tier: z.ZodString;
|
|
474
|
+
duration_months: z.ZodNumber;
|
|
475
|
+
is_prime: z.ZodOptional<z.ZodBoolean>;
|
|
476
|
+
sub: z.ZodObject<{
|
|
477
|
+
sub_tier: z.ZodString;
|
|
478
|
+
is_prime: z.ZodBoolean;
|
|
479
|
+
duration_months: z.ZodNumber;
|
|
480
|
+
}, z.core.$loose>;
|
|
481
|
+
chatter_user_id: z.ZodString;
|
|
482
|
+
chatter_user_login: z.ZodString;
|
|
483
|
+
chatter_user_name: z.ZodString;
|
|
484
|
+
chatter_is_anonymous: z.ZodBoolean;
|
|
485
|
+
color: z.ZodString;
|
|
486
|
+
badges: z.ZodArray<z.ZodObject<{
|
|
487
|
+
set_id: z.ZodString;
|
|
488
|
+
id: z.ZodString;
|
|
489
|
+
info: z.ZodString;
|
|
490
|
+
}, z.core.$loose>>;
|
|
491
|
+
message: z.ZodObject<{
|
|
492
|
+
text: z.ZodString;
|
|
493
|
+
fragments: z.ZodArray<z.ZodUnknown>;
|
|
494
|
+
}, z.core.$loose>;
|
|
495
|
+
message_id: z.ZodString;
|
|
496
|
+
notice_type: z.ZodString;
|
|
497
|
+
system_message: z.ZodString;
|
|
498
|
+
/** Emotes of `message`, normalised like chat-message emotes (ZAF-1306). */
|
|
499
|
+
emotes: z.ZodOptional<z.ZodArray<z.ZodUnknown>>;
|
|
500
|
+
avatarUrl: z.ZodOptional<z.ZodString>;
|
|
501
|
+
user_id: z.ZodString;
|
|
502
|
+
user_login: z.ZodString;
|
|
503
|
+
user_name: z.ZodString;
|
|
504
|
+
broadcaster_user_id: z.ZodString;
|
|
505
|
+
broadcaster_user_login: z.ZodString;
|
|
506
|
+
broadcaster_user_name: z.ZodString;
|
|
507
|
+
}, z.core.$loose>;
|
|
508
|
+
readonly "twitch:gift": z.ZodObject<{
|
|
509
|
+
/** Sub tier (`1000`, `2000`, `3000`). */
|
|
510
|
+
tier: z.ZodOptional<z.ZodString>;
|
|
511
|
+
duration_months: z.ZodOptional<z.ZodNumber>;
|
|
512
|
+
/** Gifts in a community gift (`community_sub_gift`). */
|
|
513
|
+
total: z.ZodOptional<z.ZodNumber>;
|
|
514
|
+
/** The gifter's all-time gift count; `null` when anonymous. */
|
|
515
|
+
cumulative_total: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
516
|
+
community_gift_id: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
517
|
+
/** Set for a single gift (`sub_gift`), absent for a community gift. */
|
|
518
|
+
recipient_user_id: z.ZodOptional<z.ZodString>;
|
|
519
|
+
recipient_user_login: z.ZodOptional<z.ZodString>;
|
|
520
|
+
recipient_user_name: z.ZodOptional<z.ZodString>;
|
|
521
|
+
chatter_user_id: z.ZodString;
|
|
522
|
+
chatter_user_login: z.ZodString;
|
|
523
|
+
chatter_user_name: z.ZodString;
|
|
524
|
+
chatter_is_anonymous: z.ZodBoolean;
|
|
525
|
+
color: z.ZodString;
|
|
526
|
+
badges: z.ZodArray<z.ZodObject<{
|
|
527
|
+
set_id: z.ZodString;
|
|
528
|
+
id: z.ZodString;
|
|
529
|
+
info: z.ZodString;
|
|
530
|
+
}, z.core.$loose>>;
|
|
531
|
+
message: z.ZodObject<{
|
|
532
|
+
text: z.ZodString;
|
|
533
|
+
fragments: z.ZodArray<z.ZodUnknown>;
|
|
534
|
+
}, z.core.$loose>;
|
|
535
|
+
message_id: z.ZodString;
|
|
536
|
+
notice_type: z.ZodString;
|
|
537
|
+
system_message: z.ZodString;
|
|
538
|
+
/** Emotes of `message`, normalised like chat-message emotes (ZAF-1306). */
|
|
539
|
+
emotes: z.ZodOptional<z.ZodArray<z.ZodUnknown>>;
|
|
540
|
+
avatarUrl: z.ZodOptional<z.ZodString>;
|
|
541
|
+
user_id: z.ZodString;
|
|
542
|
+
user_login: z.ZodString;
|
|
543
|
+
user_name: z.ZodString;
|
|
544
|
+
broadcaster_user_id: z.ZodString;
|
|
545
|
+
broadcaster_user_login: z.ZodString;
|
|
546
|
+
broadcaster_user_name: z.ZodString;
|
|
547
|
+
}, z.core.$loose>;
|
|
548
|
+
readonly "twitch:resub": z.ZodObject<{
|
|
549
|
+
cumulative_months: z.ZodNumber;
|
|
550
|
+
duration_months: z.ZodNumber;
|
|
551
|
+
streak_months: z.ZodNullable<z.ZodNumber>;
|
|
552
|
+
is_gift: z.ZodBoolean;
|
|
553
|
+
tier: z.ZodOptional<z.ZodString>;
|
|
554
|
+
is_prime: z.ZodOptional<z.ZodBoolean>;
|
|
555
|
+
gifter_is_anonymous: z.ZodNullable<z.ZodBoolean>;
|
|
556
|
+
gifter_user_login: z.ZodNullable<z.ZodString>;
|
|
557
|
+
gifter_user_name: z.ZodNullable<z.ZodString>;
|
|
558
|
+
resub: z.ZodObject<{
|
|
559
|
+
cumulative_months: z.ZodNumber;
|
|
560
|
+
duration_months: z.ZodNumber;
|
|
561
|
+
streak_months: z.ZodNullable<z.ZodNumber>;
|
|
562
|
+
sub_plan: z.ZodString;
|
|
563
|
+
is_gift: z.ZodBoolean;
|
|
564
|
+
}, z.core.$loose>;
|
|
565
|
+
chatter_user_id: z.ZodString;
|
|
566
|
+
chatter_user_login: z.ZodString;
|
|
567
|
+
chatter_user_name: z.ZodString;
|
|
568
|
+
chatter_is_anonymous: z.ZodBoolean;
|
|
569
|
+
color: z.ZodString;
|
|
570
|
+
badges: z.ZodArray<z.ZodObject<{
|
|
571
|
+
set_id: z.ZodString;
|
|
572
|
+
id: z.ZodString;
|
|
573
|
+
info: z.ZodString;
|
|
574
|
+
}, z.core.$loose>>;
|
|
575
|
+
message: z.ZodObject<{
|
|
576
|
+
text: z.ZodString;
|
|
577
|
+
fragments: z.ZodArray<z.ZodUnknown>;
|
|
578
|
+
}, z.core.$loose>;
|
|
579
|
+
message_id: z.ZodString;
|
|
580
|
+
notice_type: z.ZodString;
|
|
581
|
+
system_message: z.ZodString;
|
|
582
|
+
/** Emotes of `message`, normalised like chat-message emotes (ZAF-1306). */
|
|
583
|
+
emotes: z.ZodOptional<z.ZodArray<z.ZodUnknown>>;
|
|
584
|
+
avatarUrl: z.ZodOptional<z.ZodString>;
|
|
585
|
+
user_id: z.ZodString;
|
|
586
|
+
user_login: z.ZodString;
|
|
587
|
+
user_name: z.ZodString;
|
|
588
|
+
broadcaster_user_id: z.ZodString;
|
|
589
|
+
broadcaster_user_login: z.ZodString;
|
|
590
|
+
broadcaster_user_name: z.ZodString;
|
|
591
|
+
}, z.core.$loose>;
|
|
592
|
+
readonly "twitch:cheer": z.ZodObject<{
|
|
593
|
+
user_id: z.ZodNullable<z.ZodString>;
|
|
594
|
+
user_login: z.ZodNullable<z.ZodString>;
|
|
595
|
+
user_name: z.ZodNullable<z.ZodString>;
|
|
596
|
+
is_anonymous: z.ZodBoolean;
|
|
597
|
+
bits: z.ZodNumber;
|
|
598
|
+
message: z.ZodString;
|
|
599
|
+
/** Cheermote entries for the cheer words in `message` (`kind: "cheermote"`). */
|
|
600
|
+
emotes: z.ZodOptional<z.ZodArray<z.ZodUnknown>>;
|
|
601
|
+
/** The cheermote for the total, when the channel's cheermotes loaded. */
|
|
602
|
+
cheermote: z.ZodOptional<z.ZodUnknown>;
|
|
603
|
+
avatarUrl: z.ZodOptional<z.ZodString>;
|
|
604
|
+
broadcaster_user_id: z.ZodString;
|
|
605
|
+
broadcaster_user_login: z.ZodString;
|
|
606
|
+
broadcaster_user_name: z.ZodString;
|
|
607
|
+
}, z.core.$loose>;
|
|
608
|
+
readonly "twitch:raid": z.ZodObject<{
|
|
609
|
+
displayName: z.ZodOptional<z.ZodString>;
|
|
610
|
+
/** The raider's channel info from Helix, when it loaded. */
|
|
611
|
+
title: z.ZodOptional<z.ZodString>;
|
|
612
|
+
category: z.ZodOptional<z.ZodString>;
|
|
613
|
+
avatarUrl: z.ZodOptional<z.ZodString>;
|
|
614
|
+
from_broadcaster_user_id: z.ZodString;
|
|
615
|
+
from_broadcaster_user_login: z.ZodString;
|
|
616
|
+
from_broadcaster_user_name: z.ZodString;
|
|
617
|
+
to_broadcaster_user_id: z.ZodString;
|
|
618
|
+
to_broadcaster_user_login: z.ZodString;
|
|
619
|
+
to_broadcaster_user_name: z.ZodString;
|
|
620
|
+
viewers: z.ZodNumber;
|
|
621
|
+
}, z.core.$loose>;
|
|
622
|
+
readonly "twitch:reward": z.ZodObject<{
|
|
623
|
+
id: z.ZodString;
|
|
624
|
+
user_input: z.ZodString;
|
|
625
|
+
status: z.ZodString;
|
|
626
|
+
redeemed_at: z.ZodString;
|
|
627
|
+
reward: z.ZodObject<{
|
|
628
|
+
id: z.ZodString;
|
|
629
|
+
title: z.ZodString;
|
|
630
|
+
cost: z.ZodNumber;
|
|
631
|
+
prompt: z.ZodString;
|
|
632
|
+
}, z.core.$loose>;
|
|
633
|
+
avatarUrl: z.ZodOptional<z.ZodString>;
|
|
634
|
+
user_id: z.ZodString;
|
|
635
|
+
user_login: z.ZodString;
|
|
636
|
+
user_name: z.ZodString;
|
|
637
|
+
broadcaster_user_id: z.ZodString;
|
|
638
|
+
broadcaster_user_login: z.ZodString;
|
|
639
|
+
broadcaster_user_name: z.ZodString;
|
|
640
|
+
}, z.core.$loose>;
|
|
641
|
+
readonly "twitch:reward_status": z.ZodObject<{
|
|
642
|
+
id: z.ZodString;
|
|
643
|
+
user_input: z.ZodString;
|
|
644
|
+
status: z.ZodString;
|
|
645
|
+
redeemed_at: z.ZodString;
|
|
646
|
+
reward: z.ZodObject<{
|
|
647
|
+
id: z.ZodString;
|
|
648
|
+
title: z.ZodString;
|
|
649
|
+
cost: z.ZodNumber;
|
|
650
|
+
prompt: z.ZodString;
|
|
651
|
+
}, z.core.$loose>;
|
|
652
|
+
avatarUrl: z.ZodOptional<z.ZodString>;
|
|
653
|
+
user_id: z.ZodString;
|
|
654
|
+
user_login: z.ZodString;
|
|
655
|
+
user_name: z.ZodString;
|
|
656
|
+
broadcaster_user_id: z.ZodString;
|
|
657
|
+
broadcaster_user_login: z.ZodString;
|
|
658
|
+
broadcaster_user_name: z.ZodString;
|
|
659
|
+
}, z.core.$loose>;
|
|
660
|
+
readonly "twitch:reward_add": z.ZodObject<{
|
|
661
|
+
id: z.ZodString;
|
|
662
|
+
title: z.ZodString;
|
|
663
|
+
cost: z.ZodNumber;
|
|
664
|
+
prompt: z.ZodString;
|
|
665
|
+
background_color: z.ZodString;
|
|
666
|
+
is_enabled: z.ZodBoolean;
|
|
667
|
+
is_paused: z.ZodBoolean;
|
|
668
|
+
is_in_stock: z.ZodBoolean;
|
|
669
|
+
is_user_input_required: z.ZodBoolean;
|
|
670
|
+
should_redemptions_skip_request_queue: z.ZodBoolean;
|
|
671
|
+
max_per_stream: z.ZodObject<{
|
|
672
|
+
is_enabled: z.ZodBoolean;
|
|
673
|
+
value: z.ZodNumber;
|
|
674
|
+
}, z.core.$loose>;
|
|
675
|
+
max_per_user_per_stream: z.ZodObject<{
|
|
676
|
+
is_enabled: z.ZodBoolean;
|
|
677
|
+
value: z.ZodNumber;
|
|
678
|
+
}, z.core.$loose>;
|
|
679
|
+
global_cooldown: z.ZodObject<{
|
|
680
|
+
is_enabled: z.ZodBoolean;
|
|
681
|
+
seconds: z.ZodNumber;
|
|
682
|
+
}, z.core.$loose>;
|
|
683
|
+
image: z.ZodNullable<z.ZodObject<{
|
|
684
|
+
url_1x: z.ZodString;
|
|
685
|
+
url_2x: z.ZodString;
|
|
686
|
+
url_4x: z.ZodString;
|
|
687
|
+
}, z.core.$loose>>;
|
|
688
|
+
default_image: z.ZodObject<{
|
|
689
|
+
url_1x: z.ZodString;
|
|
690
|
+
url_2x: z.ZodString;
|
|
691
|
+
url_4x: z.ZodString;
|
|
692
|
+
}, z.core.$loose>;
|
|
693
|
+
cooldown_expires_at: z.ZodNullable<z.ZodString>;
|
|
694
|
+
redemptions_redeemed_current_stream: z.ZodNullable<z.ZodNumber>;
|
|
695
|
+
broadcaster_user_id: z.ZodString;
|
|
696
|
+
broadcaster_user_login: z.ZodString;
|
|
697
|
+
broadcaster_user_name: z.ZodString;
|
|
698
|
+
}, z.core.$loose>;
|
|
699
|
+
readonly "twitch:reward_update": z.ZodObject<{
|
|
700
|
+
id: z.ZodString;
|
|
701
|
+
title: z.ZodString;
|
|
702
|
+
cost: z.ZodNumber;
|
|
703
|
+
prompt: z.ZodString;
|
|
704
|
+
background_color: z.ZodString;
|
|
705
|
+
is_enabled: z.ZodBoolean;
|
|
706
|
+
is_paused: z.ZodBoolean;
|
|
707
|
+
is_in_stock: z.ZodBoolean;
|
|
708
|
+
is_user_input_required: z.ZodBoolean;
|
|
709
|
+
should_redemptions_skip_request_queue: z.ZodBoolean;
|
|
710
|
+
max_per_stream: z.ZodObject<{
|
|
711
|
+
is_enabled: z.ZodBoolean;
|
|
712
|
+
value: z.ZodNumber;
|
|
713
|
+
}, z.core.$loose>;
|
|
714
|
+
max_per_user_per_stream: z.ZodObject<{
|
|
715
|
+
is_enabled: z.ZodBoolean;
|
|
716
|
+
value: z.ZodNumber;
|
|
717
|
+
}, z.core.$loose>;
|
|
718
|
+
global_cooldown: z.ZodObject<{
|
|
719
|
+
is_enabled: z.ZodBoolean;
|
|
720
|
+
seconds: z.ZodNumber;
|
|
721
|
+
}, z.core.$loose>;
|
|
722
|
+
image: z.ZodNullable<z.ZodObject<{
|
|
723
|
+
url_1x: z.ZodString;
|
|
724
|
+
url_2x: z.ZodString;
|
|
725
|
+
url_4x: z.ZodString;
|
|
726
|
+
}, z.core.$loose>>;
|
|
727
|
+
default_image: z.ZodObject<{
|
|
728
|
+
url_1x: z.ZodString;
|
|
729
|
+
url_2x: z.ZodString;
|
|
730
|
+
url_4x: z.ZodString;
|
|
731
|
+
}, z.core.$loose>;
|
|
732
|
+
cooldown_expires_at: z.ZodNullable<z.ZodString>;
|
|
733
|
+
redemptions_redeemed_current_stream: z.ZodNullable<z.ZodNumber>;
|
|
734
|
+
broadcaster_user_id: z.ZodString;
|
|
735
|
+
broadcaster_user_login: z.ZodString;
|
|
736
|
+
broadcaster_user_name: z.ZodString;
|
|
737
|
+
}, z.core.$loose>;
|
|
738
|
+
readonly "twitch:reward_remove": z.ZodObject<{
|
|
739
|
+
id: z.ZodString;
|
|
740
|
+
title: z.ZodString;
|
|
741
|
+
cost: z.ZodNumber;
|
|
742
|
+
prompt: z.ZodString;
|
|
743
|
+
background_color: z.ZodString;
|
|
744
|
+
is_enabled: z.ZodBoolean;
|
|
745
|
+
is_paused: z.ZodBoolean;
|
|
746
|
+
is_in_stock: z.ZodBoolean;
|
|
747
|
+
is_user_input_required: z.ZodBoolean;
|
|
748
|
+
should_redemptions_skip_request_queue: z.ZodBoolean;
|
|
749
|
+
max_per_stream: z.ZodObject<{
|
|
750
|
+
is_enabled: z.ZodBoolean;
|
|
751
|
+
value: z.ZodNumber;
|
|
752
|
+
}, z.core.$loose>;
|
|
753
|
+
max_per_user_per_stream: z.ZodObject<{
|
|
754
|
+
is_enabled: z.ZodBoolean;
|
|
755
|
+
value: z.ZodNumber;
|
|
756
|
+
}, z.core.$loose>;
|
|
757
|
+
global_cooldown: z.ZodObject<{
|
|
758
|
+
is_enabled: z.ZodBoolean;
|
|
759
|
+
seconds: z.ZodNumber;
|
|
760
|
+
}, z.core.$loose>;
|
|
761
|
+
image: z.ZodNullable<z.ZodObject<{
|
|
762
|
+
url_1x: z.ZodString;
|
|
763
|
+
url_2x: z.ZodString;
|
|
764
|
+
url_4x: z.ZodString;
|
|
765
|
+
}, z.core.$loose>>;
|
|
766
|
+
default_image: z.ZodObject<{
|
|
767
|
+
url_1x: z.ZodString;
|
|
768
|
+
url_2x: z.ZodString;
|
|
769
|
+
url_4x: z.ZodString;
|
|
770
|
+
}, z.core.$loose>;
|
|
771
|
+
cooldown_expires_at: z.ZodNullable<z.ZodString>;
|
|
772
|
+
redemptions_redeemed_current_stream: z.ZodNullable<z.ZodNumber>;
|
|
773
|
+
broadcaster_user_id: z.ZodString;
|
|
774
|
+
broadcaster_user_login: z.ZodString;
|
|
775
|
+
broadcaster_user_name: z.ZodString;
|
|
776
|
+
}, z.core.$loose>;
|
|
777
|
+
readonly "twitch:hype_train": z.ZodObject<{
|
|
778
|
+
progress: z.ZodNumber;
|
|
779
|
+
goal: z.ZodNumber;
|
|
780
|
+
expires_at: z.ZodString;
|
|
781
|
+
all_time_high_level: z.ZodOptional<z.ZodNumber>;
|
|
782
|
+
all_time_high_total: z.ZodOptional<z.ZodNumber>;
|
|
783
|
+
id: z.ZodString;
|
|
784
|
+
type: z.ZodString;
|
|
785
|
+
level: z.ZodNumber;
|
|
786
|
+
total: z.ZodNumber;
|
|
787
|
+
top_contributions: z.ZodArray<z.ZodObject<{
|
|
788
|
+
type: z.ZodString;
|
|
789
|
+
total: z.ZodNumber;
|
|
790
|
+
user_id: z.ZodString;
|
|
791
|
+
user_login: z.ZodString;
|
|
792
|
+
user_name: z.ZodString;
|
|
793
|
+
}, z.core.$loose>>;
|
|
794
|
+
started_at: z.ZodString;
|
|
795
|
+
is_shared_train: z.ZodBoolean;
|
|
796
|
+
shared_train_participants: z.ZodNullable<z.ZodArray<z.ZodUnknown>>;
|
|
797
|
+
broadcaster_user_id: z.ZodString;
|
|
798
|
+
broadcaster_user_login: z.ZodString;
|
|
799
|
+
broadcaster_user_name: z.ZodString;
|
|
800
|
+
}, z.core.$loose>;
|
|
801
|
+
readonly "twitch:hype_train_end": z.ZodObject<{
|
|
802
|
+
ended_at: z.ZodString;
|
|
803
|
+
cooldown_ends_at: z.ZodString;
|
|
804
|
+
id: z.ZodString;
|
|
805
|
+
type: z.ZodString;
|
|
806
|
+
level: z.ZodNumber;
|
|
807
|
+
total: z.ZodNumber;
|
|
808
|
+
top_contributions: z.ZodArray<z.ZodObject<{
|
|
809
|
+
type: z.ZodString;
|
|
810
|
+
total: z.ZodNumber;
|
|
811
|
+
user_id: z.ZodString;
|
|
812
|
+
user_login: z.ZodString;
|
|
813
|
+
user_name: z.ZodString;
|
|
814
|
+
}, z.core.$loose>>;
|
|
815
|
+
started_at: z.ZodString;
|
|
816
|
+
is_shared_train: z.ZodBoolean;
|
|
817
|
+
shared_train_participants: z.ZodNullable<z.ZodArray<z.ZodUnknown>>;
|
|
818
|
+
broadcaster_user_id: z.ZodString;
|
|
819
|
+
broadcaster_user_login: z.ZodString;
|
|
820
|
+
broadcaster_user_name: z.ZodString;
|
|
821
|
+
}, z.core.$loose>;
|
|
822
|
+
readonly "twitch:poll": z.ZodObject<{
|
|
823
|
+
ends_at: z.ZodString;
|
|
824
|
+
id: z.ZodString;
|
|
825
|
+
title: z.ZodString;
|
|
826
|
+
choices: z.ZodArray<z.ZodObject<{
|
|
827
|
+
id: z.ZodString;
|
|
828
|
+
title: z.ZodString;
|
|
829
|
+
votes: z.ZodOptional<z.ZodNumber>;
|
|
830
|
+
bits_votes: z.ZodOptional<z.ZodNumber>;
|
|
831
|
+
channel_points_votes: z.ZodOptional<z.ZodNumber>;
|
|
832
|
+
}, z.core.$loose>>;
|
|
833
|
+
bits_voting: z.ZodObject<{
|
|
834
|
+
is_enabled: z.ZodBoolean;
|
|
835
|
+
amount_per_vote: z.ZodNumber;
|
|
836
|
+
}, z.core.$loose>;
|
|
837
|
+
channel_points_voting: z.ZodObject<{
|
|
838
|
+
is_enabled: z.ZodBoolean;
|
|
839
|
+
amount_per_vote: z.ZodNumber;
|
|
840
|
+
}, z.core.$loose>;
|
|
841
|
+
started_at: z.ZodString;
|
|
842
|
+
broadcaster_user_id: z.ZodString;
|
|
843
|
+
broadcaster_user_login: z.ZodString;
|
|
844
|
+
broadcaster_user_name: z.ZodString;
|
|
845
|
+
}, z.core.$loose>;
|
|
846
|
+
readonly "twitch:poll_end": z.ZodObject<{
|
|
847
|
+
status: z.ZodString;
|
|
848
|
+
ended_at: z.ZodString;
|
|
849
|
+
id: z.ZodString;
|
|
850
|
+
title: z.ZodString;
|
|
851
|
+
choices: z.ZodArray<z.ZodObject<{
|
|
852
|
+
id: z.ZodString;
|
|
853
|
+
title: z.ZodString;
|
|
854
|
+
votes: z.ZodOptional<z.ZodNumber>;
|
|
855
|
+
bits_votes: z.ZodOptional<z.ZodNumber>;
|
|
856
|
+
channel_points_votes: z.ZodOptional<z.ZodNumber>;
|
|
857
|
+
}, z.core.$loose>>;
|
|
858
|
+
bits_voting: z.ZodObject<{
|
|
859
|
+
is_enabled: z.ZodBoolean;
|
|
860
|
+
amount_per_vote: z.ZodNumber;
|
|
861
|
+
}, z.core.$loose>;
|
|
862
|
+
channel_points_voting: z.ZodObject<{
|
|
863
|
+
is_enabled: z.ZodBoolean;
|
|
864
|
+
amount_per_vote: z.ZodNumber;
|
|
865
|
+
}, z.core.$loose>;
|
|
866
|
+
started_at: z.ZodString;
|
|
867
|
+
broadcaster_user_id: z.ZodString;
|
|
868
|
+
broadcaster_user_login: z.ZodString;
|
|
869
|
+
broadcaster_user_name: z.ZodString;
|
|
870
|
+
}, z.core.$loose>;
|
|
871
|
+
readonly "twitch:prediction": z.ZodObject<{
|
|
872
|
+
locks_at: z.ZodString;
|
|
873
|
+
id: z.ZodString;
|
|
874
|
+
title: z.ZodString;
|
|
875
|
+
outcomes: z.ZodArray<z.ZodObject<{
|
|
876
|
+
id: z.ZodString;
|
|
877
|
+
title: z.ZodString;
|
|
878
|
+
color: z.ZodString;
|
|
879
|
+
users: z.ZodOptional<z.ZodNumber>;
|
|
880
|
+
channel_points: z.ZodOptional<z.ZodNumber>;
|
|
881
|
+
top_predictors: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
|
|
882
|
+
channel_points_used: z.ZodNumber;
|
|
883
|
+
channel_points_won: z.ZodNullable<z.ZodNumber>;
|
|
884
|
+
user_id: z.ZodString;
|
|
885
|
+
user_login: z.ZodString;
|
|
886
|
+
user_name: z.ZodString;
|
|
887
|
+
}, z.core.$loose>>>>;
|
|
888
|
+
}, z.core.$loose>>;
|
|
889
|
+
started_at: z.ZodString;
|
|
890
|
+
broadcaster_user_id: z.ZodString;
|
|
891
|
+
broadcaster_user_login: z.ZodString;
|
|
892
|
+
broadcaster_user_name: z.ZodString;
|
|
893
|
+
}, z.core.$loose>;
|
|
894
|
+
readonly "twitch:prediction_lock": z.ZodObject<{
|
|
895
|
+
locked_at: z.ZodString;
|
|
896
|
+
id: z.ZodString;
|
|
897
|
+
title: z.ZodString;
|
|
898
|
+
outcomes: z.ZodArray<z.ZodObject<{
|
|
899
|
+
id: z.ZodString;
|
|
900
|
+
title: z.ZodString;
|
|
901
|
+
color: z.ZodString;
|
|
902
|
+
users: z.ZodOptional<z.ZodNumber>;
|
|
903
|
+
channel_points: z.ZodOptional<z.ZodNumber>;
|
|
904
|
+
top_predictors: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
|
|
905
|
+
channel_points_used: z.ZodNumber;
|
|
906
|
+
channel_points_won: z.ZodNullable<z.ZodNumber>;
|
|
907
|
+
user_id: z.ZodString;
|
|
908
|
+
user_login: z.ZodString;
|
|
909
|
+
user_name: z.ZodString;
|
|
910
|
+
}, z.core.$loose>>>>;
|
|
911
|
+
}, z.core.$loose>>;
|
|
912
|
+
started_at: z.ZodString;
|
|
913
|
+
broadcaster_user_id: z.ZodString;
|
|
914
|
+
broadcaster_user_login: z.ZodString;
|
|
915
|
+
broadcaster_user_name: z.ZodString;
|
|
916
|
+
}, z.core.$loose>;
|
|
917
|
+
readonly "twitch:prediction_end": z.ZodObject<{
|
|
918
|
+
status: z.ZodString;
|
|
919
|
+
ended_at: z.ZodString;
|
|
920
|
+
winning_outcome_id: z.ZodNullable<z.ZodString>;
|
|
921
|
+
id: z.ZodString;
|
|
922
|
+
title: z.ZodString;
|
|
923
|
+
outcomes: z.ZodArray<z.ZodObject<{
|
|
924
|
+
id: z.ZodString;
|
|
925
|
+
title: z.ZodString;
|
|
926
|
+
color: z.ZodString;
|
|
927
|
+
users: z.ZodOptional<z.ZodNumber>;
|
|
928
|
+
channel_points: z.ZodOptional<z.ZodNumber>;
|
|
929
|
+
top_predictors: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
|
|
930
|
+
channel_points_used: z.ZodNumber;
|
|
931
|
+
channel_points_won: z.ZodNullable<z.ZodNumber>;
|
|
932
|
+
user_id: z.ZodString;
|
|
933
|
+
user_login: z.ZodString;
|
|
934
|
+
user_name: z.ZodString;
|
|
935
|
+
}, z.core.$loose>>>>;
|
|
936
|
+
}, z.core.$loose>>;
|
|
937
|
+
started_at: z.ZodString;
|
|
938
|
+
broadcaster_user_id: z.ZodString;
|
|
939
|
+
broadcaster_user_login: z.ZodString;
|
|
940
|
+
broadcaster_user_name: z.ZodString;
|
|
941
|
+
}, z.core.$loose>;
|
|
942
|
+
readonly "twitch:goal": z.ZodObject<{
|
|
943
|
+
id: z.ZodString;
|
|
944
|
+
type: z.ZodString;
|
|
945
|
+
description: z.ZodString;
|
|
946
|
+
current_amount: z.ZodNumber;
|
|
947
|
+
target_amount: z.ZodNumber;
|
|
948
|
+
started_at: z.ZodString;
|
|
949
|
+
broadcaster_user_id: z.ZodString;
|
|
950
|
+
broadcaster_user_login: z.ZodString;
|
|
951
|
+
broadcaster_user_name: z.ZodString;
|
|
952
|
+
}, z.core.$loose>;
|
|
953
|
+
readonly "twitch:goal_end": z.ZodObject<{
|
|
954
|
+
ended_at: z.ZodString;
|
|
955
|
+
is_achieved: z.ZodBoolean;
|
|
956
|
+
id: z.ZodString;
|
|
957
|
+
type: z.ZodString;
|
|
958
|
+
description: z.ZodString;
|
|
959
|
+
current_amount: z.ZodNumber;
|
|
960
|
+
target_amount: z.ZodNumber;
|
|
961
|
+
started_at: z.ZodString;
|
|
962
|
+
broadcaster_user_id: z.ZodString;
|
|
963
|
+
broadcaster_user_login: z.ZodString;
|
|
964
|
+
broadcaster_user_name: z.ZodString;
|
|
965
|
+
}, z.core.$loose>;
|
|
966
|
+
readonly "twitch:ad_break": z.ZodObject<{
|
|
967
|
+
requester_user_id: z.ZodString;
|
|
968
|
+
requester_user_login: z.ZodString;
|
|
969
|
+
requester_user_name: z.ZodString;
|
|
970
|
+
/** Seconds; Twitch's own sample payload sends it as a string. */
|
|
971
|
+
duration_seconds: z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>;
|
|
972
|
+
/** Twitch's own sample payload sends it as a string. */
|
|
973
|
+
is_automatic: z.ZodUnion<readonly [z.ZodBoolean, z.ZodString]>;
|
|
974
|
+
started_at: z.ZodString;
|
|
975
|
+
broadcaster_user_id: z.ZodString;
|
|
976
|
+
broadcaster_user_login: z.ZodString;
|
|
977
|
+
broadcaster_user_name: z.ZodString;
|
|
978
|
+
}, z.core.$loose>;
|
|
979
|
+
readonly "twitch:ban": z.ZodObject<{
|
|
980
|
+
action: z.ZodString;
|
|
981
|
+
platform: z.ZodString;
|
|
982
|
+
target_user_id: z.ZodNullable<z.ZodString>;
|
|
983
|
+
target_username: z.ZodNullable<z.ZodString>;
|
|
984
|
+
target_display_name: z.ZodNullable<z.ZodString>;
|
|
985
|
+
moderator_name: z.ZodString;
|
|
986
|
+
moderator_login: z.ZodNullable<z.ZodString>;
|
|
987
|
+
reason: z.ZodNullable<z.ZodString>;
|
|
988
|
+
duration_secs: z.ZodNullable<z.ZodNumber>;
|
|
989
|
+
ends_at: z.ZodNullable<z.ZodString>;
|
|
990
|
+
target_message_id: z.ZodNullable<z.ZodString>;
|
|
991
|
+
created_at: z.ZodString;
|
|
992
|
+
}, z.core.$loose>;
|
|
993
|
+
readonly "twitch:unban": z.ZodObject<{
|
|
994
|
+
action: z.ZodString;
|
|
995
|
+
platform: z.ZodString;
|
|
996
|
+
target_user_id: z.ZodNullable<z.ZodString>;
|
|
997
|
+
target_username: z.ZodNullable<z.ZodString>;
|
|
998
|
+
target_display_name: z.ZodNullable<z.ZodString>;
|
|
999
|
+
moderator_name: z.ZodString;
|
|
1000
|
+
moderator_login: z.ZodNullable<z.ZodString>;
|
|
1001
|
+
reason: z.ZodNullable<z.ZodString>;
|
|
1002
|
+
duration_secs: z.ZodNullable<z.ZodNumber>;
|
|
1003
|
+
ends_at: z.ZodNullable<z.ZodString>;
|
|
1004
|
+
target_message_id: z.ZodNullable<z.ZodString>;
|
|
1005
|
+
created_at: z.ZodString;
|
|
1006
|
+
}, z.core.$loose>;
|
|
1007
|
+
readonly "twitch:stream_online": z.ZodObject<{
|
|
1008
|
+
id: z.ZodString;
|
|
1009
|
+
type: z.ZodString;
|
|
1010
|
+
started_at: z.ZodString;
|
|
1011
|
+
/** Channel info from Helix, when it loaded. */
|
|
1012
|
+
title: z.ZodOptional<z.ZodString>;
|
|
1013
|
+
category: z.ZodOptional<z.ZodString>;
|
|
1014
|
+
broadcaster_user_id: z.ZodString;
|
|
1015
|
+
broadcaster_user_login: z.ZodString;
|
|
1016
|
+
broadcaster_user_name: z.ZodString;
|
|
1017
|
+
}, z.core.$loose>;
|
|
1018
|
+
readonly "twitch:stream_offline": z.ZodObject<{
|
|
1019
|
+
/** Set when the stream's start is known. */
|
|
1020
|
+
started_at: z.ZodOptional<z.ZodString>;
|
|
1021
|
+
duration_seconds: z.ZodOptional<z.ZodNumber>;
|
|
1022
|
+
broadcaster_user_id: z.ZodString;
|
|
1023
|
+
broadcaster_user_login: z.ZodString;
|
|
1024
|
+
broadcaster_user_name: z.ZodString;
|
|
1025
|
+
}, z.core.$loose>;
|
|
1026
|
+
readonly "twitch:stream_update": z.ZodObject<{
|
|
1027
|
+
title: z.ZodString;
|
|
1028
|
+
language: z.ZodString;
|
|
1029
|
+
category_id: z.ZodString;
|
|
1030
|
+
category_name: z.ZodString;
|
|
1031
|
+
content_classification_labels: z.ZodArray<z.ZodString>;
|
|
1032
|
+
tags: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
1033
|
+
/** Diff against the previous channel info, when it was known. */
|
|
1034
|
+
title_changed: z.ZodOptional<z.ZodBoolean>;
|
|
1035
|
+
category_changed: z.ZodOptional<z.ZodBoolean>;
|
|
1036
|
+
language_changed: z.ZodOptional<z.ZodBoolean>;
|
|
1037
|
+
tags_changed: z.ZodOptional<z.ZodBoolean>;
|
|
1038
|
+
old_title: z.ZodOptional<z.ZodString>;
|
|
1039
|
+
old_category_name: z.ZodOptional<z.ZodString>;
|
|
1040
|
+
old_tags: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
1041
|
+
broadcaster_user_id: z.ZodString;
|
|
1042
|
+
broadcaster_user_login: z.ZodString;
|
|
1043
|
+
broadcaster_user_name: z.ZodString;
|
|
1044
|
+
}, z.core.$loose>;
|
|
1045
|
+
readonly "youtube:subscribe": z.ZodObject<{
|
|
1046
|
+
channel_id: z.ZodString;
|
|
1047
|
+
video_id: z.ZodString;
|
|
1048
|
+
title: z.ZodString;
|
|
1049
|
+
published: z.ZodString;
|
|
1050
|
+
updated: z.ZodString;
|
|
1051
|
+
}, z.core.$loose>;
|
|
1052
|
+
readonly "youtube:member": z.ZodObject<{
|
|
1053
|
+
membership_event_type: z.ZodString;
|
|
1054
|
+
memberLevelName: z.ZodNullable<z.ZodString>;
|
|
1055
|
+
memberMonth: z.ZodNullable<z.ZodNumber>;
|
|
1056
|
+
isUpgrade: z.ZodBoolean;
|
|
1057
|
+
display_message: z.ZodString;
|
|
1058
|
+
userComment: z.ZodString;
|
|
1059
|
+
user_id: z.ZodString;
|
|
1060
|
+
user_login: z.ZodString;
|
|
1061
|
+
displayName: z.ZodString;
|
|
1062
|
+
avatarUrl: z.ZodString;
|
|
1063
|
+
}, z.core.$loose>;
|
|
1064
|
+
readonly "youtube:superchat": z.ZodObject<{
|
|
1065
|
+
amountMicros: z.ZodNumber;
|
|
1066
|
+
amountDisplayString: z.ZodString;
|
|
1067
|
+
currency: z.ZodString;
|
|
1068
|
+
tier: z.ZodNumber;
|
|
1069
|
+
userComment: z.ZodString;
|
|
1070
|
+
headerBackgroundColor: z.ZodNumber;
|
|
1071
|
+
bodyBackgroundColor: z.ZodNumber;
|
|
1072
|
+
user_id: z.ZodString;
|
|
1073
|
+
user_login: z.ZodString;
|
|
1074
|
+
displayName: z.ZodString;
|
|
1075
|
+
avatarUrl: z.ZodString;
|
|
1076
|
+
}, z.core.$loose>;
|
|
1077
|
+
readonly "youtube:supersticker": z.ZodObject<{
|
|
1078
|
+
amountMicros: z.ZodNumber;
|
|
1079
|
+
amountDisplayString: z.ZodString;
|
|
1080
|
+
currency: z.ZodString;
|
|
1081
|
+
stickerName: z.ZodString;
|
|
1082
|
+
stickerUrl: z.ZodString;
|
|
1083
|
+
user_id: z.ZodString;
|
|
1084
|
+
user_login: z.ZodString;
|
|
1085
|
+
displayName: z.ZodString;
|
|
1086
|
+
avatarUrl: z.ZodString;
|
|
1087
|
+
}, z.core.$loose>;
|
|
1088
|
+
readonly "youtube:gift_membership": z.ZodObject<{
|
|
1089
|
+
giftCount: z.ZodNumber;
|
|
1090
|
+
isGift: z.ZodBoolean;
|
|
1091
|
+
gift_memberships_level_name: z.ZodNullable<z.ZodString>;
|
|
1092
|
+
user_id: z.ZodString;
|
|
1093
|
+
user_login: z.ZodString;
|
|
1094
|
+
displayName: z.ZodString;
|
|
1095
|
+
avatarUrl: z.ZodString;
|
|
1096
|
+
}, z.core.$loose>;
|
|
1097
|
+
/** Stored in the event history only; never broadcast live (no fixture). */
|
|
1098
|
+
readonly "youtube:gift_membership_received": z.ZodObject<{
|
|
1099
|
+
user_id: z.ZodNullable<z.ZodString>;
|
|
1100
|
+
user_login: z.ZodNullable<z.ZodString>;
|
|
1101
|
+
displayName: z.ZodString;
|
|
1102
|
+
avatarUrl: z.ZodNullable<z.ZodString>;
|
|
1103
|
+
gifter_channel_id: z.ZodNullable<z.ZodString>;
|
|
1104
|
+
gifter_display_name: z.ZodNullable<z.ZodString>;
|
|
1105
|
+
gift_memberships_level_name: z.ZodNullable<z.ZodString>;
|
|
1106
|
+
}, z.core.$loose>;
|
|
1107
|
+
readonly "youtube:poll": z.ZodObject<{
|
|
1108
|
+
poll_id: z.ZodString;
|
|
1109
|
+
question: z.ZodString;
|
|
1110
|
+
status: z.ZodString;
|
|
1111
|
+
options: z.ZodArray<z.ZodObject<{
|
|
1112
|
+
option_text: z.ZodString;
|
|
1113
|
+
tally: z.ZodNullable<z.ZodString>;
|
|
1114
|
+
vote_ratio: z.ZodNullable<z.ZodNumber>;
|
|
1115
|
+
}, z.core.$loose>>;
|
|
1116
|
+
}, z.core.$loose>;
|
|
1117
|
+
readonly "youtube:stream_online": z.ZodObject<{
|
|
1118
|
+
broadcast_id: z.ZodString;
|
|
1119
|
+
started_at: z.ZodString;
|
|
1120
|
+
title: z.ZodOptional<z.ZodString>;
|
|
1121
|
+
category: z.ZodOptional<z.ZodString>;
|
|
1122
|
+
}, z.core.$loose>;
|
|
1123
|
+
readonly "youtube:stream_offline": z.ZodObject<{
|
|
1124
|
+
broadcast_id: z.ZodString;
|
|
1125
|
+
started_at: z.ZodOptional<z.ZodString>;
|
|
1126
|
+
duration_seconds: z.ZodOptional<z.ZodNumber>;
|
|
1127
|
+
}, z.core.$loose>;
|
|
1128
|
+
readonly "kick:follower": z.ZodObject<{
|
|
1129
|
+
broadcaster: z.ZodObject<{
|
|
1130
|
+
user_id: z.ZodNumber;
|
|
1131
|
+
username: z.ZodString;
|
|
1132
|
+
channel_slug: z.ZodString;
|
|
1133
|
+
is_verified: z.ZodBoolean;
|
|
1134
|
+
profile_picture: z.ZodString;
|
|
1135
|
+
is_anonymous: z.ZodOptional<z.ZodBoolean>;
|
|
1136
|
+
identity: z.ZodOptional<z.ZodUnknown>;
|
|
1137
|
+
}, z.core.$loose>;
|
|
1138
|
+
follower: z.ZodObject<{
|
|
1139
|
+
user_id: z.ZodNumber;
|
|
1140
|
+
username: z.ZodString;
|
|
1141
|
+
channel_slug: z.ZodString;
|
|
1142
|
+
is_verified: z.ZodBoolean;
|
|
1143
|
+
profile_picture: z.ZodString;
|
|
1144
|
+
is_anonymous: z.ZodOptional<z.ZodBoolean>;
|
|
1145
|
+
identity: z.ZodOptional<z.ZodUnknown>;
|
|
1146
|
+
}, z.core.$loose>;
|
|
1147
|
+
avatarUrl: z.ZodOptional<z.ZodString>;
|
|
1148
|
+
user_id: z.ZodString;
|
|
1149
|
+
user_login: z.ZodString;
|
|
1150
|
+
user_name: z.ZodString;
|
|
1151
|
+
is_anonymous: z.ZodBoolean;
|
|
1152
|
+
}, z.core.$loose>;
|
|
1153
|
+
readonly "kick:subscribe": z.ZodObject<{
|
|
1154
|
+
broadcaster: z.ZodObject<{
|
|
1155
|
+
user_id: z.ZodNumber;
|
|
1156
|
+
username: z.ZodString;
|
|
1157
|
+
channel_slug: z.ZodString;
|
|
1158
|
+
is_verified: z.ZodBoolean;
|
|
1159
|
+
profile_picture: z.ZodString;
|
|
1160
|
+
is_anonymous: z.ZodOptional<z.ZodBoolean>;
|
|
1161
|
+
identity: z.ZodOptional<z.ZodUnknown>;
|
|
1162
|
+
}, z.core.$loose>;
|
|
1163
|
+
subscriber: z.ZodObject<{
|
|
1164
|
+
user_id: z.ZodNumber;
|
|
1165
|
+
username: z.ZodString;
|
|
1166
|
+
channel_slug: z.ZodString;
|
|
1167
|
+
is_verified: z.ZodBoolean;
|
|
1168
|
+
profile_picture: z.ZodString;
|
|
1169
|
+
is_anonymous: z.ZodOptional<z.ZodBoolean>;
|
|
1170
|
+
identity: z.ZodOptional<z.ZodUnknown>;
|
|
1171
|
+
}, z.core.$loose>;
|
|
1172
|
+
duration: z.ZodNumber;
|
|
1173
|
+
cumulative_months: z.ZodNumber;
|
|
1174
|
+
created_at: z.ZodString;
|
|
1175
|
+
expires_at: z.ZodString;
|
|
1176
|
+
avatarUrl: z.ZodOptional<z.ZodString>;
|
|
1177
|
+
user_id: z.ZodString;
|
|
1178
|
+
user_login: z.ZodString;
|
|
1179
|
+
user_name: z.ZodString;
|
|
1180
|
+
is_anonymous: z.ZodBoolean;
|
|
1181
|
+
}, z.core.$loose>;
|
|
1182
|
+
readonly "kick:resub": z.ZodObject<{
|
|
1183
|
+
broadcaster: z.ZodObject<{
|
|
1184
|
+
user_id: z.ZodNumber;
|
|
1185
|
+
username: z.ZodString;
|
|
1186
|
+
channel_slug: z.ZodString;
|
|
1187
|
+
is_verified: z.ZodBoolean;
|
|
1188
|
+
profile_picture: z.ZodString;
|
|
1189
|
+
is_anonymous: z.ZodOptional<z.ZodBoolean>;
|
|
1190
|
+
identity: z.ZodOptional<z.ZodUnknown>;
|
|
1191
|
+
}, z.core.$loose>;
|
|
1192
|
+
subscriber: z.ZodObject<{
|
|
1193
|
+
user_id: z.ZodNumber;
|
|
1194
|
+
username: z.ZodString;
|
|
1195
|
+
channel_slug: z.ZodString;
|
|
1196
|
+
is_verified: z.ZodBoolean;
|
|
1197
|
+
profile_picture: z.ZodString;
|
|
1198
|
+
is_anonymous: z.ZodOptional<z.ZodBoolean>;
|
|
1199
|
+
identity: z.ZodOptional<z.ZodUnknown>;
|
|
1200
|
+
}, z.core.$loose>;
|
|
1201
|
+
duration: z.ZodNumber;
|
|
1202
|
+
cumulative_months: z.ZodNumber;
|
|
1203
|
+
created_at: z.ZodString;
|
|
1204
|
+
expires_at: z.ZodString;
|
|
1205
|
+
avatarUrl: z.ZodOptional<z.ZodString>;
|
|
1206
|
+
user_id: z.ZodString;
|
|
1207
|
+
user_login: z.ZodString;
|
|
1208
|
+
user_name: z.ZodString;
|
|
1209
|
+
is_anonymous: z.ZodBoolean;
|
|
1210
|
+
}, z.core.$loose>;
|
|
1211
|
+
readonly "kick:gift": z.ZodObject<{
|
|
1212
|
+
broadcaster: z.ZodObject<{
|
|
1213
|
+
user_id: z.ZodNumber;
|
|
1214
|
+
username: z.ZodString;
|
|
1215
|
+
channel_slug: z.ZodString;
|
|
1216
|
+
is_verified: z.ZodBoolean;
|
|
1217
|
+
profile_picture: z.ZodString;
|
|
1218
|
+
is_anonymous: z.ZodOptional<z.ZodBoolean>;
|
|
1219
|
+
identity: z.ZodOptional<z.ZodUnknown>;
|
|
1220
|
+
}, z.core.$loose>;
|
|
1221
|
+
gifter: z.ZodObject<{
|
|
1222
|
+
user_id: z.ZodNumber;
|
|
1223
|
+
username: z.ZodString;
|
|
1224
|
+
channel_slug: z.ZodString;
|
|
1225
|
+
is_verified: z.ZodBoolean;
|
|
1226
|
+
profile_picture: z.ZodString;
|
|
1227
|
+
is_anonymous: z.ZodOptional<z.ZodBoolean>;
|
|
1228
|
+
identity: z.ZodOptional<z.ZodUnknown>;
|
|
1229
|
+
}, z.core.$loose>;
|
|
1230
|
+
giftees: z.ZodArray<z.ZodObject<{
|
|
1231
|
+
user_id: z.ZodNumber;
|
|
1232
|
+
username: z.ZodString;
|
|
1233
|
+
channel_slug: z.ZodString;
|
|
1234
|
+
is_verified: z.ZodBoolean;
|
|
1235
|
+
profile_picture: z.ZodString;
|
|
1236
|
+
is_anonymous: z.ZodOptional<z.ZodBoolean>;
|
|
1237
|
+
identity: z.ZodOptional<z.ZodUnknown>;
|
|
1238
|
+
}, z.core.$loose>>;
|
|
1239
|
+
/** Usernames of `giftees`. */
|
|
1240
|
+
giftRecipients: z.ZodArray<z.ZodString>;
|
|
1241
|
+
giftCount: z.ZodNumber;
|
|
1242
|
+
total: z.ZodNumber;
|
|
1243
|
+
isGift: z.ZodBoolean;
|
|
1244
|
+
is_gift: z.ZodBoolean;
|
|
1245
|
+
/** The first giftee. */
|
|
1246
|
+
recipient_user_id: z.ZodOptional<z.ZodString>;
|
|
1247
|
+
recipient_user_login: z.ZodOptional<z.ZodString>;
|
|
1248
|
+
recipient_user_name: z.ZodOptional<z.ZodString>;
|
|
1249
|
+
created_at: z.ZodString;
|
|
1250
|
+
expires_at: z.ZodString;
|
|
1251
|
+
avatarUrl: z.ZodOptional<z.ZodString>;
|
|
1252
|
+
user_id: z.ZodString;
|
|
1253
|
+
user_login: z.ZodString;
|
|
1254
|
+
user_name: z.ZodString;
|
|
1255
|
+
is_anonymous: z.ZodBoolean;
|
|
1256
|
+
}, z.core.$loose>;
|
|
1257
|
+
readonly "kick:kicks": z.ZodObject<{
|
|
1258
|
+
broadcaster: z.ZodObject<{
|
|
1259
|
+
user_id: z.ZodNumber;
|
|
1260
|
+
username: z.ZodString;
|
|
1261
|
+
channel_slug: z.ZodString;
|
|
1262
|
+
is_verified: z.ZodBoolean;
|
|
1263
|
+
profile_picture: z.ZodString;
|
|
1264
|
+
is_anonymous: z.ZodOptional<z.ZodBoolean>;
|
|
1265
|
+
identity: z.ZodOptional<z.ZodUnknown>;
|
|
1266
|
+
}, z.core.$loose>;
|
|
1267
|
+
sender: z.ZodObject<{
|
|
1268
|
+
user_id: z.ZodNumber;
|
|
1269
|
+
username: z.ZodString;
|
|
1270
|
+
channel_slug: z.ZodString;
|
|
1271
|
+
is_verified: z.ZodBoolean;
|
|
1272
|
+
profile_picture: z.ZodString;
|
|
1273
|
+
is_anonymous: z.ZodOptional<z.ZodBoolean>;
|
|
1274
|
+
identity: z.ZodOptional<z.ZodUnknown>;
|
|
1275
|
+
}, z.core.$loose>;
|
|
1276
|
+
gift: z.ZodObject<{
|
|
1277
|
+
amount: z.ZodNumber;
|
|
1278
|
+
name: z.ZodString;
|
|
1279
|
+
type: z.ZodString;
|
|
1280
|
+
tier: z.ZodString;
|
|
1281
|
+
message: z.ZodString;
|
|
1282
|
+
pinned_time_seconds: z.ZodNumber;
|
|
1283
|
+
}, z.core.$loose>;
|
|
1284
|
+
kicks: z.ZodNumber;
|
|
1285
|
+
message: z.ZodString;
|
|
1286
|
+
kick_gift_id: z.ZodString;
|
|
1287
|
+
kick_gift_name: z.ZodString;
|
|
1288
|
+
kick_gift_type: z.ZodString;
|
|
1289
|
+
kick_gift_tier: z.ZodString;
|
|
1290
|
+
kick_gift_color: z.ZodString;
|
|
1291
|
+
kick_gift_image: z.ZodObject<{
|
|
1292
|
+
static: z.ZodString;
|
|
1293
|
+
animated: z.ZodString;
|
|
1294
|
+
}, z.core.$loose>;
|
|
1295
|
+
kick_pinned_time_seconds: z.ZodNumber;
|
|
1296
|
+
created_at: z.ZodString;
|
|
1297
|
+
avatarUrl: z.ZodOptional<z.ZodString>;
|
|
1298
|
+
user_id: z.ZodString;
|
|
1299
|
+
user_login: z.ZodString;
|
|
1300
|
+
user_name: z.ZodString;
|
|
1301
|
+
is_anonymous: z.ZodBoolean;
|
|
1302
|
+
}, z.core.$loose>;
|
|
1303
|
+
readonly "kick:reward": z.ZodObject<{
|
|
1304
|
+
broadcaster: z.ZodObject<{
|
|
1305
|
+
user_id: z.ZodNumber;
|
|
1306
|
+
username: z.ZodString;
|
|
1307
|
+
channel_slug: z.ZodString;
|
|
1308
|
+
is_verified: z.ZodBoolean;
|
|
1309
|
+
profile_picture: z.ZodString;
|
|
1310
|
+
is_anonymous: z.ZodOptional<z.ZodBoolean>;
|
|
1311
|
+
identity: z.ZodOptional<z.ZodUnknown>;
|
|
1312
|
+
}, z.core.$loose>;
|
|
1313
|
+
redeemer: z.ZodObject<{
|
|
1314
|
+
user_id: z.ZodNumber;
|
|
1315
|
+
username: z.ZodString;
|
|
1316
|
+
channel_slug: z.ZodString;
|
|
1317
|
+
is_verified: z.ZodBoolean;
|
|
1318
|
+
profile_picture: z.ZodString;
|
|
1319
|
+
is_anonymous: z.ZodOptional<z.ZodBoolean>;
|
|
1320
|
+
identity: z.ZodOptional<z.ZodUnknown>;
|
|
1321
|
+
}, z.core.$loose>;
|
|
1322
|
+
id: z.ZodString;
|
|
1323
|
+
user_input: z.ZodString;
|
|
1324
|
+
status: z.ZodString;
|
|
1325
|
+
redeemed_at: z.ZodString;
|
|
1326
|
+
reward: z.ZodObject<{
|
|
1327
|
+
id: z.ZodString;
|
|
1328
|
+
title: z.ZodString;
|
|
1329
|
+
cost: z.ZodNumber;
|
|
1330
|
+
}, z.core.$loose>;
|
|
1331
|
+
user_id: z.ZodString;
|
|
1332
|
+
user_login: z.ZodString;
|
|
1333
|
+
user_name: z.ZodString;
|
|
1334
|
+
is_anonymous: z.ZodBoolean;
|
|
1335
|
+
}, z.core.$loose>;
|
|
1336
|
+
readonly "kick:reward_status": z.ZodObject<{
|
|
1337
|
+
broadcaster: z.ZodObject<{
|
|
1338
|
+
user_id: z.ZodNumber;
|
|
1339
|
+
username: z.ZodString;
|
|
1340
|
+
channel_slug: z.ZodString;
|
|
1341
|
+
is_verified: z.ZodBoolean;
|
|
1342
|
+
profile_picture: z.ZodString;
|
|
1343
|
+
is_anonymous: z.ZodOptional<z.ZodBoolean>;
|
|
1344
|
+
identity: z.ZodOptional<z.ZodUnknown>;
|
|
1345
|
+
}, z.core.$loose>;
|
|
1346
|
+
redeemer: z.ZodObject<{
|
|
1347
|
+
user_id: z.ZodNumber;
|
|
1348
|
+
username: z.ZodString;
|
|
1349
|
+
channel_slug: z.ZodString;
|
|
1350
|
+
is_verified: z.ZodBoolean;
|
|
1351
|
+
profile_picture: z.ZodString;
|
|
1352
|
+
is_anonymous: z.ZodOptional<z.ZodBoolean>;
|
|
1353
|
+
identity: z.ZodOptional<z.ZodUnknown>;
|
|
1354
|
+
}, z.core.$loose>;
|
|
1355
|
+
id: z.ZodString;
|
|
1356
|
+
user_input: z.ZodString;
|
|
1357
|
+
status: z.ZodString;
|
|
1358
|
+
redeemed_at: z.ZodString;
|
|
1359
|
+
reward: z.ZodObject<{
|
|
1360
|
+
id: z.ZodString;
|
|
1361
|
+
title: z.ZodString;
|
|
1362
|
+
cost: z.ZodNumber;
|
|
1363
|
+
}, z.core.$loose>;
|
|
1364
|
+
user_id: z.ZodString;
|
|
1365
|
+
user_login: z.ZodString;
|
|
1366
|
+
user_name: z.ZodString;
|
|
1367
|
+
is_anonymous: z.ZodBoolean;
|
|
1368
|
+
}, z.core.$loose>;
|
|
1369
|
+
readonly "kick:stream_online": z.ZodObject<{
|
|
1370
|
+
broadcaster: z.ZodObject<{
|
|
1371
|
+
user_id: z.ZodNumber;
|
|
1372
|
+
username: z.ZodString;
|
|
1373
|
+
channel_slug: z.ZodString;
|
|
1374
|
+
is_verified: z.ZodBoolean;
|
|
1375
|
+
profile_picture: z.ZodString;
|
|
1376
|
+
is_anonymous: z.ZodOptional<z.ZodBoolean>;
|
|
1377
|
+
identity: z.ZodOptional<z.ZodUnknown>;
|
|
1378
|
+
}, z.core.$loose>;
|
|
1379
|
+
is_live: z.ZodBoolean;
|
|
1380
|
+
title: z.ZodString;
|
|
1381
|
+
started_at: z.ZodString;
|
|
1382
|
+
ended_at: z.ZodNullable<z.ZodString>;
|
|
1383
|
+
}, z.core.$loose>;
|
|
1384
|
+
readonly "kick:stream_offline": z.ZodObject<{
|
|
1385
|
+
broadcaster: z.ZodObject<{
|
|
1386
|
+
user_id: z.ZodNumber;
|
|
1387
|
+
username: z.ZodString;
|
|
1388
|
+
channel_slug: z.ZodString;
|
|
1389
|
+
is_verified: z.ZodBoolean;
|
|
1390
|
+
profile_picture: z.ZodString;
|
|
1391
|
+
is_anonymous: z.ZodOptional<z.ZodBoolean>;
|
|
1392
|
+
identity: z.ZodOptional<z.ZodUnknown>;
|
|
1393
|
+
}, z.core.$loose>;
|
|
1394
|
+
is_live: z.ZodBoolean;
|
|
1395
|
+
title: z.ZodString;
|
|
1396
|
+
started_at: z.ZodString;
|
|
1397
|
+
ended_at: z.ZodString;
|
|
1398
|
+
duration_seconds: z.ZodOptional<z.ZodNumber>;
|
|
1399
|
+
}, z.core.$loose>;
|
|
1400
|
+
readonly "kick:stream_update": z.ZodObject<{
|
|
1401
|
+
broadcaster: z.ZodObject<{
|
|
1402
|
+
user_id: z.ZodNumber;
|
|
1403
|
+
username: z.ZodString;
|
|
1404
|
+
channel_slug: z.ZodString;
|
|
1405
|
+
is_verified: z.ZodBoolean;
|
|
1406
|
+
profile_picture: z.ZodString;
|
|
1407
|
+
is_anonymous: z.ZodOptional<z.ZodBoolean>;
|
|
1408
|
+
identity: z.ZodOptional<z.ZodUnknown>;
|
|
1409
|
+
}, z.core.$loose>;
|
|
1410
|
+
metadata: z.ZodObject<{
|
|
1411
|
+
title: z.ZodString;
|
|
1412
|
+
language: z.ZodString;
|
|
1413
|
+
has_mature_content: z.ZodBoolean;
|
|
1414
|
+
category: z.ZodObject<{
|
|
1415
|
+
id: z.ZodNumber;
|
|
1416
|
+
name: z.ZodString;
|
|
1417
|
+
thumbnail: z.ZodString;
|
|
1418
|
+
}, z.core.$loose>;
|
|
1419
|
+
}, z.core.$loose>;
|
|
1420
|
+
title: z.ZodString;
|
|
1421
|
+
language: z.ZodString;
|
|
1422
|
+
has_mature_content: z.ZodBoolean;
|
|
1423
|
+
category_id: z.ZodString;
|
|
1424
|
+
category_name: z.ZodString;
|
|
1425
|
+
/** Diff against the previous stream info, when it was known. */
|
|
1426
|
+
title_changed: z.ZodOptional<z.ZodBoolean>;
|
|
1427
|
+
category_changed: z.ZodOptional<z.ZodBoolean>;
|
|
1428
|
+
language_changed: z.ZodOptional<z.ZodBoolean>;
|
|
1429
|
+
old_title: z.ZodOptional<z.ZodString>;
|
|
1430
|
+
}, z.core.$loose>;
|
|
1431
|
+
readonly "spotify:track": z.ZodObject<{
|
|
1432
|
+
is_playing: z.ZodBoolean;
|
|
1433
|
+
progress_ms: z.ZodNumber;
|
|
1434
|
+
timestamp: z.ZodNumber;
|
|
1435
|
+
shuffle: z.ZodString;
|
|
1436
|
+
repeat: z.ZodString;
|
|
1437
|
+
track: z.ZodObject<{
|
|
1438
|
+
id: z.ZodString;
|
|
1439
|
+
uri: z.ZodString;
|
|
1440
|
+
name: z.ZodString;
|
|
1441
|
+
artist: z.ZodString;
|
|
1442
|
+
album: z.ZodString;
|
|
1443
|
+
album_art: z.ZodString;
|
|
1444
|
+
duration_ms: z.ZodNumber;
|
|
1445
|
+
}, z.core.$loose>;
|
|
1446
|
+
device: z.ZodNullable<z.ZodObject<{
|
|
1447
|
+
id: z.ZodString;
|
|
1448
|
+
name: z.ZodString;
|
|
1449
|
+
device_type: z.ZodString;
|
|
1450
|
+
is_active: z.ZodBoolean;
|
|
1451
|
+
volume_percent: z.ZodNullable<z.ZodNumber>;
|
|
1452
|
+
}, z.core.$loose>>;
|
|
1453
|
+
context: z.ZodNullable<z.ZodObject<{
|
|
1454
|
+
context_type: z.ZodString;
|
|
1455
|
+
id: z.ZodString;
|
|
1456
|
+
name: z.ZodNullable<z.ZodString>;
|
|
1457
|
+
uri: z.ZodString;
|
|
1458
|
+
}, z.core.$loose>>;
|
|
1459
|
+
/** The Lumio user whose action caused the change; `null` when it came from Spotify. */
|
|
1460
|
+
triggered_by: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
1461
|
+
}, z.core.$loose>;
|
|
1462
|
+
readonly "spotify:play": z.ZodObject<{
|
|
1463
|
+
track_uri: z.ZodString;
|
|
1464
|
+
source: z.ZodOptional<z.ZodString>;
|
|
1465
|
+
extension_id: z.ZodOptional<z.ZodString>;
|
|
1466
|
+
install_id: z.ZodOptional<z.ZodString>;
|
|
1467
|
+
action: z.ZodString;
|
|
1468
|
+
track_id: z.ZodString;
|
|
1469
|
+
track_name: z.ZodString;
|
|
1470
|
+
artist: z.ZodString;
|
|
1471
|
+
album: z.ZodString;
|
|
1472
|
+
album_art: z.ZodString;
|
|
1473
|
+
song_url: z.ZodString;
|
|
1474
|
+
}, z.core.$loose>;
|
|
1475
|
+
readonly "spotify:pause": z.ZodObject<{
|
|
1476
|
+
source: z.ZodOptional<z.ZodString>;
|
|
1477
|
+
extension_id: z.ZodOptional<z.ZodString>;
|
|
1478
|
+
install_id: z.ZodOptional<z.ZodString>;
|
|
1479
|
+
action: z.ZodString;
|
|
1480
|
+
track_id: z.ZodString;
|
|
1481
|
+
track_name: z.ZodString;
|
|
1482
|
+
artist: z.ZodString;
|
|
1483
|
+
album: z.ZodString;
|
|
1484
|
+
album_art: z.ZodString;
|
|
1485
|
+
song_url: z.ZodString;
|
|
1486
|
+
}, z.core.$loose>;
|
|
1487
|
+
readonly "spotify:skip": z.ZodObject<{
|
|
1488
|
+
source: z.ZodOptional<z.ZodString>;
|
|
1489
|
+
extension_id: z.ZodOptional<z.ZodString>;
|
|
1490
|
+
install_id: z.ZodOptional<z.ZodString>;
|
|
1491
|
+
action: z.ZodString;
|
|
1492
|
+
}, z.core.$loose>;
|
|
1493
|
+
readonly "spotify:volume": z.ZodObject<{
|
|
1494
|
+
oldVolume: z.ZodNumber;
|
|
1495
|
+
newVolume: z.ZodNumber;
|
|
1496
|
+
volume_percent: z.ZodNumber;
|
|
1497
|
+
source: z.ZodOptional<z.ZodString>;
|
|
1498
|
+
extension_id: z.ZodOptional<z.ZodString>;
|
|
1499
|
+
install_id: z.ZodOptional<z.ZodString>;
|
|
1500
|
+
action: z.ZodString;
|
|
1501
|
+
track_id: z.ZodString;
|
|
1502
|
+
track_name: z.ZodString;
|
|
1503
|
+
artist: z.ZodString;
|
|
1504
|
+
album: z.ZodString;
|
|
1505
|
+
album_art: z.ZodString;
|
|
1506
|
+
song_url: z.ZodString;
|
|
1507
|
+
}, z.core.$loose>;
|
|
1508
|
+
readonly "spotify:queue_add": z.ZodObject<{
|
|
1509
|
+
source: z.ZodOptional<z.ZodString>;
|
|
1510
|
+
extension_id: z.ZodOptional<z.ZodString>;
|
|
1511
|
+
install_id: z.ZodOptional<z.ZodString>;
|
|
1512
|
+
uri: z.ZodString;
|
|
1513
|
+
}, z.core.$loose>;
|
|
1514
|
+
readonly "spotify:device": z.ZodObject<{
|
|
1515
|
+
fromDevice: z.ZodString;
|
|
1516
|
+
fromDeviceType: z.ZodString;
|
|
1517
|
+
toDevice: z.ZodString;
|
|
1518
|
+
toDeviceType: z.ZodString;
|
|
1519
|
+
}, z.core.$loose>;
|
|
1520
|
+
readonly "spotify:playlist_add": z.ZodObject<{
|
|
1521
|
+
playlistId: z.ZodString;
|
|
1522
|
+
}, z.core.$loose>;
|
|
1523
|
+
readonly "spotify:playlist_remove": z.ZodObject<{
|
|
1524
|
+
playlistId: z.ZodString;
|
|
1525
|
+
trackUri: z.ZodString;
|
|
1526
|
+
}, z.core.$loose>;
|
|
1527
|
+
readonly "spotify:playlist_create": z.ZodObject<{
|
|
1528
|
+
playlistName: z.ZodString;
|
|
1529
|
+
}, z.core.$loose>;
|
|
1530
|
+
readonly "spotify:playlist_edit": z.ZodObject<{
|
|
1531
|
+
playlistName: z.ZodString;
|
|
1532
|
+
}, z.core.$loose>;
|
|
1533
|
+
readonly "spotify:playlist_delete": z.ZodObject<{
|
|
1534
|
+
playlistId: z.ZodString;
|
|
1535
|
+
}, z.core.$loose>;
|
|
1536
|
+
readonly "streamelements:tip": z.ZodObject<{
|
|
1537
|
+
_id: z.ZodString;
|
|
1538
|
+
channel: z.ZodString;
|
|
1539
|
+
provider: z.ZodString;
|
|
1540
|
+
type: z.ZodString;
|
|
1541
|
+
flagged: z.ZodBoolean;
|
|
1542
|
+
createdAt: z.ZodString;
|
|
1543
|
+
updatedAt: z.ZodString;
|
|
1544
|
+
data: z.ZodObject<{
|
|
1545
|
+
tipId: z.ZodString;
|
|
1546
|
+
username: z.ZodString;
|
|
1547
|
+
displayName: z.ZodString;
|
|
1548
|
+
providerId: z.ZodOptional<z.ZodString>;
|
|
1549
|
+
amount: z.ZodNumber;
|
|
1550
|
+
currency: z.ZodString;
|
|
1551
|
+
message: z.ZodString;
|
|
1552
|
+
avatar: z.ZodOptional<z.ZodString>;
|
|
1553
|
+
}, z.core.$loose>;
|
|
1554
|
+
}, z.core.$loose>;
|
|
1555
|
+
readonly "twitch:chat": z.ZodObject<{
|
|
1556
|
+
account_id: z.ZodString;
|
|
1557
|
+
platform: z.ZodString;
|
|
1558
|
+
channel_name: z.ZodNullable<z.ZodString>;
|
|
1559
|
+
user_id: z.ZodNullable<z.ZodString>;
|
|
1560
|
+
username: z.ZodString;
|
|
1561
|
+
display_name: z.ZodNullable<z.ZodString>;
|
|
1562
|
+
avatar_url: z.ZodNullable<z.ZodString>;
|
|
1563
|
+
message: z.ZodString;
|
|
1564
|
+
/** Platform-specific emote entries. */
|
|
1565
|
+
emotes: z.ZodNullable<z.ZodArray<z.ZodUnknown>>;
|
|
1566
|
+
/** Twitch GIF fragments `{ id, url, provider, alt }`; absent without a GIF. */
|
|
1567
|
+
gifs: z.ZodOptional<z.ZodArray<z.ZodUnknown>>;
|
|
1568
|
+
/** Platform-specific badge entries. */
|
|
1569
|
+
badges: z.ZodNullable<z.ZodArray<z.ZodUnknown>>;
|
|
1570
|
+
color: z.ZodNullable<z.ZodString>;
|
|
1571
|
+
is_mod: z.ZodBoolean;
|
|
1572
|
+
is_sub: z.ZodBoolean;
|
|
1573
|
+
is_vip: z.ZodBoolean;
|
|
1574
|
+
sub_tier: z.ZodNullable<z.ZodString>;
|
|
1575
|
+
platform_message_id: z.ZodNullable<z.ZodString>;
|
|
1576
|
+
lumio_user_id: z.ZodNullable<z.ZodString>;
|
|
1577
|
+
reply_parent_msg_id: z.ZodNullable<z.ZodString>;
|
|
1578
|
+
reply_parent_username: z.ZodNullable<z.ZodString>;
|
|
1579
|
+
reply_parent_login: z.ZodNullable<z.ZodString>;
|
|
1580
|
+
reply_parent_message: z.ZodNullable<z.ZodString>;
|
|
1581
|
+
created_at: z.ZodNullable<z.ZodString>;
|
|
1582
|
+
message_type: z.ZodNullable<z.ZodString>;
|
|
1583
|
+
user_treatment: z.ZodNullable<z.ZodString>;
|
|
1584
|
+
live_chat_id: z.ZodOptional<z.ZodString>;
|
|
1585
|
+
is_shared_chat: z.ZodOptional<z.ZodBoolean>;
|
|
1586
|
+
source_channel: z.ZodOptional<z.ZodUnknown>;
|
|
1587
|
+
announcement_color: z.ZodOptional<z.ZodUnknown>;
|
|
1588
|
+
}, z.core.$loose>;
|
|
1589
|
+
readonly "youtube:chat": z.ZodObject<{
|
|
1590
|
+
account_id: z.ZodString;
|
|
1591
|
+
platform: z.ZodString;
|
|
1592
|
+
channel_name: z.ZodNullable<z.ZodString>;
|
|
1593
|
+
user_id: z.ZodNullable<z.ZodString>;
|
|
1594
|
+
username: z.ZodString;
|
|
1595
|
+
display_name: z.ZodNullable<z.ZodString>;
|
|
1596
|
+
avatar_url: z.ZodNullable<z.ZodString>;
|
|
1597
|
+
message: z.ZodString;
|
|
1598
|
+
/** Platform-specific emote entries. */
|
|
1599
|
+
emotes: z.ZodNullable<z.ZodArray<z.ZodUnknown>>;
|
|
1600
|
+
/** Twitch GIF fragments `{ id, url, provider, alt }`; absent without a GIF. */
|
|
1601
|
+
gifs: z.ZodOptional<z.ZodArray<z.ZodUnknown>>;
|
|
1602
|
+
/** Platform-specific badge entries. */
|
|
1603
|
+
badges: z.ZodNullable<z.ZodArray<z.ZodUnknown>>;
|
|
1604
|
+
color: z.ZodNullable<z.ZodString>;
|
|
1605
|
+
is_mod: z.ZodBoolean;
|
|
1606
|
+
is_sub: z.ZodBoolean;
|
|
1607
|
+
is_vip: z.ZodBoolean;
|
|
1608
|
+
sub_tier: z.ZodNullable<z.ZodString>;
|
|
1609
|
+
platform_message_id: z.ZodNullable<z.ZodString>;
|
|
1610
|
+
lumio_user_id: z.ZodNullable<z.ZodString>;
|
|
1611
|
+
reply_parent_msg_id: z.ZodNullable<z.ZodString>;
|
|
1612
|
+
reply_parent_username: z.ZodNullable<z.ZodString>;
|
|
1613
|
+
reply_parent_login: z.ZodNullable<z.ZodString>;
|
|
1614
|
+
reply_parent_message: z.ZodNullable<z.ZodString>;
|
|
1615
|
+
created_at: z.ZodNullable<z.ZodString>;
|
|
1616
|
+
message_type: z.ZodNullable<z.ZodString>;
|
|
1617
|
+
user_treatment: z.ZodNullable<z.ZodString>;
|
|
1618
|
+
live_chat_id: z.ZodOptional<z.ZodString>;
|
|
1619
|
+
is_shared_chat: z.ZodOptional<z.ZodBoolean>;
|
|
1620
|
+
source_channel: z.ZodOptional<z.ZodUnknown>;
|
|
1621
|
+
announcement_color: z.ZodOptional<z.ZodUnknown>;
|
|
1622
|
+
}, z.core.$loose>;
|
|
1623
|
+
readonly "kick:chat": z.ZodObject<{
|
|
1624
|
+
account_id: z.ZodString;
|
|
1625
|
+
platform: z.ZodString;
|
|
1626
|
+
channel_name: z.ZodNullable<z.ZodString>;
|
|
1627
|
+
user_id: z.ZodNullable<z.ZodString>;
|
|
1628
|
+
username: z.ZodString;
|
|
1629
|
+
display_name: z.ZodNullable<z.ZodString>;
|
|
1630
|
+
avatar_url: z.ZodNullable<z.ZodString>;
|
|
1631
|
+
message: z.ZodString;
|
|
1632
|
+
/** Platform-specific emote entries. */
|
|
1633
|
+
emotes: z.ZodNullable<z.ZodArray<z.ZodUnknown>>;
|
|
1634
|
+
/** Twitch GIF fragments `{ id, url, provider, alt }`; absent without a GIF. */
|
|
1635
|
+
gifs: z.ZodOptional<z.ZodArray<z.ZodUnknown>>;
|
|
1636
|
+
/** Platform-specific badge entries. */
|
|
1637
|
+
badges: z.ZodNullable<z.ZodArray<z.ZodUnknown>>;
|
|
1638
|
+
color: z.ZodNullable<z.ZodString>;
|
|
1639
|
+
is_mod: z.ZodBoolean;
|
|
1640
|
+
is_sub: z.ZodBoolean;
|
|
1641
|
+
is_vip: z.ZodBoolean;
|
|
1642
|
+
sub_tier: z.ZodNullable<z.ZodString>;
|
|
1643
|
+
platform_message_id: z.ZodNullable<z.ZodString>;
|
|
1644
|
+
lumio_user_id: z.ZodNullable<z.ZodString>;
|
|
1645
|
+
reply_parent_msg_id: z.ZodNullable<z.ZodString>;
|
|
1646
|
+
reply_parent_username: z.ZodNullable<z.ZodString>;
|
|
1647
|
+
reply_parent_login: z.ZodNullable<z.ZodString>;
|
|
1648
|
+
reply_parent_message: z.ZodNullable<z.ZodString>;
|
|
1649
|
+
created_at: z.ZodNullable<z.ZodString>;
|
|
1650
|
+
message_type: z.ZodNullable<z.ZodString>;
|
|
1651
|
+
user_treatment: z.ZodNullable<z.ZodString>;
|
|
1652
|
+
live_chat_id: z.ZodOptional<z.ZodString>;
|
|
1653
|
+
is_shared_chat: z.ZodOptional<z.ZodBoolean>;
|
|
1654
|
+
source_channel: z.ZodOptional<z.ZodUnknown>;
|
|
1655
|
+
announcement_color: z.ZodOptional<z.ZodUnknown>;
|
|
1656
|
+
}, z.core.$loose>;
|
|
1657
|
+
readonly "chat:message": z.ZodObject<{
|
|
1658
|
+
account_id: z.ZodString;
|
|
1659
|
+
platform: z.ZodString;
|
|
1660
|
+
channel_name: z.ZodNullable<z.ZodString>;
|
|
1661
|
+
user_id: z.ZodNullable<z.ZodString>;
|
|
1662
|
+
username: z.ZodString;
|
|
1663
|
+
display_name: z.ZodNullable<z.ZodString>;
|
|
1664
|
+
avatar_url: z.ZodNullable<z.ZodString>;
|
|
1665
|
+
message: z.ZodString;
|
|
1666
|
+
/** Platform-specific emote entries. */
|
|
1667
|
+
emotes: z.ZodNullable<z.ZodArray<z.ZodUnknown>>;
|
|
1668
|
+
/** Twitch GIF fragments `{ id, url, provider, alt }`; absent without a GIF. */
|
|
1669
|
+
gifs: z.ZodOptional<z.ZodArray<z.ZodUnknown>>;
|
|
1670
|
+
/** Platform-specific badge entries. */
|
|
1671
|
+
badges: z.ZodNullable<z.ZodArray<z.ZodUnknown>>;
|
|
1672
|
+
color: z.ZodNullable<z.ZodString>;
|
|
1673
|
+
is_mod: z.ZodBoolean;
|
|
1674
|
+
is_sub: z.ZodBoolean;
|
|
1675
|
+
is_vip: z.ZodBoolean;
|
|
1676
|
+
sub_tier: z.ZodNullable<z.ZodString>;
|
|
1677
|
+
platform_message_id: z.ZodNullable<z.ZodString>;
|
|
1678
|
+
lumio_user_id: z.ZodNullable<z.ZodString>;
|
|
1679
|
+
reply_parent_msg_id: z.ZodNullable<z.ZodString>;
|
|
1680
|
+
reply_parent_username: z.ZodNullable<z.ZodString>;
|
|
1681
|
+
reply_parent_login: z.ZodNullable<z.ZodString>;
|
|
1682
|
+
reply_parent_message: z.ZodNullable<z.ZodString>;
|
|
1683
|
+
created_at: z.ZodNullable<z.ZodString>;
|
|
1684
|
+
message_type: z.ZodNullable<z.ZodString>;
|
|
1685
|
+
user_treatment: z.ZodNullable<z.ZodString>;
|
|
1686
|
+
live_chat_id: z.ZodOptional<z.ZodString>;
|
|
1687
|
+
is_shared_chat: z.ZodOptional<z.ZodBoolean>;
|
|
1688
|
+
source_channel: z.ZodOptional<z.ZodUnknown>;
|
|
1689
|
+
announcement_color: z.ZodOptional<z.ZodUnknown>;
|
|
1690
|
+
}, z.core.$loose>;
|
|
1691
|
+
};
|
|
1692
|
+
/** The payload type of every event type, inferred from its schema. */
|
|
1693
|
+
type LumioEventPayloadMap = {
|
|
1694
|
+
[K in LumioEventType]: z.infer<(typeof LUMIO_EVENT_PAYLOAD_SCHEMAS)[K]>;
|
|
1695
|
+
};
|
|
1696
|
+
/** The payload of one event type, e.g. `LumioEventPayload<"twitch:follower">`. */
|
|
1697
|
+
type LumioEventPayload<K extends LumioEventType> = LumioEventPayloadMap[K];
|
|
1698
|
+
/** A chat message (`twitch:chat`, `youtube:chat`, `kick:chat`, `chat:message`). */
|
|
1699
|
+
type ChatMessagePayload = z.infer<typeof chatMessagePayloadSchema>;
|
|
1700
|
+
/** A `twitch:ban` / `twitch:unban` moderation-log entry. */
|
|
1701
|
+
type ModerationLogPayload = z.infer<typeof moderationLogEntry>;
|
|
1702
|
+
/** The zod schema for one event type's payload. */
|
|
1703
|
+
declare function lumioEventPayloadSchema<K extends LumioEventType>(type: K): (typeof LUMIO_EVENT_PAYLOAD_SCHEMAS)[K];
|
|
1704
|
+
/** Validates `data` as the payload of `type`, e.g. before a mock host emits it. */
|
|
1705
|
+
declare function parseLumioEventPayload<K extends LumioEventType>(type: K, data: unknown): z.ZodSafeParseResult<LumioEventPayloadMap[K]>;
|
|
1706
|
+
|
|
404
1707
|
declare const LUMIO_COMPONENT_TYPES: readonly ["Box", "VStack", "HStack", "CompactView", "List", "Text", "Image", "Button", "Toggle", "TextField", "TextArea", "NumberField", "Dropdown", "Slider", "IconPicker", "IconDisplay", "EditorInput", "EditorTextarea", "EditorSelect", "EditorCheckbox", "EditorSlider", "EditorColorPicker", "EditorGroup", "EditorLabel", "EditorDivider", "EditorInfo", "EditorFontRow", "EditorButton", "EditorFontPicker", "EditorChannelRow"];
|
|
405
1708
|
type LumioComponentType = (typeof LUMIO_COMPONENT_TYPES)[number];
|
|
406
1709
|
interface LumioComponentNode {
|
|
@@ -446,10 +1749,16 @@ interface StorageSetParams {
|
|
|
446
1749
|
interface StorageGetParams {
|
|
447
1750
|
key: string;
|
|
448
1751
|
}
|
|
1752
|
+
/** `server.query` — run a `queryRows` export of `server/functions.ts` by name. Resolves with its rows. */
|
|
449
1753
|
interface ServerQueryParams {
|
|
450
1754
|
fn: string;
|
|
451
1755
|
params: Record<string, unknown>;
|
|
452
1756
|
}
|
|
1757
|
+
/**
|
|
1758
|
+
* `server.mutation` — run an `insertRow` / `patchRow` / `deleteRow` export by
|
|
1759
|
+
* name. Resolves with the written row (the deleted row's `{ _id }` for
|
|
1760
|
+
* `deleteRow`), or `null` when no row matched.
|
|
1761
|
+
*/
|
|
453
1762
|
interface ServerMutationParams {
|
|
454
1763
|
fn: string;
|
|
455
1764
|
params: Record<string, unknown>;
|
|
@@ -463,6 +1772,57 @@ interface SoundStopParams {
|
|
|
463
1772
|
}
|
|
464
1773
|
interface SoundGetListParams {
|
|
465
1774
|
}
|
|
1775
|
+
/** `action.execute` — run a Lumio service action on behalf of the extension install. */
|
|
1776
|
+
interface ActionExecuteParams {
|
|
1777
|
+
action: LumioActionType;
|
|
1778
|
+
params: Record<string, unknown>;
|
|
1779
|
+
}
|
|
1780
|
+
/** Successful `action.execute` response: the action's return data (`null` when it has none). */
|
|
1781
|
+
interface ActionExecuteResult {
|
|
1782
|
+
data: unknown;
|
|
1783
|
+
}
|
|
1784
|
+
/**
|
|
1785
|
+
* JSON-RPC error codes a host answers a failed `action.execute` with. The host
|
|
1786
|
+
* never decides whether an action is allowed — the API does, with the extension
|
|
1787
|
+
* identity it derives from the install, not from the worker's claim.
|
|
1788
|
+
*/
|
|
1789
|
+
declare const ACTION_EXECUTE_ERRORS: {
|
|
1790
|
+
/** Malformed request: `action` is not a string or `params` is not an object. */
|
|
1791
|
+
readonly INVALID_REQUEST: -32602;
|
|
1792
|
+
/** This host cannot run actions (no install, or a credential that may not run them). */
|
|
1793
|
+
readonly UNAVAILABLE: -32001;
|
|
1794
|
+
/** The extension does not declare the action's permission, or the caller may not use it. */
|
|
1795
|
+
readonly DENIED: -32002;
|
|
1796
|
+
/** The API does not dispatch this action. */
|
|
1797
|
+
readonly UNKNOWN_ACTION: -32003;
|
|
1798
|
+
/** The API rejected the action's params. */
|
|
1799
|
+
readonly INVALID_PARAMS: -32004;
|
|
1800
|
+
/** The action ran and failed (e.g. its target service is not connected). */
|
|
1801
|
+
readonly FAILED: -32005;
|
|
1802
|
+
};
|
|
1803
|
+
type ActionExecuteErrorCode = (typeof ACTION_EXECUTE_ERRORS)[keyof typeof ACTION_EXECUTE_ERRORS];
|
|
1804
|
+
/**
|
|
1805
|
+
* JSON-RPC error codes a host answers a failed `server.query` /
|
|
1806
|
+
* `server.mutation` with. The API resolves the function by name from the
|
|
1807
|
+
* install's published functions manifest and decides from the host's
|
|
1808
|
+
* credential whether an `editorOnly` function may run — the worker cannot
|
|
1809
|
+
* claim the editor.
|
|
1810
|
+
*/
|
|
1811
|
+
declare const SERVER_FUNCTION_ERRORS: {
|
|
1812
|
+
/** Malformed request: `fn` is not a function name or `params` is not an object. */
|
|
1813
|
+
readonly INVALID_REQUEST: -32602;
|
|
1814
|
+
/** This host cannot call server functions (no install, or a credential that may not call them). */
|
|
1815
|
+
readonly UNAVAILABLE: -32001;
|
|
1816
|
+
/** The caller may not run the function (an `editorOnly` function outside the editor, or missing permission). */
|
|
1817
|
+
readonly DENIED: -32002;
|
|
1818
|
+
/** The install's published version has no server function with this name, or not of this kind. */
|
|
1819
|
+
readonly UNKNOWN_FUNCTION: -32003;
|
|
1820
|
+
/** The API rejected the params (missing or mistyped `arg()` value, invalid row id or column value). */
|
|
1821
|
+
readonly INVALID_PARAMS: -32004;
|
|
1822
|
+
/** The function ran and failed (rate limit, no data schema, storage quota, timeout). */
|
|
1823
|
+
readonly FAILED: -32005;
|
|
1824
|
+
};
|
|
1825
|
+
type ServerFunctionErrorCode = (typeof SERVER_FUNCTION_ERRORS)[keyof typeof SERVER_FUNCTION_ERRORS];
|
|
466
1826
|
interface Sound {
|
|
467
1827
|
id: string;
|
|
468
1828
|
name: string;
|
|
@@ -475,7 +1835,7 @@ interface LifecycleInitParams {
|
|
|
475
1835
|
extensionId: string;
|
|
476
1836
|
installId: string;
|
|
477
1837
|
accountId: string;
|
|
478
|
-
target: "editor" | "layer"
|
|
1838
|
+
target: "editor" | "layer";
|
|
479
1839
|
storage: Record<string, unknown>;
|
|
480
1840
|
theme: Theme;
|
|
481
1841
|
}
|
|
@@ -493,6 +1853,16 @@ interface StorageUpdateParams {
|
|
|
493
1853
|
key: string;
|
|
494
1854
|
value: unknown;
|
|
495
1855
|
}
|
|
1856
|
+
/**
|
|
1857
|
+
* `server.realtime` — a message a handler of this install pushed with
|
|
1858
|
+
* `ctx.realtime.push(topic, payload)`. The host relays it to every rendered
|
|
1859
|
+
* surface of the install (editor, layer); the SDK hands it to
|
|
1860
|
+
* `useRealtime(topic, cb)`.
|
|
1861
|
+
*/
|
|
1862
|
+
interface ServerRealtimeParams {
|
|
1863
|
+
topic: string;
|
|
1864
|
+
payload: unknown;
|
|
1865
|
+
}
|
|
496
1866
|
interface ThemeChangeParams {
|
|
497
1867
|
theme: Theme;
|
|
498
1868
|
}
|
|
@@ -509,6 +1879,7 @@ declare const WORKER_METHODS: {
|
|
|
509
1879
|
readonly SOUND_PLAY: "sound.play";
|
|
510
1880
|
readonly SOUND_STOP: "sound.stop";
|
|
511
1881
|
readonly SOUND_LIST: "sound.list";
|
|
1882
|
+
readonly ACTION_EXECUTE: "action.execute";
|
|
512
1883
|
};
|
|
513
1884
|
declare const HOST_METHODS: {
|
|
514
1885
|
readonly LIFECYCLE_INIT: "lifecycle.init";
|
|
@@ -518,6 +1889,27 @@ declare const HOST_METHODS: {
|
|
|
518
1889
|
readonly STORAGE_UPDATE: "storage.update";
|
|
519
1890
|
readonly THEME_CHANGE: "theme.change";
|
|
520
1891
|
readonly CONFIG_UPDATE: "config.update";
|
|
1892
|
+
readonly SERVER_REALTIME: "server.realtime";
|
|
1893
|
+
};
|
|
1894
|
+
/**
|
|
1895
|
+
* Rules of `ctx.realtime.push(topic, payload)`. The API and the Bot Module
|
|
1896
|
+
* Worker enforce them (`lo_extensions_runtime::realtime`); a push that breaks
|
|
1897
|
+
* one throws in the handler.
|
|
1898
|
+
*/
|
|
1899
|
+
declare const REALTIME_LIMITS: {
|
|
1900
|
+
/** 1–64 characters of `A-Z a-z 0-9 _ . : -`, starting with a letter or digit. */
|
|
1901
|
+
readonly TOPIC_PATTERN: RegExp;
|
|
1902
|
+
/** Largest serialized payload of one push, in bytes. */
|
|
1903
|
+
readonly MAX_PAYLOAD_BYTES: number;
|
|
1904
|
+
/** Most pushes one handler run may make. */
|
|
1905
|
+
readonly MAX_PUSHES_PER_INVOCATION: 32;
|
|
1906
|
+
/** Pushes per install and minute; pushes over the cap are dropped. */
|
|
1907
|
+
readonly MAX_PUSHES_PER_MINUTE: 300;
|
|
1908
|
+
/**
|
|
1909
|
+
* Published bytes (serialized `{ topic, payload }`) per install and minute;
|
|
1910
|
+
* pushes over the cap are dropped.
|
|
1911
|
+
*/
|
|
1912
|
+
readonly MAX_BYTES_PER_MINUTE: number;
|
|
521
1913
|
};
|
|
522
1914
|
|
|
523
|
-
export { ACTION_TYPES, type ActionMessage, type ConfigUpdateMessage, type ErrorMessage, type EventCallbackParams, type EventMessage, type EventPlatformParams, type ExtensionConfig, HOST_METHODS, type InitMessage, type JsonRpcMessage, type JsonRpcNotification, type JsonRpcRequest, type JsonRpcResponse, LUMIO_COMPONENT_TYPES, LUMIO_EVENT_TYPES, type LifecycleDestroyParams, type LifecycleInitParams, type LumioActionType, type LumioComponentNode, type LumioComponentType, type LumioEventType, type LumioMessage, MESSAGE_TYPES, type MessageType, type NodeConfigRequestMessage, type NodeConfigUpdateMessage, type ReadyMessage, STORAGE_SCOPES, type ServerMutationParams, type ServerQueryParams, type Sound, type SoundGetListParams, type SoundPlayEvent, type SoundPlayParams, type SoundStopEvent, type SoundStopParams, type StorageGetParams, type StorageScope, type StorageSetParams, type StorageUpdateMessage, type StorageUpdateParams, type Theme, type ThemeBorderRadius, type ThemeChangeMessage, type ThemeChangeParams, type ThemeColors, type ThemeFonts, type UiKeyframesParams, type UiReadyParams, type UiRenderParams, WORKER_METHODS, actionMessageSchema, configUpdateMessageSchema, errorMessageSchema, eventMessageSchema, extensionConfigSchema, initMessageSchema, lumioActionTypeSchema, lumioEventTypeSchema, lumioMessageSchema, nodeConfigRequestMessageSchema, nodeConfigUpdateMessageSchema, readyMessageSchema, storageScopeSchema, storageUpdateMessageSchema, themeBorderRadiusSchema, themeChangeMessageSchema, themeColorsSchema, themeFontsSchema, themeSchema };
|
|
1915
|
+
export { ACTION_EXECUTE_ERRORS, ACTION_TYPES, type ActionExecuteErrorCode, type ActionExecuteParams, type ActionExecuteResult, type ActionMessage, type ChatMessagePayload, type ConfigUpdateMessage, type ErrorMessage, type EventCallbackParams, type EventMessage, type EventPlatformParams, type ExtensionConfig, HOST_METHODS, type InitMessage, type JsonRpcMessage, type JsonRpcNotification, type JsonRpcRequest, type JsonRpcResponse, LUMIO_COMPONENT_TYPES, LUMIO_EVENT_PAYLOAD_SCHEMAS, LUMIO_EVENT_TYPES, type LifecycleDestroyParams, type LifecycleInitParams, type LumioActionType, type LumioComponentNode, type LumioComponentType, type LumioEventPayload, type LumioEventPayloadMap, type LumioEventType, type LumioMessage, MESSAGE_TYPES, type MessageType, type ModerationLogPayload, type NodeConfigRequestMessage, type NodeConfigUpdateMessage, REALTIME_LIMITS, type ReadyMessage, SERVER_FUNCTION_ERRORS, STORAGE_SCOPES, type ServerFunctionErrorCode, type ServerMutationParams, type ServerQueryParams, type ServerRealtimeParams, type Sound, type SoundGetListParams, type SoundPlayEvent, type SoundPlayParams, type SoundStopEvent, type SoundStopParams, type StorageGetParams, type StorageScope, type StorageSetParams, type StorageUpdateMessage, type StorageUpdateParams, type Theme, type ThemeBorderRadius, type ThemeChangeMessage, type ThemeChangeParams, type ThemeColors, type ThemeFonts, type UiKeyframesParams, type UiReadyParams, type UiRenderParams, WORKER_METHODS, actionMessageSchema, chatMessagePayloadSchema, configUpdateMessageSchema, errorMessageSchema, eventMessageSchema, extensionConfigSchema, initMessageSchema, lumioActionTypeSchema, lumioEventPayloadSchema, lumioEventTypeSchema, lumioMessageSchema, nodeConfigRequestMessageSchema, nodeConfigUpdateMessageSchema, parseLumioEventPayload, readyMessageSchema, storageScopeSchema, storageUpdateMessageSchema, themeBorderRadiusSchema, themeChangeMessageSchema, themeColorsSchema, themeFontsSchema, themeSchema };
|