ts-twitch-api 0.2.5 → 0.2.6
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 +52 -3
- package/dist/index.d.cts +274 -9
- package/dist/index.d.ts +274 -9
- package/dist/index.js +52 -3
- package/package.json +4 -4
package/dist/index.cjs
CHANGED
|
@@ -1545,6 +1545,11 @@ var TwitchApi = class {
|
|
|
1545
1545
|
/**
|
|
1546
1546
|
* NEW Sends a message to the broadcaster’s chat room.
|
|
1547
1547
|
*
|
|
1548
|
+
* **NOTE:** When sending messages to a Shared Chat session, behaviors differ depending on your authentication token type:
|
|
1549
|
+
*
|
|
1550
|
+
* * When using an _App Access Token_, messages will only be sent to the source channel (defined by the `broadcaster_id` parameter) by default starting on May 19, 2025\. Messages can be sent to all channels by using the `for_source_only` parameter and setting it to `false`.
|
|
1551
|
+
* * When using a _User Access Token_, messages will be sent to all channels in the shared chat session, including the source channel. This behavior cannot be changed with this token type.
|
|
1552
|
+
*
|
|
1548
1553
|
* __Authorization:__
|
|
1549
1554
|
*
|
|
1550
1555
|
* Requires an [app access token](https://dev.twitch.tv/docs/authentication#app-access-tokens) or [user access token](https://dev.twitch.tv/docs/authentication#user-access-tokens) that includes the `user:write:chat` scope. If app access token used, then additionally requires `user:bot` scope from chatting user, and either `channel:bot` scope from broadcaster or moderator status.
|
|
@@ -1567,6 +1572,7 @@ var TwitchApi = class {
|
|
|
1567
1572
|
* * The ID in the _sender\_id_ query parameter is not valid.
|
|
1568
1573
|
* * The _text_ query parameter is required.
|
|
1569
1574
|
* * The ID in the _reply\_parent\_message\_id_ query parameter is not valid.
|
|
1575
|
+
* * Cannot set \*for\_source\_only\* if User Access Token is used.
|
|
1570
1576
|
*
|
|
1571
1577
|
* _401 Unauthorized_
|
|
1572
1578
|
*
|
|
@@ -2040,7 +2046,7 @@ var TwitchApi = class {
|
|
|
2040
2046
|
*
|
|
2041
2047
|
* __Authorization:__
|
|
2042
2048
|
*
|
|
2043
|
-
* Requires an [app access token](https://dev.twitch.tv/docs/authentication#app-access-tokens) or [user access token](https://dev.twitch.tv/docs/authentication#user-access-tokens). The
|
|
2049
|
+
* Requires an [app access token](https://dev.twitch.tv/docs/authentication#app-access-tokens) or [user access token](https://dev.twitch.tv/docs/authentication#user-access-tokens). The Client ID associated with the access token must be owned by a user who is a member of the [organization](https://dev.twitch.tv/docs/docs/companies/) that holds ownership of the game.
|
|
2044
2050
|
*
|
|
2045
2051
|
* __URL:__
|
|
2046
2052
|
*
|
|
@@ -2092,7 +2098,7 @@ var TwitchApi = class {
|
|
|
2092
2098
|
*
|
|
2093
2099
|
* __Authorization:__
|
|
2094
2100
|
*
|
|
2095
|
-
* Requires an [app access token](https://dev.twitch.tv/docs/authentication#app-access-tokens) or [user access token](https://dev.twitch.tv/docs/authentication#user-access-tokens). The
|
|
2101
|
+
* Requires an [app access token](https://dev.twitch.tv/docs/authentication#app-access-tokens) or [user access token](https://dev.twitch.tv/docs/authentication#user-access-tokens). The Client ID associated with the access token must be owned by a user who is a member of the [organization](https://dev.twitch.tv/docs/docs/companies/) that holds ownership of the game.
|
|
2096
2102
|
*
|
|
2097
2103
|
* __URL:__
|
|
2098
2104
|
*
|
|
@@ -2743,7 +2749,7 @@ var TwitchApi = class {
|
|
|
2743
2749
|
*
|
|
2744
2750
|
* __Request Query Parameters:__
|
|
2745
2751
|
*
|
|
2746
|
-
* Use the _status_, _type_, and
|
|
2752
|
+
* Use the _status_, _type_, _user\_id_, and _subscription\_id_ query parameters to filter the list of subscriptions that are returned. The filters are mutually exclusive; the request fails if you specify more than one filter.
|
|
2747
2753
|
*
|
|
2748
2754
|
* __URL:__
|
|
2749
2755
|
*
|
|
@@ -3351,6 +3357,45 @@ var TwitchApi = class {
|
|
|
3351
3357
|
path: "/hypetrain/events",
|
|
3352
3358
|
params,
|
|
3353
3359
|
options
|
|
3360
|
+
}),
|
|
3361
|
+
/**
|
|
3362
|
+
* BETA Get the status of a Hype Train for the specified broadcaster.
|
|
3363
|
+
*
|
|
3364
|
+
* __Authorization:__
|
|
3365
|
+
*
|
|
3366
|
+
* * Requires an [user access token](https://dev.twitch.tv/docs/authentication/#user-access-tokens).
|
|
3367
|
+
* * Requires OAuth Scope: `channel:read:hype_train`.
|
|
3368
|
+
* * Requires that `broadcaster_id` and `user_id` match in the User-Access token.
|
|
3369
|
+
*
|
|
3370
|
+
* __URL:__
|
|
3371
|
+
*
|
|
3372
|
+
* `GET https://api.twitch.tv/helix/hypetrain/status`
|
|
3373
|
+
*
|
|
3374
|
+
* __Response Codes:__
|
|
3375
|
+
*
|
|
3376
|
+
* _200 OK_
|
|
3377
|
+
*
|
|
3378
|
+
* Successfully retrieved the status object.
|
|
3379
|
+
*
|
|
3380
|
+
* _400 Bad Request_
|
|
3381
|
+
*
|
|
3382
|
+
* The ID in the `broadcaster_id` query parameter is not valid.
|
|
3383
|
+
*
|
|
3384
|
+
* _401 Unauthorized_
|
|
3385
|
+
*
|
|
3386
|
+
* * The OAuth token is not valid.
|
|
3387
|
+
* * The Authorization header is required and must contain a user access token.
|
|
3388
|
+
*
|
|
3389
|
+
* _500 Internal Server Error_
|
|
3390
|
+
*
|
|
3391
|
+
* Internal Server Error.
|
|
3392
|
+
*
|
|
3393
|
+
* @see https://dev.twitch.tv/docs/api/reference#get-hype-train-status
|
|
3394
|
+
*/
|
|
3395
|
+
getHypeTrainStatus: (params, options = {}) => this.callApi({
|
|
3396
|
+
path: "/hypetrain/status",
|
|
3397
|
+
params,
|
|
3398
|
+
options
|
|
3354
3399
|
})
|
|
3355
3400
|
};
|
|
3356
3401
|
moderation = {
|
|
@@ -5710,6 +5755,10 @@ var TwitchApi = class {
|
|
|
5710
5755
|
* * The access token is not valid.
|
|
5711
5756
|
* * The ID specified in the Client-Id header does not match the client ID specified in the access token.
|
|
5712
5757
|
*
|
|
5758
|
+
* _429 Too Many Requests_
|
|
5759
|
+
*
|
|
5760
|
+
* The app exceeded the number of requests that it may make.
|
|
5761
|
+
*
|
|
5713
5762
|
* @see https://dev.twitch.tv/docs/api/reference#update-user
|
|
5714
5763
|
*/
|
|
5715
5764
|
updateUser: (params = null, options = {}) => this.callApi({
|
package/dist/index.d.cts
CHANGED
|
@@ -1319,9 +1319,10 @@ interface components {
|
|
|
1319
1319
|
* * primary (default)
|
|
1320
1320
|
*
|
|
1321
1321
|
* If `color` is set to _primary_ or is not set, the channel’s accent color is used to highlight the announcement (see **Profile Accent Color** under [profile settings](https://www.twitch.tv/settings/profile), **Channel and Videos**, and **Brand**).
|
|
1322
|
+
* @default primary
|
|
1322
1323
|
* @enum {string}
|
|
1323
1324
|
*/
|
|
1324
|
-
color?: "blue" | "green" | "orange" | "purple" | "primary
|
|
1325
|
+
color?: "blue" | "green" | "orange" | "purple" | "primary";
|
|
1325
1326
|
};
|
|
1326
1327
|
SendChatMessageBody: {
|
|
1327
1328
|
/** @description The ID of the broadcaster whose chat room the message will be sent to. */
|
|
@@ -1332,6 +1333,14 @@ interface components {
|
|
|
1332
1333
|
message: string;
|
|
1333
1334
|
/** @description The ID of the chat message being replied to. */
|
|
1334
1335
|
reply_parent_message_id?: string;
|
|
1336
|
+
/**
|
|
1337
|
+
* @description **NOTE:** This parameter can only be set when utilizing an App Access Token. It cannot be specified when a User Access Token is used, and will instead result in an HTTP 400 error.
|
|
1338
|
+
*
|
|
1339
|
+
* Determines if the chat message is sent only to the source channel (defined by _broadcaster\_id_) during a shared chat session. This has no effect if the message is sent during a shared chat session.
|
|
1340
|
+
*
|
|
1341
|
+
* If this parameter is not set, the default value when using an App Access Token is `false`. On May 19, 2025 the default value for this parameter will be updated to `true`, and chat messages sent using an App Access Token will only be shared with the source channel by default. If you prefer to send a chat message to both channels in a shared chat session, make sure this parameter is explicitly set to `false` in your API request before May 19.
|
|
1342
|
+
*/
|
|
1343
|
+
for_source_only?: Record<string, never>;
|
|
1335
1344
|
};
|
|
1336
1345
|
SendChatMessageResponse: {
|
|
1337
1346
|
data: {
|
|
@@ -2511,6 +2520,124 @@ interface components {
|
|
|
2511
2520
|
cursor?: string;
|
|
2512
2521
|
};
|
|
2513
2522
|
};
|
|
2523
|
+
GetHypeTrainStatusResponse: {
|
|
2524
|
+
/** @description A list that contains information related to the channel’s Hype Train. */
|
|
2525
|
+
data: ({
|
|
2526
|
+
/** @description An object describing the current Hype Train. Null if a Hype Train is not active. */
|
|
2527
|
+
current: {
|
|
2528
|
+
/** @description The Hype Train ID. */
|
|
2529
|
+
id: string;
|
|
2530
|
+
/** @description The broadcaster ID. */
|
|
2531
|
+
broadcaster_user_id: string;
|
|
2532
|
+
/** @description The broadcaster login. */
|
|
2533
|
+
broadcaster_user_login: string;
|
|
2534
|
+
/** @description The broadcaster display name. */
|
|
2535
|
+
broadcaster_user_name: string;
|
|
2536
|
+
/**
|
|
2537
|
+
* Format: int32
|
|
2538
|
+
* @description The current level of the Hype Train.
|
|
2539
|
+
*/
|
|
2540
|
+
level: number;
|
|
2541
|
+
/**
|
|
2542
|
+
* Format: int32
|
|
2543
|
+
* @description Total points contributed to the Hype Train.
|
|
2544
|
+
*/
|
|
2545
|
+
total: number;
|
|
2546
|
+
/**
|
|
2547
|
+
* Format: int32
|
|
2548
|
+
* @description The number of points contributed to the Hype Train at the current level.
|
|
2549
|
+
*/
|
|
2550
|
+
progress: number;
|
|
2551
|
+
/**
|
|
2552
|
+
* Format: int32
|
|
2553
|
+
* @description The number of points required to reach the next level.
|
|
2554
|
+
*/
|
|
2555
|
+
goal: number;
|
|
2556
|
+
/** @description The contributors with the most points contributed. */
|
|
2557
|
+
top_contributions: ({
|
|
2558
|
+
/** @description The ID of the user that made the contribution. */
|
|
2559
|
+
user_id: string;
|
|
2560
|
+
/** @description The user’s login name. */
|
|
2561
|
+
user_login: string;
|
|
2562
|
+
/** @description The user’s display name. */
|
|
2563
|
+
user_name: string;
|
|
2564
|
+
/**
|
|
2565
|
+
* @description The type of the Hype Train. Possible values are:
|
|
2566
|
+
*
|
|
2567
|
+
* * **treasure**
|
|
2568
|
+
* * **golden\_kappa**
|
|
2569
|
+
* * **regular**
|
|
2570
|
+
*
|
|
2571
|
+
* [Learn More](https://help.twitch.tv/s/article/hype-train-guide#special)
|
|
2572
|
+
* @enum {string}
|
|
2573
|
+
*/
|
|
2574
|
+
type: "treasure" | "golden_kappa" | "regular";
|
|
2575
|
+
/**
|
|
2576
|
+
* Format: int32
|
|
2577
|
+
* @description The total number of points contributed for the type.
|
|
2578
|
+
*/
|
|
2579
|
+
total: number;
|
|
2580
|
+
/** @description A list containing the broadcasters participating in the shared Hype Train. Null if the Hype Train is not shared. */
|
|
2581
|
+
shared_train_participants: {
|
|
2582
|
+
/** @description The broadcaster ID. */
|
|
2583
|
+
broadcaster_user_id: string;
|
|
2584
|
+
/** @description The broadcaster login. */
|
|
2585
|
+
broadcaster_user_login: string;
|
|
2586
|
+
/** @description The broadcaster display name. */
|
|
2587
|
+
broadcaster_user_name: string;
|
|
2588
|
+
}[];
|
|
2589
|
+
/**
|
|
2590
|
+
* Format: date-time
|
|
2591
|
+
* @description The time when the Hype Train started.
|
|
2592
|
+
*/
|
|
2593
|
+
started_at: string;
|
|
2594
|
+
/**
|
|
2595
|
+
* Format: date-time
|
|
2596
|
+
* @description The time when the Hype Train expires. The expiration is extended when the Hype Train reaches a new level.
|
|
2597
|
+
*/
|
|
2598
|
+
expires_at: string;
|
|
2599
|
+
/** @description Indicates if the Hype Train is shared. When true, shared\_train\_participants will contain the list of broadcasters the train is shared with. */
|
|
2600
|
+
is_shared_train: boolean;
|
|
2601
|
+
})[];
|
|
2602
|
+
};
|
|
2603
|
+
})[];
|
|
2604
|
+
/** @description An object with information about the channel’s Hype Train records. Null if a Hype Train has not occurred. */
|
|
2605
|
+
all_time_high: {
|
|
2606
|
+
/**
|
|
2607
|
+
* Format: int32
|
|
2608
|
+
* @description The level of the record Hype Train.
|
|
2609
|
+
*/
|
|
2610
|
+
level: number;
|
|
2611
|
+
/**
|
|
2612
|
+
* Format: int32
|
|
2613
|
+
* @description Total points contributed to the record Hype Train.
|
|
2614
|
+
*/
|
|
2615
|
+
total: number;
|
|
2616
|
+
/**
|
|
2617
|
+
* Format: date-time
|
|
2618
|
+
* @description The time when the record was achieved.
|
|
2619
|
+
*/
|
|
2620
|
+
achieved_at: string;
|
|
2621
|
+
};
|
|
2622
|
+
/** @description An object with information about the channel’s shared Hype Train records. Null if a Hype Train has not occurred. */
|
|
2623
|
+
shared_all_time_high: {
|
|
2624
|
+
/**
|
|
2625
|
+
* Format: int32
|
|
2626
|
+
* @description The level of the record Hype Train.
|
|
2627
|
+
*/
|
|
2628
|
+
level: number;
|
|
2629
|
+
/**
|
|
2630
|
+
* Format: int32
|
|
2631
|
+
* @description Total points contributed to the record Hype Train.
|
|
2632
|
+
*/
|
|
2633
|
+
total: number;
|
|
2634
|
+
/**
|
|
2635
|
+
* Format: date-time
|
|
2636
|
+
* @description The time when the record was achieved.
|
|
2637
|
+
*/
|
|
2638
|
+
achieved_at: string;
|
|
2639
|
+
};
|
|
2640
|
+
};
|
|
2514
2641
|
CheckAutoModStatusBody: {
|
|
2515
2642
|
/** @description The list of messages to check. The list must contain at least one message and may contain up to a maximum of 100 messages. */
|
|
2516
2643
|
data: {
|
|
@@ -5983,6 +6110,11 @@ interface operations {
|
|
|
5983
6110
|
* NEW Sends a message to the broadcaster’s chat room.
|
|
5984
6111
|
* @description NEW Sends a message to the broadcaster’s chat room.
|
|
5985
6112
|
*
|
|
6113
|
+
* **NOTE:** When sending messages to a Shared Chat session, behaviors differ depending on your authentication token type:
|
|
6114
|
+
*
|
|
6115
|
+
* * When using an _App Access Token_, messages will only be sent to the source channel (defined by the `broadcaster_id` parameter) by default starting on May 19, 2025\. Messages can be sent to all channels by using the `for_source_only` parameter and setting it to `false`.
|
|
6116
|
+
* * When using a _User Access Token_, messages will be sent to all channels in the shared chat session, including the source channel. This behavior cannot be changed with this token type.
|
|
6117
|
+
*
|
|
5986
6118
|
* __Authorization:__
|
|
5987
6119
|
*
|
|
5988
6120
|
* Requires an [app access token](https://dev.twitch.tv/docs/authentication#app-access-tokens) or [user access token](https://dev.twitch.tv/docs/authentication#user-access-tokens) that includes the `user:write:chat` scope. If app access token used, then additionally requires `user:bot` scope from chatting user, and either `channel:bot` scope from broadcaster or moderator status.
|
|
@@ -6007,6 +6139,7 @@ interface operations {
|
|
|
6007
6139
|
* * The ID in the _sender\_id_ query parameter is not valid.
|
|
6008
6140
|
* * The _text_ query parameter is required.
|
|
6009
6141
|
* * The ID in the _reply\_parent\_message\_id_ query parameter is not valid.
|
|
6142
|
+
* * Cannot set \*for\_source\_only\* if User Access Token is used.
|
|
6010
6143
|
*/
|
|
6011
6144
|
400: {
|
|
6012
6145
|
content: never;
|
|
@@ -6568,7 +6701,7 @@ interface operations {
|
|
|
6568
6701
|
*
|
|
6569
6702
|
* __Authorization:__
|
|
6570
6703
|
*
|
|
6571
|
-
* Requires an [app access token](https://dev.twitch.tv/docs/authentication#app-access-tokens) or [user access token](https://dev.twitch.tv/docs/authentication#user-access-tokens). The
|
|
6704
|
+
* Requires an [app access token](https://dev.twitch.tv/docs/authentication#app-access-tokens) or [user access token](https://dev.twitch.tv/docs/authentication#user-access-tokens). The Client ID associated with the access token must be owned by a user who is a member of the [organization](https://dev.twitch.tv/docs/docs/companies/) that holds ownership of the game.
|
|
6572
6705
|
*/
|
|
6573
6706
|
"get-drops-entitlements": {
|
|
6574
6707
|
parameters: {
|
|
@@ -6642,7 +6775,7 @@ interface operations {
|
|
|
6642
6775
|
*
|
|
6643
6776
|
* __Authorization:__
|
|
6644
6777
|
*
|
|
6645
|
-
* Requires an [app access token](https://dev.twitch.tv/docs/authentication#app-access-tokens) or [user access token](https://dev.twitch.tv/docs/authentication#user-access-tokens). The
|
|
6778
|
+
* Requires an [app access token](https://dev.twitch.tv/docs/authentication#app-access-tokens) or [user access token](https://dev.twitch.tv/docs/authentication#user-access-tokens). The Client ID associated with the access token must be owned by a user who is a member of the [organization](https://dev.twitch.tv/docs/docs/companies/) that holds ownership of the game.
|
|
6646
6779
|
*/
|
|
6647
6780
|
"update-drops-entitlements": {
|
|
6648
6781
|
requestBody?: {
|
|
@@ -7306,7 +7439,7 @@ interface operations {
|
|
|
7306
7439
|
*
|
|
7307
7440
|
* __Request Query Parameters:__
|
|
7308
7441
|
*
|
|
7309
|
-
* Use the _status_, _type_, and
|
|
7442
|
+
* Use the _status_, _type_, _user\_id_, and _subscription\_id_ query parameters to filter the list of subscriptions that are returned. The filters are mutually exclusive; the request fails if you specify more than one filter.
|
|
7310
7443
|
*/
|
|
7311
7444
|
"get-eventsub-subscriptions": {
|
|
7312
7445
|
parameters: {
|
|
@@ -7338,6 +7471,8 @@ interface operations {
|
|
|
7338
7471
|
type?: "automod.message.hold" | "automod.message.update" | "automod.settings.update" | "automod.terms.update" | "channel.bits.use" | "channel.update" | "channel.follow" | "channel.ad_break.begin" | "channel.chat.clear" | "channel.chat.clear_user_messages" | "channel.chat.message" | "channel.chat.message_delete" | "channel.chat.notification" | "channel.chat_settings.update" | "channel.chat.user_message_hold" | "channel.chat.user_message_update" | "channel.shared_chat.begin" | "channel.shared_chat.update" | "channel.shared_chat.end" | "channel.subscribe" | "channel.subscription.end" | "channel.subscription.gift" | "channel.subscription.message" | "channel.cheer" | "channel.raid" | "channel.ban" | "channel.unban" | "channel.unban_request.create" | "channel.unban_request.resolve" | "channel.moderate" | "channel.moderator.add" | "channel.moderator.remove" | "channel.guest_star_session.begin" | "channel.guest_star_session.end" | "channel.guest_star_guest.update" | "channel.guest_star_settings.update" | "channel.channel_points_automatic_reward_redemption.add" | "channel.channel_points_custom_reward.add" | "channel.channel_points_custom_reward.update" | "channel.channel_points_custom_reward.remove" | "channel.channel_points_custom_reward_redemption.add" | "channel.channel_points_custom_reward_redemption.update" | "channel.poll.begin" | "channel.poll.progress" | "channel.poll.end" | "channel.prediction.begin" | "channel.prediction.progress" | "channel.prediction.lock" | "channel.prediction.end" | "channel.suspicious_user.message" | "channel.suspicious_user.update" | "channel.vip.add" | "channel.vip.remove" | "channel.warning.acknowledge" | "channel.warning.send" | "channel.charity_campaign.donate" | "channel.charity_campaign.start" | "channel.charity_campaign.progress" | "channel.charity_campaign.stop" | "conduit.shard.disabled" | "drop.entitlement.grant" | "extension.bits_transaction.create" | "channel.goal.begin" | "channel.goal.progress" | "channel.goal.end" | "channel.hype_train.begin" | "channel.hype_train.progress" | "channel.hype_train.end" | "channel.shield_mode.begin" | "channel.shield_mode.end" | "channel.shoutout.create" | "channel.shoutout.receive" | "stream.online" | "stream.offline" | "user.authorization.grant" | "user.authorization.revoke" | "user.update" | "user.whisper.message";
|
|
7339
7472
|
/** @description Filter subscriptions by user ID. The response contains subscriptions where this ID matches a user ID that you specified in the **Condition** object when you [created the subscription](https://dev.twitch.tv/docs/api/reference#create-eventsub-subscription). */
|
|
7340
7473
|
user_id?: string;
|
|
7474
|
+
/** @description Returns an array with the subscription matching the ID (as long as it is owned by the client making the request), or an empty array if there is no matching subscription. */
|
|
7475
|
+
subscription_id?: string;
|
|
7341
7476
|
/** @description The cursor used to get the next page of results. The `pagination` object in the response contains the cursor's value. */
|
|
7342
7477
|
after?: string;
|
|
7343
7478
|
};
|
|
@@ -8331,6 +8466,47 @@ interface operations {
|
|
|
8331
8466
|
};
|
|
8332
8467
|
};
|
|
8333
8468
|
};
|
|
8469
|
+
/**
|
|
8470
|
+
* BETA Gets the status of a Hype Train for the specified broadcaster.
|
|
8471
|
+
* @description BETA Get the status of a Hype Train for the specified broadcaster.
|
|
8472
|
+
*
|
|
8473
|
+
* __Authorization:__
|
|
8474
|
+
*
|
|
8475
|
+
* * Requires an [user access token](https://dev.twitch.tv/docs/authentication/#user-access-tokens).
|
|
8476
|
+
* * Requires OAuth Scope: `channel:read:hype_train`.
|
|
8477
|
+
* * Requires that `broadcaster_id` and `user_id` match in the User-Access token.
|
|
8478
|
+
*/
|
|
8479
|
+
"get-hype-train-status": {
|
|
8480
|
+
parameters: {
|
|
8481
|
+
query: {
|
|
8482
|
+
/** @description The User ID of the channel broadcaster. */
|
|
8483
|
+
broadcaster_id: string;
|
|
8484
|
+
};
|
|
8485
|
+
};
|
|
8486
|
+
responses: {
|
|
8487
|
+
/** @description Successfully retrieved the status object. */
|
|
8488
|
+
200: {
|
|
8489
|
+
content: {
|
|
8490
|
+
"application/json": components["schemas"]["GetHypeTrainStatusResponse"];
|
|
8491
|
+
};
|
|
8492
|
+
};
|
|
8493
|
+
/** @description The ID in the `broadcaster_id` query parameter is not valid. */
|
|
8494
|
+
400: {
|
|
8495
|
+
content: never;
|
|
8496
|
+
};
|
|
8497
|
+
/**
|
|
8498
|
+
* @description * The OAuth token is not valid.
|
|
8499
|
+
* * The Authorization header is required and must contain a user access token.
|
|
8500
|
+
*/
|
|
8501
|
+
401: {
|
|
8502
|
+
content: never;
|
|
8503
|
+
};
|
|
8504
|
+
/** @description Internal Server Error. */
|
|
8505
|
+
500: {
|
|
8506
|
+
content: never;
|
|
8507
|
+
};
|
|
8508
|
+
};
|
|
8509
|
+
};
|
|
8334
8510
|
/**
|
|
8335
8511
|
* Checks whether AutoMod would flag the specified message for review.
|
|
8336
8512
|
* @description Checks whether AutoMod would flag the specified message for review.
|
|
@@ -11240,6 +11416,10 @@ interface operations {
|
|
|
11240
11416
|
401: {
|
|
11241
11417
|
content: never;
|
|
11242
11418
|
};
|
|
11419
|
+
/** @description The app exceeded the number of requests that it may make. */
|
|
11420
|
+
429: {
|
|
11421
|
+
content: never;
|
|
11422
|
+
};
|
|
11243
11423
|
};
|
|
11244
11424
|
};
|
|
11245
11425
|
/**
|
|
@@ -11853,6 +12033,7 @@ type UpdateGuestStarSlotParams = ParamsSchema<'update-guest-star-slot'>;
|
|
|
11853
12033
|
type DeleteGuestStarSlotParams = ParamsSchema<'delete-guest-star-slot'>;
|
|
11854
12034
|
type UpdateGuestStarSlotSettingsParams = ParamsSchema<'update-guest-star-slot-settings'>;
|
|
11855
12035
|
type GetHypeTrainEventsParams = ParamsSchema<'get-hype-train-events'>;
|
|
12036
|
+
type GetHypeTrainStatusParams = ParamsSchema<'get-hype-train-status'>;
|
|
11856
12037
|
type CheckAutoModStatusParams = ParamsSchema<'check-automod-status'>;
|
|
11857
12038
|
type GetAutoModSettingsParams = ParamsSchema<'get-automod-settings'>;
|
|
11858
12039
|
type UpdateAutoModSettingsParams = ParamsSchema<'update-automod-settings'>;
|
|
@@ -12024,6 +12205,7 @@ type GuestStarInvite = Schema<'GuestStarInvite'>;
|
|
|
12024
12205
|
type GetGuestStarInvitesResponse = Schema<'GetGuestStarInvitesResponse'>;
|
|
12025
12206
|
type HypeTrainEvent = Schema<'HypeTrainEvent'>;
|
|
12026
12207
|
type GetHypeTrainEventsResponse = Schema<'GetHypeTrainEventsResponse'>;
|
|
12208
|
+
type GetHypeTrainStatusResponse = Schema<'GetHypeTrainStatusResponse'>;
|
|
12027
12209
|
type CheckAutoModStatusBody = Schema<'CheckAutoModStatusBody'>;
|
|
12028
12210
|
type AutoModStatus = Schema<'AutoModStatus'>;
|
|
12029
12211
|
type CheckAutoModStatusResponse = Schema<'CheckAutoModStatusResponse'>;
|
|
@@ -13600,6 +13782,11 @@ declare class TwitchApi {
|
|
|
13600
13782
|
/**
|
|
13601
13783
|
* NEW Sends a message to the broadcaster’s chat room.
|
|
13602
13784
|
*
|
|
13785
|
+
* **NOTE:** When sending messages to a Shared Chat session, behaviors differ depending on your authentication token type:
|
|
13786
|
+
*
|
|
13787
|
+
* * When using an _App Access Token_, messages will only be sent to the source channel (defined by the `broadcaster_id` parameter) by default starting on May 19, 2025\. Messages can be sent to all channels by using the `for_source_only` parameter and setting it to `false`.
|
|
13788
|
+
* * When using a _User Access Token_, messages will be sent to all channels in the shared chat session, including the source channel. This behavior cannot be changed with this token type.
|
|
13789
|
+
*
|
|
13603
13790
|
* __Authorization:__
|
|
13604
13791
|
*
|
|
13605
13792
|
* Requires an [app access token](https://dev.twitch.tv/docs/authentication#app-access-tokens) or [user access token](https://dev.twitch.tv/docs/authentication#user-access-tokens) that includes the `user:write:chat` scope. If app access token used, then additionally requires `user:bot` scope from chatting user, and either `channel:bot` scope from broadcaster or moderator status.
|
|
@@ -13622,6 +13809,7 @@ declare class TwitchApi {
|
|
|
13622
13809
|
* * The ID in the _sender\_id_ query parameter is not valid.
|
|
13623
13810
|
* * The _text_ query parameter is required.
|
|
13624
13811
|
* * The ID in the _reply\_parent\_message\_id_ query parameter is not valid.
|
|
13812
|
+
* * Cannot set \*for\_source\_only\* if User Access Token is used.
|
|
13625
13813
|
*
|
|
13626
13814
|
* _401 Unauthorized_
|
|
13627
13815
|
*
|
|
@@ -14111,7 +14299,7 @@ declare class TwitchApi {
|
|
|
14111
14299
|
*
|
|
14112
14300
|
* __Authorization:__
|
|
14113
14301
|
*
|
|
14114
|
-
* Requires an [app access token](https://dev.twitch.tv/docs/authentication#app-access-tokens) or [user access token](https://dev.twitch.tv/docs/authentication#user-access-tokens). The
|
|
14302
|
+
* Requires an [app access token](https://dev.twitch.tv/docs/authentication#app-access-tokens) or [user access token](https://dev.twitch.tv/docs/authentication#user-access-tokens). The Client ID associated with the access token must be owned by a user who is a member of the [organization](https://dev.twitch.tv/docs/docs/companies/) that holds ownership of the game.
|
|
14115
14303
|
*
|
|
14116
14304
|
* __URL:__
|
|
14117
14305
|
*
|
|
@@ -14164,7 +14352,7 @@ declare class TwitchApi {
|
|
|
14164
14352
|
*
|
|
14165
14353
|
* __Authorization:__
|
|
14166
14354
|
*
|
|
14167
|
-
* Requires an [app access token](https://dev.twitch.tv/docs/authentication#app-access-tokens) or [user access token](https://dev.twitch.tv/docs/authentication#user-access-tokens). The
|
|
14355
|
+
* Requires an [app access token](https://dev.twitch.tv/docs/authentication#app-access-tokens) or [user access token](https://dev.twitch.tv/docs/authentication#user-access-tokens). The Client ID associated with the access token must be owned by a user who is a member of the [organization](https://dev.twitch.tv/docs/docs/companies/) that holds ownership of the game.
|
|
14168
14356
|
*
|
|
14169
14357
|
* __URL:__
|
|
14170
14358
|
*
|
|
@@ -14769,7 +14957,7 @@ declare class TwitchApi {
|
|
|
14769
14957
|
*
|
|
14770
14958
|
* __Request Query Parameters:__
|
|
14771
14959
|
*
|
|
14772
|
-
* Use the _status_, _type_, and
|
|
14960
|
+
* Use the _status_, _type_, _user\_id_, and _subscription\_id_ query parameters to filter the list of subscriptions that are returned. The filters are mutually exclusive; the request fails if you specify more than one filter.
|
|
14773
14961
|
*
|
|
14774
14962
|
* __URL:__
|
|
14775
14963
|
*
|
|
@@ -15334,6 +15522,79 @@ declare class TwitchApi {
|
|
|
15334
15522
|
cursor?: string;
|
|
15335
15523
|
};
|
|
15336
15524
|
}, 200, 401>;
|
|
15525
|
+
/**
|
|
15526
|
+
* BETA Get the status of a Hype Train for the specified broadcaster.
|
|
15527
|
+
*
|
|
15528
|
+
* __Authorization:__
|
|
15529
|
+
*
|
|
15530
|
+
* * Requires an [user access token](https://dev.twitch.tv/docs/authentication/#user-access-tokens).
|
|
15531
|
+
* * Requires OAuth Scope: `channel:read:hype_train`.
|
|
15532
|
+
* * Requires that `broadcaster_id` and `user_id` match in the User-Access token.
|
|
15533
|
+
*
|
|
15534
|
+
* __URL:__
|
|
15535
|
+
*
|
|
15536
|
+
* `GET https://api.twitch.tv/helix/hypetrain/status`
|
|
15537
|
+
*
|
|
15538
|
+
* __Response Codes:__
|
|
15539
|
+
*
|
|
15540
|
+
* _200 OK_
|
|
15541
|
+
*
|
|
15542
|
+
* Successfully retrieved the status object.
|
|
15543
|
+
*
|
|
15544
|
+
* _400 Bad Request_
|
|
15545
|
+
*
|
|
15546
|
+
* The ID in the `broadcaster_id` query parameter is not valid.
|
|
15547
|
+
*
|
|
15548
|
+
* _401 Unauthorized_
|
|
15549
|
+
*
|
|
15550
|
+
* * The OAuth token is not valid.
|
|
15551
|
+
* * The Authorization header is required and must contain a user access token.
|
|
15552
|
+
*
|
|
15553
|
+
* _500 Internal Server Error_
|
|
15554
|
+
*
|
|
15555
|
+
* Internal Server Error.
|
|
15556
|
+
*
|
|
15557
|
+
* @see https://dev.twitch.tv/docs/api/reference#get-hype-train-status
|
|
15558
|
+
*/
|
|
15559
|
+
getHypeTrainStatus: (params: GetHypeTrainStatusParams, options?: CallApiOptions["options"]) => ApiResponse<{
|
|
15560
|
+
data: ({
|
|
15561
|
+
current: {
|
|
15562
|
+
id: string;
|
|
15563
|
+
broadcaster_user_id: string;
|
|
15564
|
+
broadcaster_user_login: string;
|
|
15565
|
+
broadcaster_user_name: string;
|
|
15566
|
+
level: number;
|
|
15567
|
+
total: number;
|
|
15568
|
+
progress: number;
|
|
15569
|
+
goal: number;
|
|
15570
|
+
top_contributions: ({
|
|
15571
|
+
user_id: string;
|
|
15572
|
+
user_login: string;
|
|
15573
|
+
user_name: string;
|
|
15574
|
+
type: "treasure" | "golden_kappa" | "regular";
|
|
15575
|
+
total: number;
|
|
15576
|
+
shared_train_participants: {
|
|
15577
|
+
broadcaster_user_id: string;
|
|
15578
|
+
broadcaster_user_login: string;
|
|
15579
|
+
broadcaster_user_name: string;
|
|
15580
|
+
}[];
|
|
15581
|
+
started_at: string;
|
|
15582
|
+
expires_at: string;
|
|
15583
|
+
is_shared_train: boolean;
|
|
15584
|
+
})[];
|
|
15585
|
+
};
|
|
15586
|
+
})[];
|
|
15587
|
+
all_time_high: {
|
|
15588
|
+
level: number;
|
|
15589
|
+
total: number;
|
|
15590
|
+
achieved_at: string;
|
|
15591
|
+
};
|
|
15592
|
+
shared_all_time_high: {
|
|
15593
|
+
level: number;
|
|
15594
|
+
total: number;
|
|
15595
|
+
achieved_at: string;
|
|
15596
|
+
};
|
|
15597
|
+
}, 200, 400 | 401 | 500>;
|
|
15337
15598
|
};
|
|
15338
15599
|
moderation: {
|
|
15339
15600
|
/**
|
|
@@ -17673,11 +17934,15 @@ declare class TwitchApi {
|
|
|
17673
17934
|
* * The access token is not valid.
|
|
17674
17935
|
* * The ID specified in the Client-Id header does not match the client ID specified in the access token.
|
|
17675
17936
|
*
|
|
17937
|
+
* _429 Too Many Requests_
|
|
17938
|
+
*
|
|
17939
|
+
* The app exceeded the number of requests that it may make.
|
|
17940
|
+
*
|
|
17676
17941
|
* @see https://dev.twitch.tv/docs/api/reference#update-user
|
|
17677
17942
|
*/
|
|
17678
17943
|
updateUser: (params?: UpdateUserParams | null | undefined, options?: CallApiOptions["options"]) => ApiResponse<{
|
|
17679
17944
|
data: components["schemas"]["User"][];
|
|
17680
|
-
}, 200, 400 | 401>;
|
|
17945
|
+
}, 200, 400 | 401 | 429>;
|
|
17681
17946
|
/**
|
|
17682
17947
|
* Gets the list of users that the broadcaster has blocked. [Read More](https://help.twitch.tv/s/article/how-to-manage-harassment-in-chat?language=en%5FUS#BlockWhispersandMessagesfromStrangers)
|
|
17683
17948
|
*
|
|
@@ -18051,4 +18316,4 @@ declare class TwitchApi {
|
|
|
18051
18316
|
};
|
|
18052
18317
|
}
|
|
18053
18318
|
|
|
18054
|
-
export { type AddBlockedTermBody, type AddBlockedTermParams, type AddBlockedTermResponse, type AddChannelModeratorParams, type AddChannelVIPParams, type ApiResponse, type AssignGuestStarSlotParams, type AutoModSettings, type AutoModStatus, type BanUserBody, type BanUserParams, type BanUserResponse, type BannedUser, type BitsLeaderboard, type BlockUserParams, type BlockedTerm, type BroadcasterSubscription, type CancelRaidParams, type Category, type Channel, type ChannelEditor, type ChannelEmote, type ChannelInformation, type ChannelStreamScheduleSegment, type ChannelTeam, type CharityCampaign, type CharityCampaignDonation, type ChatBadge, type ChatSettings, type ChatSettingsUpdated, type Chatter, type CheckAutoModStatusBody, type CheckAutoModStatusParams, type CheckAutoModStatusResponse, type CheckUserSubscriptionParams, type CheckUserSubscriptionResponse, type Cheermote, type CheermoteImageFormat, type CheermoteImageTheme, type CheermoteImages, type Clip, type ContentClassificationLabel, type CreateChannelStreamScheduleSegmentBody, type CreateChannelStreamScheduleSegmentParams, type CreateChannelStreamScheduleSegmentResponse, type CreateClipParams, type CreateClipResponse, type CreateConduitsBody, type CreateConduitsResponse, type CreateCustomRewardsBody, type CreateCustomRewardsParams, type CreateCustomRewardsResponse, type CreateEventSubSubscriptionBody, type CreateEventSubSubscriptionResponse, type CreateExtensionSecretParams, type CreateExtensionSecretResponse, type CreateGuestStarSessionParams, type CreateGuestStarSessionResponse, type CreatePollBody, type CreatePollResponse, type CreatePredictionBody, type CreatePredictionResponse, type CreateStreamMarkerBody, type CreateStreamMarkerResponse, type CreatorGoal, type CustomReward, type CustomRewardRedemption, type DeleteChannelStreamScheduleSegmentParams, type DeleteChatMessagesParams, type DeleteConduitParams, type DeleteCustomRewardParams, type DeleteEventSubSubscriptionParams, type DeleteGuestStarInviteParams, type DeleteGuestStarSlotParams, type DeleteVideosParams, type DeleteVideosResponse, type DropsEntitlement, type DropsEntitlementUpdated, type Emote, type EndGuestStarSessionParams, type EndGuestStarSessionResponse, type EndPollBody, type EndPollResponse, type EndPredictionBody, type EndPredictionResponse, type EventSubSubscription, type Extension, type ExtensionAnalytics, type ExtensionBitsProduct, type ExtensionConfigurationSegment, type ExtensionIconUrls, type ExtensionLiveChannel, type ExtensionSecret, type ExtensionTransaction, type Game, type GameAnalytics, type GetAdScheduleParams, type GetAdScheduleResponse, type GetAllStreamTagsParams, type GetAllStreamTagsResponse, type GetAutoModSettingsParams, type GetAutoModSettingsResponse, type GetBannedUsersParams, type GetBannedUsersResponse, type GetBitsLeaderboardParams, type GetBitsLeaderboardResponse, type GetBlockedTermsParams, type GetBlockedTermsResponse, type GetBroadcasterSubscriptionsParams, type GetBroadcasterSubscriptionsResponse, type GetChannelChatBadgesParams, type GetChannelChatBadgesResponse, type GetChannelEditorsParams, type GetChannelEditorsResponse, type GetChannelEmotesParams, type GetChannelEmotesResponse, type GetChannelFollowersParams, type GetChannelFollowersResponse, type GetChannelGuestStarSettingsParams, type GetChannelGuestStarSettingsResponse, type GetChannelICalendarParams, type GetChannelInformationParams, type GetChannelInformationResponse, type GetChannelStreamScheduleParams, type GetChannelStreamScheduleResponse, type GetChannelTeamsParams, type GetChannelTeamsResponse, type GetCharityCampaignDonationsParams, type GetCharityCampaignDonationsResponse, type GetCharityCampaignParams, type GetCharityCampaignResponse, type GetChatSettingsParams, type GetChatSettingsResponse, type GetChattersParams, type GetChattersResponse, type GetCheermotesParams, type GetCheermotesResponse, type GetClipsParams, type GetClipsResponse, type GetConduitShardsParams, type GetConduitShardsResponse, type GetConduitsResponse, type GetContentClassificationLabelsParams, type GetContentClassificationLabelsResponse, type GetCreatorGoalsParams, type GetCreatorGoalsResponse, type GetCustomRewardParams, type GetCustomRewardRedemptionParams, type GetCustomRewardRedemptionResponse, type GetCustomRewardResponse, type GetDropsEntitlementsParams, type GetDropsEntitlementsResponse, type GetEmoteSetsParams, type GetEmoteSetsResponse, type GetEventSubSubscriptionsParams, type GetEventSubSubscriptionsResponse, type GetExtensionAnalyticsParams, type GetExtensionAnalyticsResponse, type GetExtensionBitsProductsParams, type GetExtensionBitsProductsResponse, type GetExtensionConfigurationSegmentParams, type GetExtensionConfigurationSegmentResponse, type GetExtensionLiveChannelsParams, type GetExtensionLiveChannelsResponse, type GetExtensionSecretsResponse, type GetExtensionTransactionsParams, type GetExtensionTransactionsResponse, type GetExtensionsParams, type GetExtensionsResponse, type GetFollowedChannelsParams, type GetFollowedChannelsResponse, type GetFollowedStreamsParams, type GetFollowedStreamsResponse, type GetGameAnalyticsParams, type GetGameAnalyticsResponse, type GetGamesParams, type GetGamesResponse, type GetGlobalChatBadgesResponse, type GetGlobalEmotesResponse, type GetGuestStarInvitesParams, type GetGuestStarInvitesResponse, type GetGuestStarSessionParams, type GetGuestStarSessionResponse, type GetHypeTrainEventsParams, type GetHypeTrainEventsResponse, type GetModeratedChannelsParams, type GetModeratedChannelsResponse, type GetModeratorsParams, type GetModeratorsResponse, type GetPollsParams, type GetPollsResponse, type GetPredictionsParams, type GetPredictionsResponse, type GetReleasedExtensionsParams, type GetReleasedExtensionsResponse, type GetSharedChatSessionParams, type GetSharedChatSessionResponse, type GetShieldModeStatusParams, type GetShieldModeStatusResponse, type GetStreamKeyParams, type GetStreamKeyResponse, type GetStreamMarkersParams, type GetStreamMarkersResponse, type GetStreamTagsParams, type GetStreamTagsResponse, type GetStreamsParams, type GetStreamsResponse, type GetTeamsParams, type GetTeamsResponse, type GetTopGamesParams, type GetTopGamesResponse, type GetUnbanRequestsParams, type GetUnbanRequestsResponse, type GetUserActiveExtensionsParams, type GetUserActiveExtensionsResponse, type GetUserBlockListParams, type GetUserBlockListResponse, type GetUserChatColorParams, type GetUserChatColorResponse, type GetUserEmotesParams, type GetUserEmotesResponse, type GetUserExtensionsResponse, type GetUsersParams, type GetUsersResponse, type GetVIPsParams, type GetVIPsResponse, type GetVideosParams, type GetVideosResponse, type GlobalEmote, type Guest, type GuestStarInvite, type GuestStarSession, type HypeTrainEvent, type ManageHeldAutoModMessagesBody, type ModifyChannelInformationBody, type ModifyChannelInformationParams, type Poll, type Prediction, type PredictionOutcome, type RemoveBlockedTermParams, type RemoveChannelModeratorParams, type RemoveChannelVIPParams, type ResolveUnbanRequestsParams, type ResolveUnbanRequestsResponse, type SearchCategoriesParams, type SearchCategoriesResponse, type SearchChannelsParams, type SearchChannelsResponse, type SendChatAnnouncementBody, type SendChatAnnouncementParams, type SendChatMessageBody, type SendChatMessageResponse, type SendExtensionChatMessageBody, type SendExtensionChatMessageParams, type SendExtensionPubSubMessageBody, type SendGuestStarInviteParams, type SendShoutoutParams, type SendWhisperBody, type SendWhisperParams, type SetExtensionConfigurationSegmentBody, type SetExtensionRequiredConfigurationBody, type SetExtensionRequiredConfigurationParams, type SnoozeNextAdParams, type SnoozeNextAdResponse, type StartCommercialBody, type StartCommercialResponse, type StartRaidParams, type StartRaidResponse, type Stream, type StreamMarkerCreated, type StreamMarkers, type StreamTag, type Team, TwitchApi, type TwitchApiOptions, type UnbanUserParams, type UnblockUserParams, type UpdateAutoModSettingsBody, type UpdateAutoModSettingsParams, type UpdateAutoModSettingsResponse, type UpdateChannelGuestStarSettingsBody, type UpdateChannelGuestStarSettingsParams, type UpdateChannelStreamScheduleParams, type UpdateChannelStreamScheduleSegmentBody, type UpdateChannelStreamScheduleSegmentParams, type UpdateChannelStreamScheduleSegmentResponse, type UpdateChatSettingsBody, type UpdateChatSettingsParams, type UpdateChatSettingsResponse, type UpdateConduitShardsBody, type UpdateConduitShardsResponse, type UpdateConduitsBody, type UpdateConduitsResponse, type UpdateCustomRewardBody, type UpdateCustomRewardParams, type UpdateCustomRewardResponse, type UpdateDropsEntitlementsBody, type UpdateDropsEntitlementsResponse, type UpdateExtensionBitsProductBody, type UpdateExtensionBitsProductResponse, type UpdateGuestStarSlotParams, type UpdateGuestStarSlotSettingsParams, type UpdateRedemptionStatusBody, type UpdateRedemptionStatusParams, type UpdateRedemptionStatusResponse, type UpdateShieldModeStatusBody, type UpdateShieldModeStatusParams, type UpdateShieldModeStatusResponse, type UpdateUserChatColorParams, type UpdateUserExtensionsBody, type UpdateUserExtensionsResponse, type UpdateUserParams, type UpdateUserResponse, type User, type UserBlockList, type UserChatColor, type UserExtension, type UserExtensionComponent, type UserExtensionComponentUpdate, type UserExtensionOverlay, type UserExtensionOverlayUpdate, type UserExtensionPanel, type UserExtensionPanelUpdate, type UserModerator, type UserSubscription, type UserVip, type Video, type WarnChatUserBody, type WarnChatUserParams, type WarnChatUserResponse };
|
|
18319
|
+
export { type AddBlockedTermBody, type AddBlockedTermParams, type AddBlockedTermResponse, type AddChannelModeratorParams, type AddChannelVIPParams, type ApiResponse, type AssignGuestStarSlotParams, type AutoModSettings, type AutoModStatus, type BanUserBody, type BanUserParams, type BanUserResponse, type BannedUser, type BitsLeaderboard, type BlockUserParams, type BlockedTerm, type BroadcasterSubscription, type CancelRaidParams, type Category, type Channel, type ChannelEditor, type ChannelEmote, type ChannelInformation, type ChannelStreamScheduleSegment, type ChannelTeam, type CharityCampaign, type CharityCampaignDonation, type ChatBadge, type ChatSettings, type ChatSettingsUpdated, type Chatter, type CheckAutoModStatusBody, type CheckAutoModStatusParams, type CheckAutoModStatusResponse, type CheckUserSubscriptionParams, type CheckUserSubscriptionResponse, type Cheermote, type CheermoteImageFormat, type CheermoteImageTheme, type CheermoteImages, type Clip, type ContentClassificationLabel, type CreateChannelStreamScheduleSegmentBody, type CreateChannelStreamScheduleSegmentParams, type CreateChannelStreamScheduleSegmentResponse, type CreateClipParams, type CreateClipResponse, type CreateConduitsBody, type CreateConduitsResponse, type CreateCustomRewardsBody, type CreateCustomRewardsParams, type CreateCustomRewardsResponse, type CreateEventSubSubscriptionBody, type CreateEventSubSubscriptionResponse, type CreateExtensionSecretParams, type CreateExtensionSecretResponse, type CreateGuestStarSessionParams, type CreateGuestStarSessionResponse, type CreatePollBody, type CreatePollResponse, type CreatePredictionBody, type CreatePredictionResponse, type CreateStreamMarkerBody, type CreateStreamMarkerResponse, type CreatorGoal, type CustomReward, type CustomRewardRedemption, type DeleteChannelStreamScheduleSegmentParams, type DeleteChatMessagesParams, type DeleteConduitParams, type DeleteCustomRewardParams, type DeleteEventSubSubscriptionParams, type DeleteGuestStarInviteParams, type DeleteGuestStarSlotParams, type DeleteVideosParams, type DeleteVideosResponse, type DropsEntitlement, type DropsEntitlementUpdated, type Emote, type EndGuestStarSessionParams, type EndGuestStarSessionResponse, type EndPollBody, type EndPollResponse, type EndPredictionBody, type EndPredictionResponse, type EventSubSubscription, type Extension, type ExtensionAnalytics, type ExtensionBitsProduct, type ExtensionConfigurationSegment, type ExtensionIconUrls, type ExtensionLiveChannel, type ExtensionSecret, type ExtensionTransaction, type Game, type GameAnalytics, type GetAdScheduleParams, type GetAdScheduleResponse, type GetAllStreamTagsParams, type GetAllStreamTagsResponse, type GetAutoModSettingsParams, type GetAutoModSettingsResponse, type GetBannedUsersParams, type GetBannedUsersResponse, type GetBitsLeaderboardParams, type GetBitsLeaderboardResponse, type GetBlockedTermsParams, type GetBlockedTermsResponse, type GetBroadcasterSubscriptionsParams, type GetBroadcasterSubscriptionsResponse, type GetChannelChatBadgesParams, type GetChannelChatBadgesResponse, type GetChannelEditorsParams, type GetChannelEditorsResponse, type GetChannelEmotesParams, type GetChannelEmotesResponse, type GetChannelFollowersParams, type GetChannelFollowersResponse, type GetChannelGuestStarSettingsParams, type GetChannelGuestStarSettingsResponse, type GetChannelICalendarParams, type GetChannelInformationParams, type GetChannelInformationResponse, type GetChannelStreamScheduleParams, type GetChannelStreamScheduleResponse, type GetChannelTeamsParams, type GetChannelTeamsResponse, type GetCharityCampaignDonationsParams, type GetCharityCampaignDonationsResponse, type GetCharityCampaignParams, type GetCharityCampaignResponse, type GetChatSettingsParams, type GetChatSettingsResponse, type GetChattersParams, type GetChattersResponse, type GetCheermotesParams, type GetCheermotesResponse, type GetClipsParams, type GetClipsResponse, type GetConduitShardsParams, type GetConduitShardsResponse, type GetConduitsResponse, type GetContentClassificationLabelsParams, type GetContentClassificationLabelsResponse, type GetCreatorGoalsParams, type GetCreatorGoalsResponse, type GetCustomRewardParams, type GetCustomRewardRedemptionParams, type GetCustomRewardRedemptionResponse, type GetCustomRewardResponse, type GetDropsEntitlementsParams, type GetDropsEntitlementsResponse, type GetEmoteSetsParams, type GetEmoteSetsResponse, type GetEventSubSubscriptionsParams, type GetEventSubSubscriptionsResponse, type GetExtensionAnalyticsParams, type GetExtensionAnalyticsResponse, type GetExtensionBitsProductsParams, type GetExtensionBitsProductsResponse, type GetExtensionConfigurationSegmentParams, type GetExtensionConfigurationSegmentResponse, type GetExtensionLiveChannelsParams, type GetExtensionLiveChannelsResponse, type GetExtensionSecretsResponse, type GetExtensionTransactionsParams, type GetExtensionTransactionsResponse, type GetExtensionsParams, type GetExtensionsResponse, type GetFollowedChannelsParams, type GetFollowedChannelsResponse, type GetFollowedStreamsParams, type GetFollowedStreamsResponse, type GetGameAnalyticsParams, type GetGameAnalyticsResponse, type GetGamesParams, type GetGamesResponse, type GetGlobalChatBadgesResponse, type GetGlobalEmotesResponse, type GetGuestStarInvitesParams, type GetGuestStarInvitesResponse, type GetGuestStarSessionParams, type GetGuestStarSessionResponse, type GetHypeTrainEventsParams, type GetHypeTrainEventsResponse, type GetHypeTrainStatusParams, type GetHypeTrainStatusResponse, type GetModeratedChannelsParams, type GetModeratedChannelsResponse, type GetModeratorsParams, type GetModeratorsResponse, type GetPollsParams, type GetPollsResponse, type GetPredictionsParams, type GetPredictionsResponse, type GetReleasedExtensionsParams, type GetReleasedExtensionsResponse, type GetSharedChatSessionParams, type GetSharedChatSessionResponse, type GetShieldModeStatusParams, type GetShieldModeStatusResponse, type GetStreamKeyParams, type GetStreamKeyResponse, type GetStreamMarkersParams, type GetStreamMarkersResponse, type GetStreamTagsParams, type GetStreamTagsResponse, type GetStreamsParams, type GetStreamsResponse, type GetTeamsParams, type GetTeamsResponse, type GetTopGamesParams, type GetTopGamesResponse, type GetUnbanRequestsParams, type GetUnbanRequestsResponse, type GetUserActiveExtensionsParams, type GetUserActiveExtensionsResponse, type GetUserBlockListParams, type GetUserBlockListResponse, type GetUserChatColorParams, type GetUserChatColorResponse, type GetUserEmotesParams, type GetUserEmotesResponse, type GetUserExtensionsResponse, type GetUsersParams, type GetUsersResponse, type GetVIPsParams, type GetVIPsResponse, type GetVideosParams, type GetVideosResponse, type GlobalEmote, type Guest, type GuestStarInvite, type GuestStarSession, type HypeTrainEvent, type ManageHeldAutoModMessagesBody, type ModifyChannelInformationBody, type ModifyChannelInformationParams, type Poll, type Prediction, type PredictionOutcome, type RemoveBlockedTermParams, type RemoveChannelModeratorParams, type RemoveChannelVIPParams, type ResolveUnbanRequestsParams, type ResolveUnbanRequestsResponse, type SearchCategoriesParams, type SearchCategoriesResponse, type SearchChannelsParams, type SearchChannelsResponse, type SendChatAnnouncementBody, type SendChatAnnouncementParams, type SendChatMessageBody, type SendChatMessageResponse, type SendExtensionChatMessageBody, type SendExtensionChatMessageParams, type SendExtensionPubSubMessageBody, type SendGuestStarInviteParams, type SendShoutoutParams, type SendWhisperBody, type SendWhisperParams, type SetExtensionConfigurationSegmentBody, type SetExtensionRequiredConfigurationBody, type SetExtensionRequiredConfigurationParams, type SnoozeNextAdParams, type SnoozeNextAdResponse, type StartCommercialBody, type StartCommercialResponse, type StartRaidParams, type StartRaidResponse, type Stream, type StreamMarkerCreated, type StreamMarkers, type StreamTag, type Team, TwitchApi, type TwitchApiOptions, type UnbanUserParams, type UnblockUserParams, type UpdateAutoModSettingsBody, type UpdateAutoModSettingsParams, type UpdateAutoModSettingsResponse, type UpdateChannelGuestStarSettingsBody, type UpdateChannelGuestStarSettingsParams, type UpdateChannelStreamScheduleParams, type UpdateChannelStreamScheduleSegmentBody, type UpdateChannelStreamScheduleSegmentParams, type UpdateChannelStreamScheduleSegmentResponse, type UpdateChatSettingsBody, type UpdateChatSettingsParams, type UpdateChatSettingsResponse, type UpdateConduitShardsBody, type UpdateConduitShardsResponse, type UpdateConduitsBody, type UpdateConduitsResponse, type UpdateCustomRewardBody, type UpdateCustomRewardParams, type UpdateCustomRewardResponse, type UpdateDropsEntitlementsBody, type UpdateDropsEntitlementsResponse, type UpdateExtensionBitsProductBody, type UpdateExtensionBitsProductResponse, type UpdateGuestStarSlotParams, type UpdateGuestStarSlotSettingsParams, type UpdateRedemptionStatusBody, type UpdateRedemptionStatusParams, type UpdateRedemptionStatusResponse, type UpdateShieldModeStatusBody, type UpdateShieldModeStatusParams, type UpdateShieldModeStatusResponse, type UpdateUserChatColorParams, type UpdateUserExtensionsBody, type UpdateUserExtensionsResponse, type UpdateUserParams, type UpdateUserResponse, type User, type UserBlockList, type UserChatColor, type UserExtension, type UserExtensionComponent, type UserExtensionComponentUpdate, type UserExtensionOverlay, type UserExtensionOverlayUpdate, type UserExtensionPanel, type UserExtensionPanelUpdate, type UserModerator, type UserSubscription, type UserVip, type Video, type WarnChatUserBody, type WarnChatUserParams, type WarnChatUserResponse };
|
package/dist/index.d.ts
CHANGED
|
@@ -1319,9 +1319,10 @@ interface components {
|
|
|
1319
1319
|
* * primary (default)
|
|
1320
1320
|
*
|
|
1321
1321
|
* If `color` is set to _primary_ or is not set, the channel’s accent color is used to highlight the announcement (see **Profile Accent Color** under [profile settings](https://www.twitch.tv/settings/profile), **Channel and Videos**, and **Brand**).
|
|
1322
|
+
* @default primary
|
|
1322
1323
|
* @enum {string}
|
|
1323
1324
|
*/
|
|
1324
|
-
color?: "blue" | "green" | "orange" | "purple" | "primary
|
|
1325
|
+
color?: "blue" | "green" | "orange" | "purple" | "primary";
|
|
1325
1326
|
};
|
|
1326
1327
|
SendChatMessageBody: {
|
|
1327
1328
|
/** @description The ID of the broadcaster whose chat room the message will be sent to. */
|
|
@@ -1332,6 +1333,14 @@ interface components {
|
|
|
1332
1333
|
message: string;
|
|
1333
1334
|
/** @description The ID of the chat message being replied to. */
|
|
1334
1335
|
reply_parent_message_id?: string;
|
|
1336
|
+
/**
|
|
1337
|
+
* @description **NOTE:** This parameter can only be set when utilizing an App Access Token. It cannot be specified when a User Access Token is used, and will instead result in an HTTP 400 error.
|
|
1338
|
+
*
|
|
1339
|
+
* Determines if the chat message is sent only to the source channel (defined by _broadcaster\_id_) during a shared chat session. This has no effect if the message is sent during a shared chat session.
|
|
1340
|
+
*
|
|
1341
|
+
* If this parameter is not set, the default value when using an App Access Token is `false`. On May 19, 2025 the default value for this parameter will be updated to `true`, and chat messages sent using an App Access Token will only be shared with the source channel by default. If you prefer to send a chat message to both channels in a shared chat session, make sure this parameter is explicitly set to `false` in your API request before May 19.
|
|
1342
|
+
*/
|
|
1343
|
+
for_source_only?: Record<string, never>;
|
|
1335
1344
|
};
|
|
1336
1345
|
SendChatMessageResponse: {
|
|
1337
1346
|
data: {
|
|
@@ -2511,6 +2520,124 @@ interface components {
|
|
|
2511
2520
|
cursor?: string;
|
|
2512
2521
|
};
|
|
2513
2522
|
};
|
|
2523
|
+
GetHypeTrainStatusResponse: {
|
|
2524
|
+
/** @description A list that contains information related to the channel’s Hype Train. */
|
|
2525
|
+
data: ({
|
|
2526
|
+
/** @description An object describing the current Hype Train. Null if a Hype Train is not active. */
|
|
2527
|
+
current: {
|
|
2528
|
+
/** @description The Hype Train ID. */
|
|
2529
|
+
id: string;
|
|
2530
|
+
/** @description The broadcaster ID. */
|
|
2531
|
+
broadcaster_user_id: string;
|
|
2532
|
+
/** @description The broadcaster login. */
|
|
2533
|
+
broadcaster_user_login: string;
|
|
2534
|
+
/** @description The broadcaster display name. */
|
|
2535
|
+
broadcaster_user_name: string;
|
|
2536
|
+
/**
|
|
2537
|
+
* Format: int32
|
|
2538
|
+
* @description The current level of the Hype Train.
|
|
2539
|
+
*/
|
|
2540
|
+
level: number;
|
|
2541
|
+
/**
|
|
2542
|
+
* Format: int32
|
|
2543
|
+
* @description Total points contributed to the Hype Train.
|
|
2544
|
+
*/
|
|
2545
|
+
total: number;
|
|
2546
|
+
/**
|
|
2547
|
+
* Format: int32
|
|
2548
|
+
* @description The number of points contributed to the Hype Train at the current level.
|
|
2549
|
+
*/
|
|
2550
|
+
progress: number;
|
|
2551
|
+
/**
|
|
2552
|
+
* Format: int32
|
|
2553
|
+
* @description The number of points required to reach the next level.
|
|
2554
|
+
*/
|
|
2555
|
+
goal: number;
|
|
2556
|
+
/** @description The contributors with the most points contributed. */
|
|
2557
|
+
top_contributions: ({
|
|
2558
|
+
/** @description The ID of the user that made the contribution. */
|
|
2559
|
+
user_id: string;
|
|
2560
|
+
/** @description The user’s login name. */
|
|
2561
|
+
user_login: string;
|
|
2562
|
+
/** @description The user’s display name. */
|
|
2563
|
+
user_name: string;
|
|
2564
|
+
/**
|
|
2565
|
+
* @description The type of the Hype Train. Possible values are:
|
|
2566
|
+
*
|
|
2567
|
+
* * **treasure**
|
|
2568
|
+
* * **golden\_kappa**
|
|
2569
|
+
* * **regular**
|
|
2570
|
+
*
|
|
2571
|
+
* [Learn More](https://help.twitch.tv/s/article/hype-train-guide#special)
|
|
2572
|
+
* @enum {string}
|
|
2573
|
+
*/
|
|
2574
|
+
type: "treasure" | "golden_kappa" | "regular";
|
|
2575
|
+
/**
|
|
2576
|
+
* Format: int32
|
|
2577
|
+
* @description The total number of points contributed for the type.
|
|
2578
|
+
*/
|
|
2579
|
+
total: number;
|
|
2580
|
+
/** @description A list containing the broadcasters participating in the shared Hype Train. Null if the Hype Train is not shared. */
|
|
2581
|
+
shared_train_participants: {
|
|
2582
|
+
/** @description The broadcaster ID. */
|
|
2583
|
+
broadcaster_user_id: string;
|
|
2584
|
+
/** @description The broadcaster login. */
|
|
2585
|
+
broadcaster_user_login: string;
|
|
2586
|
+
/** @description The broadcaster display name. */
|
|
2587
|
+
broadcaster_user_name: string;
|
|
2588
|
+
}[];
|
|
2589
|
+
/**
|
|
2590
|
+
* Format: date-time
|
|
2591
|
+
* @description The time when the Hype Train started.
|
|
2592
|
+
*/
|
|
2593
|
+
started_at: string;
|
|
2594
|
+
/**
|
|
2595
|
+
* Format: date-time
|
|
2596
|
+
* @description The time when the Hype Train expires. The expiration is extended when the Hype Train reaches a new level.
|
|
2597
|
+
*/
|
|
2598
|
+
expires_at: string;
|
|
2599
|
+
/** @description Indicates if the Hype Train is shared. When true, shared\_train\_participants will contain the list of broadcasters the train is shared with. */
|
|
2600
|
+
is_shared_train: boolean;
|
|
2601
|
+
})[];
|
|
2602
|
+
};
|
|
2603
|
+
})[];
|
|
2604
|
+
/** @description An object with information about the channel’s Hype Train records. Null if a Hype Train has not occurred. */
|
|
2605
|
+
all_time_high: {
|
|
2606
|
+
/**
|
|
2607
|
+
* Format: int32
|
|
2608
|
+
* @description The level of the record Hype Train.
|
|
2609
|
+
*/
|
|
2610
|
+
level: number;
|
|
2611
|
+
/**
|
|
2612
|
+
* Format: int32
|
|
2613
|
+
* @description Total points contributed to the record Hype Train.
|
|
2614
|
+
*/
|
|
2615
|
+
total: number;
|
|
2616
|
+
/**
|
|
2617
|
+
* Format: date-time
|
|
2618
|
+
* @description The time when the record was achieved.
|
|
2619
|
+
*/
|
|
2620
|
+
achieved_at: string;
|
|
2621
|
+
};
|
|
2622
|
+
/** @description An object with information about the channel’s shared Hype Train records. Null if a Hype Train has not occurred. */
|
|
2623
|
+
shared_all_time_high: {
|
|
2624
|
+
/**
|
|
2625
|
+
* Format: int32
|
|
2626
|
+
* @description The level of the record Hype Train.
|
|
2627
|
+
*/
|
|
2628
|
+
level: number;
|
|
2629
|
+
/**
|
|
2630
|
+
* Format: int32
|
|
2631
|
+
* @description Total points contributed to the record Hype Train.
|
|
2632
|
+
*/
|
|
2633
|
+
total: number;
|
|
2634
|
+
/**
|
|
2635
|
+
* Format: date-time
|
|
2636
|
+
* @description The time when the record was achieved.
|
|
2637
|
+
*/
|
|
2638
|
+
achieved_at: string;
|
|
2639
|
+
};
|
|
2640
|
+
};
|
|
2514
2641
|
CheckAutoModStatusBody: {
|
|
2515
2642
|
/** @description The list of messages to check. The list must contain at least one message and may contain up to a maximum of 100 messages. */
|
|
2516
2643
|
data: {
|
|
@@ -5983,6 +6110,11 @@ interface operations {
|
|
|
5983
6110
|
* NEW Sends a message to the broadcaster’s chat room.
|
|
5984
6111
|
* @description NEW Sends a message to the broadcaster’s chat room.
|
|
5985
6112
|
*
|
|
6113
|
+
* **NOTE:** When sending messages to a Shared Chat session, behaviors differ depending on your authentication token type:
|
|
6114
|
+
*
|
|
6115
|
+
* * When using an _App Access Token_, messages will only be sent to the source channel (defined by the `broadcaster_id` parameter) by default starting on May 19, 2025\. Messages can be sent to all channels by using the `for_source_only` parameter and setting it to `false`.
|
|
6116
|
+
* * When using a _User Access Token_, messages will be sent to all channels in the shared chat session, including the source channel. This behavior cannot be changed with this token type.
|
|
6117
|
+
*
|
|
5986
6118
|
* __Authorization:__
|
|
5987
6119
|
*
|
|
5988
6120
|
* Requires an [app access token](https://dev.twitch.tv/docs/authentication#app-access-tokens) or [user access token](https://dev.twitch.tv/docs/authentication#user-access-tokens) that includes the `user:write:chat` scope. If app access token used, then additionally requires `user:bot` scope from chatting user, and either `channel:bot` scope from broadcaster or moderator status.
|
|
@@ -6007,6 +6139,7 @@ interface operations {
|
|
|
6007
6139
|
* * The ID in the _sender\_id_ query parameter is not valid.
|
|
6008
6140
|
* * The _text_ query parameter is required.
|
|
6009
6141
|
* * The ID in the _reply\_parent\_message\_id_ query parameter is not valid.
|
|
6142
|
+
* * Cannot set \*for\_source\_only\* if User Access Token is used.
|
|
6010
6143
|
*/
|
|
6011
6144
|
400: {
|
|
6012
6145
|
content: never;
|
|
@@ -6568,7 +6701,7 @@ interface operations {
|
|
|
6568
6701
|
*
|
|
6569
6702
|
* __Authorization:__
|
|
6570
6703
|
*
|
|
6571
|
-
* Requires an [app access token](https://dev.twitch.tv/docs/authentication#app-access-tokens) or [user access token](https://dev.twitch.tv/docs/authentication#user-access-tokens). The
|
|
6704
|
+
* Requires an [app access token](https://dev.twitch.tv/docs/authentication#app-access-tokens) or [user access token](https://dev.twitch.tv/docs/authentication#user-access-tokens). The Client ID associated with the access token must be owned by a user who is a member of the [organization](https://dev.twitch.tv/docs/docs/companies/) that holds ownership of the game.
|
|
6572
6705
|
*/
|
|
6573
6706
|
"get-drops-entitlements": {
|
|
6574
6707
|
parameters: {
|
|
@@ -6642,7 +6775,7 @@ interface operations {
|
|
|
6642
6775
|
*
|
|
6643
6776
|
* __Authorization:__
|
|
6644
6777
|
*
|
|
6645
|
-
* Requires an [app access token](https://dev.twitch.tv/docs/authentication#app-access-tokens) or [user access token](https://dev.twitch.tv/docs/authentication#user-access-tokens). The
|
|
6778
|
+
* Requires an [app access token](https://dev.twitch.tv/docs/authentication#app-access-tokens) or [user access token](https://dev.twitch.tv/docs/authentication#user-access-tokens). The Client ID associated with the access token must be owned by a user who is a member of the [organization](https://dev.twitch.tv/docs/docs/companies/) that holds ownership of the game.
|
|
6646
6779
|
*/
|
|
6647
6780
|
"update-drops-entitlements": {
|
|
6648
6781
|
requestBody?: {
|
|
@@ -7306,7 +7439,7 @@ interface operations {
|
|
|
7306
7439
|
*
|
|
7307
7440
|
* __Request Query Parameters:__
|
|
7308
7441
|
*
|
|
7309
|
-
* Use the _status_, _type_, and
|
|
7442
|
+
* Use the _status_, _type_, _user\_id_, and _subscription\_id_ query parameters to filter the list of subscriptions that are returned. The filters are mutually exclusive; the request fails if you specify more than one filter.
|
|
7310
7443
|
*/
|
|
7311
7444
|
"get-eventsub-subscriptions": {
|
|
7312
7445
|
parameters: {
|
|
@@ -7338,6 +7471,8 @@ interface operations {
|
|
|
7338
7471
|
type?: "automod.message.hold" | "automod.message.update" | "automod.settings.update" | "automod.terms.update" | "channel.bits.use" | "channel.update" | "channel.follow" | "channel.ad_break.begin" | "channel.chat.clear" | "channel.chat.clear_user_messages" | "channel.chat.message" | "channel.chat.message_delete" | "channel.chat.notification" | "channel.chat_settings.update" | "channel.chat.user_message_hold" | "channel.chat.user_message_update" | "channel.shared_chat.begin" | "channel.shared_chat.update" | "channel.shared_chat.end" | "channel.subscribe" | "channel.subscription.end" | "channel.subscription.gift" | "channel.subscription.message" | "channel.cheer" | "channel.raid" | "channel.ban" | "channel.unban" | "channel.unban_request.create" | "channel.unban_request.resolve" | "channel.moderate" | "channel.moderator.add" | "channel.moderator.remove" | "channel.guest_star_session.begin" | "channel.guest_star_session.end" | "channel.guest_star_guest.update" | "channel.guest_star_settings.update" | "channel.channel_points_automatic_reward_redemption.add" | "channel.channel_points_custom_reward.add" | "channel.channel_points_custom_reward.update" | "channel.channel_points_custom_reward.remove" | "channel.channel_points_custom_reward_redemption.add" | "channel.channel_points_custom_reward_redemption.update" | "channel.poll.begin" | "channel.poll.progress" | "channel.poll.end" | "channel.prediction.begin" | "channel.prediction.progress" | "channel.prediction.lock" | "channel.prediction.end" | "channel.suspicious_user.message" | "channel.suspicious_user.update" | "channel.vip.add" | "channel.vip.remove" | "channel.warning.acknowledge" | "channel.warning.send" | "channel.charity_campaign.donate" | "channel.charity_campaign.start" | "channel.charity_campaign.progress" | "channel.charity_campaign.stop" | "conduit.shard.disabled" | "drop.entitlement.grant" | "extension.bits_transaction.create" | "channel.goal.begin" | "channel.goal.progress" | "channel.goal.end" | "channel.hype_train.begin" | "channel.hype_train.progress" | "channel.hype_train.end" | "channel.shield_mode.begin" | "channel.shield_mode.end" | "channel.shoutout.create" | "channel.shoutout.receive" | "stream.online" | "stream.offline" | "user.authorization.grant" | "user.authorization.revoke" | "user.update" | "user.whisper.message";
|
|
7339
7472
|
/** @description Filter subscriptions by user ID. The response contains subscriptions where this ID matches a user ID that you specified in the **Condition** object when you [created the subscription](https://dev.twitch.tv/docs/api/reference#create-eventsub-subscription). */
|
|
7340
7473
|
user_id?: string;
|
|
7474
|
+
/** @description Returns an array with the subscription matching the ID (as long as it is owned by the client making the request), or an empty array if there is no matching subscription. */
|
|
7475
|
+
subscription_id?: string;
|
|
7341
7476
|
/** @description The cursor used to get the next page of results. The `pagination` object in the response contains the cursor's value. */
|
|
7342
7477
|
after?: string;
|
|
7343
7478
|
};
|
|
@@ -8331,6 +8466,47 @@ interface operations {
|
|
|
8331
8466
|
};
|
|
8332
8467
|
};
|
|
8333
8468
|
};
|
|
8469
|
+
/**
|
|
8470
|
+
* BETA Gets the status of a Hype Train for the specified broadcaster.
|
|
8471
|
+
* @description BETA Get the status of a Hype Train for the specified broadcaster.
|
|
8472
|
+
*
|
|
8473
|
+
* __Authorization:__
|
|
8474
|
+
*
|
|
8475
|
+
* * Requires an [user access token](https://dev.twitch.tv/docs/authentication/#user-access-tokens).
|
|
8476
|
+
* * Requires OAuth Scope: `channel:read:hype_train`.
|
|
8477
|
+
* * Requires that `broadcaster_id` and `user_id` match in the User-Access token.
|
|
8478
|
+
*/
|
|
8479
|
+
"get-hype-train-status": {
|
|
8480
|
+
parameters: {
|
|
8481
|
+
query: {
|
|
8482
|
+
/** @description The User ID of the channel broadcaster. */
|
|
8483
|
+
broadcaster_id: string;
|
|
8484
|
+
};
|
|
8485
|
+
};
|
|
8486
|
+
responses: {
|
|
8487
|
+
/** @description Successfully retrieved the status object. */
|
|
8488
|
+
200: {
|
|
8489
|
+
content: {
|
|
8490
|
+
"application/json": components["schemas"]["GetHypeTrainStatusResponse"];
|
|
8491
|
+
};
|
|
8492
|
+
};
|
|
8493
|
+
/** @description The ID in the `broadcaster_id` query parameter is not valid. */
|
|
8494
|
+
400: {
|
|
8495
|
+
content: never;
|
|
8496
|
+
};
|
|
8497
|
+
/**
|
|
8498
|
+
* @description * The OAuth token is not valid.
|
|
8499
|
+
* * The Authorization header is required and must contain a user access token.
|
|
8500
|
+
*/
|
|
8501
|
+
401: {
|
|
8502
|
+
content: never;
|
|
8503
|
+
};
|
|
8504
|
+
/** @description Internal Server Error. */
|
|
8505
|
+
500: {
|
|
8506
|
+
content: never;
|
|
8507
|
+
};
|
|
8508
|
+
};
|
|
8509
|
+
};
|
|
8334
8510
|
/**
|
|
8335
8511
|
* Checks whether AutoMod would flag the specified message for review.
|
|
8336
8512
|
* @description Checks whether AutoMod would flag the specified message for review.
|
|
@@ -11240,6 +11416,10 @@ interface operations {
|
|
|
11240
11416
|
401: {
|
|
11241
11417
|
content: never;
|
|
11242
11418
|
};
|
|
11419
|
+
/** @description The app exceeded the number of requests that it may make. */
|
|
11420
|
+
429: {
|
|
11421
|
+
content: never;
|
|
11422
|
+
};
|
|
11243
11423
|
};
|
|
11244
11424
|
};
|
|
11245
11425
|
/**
|
|
@@ -11853,6 +12033,7 @@ type UpdateGuestStarSlotParams = ParamsSchema<'update-guest-star-slot'>;
|
|
|
11853
12033
|
type DeleteGuestStarSlotParams = ParamsSchema<'delete-guest-star-slot'>;
|
|
11854
12034
|
type UpdateGuestStarSlotSettingsParams = ParamsSchema<'update-guest-star-slot-settings'>;
|
|
11855
12035
|
type GetHypeTrainEventsParams = ParamsSchema<'get-hype-train-events'>;
|
|
12036
|
+
type GetHypeTrainStatusParams = ParamsSchema<'get-hype-train-status'>;
|
|
11856
12037
|
type CheckAutoModStatusParams = ParamsSchema<'check-automod-status'>;
|
|
11857
12038
|
type GetAutoModSettingsParams = ParamsSchema<'get-automod-settings'>;
|
|
11858
12039
|
type UpdateAutoModSettingsParams = ParamsSchema<'update-automod-settings'>;
|
|
@@ -12024,6 +12205,7 @@ type GuestStarInvite = Schema<'GuestStarInvite'>;
|
|
|
12024
12205
|
type GetGuestStarInvitesResponse = Schema<'GetGuestStarInvitesResponse'>;
|
|
12025
12206
|
type HypeTrainEvent = Schema<'HypeTrainEvent'>;
|
|
12026
12207
|
type GetHypeTrainEventsResponse = Schema<'GetHypeTrainEventsResponse'>;
|
|
12208
|
+
type GetHypeTrainStatusResponse = Schema<'GetHypeTrainStatusResponse'>;
|
|
12027
12209
|
type CheckAutoModStatusBody = Schema<'CheckAutoModStatusBody'>;
|
|
12028
12210
|
type AutoModStatus = Schema<'AutoModStatus'>;
|
|
12029
12211
|
type CheckAutoModStatusResponse = Schema<'CheckAutoModStatusResponse'>;
|
|
@@ -13600,6 +13782,11 @@ declare class TwitchApi {
|
|
|
13600
13782
|
/**
|
|
13601
13783
|
* NEW Sends a message to the broadcaster’s chat room.
|
|
13602
13784
|
*
|
|
13785
|
+
* **NOTE:** When sending messages to a Shared Chat session, behaviors differ depending on your authentication token type:
|
|
13786
|
+
*
|
|
13787
|
+
* * When using an _App Access Token_, messages will only be sent to the source channel (defined by the `broadcaster_id` parameter) by default starting on May 19, 2025\. Messages can be sent to all channels by using the `for_source_only` parameter and setting it to `false`.
|
|
13788
|
+
* * When using a _User Access Token_, messages will be sent to all channels in the shared chat session, including the source channel. This behavior cannot be changed with this token type.
|
|
13789
|
+
*
|
|
13603
13790
|
* __Authorization:__
|
|
13604
13791
|
*
|
|
13605
13792
|
* Requires an [app access token](https://dev.twitch.tv/docs/authentication#app-access-tokens) or [user access token](https://dev.twitch.tv/docs/authentication#user-access-tokens) that includes the `user:write:chat` scope. If app access token used, then additionally requires `user:bot` scope from chatting user, and either `channel:bot` scope from broadcaster or moderator status.
|
|
@@ -13622,6 +13809,7 @@ declare class TwitchApi {
|
|
|
13622
13809
|
* * The ID in the _sender\_id_ query parameter is not valid.
|
|
13623
13810
|
* * The _text_ query parameter is required.
|
|
13624
13811
|
* * The ID in the _reply\_parent\_message\_id_ query parameter is not valid.
|
|
13812
|
+
* * Cannot set \*for\_source\_only\* if User Access Token is used.
|
|
13625
13813
|
*
|
|
13626
13814
|
* _401 Unauthorized_
|
|
13627
13815
|
*
|
|
@@ -14111,7 +14299,7 @@ declare class TwitchApi {
|
|
|
14111
14299
|
*
|
|
14112
14300
|
* __Authorization:__
|
|
14113
14301
|
*
|
|
14114
|
-
* Requires an [app access token](https://dev.twitch.tv/docs/authentication#app-access-tokens) or [user access token](https://dev.twitch.tv/docs/authentication#user-access-tokens). The
|
|
14302
|
+
* Requires an [app access token](https://dev.twitch.tv/docs/authentication#app-access-tokens) or [user access token](https://dev.twitch.tv/docs/authentication#user-access-tokens). The Client ID associated with the access token must be owned by a user who is a member of the [organization](https://dev.twitch.tv/docs/docs/companies/) that holds ownership of the game.
|
|
14115
14303
|
*
|
|
14116
14304
|
* __URL:__
|
|
14117
14305
|
*
|
|
@@ -14164,7 +14352,7 @@ declare class TwitchApi {
|
|
|
14164
14352
|
*
|
|
14165
14353
|
* __Authorization:__
|
|
14166
14354
|
*
|
|
14167
|
-
* Requires an [app access token](https://dev.twitch.tv/docs/authentication#app-access-tokens) or [user access token](https://dev.twitch.tv/docs/authentication#user-access-tokens). The
|
|
14355
|
+
* Requires an [app access token](https://dev.twitch.tv/docs/authentication#app-access-tokens) or [user access token](https://dev.twitch.tv/docs/authentication#user-access-tokens). The Client ID associated with the access token must be owned by a user who is a member of the [organization](https://dev.twitch.tv/docs/docs/companies/) that holds ownership of the game.
|
|
14168
14356
|
*
|
|
14169
14357
|
* __URL:__
|
|
14170
14358
|
*
|
|
@@ -14769,7 +14957,7 @@ declare class TwitchApi {
|
|
|
14769
14957
|
*
|
|
14770
14958
|
* __Request Query Parameters:__
|
|
14771
14959
|
*
|
|
14772
|
-
* Use the _status_, _type_, and
|
|
14960
|
+
* Use the _status_, _type_, _user\_id_, and _subscription\_id_ query parameters to filter the list of subscriptions that are returned. The filters are mutually exclusive; the request fails if you specify more than one filter.
|
|
14773
14961
|
*
|
|
14774
14962
|
* __URL:__
|
|
14775
14963
|
*
|
|
@@ -15334,6 +15522,79 @@ declare class TwitchApi {
|
|
|
15334
15522
|
cursor?: string;
|
|
15335
15523
|
};
|
|
15336
15524
|
}, 200, 401>;
|
|
15525
|
+
/**
|
|
15526
|
+
* BETA Get the status of a Hype Train for the specified broadcaster.
|
|
15527
|
+
*
|
|
15528
|
+
* __Authorization:__
|
|
15529
|
+
*
|
|
15530
|
+
* * Requires an [user access token](https://dev.twitch.tv/docs/authentication/#user-access-tokens).
|
|
15531
|
+
* * Requires OAuth Scope: `channel:read:hype_train`.
|
|
15532
|
+
* * Requires that `broadcaster_id` and `user_id` match in the User-Access token.
|
|
15533
|
+
*
|
|
15534
|
+
* __URL:__
|
|
15535
|
+
*
|
|
15536
|
+
* `GET https://api.twitch.tv/helix/hypetrain/status`
|
|
15537
|
+
*
|
|
15538
|
+
* __Response Codes:__
|
|
15539
|
+
*
|
|
15540
|
+
* _200 OK_
|
|
15541
|
+
*
|
|
15542
|
+
* Successfully retrieved the status object.
|
|
15543
|
+
*
|
|
15544
|
+
* _400 Bad Request_
|
|
15545
|
+
*
|
|
15546
|
+
* The ID in the `broadcaster_id` query parameter is not valid.
|
|
15547
|
+
*
|
|
15548
|
+
* _401 Unauthorized_
|
|
15549
|
+
*
|
|
15550
|
+
* * The OAuth token is not valid.
|
|
15551
|
+
* * The Authorization header is required and must contain a user access token.
|
|
15552
|
+
*
|
|
15553
|
+
* _500 Internal Server Error_
|
|
15554
|
+
*
|
|
15555
|
+
* Internal Server Error.
|
|
15556
|
+
*
|
|
15557
|
+
* @see https://dev.twitch.tv/docs/api/reference#get-hype-train-status
|
|
15558
|
+
*/
|
|
15559
|
+
getHypeTrainStatus: (params: GetHypeTrainStatusParams, options?: CallApiOptions["options"]) => ApiResponse<{
|
|
15560
|
+
data: ({
|
|
15561
|
+
current: {
|
|
15562
|
+
id: string;
|
|
15563
|
+
broadcaster_user_id: string;
|
|
15564
|
+
broadcaster_user_login: string;
|
|
15565
|
+
broadcaster_user_name: string;
|
|
15566
|
+
level: number;
|
|
15567
|
+
total: number;
|
|
15568
|
+
progress: number;
|
|
15569
|
+
goal: number;
|
|
15570
|
+
top_contributions: ({
|
|
15571
|
+
user_id: string;
|
|
15572
|
+
user_login: string;
|
|
15573
|
+
user_name: string;
|
|
15574
|
+
type: "treasure" | "golden_kappa" | "regular";
|
|
15575
|
+
total: number;
|
|
15576
|
+
shared_train_participants: {
|
|
15577
|
+
broadcaster_user_id: string;
|
|
15578
|
+
broadcaster_user_login: string;
|
|
15579
|
+
broadcaster_user_name: string;
|
|
15580
|
+
}[];
|
|
15581
|
+
started_at: string;
|
|
15582
|
+
expires_at: string;
|
|
15583
|
+
is_shared_train: boolean;
|
|
15584
|
+
})[];
|
|
15585
|
+
};
|
|
15586
|
+
})[];
|
|
15587
|
+
all_time_high: {
|
|
15588
|
+
level: number;
|
|
15589
|
+
total: number;
|
|
15590
|
+
achieved_at: string;
|
|
15591
|
+
};
|
|
15592
|
+
shared_all_time_high: {
|
|
15593
|
+
level: number;
|
|
15594
|
+
total: number;
|
|
15595
|
+
achieved_at: string;
|
|
15596
|
+
};
|
|
15597
|
+
}, 200, 400 | 401 | 500>;
|
|
15337
15598
|
};
|
|
15338
15599
|
moderation: {
|
|
15339
15600
|
/**
|
|
@@ -17673,11 +17934,15 @@ declare class TwitchApi {
|
|
|
17673
17934
|
* * The access token is not valid.
|
|
17674
17935
|
* * The ID specified in the Client-Id header does not match the client ID specified in the access token.
|
|
17675
17936
|
*
|
|
17937
|
+
* _429 Too Many Requests_
|
|
17938
|
+
*
|
|
17939
|
+
* The app exceeded the number of requests that it may make.
|
|
17940
|
+
*
|
|
17676
17941
|
* @see https://dev.twitch.tv/docs/api/reference#update-user
|
|
17677
17942
|
*/
|
|
17678
17943
|
updateUser: (params?: UpdateUserParams | null | undefined, options?: CallApiOptions["options"]) => ApiResponse<{
|
|
17679
17944
|
data: components["schemas"]["User"][];
|
|
17680
|
-
}, 200, 400 | 401>;
|
|
17945
|
+
}, 200, 400 | 401 | 429>;
|
|
17681
17946
|
/**
|
|
17682
17947
|
* Gets the list of users that the broadcaster has blocked. [Read More](https://help.twitch.tv/s/article/how-to-manage-harassment-in-chat?language=en%5FUS#BlockWhispersandMessagesfromStrangers)
|
|
17683
17948
|
*
|
|
@@ -18051,4 +18316,4 @@ declare class TwitchApi {
|
|
|
18051
18316
|
};
|
|
18052
18317
|
}
|
|
18053
18318
|
|
|
18054
|
-
export { type AddBlockedTermBody, type AddBlockedTermParams, type AddBlockedTermResponse, type AddChannelModeratorParams, type AddChannelVIPParams, type ApiResponse, type AssignGuestStarSlotParams, type AutoModSettings, type AutoModStatus, type BanUserBody, type BanUserParams, type BanUserResponse, type BannedUser, type BitsLeaderboard, type BlockUserParams, type BlockedTerm, type BroadcasterSubscription, type CancelRaidParams, type Category, type Channel, type ChannelEditor, type ChannelEmote, type ChannelInformation, type ChannelStreamScheduleSegment, type ChannelTeam, type CharityCampaign, type CharityCampaignDonation, type ChatBadge, type ChatSettings, type ChatSettingsUpdated, type Chatter, type CheckAutoModStatusBody, type CheckAutoModStatusParams, type CheckAutoModStatusResponse, type CheckUserSubscriptionParams, type CheckUserSubscriptionResponse, type Cheermote, type CheermoteImageFormat, type CheermoteImageTheme, type CheermoteImages, type Clip, type ContentClassificationLabel, type CreateChannelStreamScheduleSegmentBody, type CreateChannelStreamScheduleSegmentParams, type CreateChannelStreamScheduleSegmentResponse, type CreateClipParams, type CreateClipResponse, type CreateConduitsBody, type CreateConduitsResponse, type CreateCustomRewardsBody, type CreateCustomRewardsParams, type CreateCustomRewardsResponse, type CreateEventSubSubscriptionBody, type CreateEventSubSubscriptionResponse, type CreateExtensionSecretParams, type CreateExtensionSecretResponse, type CreateGuestStarSessionParams, type CreateGuestStarSessionResponse, type CreatePollBody, type CreatePollResponse, type CreatePredictionBody, type CreatePredictionResponse, type CreateStreamMarkerBody, type CreateStreamMarkerResponse, type CreatorGoal, type CustomReward, type CustomRewardRedemption, type DeleteChannelStreamScheduleSegmentParams, type DeleteChatMessagesParams, type DeleteConduitParams, type DeleteCustomRewardParams, type DeleteEventSubSubscriptionParams, type DeleteGuestStarInviteParams, type DeleteGuestStarSlotParams, type DeleteVideosParams, type DeleteVideosResponse, type DropsEntitlement, type DropsEntitlementUpdated, type Emote, type EndGuestStarSessionParams, type EndGuestStarSessionResponse, type EndPollBody, type EndPollResponse, type EndPredictionBody, type EndPredictionResponse, type EventSubSubscription, type Extension, type ExtensionAnalytics, type ExtensionBitsProduct, type ExtensionConfigurationSegment, type ExtensionIconUrls, type ExtensionLiveChannel, type ExtensionSecret, type ExtensionTransaction, type Game, type GameAnalytics, type GetAdScheduleParams, type GetAdScheduleResponse, type GetAllStreamTagsParams, type GetAllStreamTagsResponse, type GetAutoModSettingsParams, type GetAutoModSettingsResponse, type GetBannedUsersParams, type GetBannedUsersResponse, type GetBitsLeaderboardParams, type GetBitsLeaderboardResponse, type GetBlockedTermsParams, type GetBlockedTermsResponse, type GetBroadcasterSubscriptionsParams, type GetBroadcasterSubscriptionsResponse, type GetChannelChatBadgesParams, type GetChannelChatBadgesResponse, type GetChannelEditorsParams, type GetChannelEditorsResponse, type GetChannelEmotesParams, type GetChannelEmotesResponse, type GetChannelFollowersParams, type GetChannelFollowersResponse, type GetChannelGuestStarSettingsParams, type GetChannelGuestStarSettingsResponse, type GetChannelICalendarParams, type GetChannelInformationParams, type GetChannelInformationResponse, type GetChannelStreamScheduleParams, type GetChannelStreamScheduleResponse, type GetChannelTeamsParams, type GetChannelTeamsResponse, type GetCharityCampaignDonationsParams, type GetCharityCampaignDonationsResponse, type GetCharityCampaignParams, type GetCharityCampaignResponse, type GetChatSettingsParams, type GetChatSettingsResponse, type GetChattersParams, type GetChattersResponse, type GetCheermotesParams, type GetCheermotesResponse, type GetClipsParams, type GetClipsResponse, type GetConduitShardsParams, type GetConduitShardsResponse, type GetConduitsResponse, type GetContentClassificationLabelsParams, type GetContentClassificationLabelsResponse, type GetCreatorGoalsParams, type GetCreatorGoalsResponse, type GetCustomRewardParams, type GetCustomRewardRedemptionParams, type GetCustomRewardRedemptionResponse, type GetCustomRewardResponse, type GetDropsEntitlementsParams, type GetDropsEntitlementsResponse, type GetEmoteSetsParams, type GetEmoteSetsResponse, type GetEventSubSubscriptionsParams, type GetEventSubSubscriptionsResponse, type GetExtensionAnalyticsParams, type GetExtensionAnalyticsResponse, type GetExtensionBitsProductsParams, type GetExtensionBitsProductsResponse, type GetExtensionConfigurationSegmentParams, type GetExtensionConfigurationSegmentResponse, type GetExtensionLiveChannelsParams, type GetExtensionLiveChannelsResponse, type GetExtensionSecretsResponse, type GetExtensionTransactionsParams, type GetExtensionTransactionsResponse, type GetExtensionsParams, type GetExtensionsResponse, type GetFollowedChannelsParams, type GetFollowedChannelsResponse, type GetFollowedStreamsParams, type GetFollowedStreamsResponse, type GetGameAnalyticsParams, type GetGameAnalyticsResponse, type GetGamesParams, type GetGamesResponse, type GetGlobalChatBadgesResponse, type GetGlobalEmotesResponse, type GetGuestStarInvitesParams, type GetGuestStarInvitesResponse, type GetGuestStarSessionParams, type GetGuestStarSessionResponse, type GetHypeTrainEventsParams, type GetHypeTrainEventsResponse, type GetModeratedChannelsParams, type GetModeratedChannelsResponse, type GetModeratorsParams, type GetModeratorsResponse, type GetPollsParams, type GetPollsResponse, type GetPredictionsParams, type GetPredictionsResponse, type GetReleasedExtensionsParams, type GetReleasedExtensionsResponse, type GetSharedChatSessionParams, type GetSharedChatSessionResponse, type GetShieldModeStatusParams, type GetShieldModeStatusResponse, type GetStreamKeyParams, type GetStreamKeyResponse, type GetStreamMarkersParams, type GetStreamMarkersResponse, type GetStreamTagsParams, type GetStreamTagsResponse, type GetStreamsParams, type GetStreamsResponse, type GetTeamsParams, type GetTeamsResponse, type GetTopGamesParams, type GetTopGamesResponse, type GetUnbanRequestsParams, type GetUnbanRequestsResponse, type GetUserActiveExtensionsParams, type GetUserActiveExtensionsResponse, type GetUserBlockListParams, type GetUserBlockListResponse, type GetUserChatColorParams, type GetUserChatColorResponse, type GetUserEmotesParams, type GetUserEmotesResponse, type GetUserExtensionsResponse, type GetUsersParams, type GetUsersResponse, type GetVIPsParams, type GetVIPsResponse, type GetVideosParams, type GetVideosResponse, type GlobalEmote, type Guest, type GuestStarInvite, type GuestStarSession, type HypeTrainEvent, type ManageHeldAutoModMessagesBody, type ModifyChannelInformationBody, type ModifyChannelInformationParams, type Poll, type Prediction, type PredictionOutcome, type RemoveBlockedTermParams, type RemoveChannelModeratorParams, type RemoveChannelVIPParams, type ResolveUnbanRequestsParams, type ResolveUnbanRequestsResponse, type SearchCategoriesParams, type SearchCategoriesResponse, type SearchChannelsParams, type SearchChannelsResponse, type SendChatAnnouncementBody, type SendChatAnnouncementParams, type SendChatMessageBody, type SendChatMessageResponse, type SendExtensionChatMessageBody, type SendExtensionChatMessageParams, type SendExtensionPubSubMessageBody, type SendGuestStarInviteParams, type SendShoutoutParams, type SendWhisperBody, type SendWhisperParams, type SetExtensionConfigurationSegmentBody, type SetExtensionRequiredConfigurationBody, type SetExtensionRequiredConfigurationParams, type SnoozeNextAdParams, type SnoozeNextAdResponse, type StartCommercialBody, type StartCommercialResponse, type StartRaidParams, type StartRaidResponse, type Stream, type StreamMarkerCreated, type StreamMarkers, type StreamTag, type Team, TwitchApi, type TwitchApiOptions, type UnbanUserParams, type UnblockUserParams, type UpdateAutoModSettingsBody, type UpdateAutoModSettingsParams, type UpdateAutoModSettingsResponse, type UpdateChannelGuestStarSettingsBody, type UpdateChannelGuestStarSettingsParams, type UpdateChannelStreamScheduleParams, type UpdateChannelStreamScheduleSegmentBody, type UpdateChannelStreamScheduleSegmentParams, type UpdateChannelStreamScheduleSegmentResponse, type UpdateChatSettingsBody, type UpdateChatSettingsParams, type UpdateChatSettingsResponse, type UpdateConduitShardsBody, type UpdateConduitShardsResponse, type UpdateConduitsBody, type UpdateConduitsResponse, type UpdateCustomRewardBody, type UpdateCustomRewardParams, type UpdateCustomRewardResponse, type UpdateDropsEntitlementsBody, type UpdateDropsEntitlementsResponse, type UpdateExtensionBitsProductBody, type UpdateExtensionBitsProductResponse, type UpdateGuestStarSlotParams, type UpdateGuestStarSlotSettingsParams, type UpdateRedemptionStatusBody, type UpdateRedemptionStatusParams, type UpdateRedemptionStatusResponse, type UpdateShieldModeStatusBody, type UpdateShieldModeStatusParams, type UpdateShieldModeStatusResponse, type UpdateUserChatColorParams, type UpdateUserExtensionsBody, type UpdateUserExtensionsResponse, type UpdateUserParams, type UpdateUserResponse, type User, type UserBlockList, type UserChatColor, type UserExtension, type UserExtensionComponent, type UserExtensionComponentUpdate, type UserExtensionOverlay, type UserExtensionOverlayUpdate, type UserExtensionPanel, type UserExtensionPanelUpdate, type UserModerator, type UserSubscription, type UserVip, type Video, type WarnChatUserBody, type WarnChatUserParams, type WarnChatUserResponse };
|
|
18319
|
+
export { type AddBlockedTermBody, type AddBlockedTermParams, type AddBlockedTermResponse, type AddChannelModeratorParams, type AddChannelVIPParams, type ApiResponse, type AssignGuestStarSlotParams, type AutoModSettings, type AutoModStatus, type BanUserBody, type BanUserParams, type BanUserResponse, type BannedUser, type BitsLeaderboard, type BlockUserParams, type BlockedTerm, type BroadcasterSubscription, type CancelRaidParams, type Category, type Channel, type ChannelEditor, type ChannelEmote, type ChannelInformation, type ChannelStreamScheduleSegment, type ChannelTeam, type CharityCampaign, type CharityCampaignDonation, type ChatBadge, type ChatSettings, type ChatSettingsUpdated, type Chatter, type CheckAutoModStatusBody, type CheckAutoModStatusParams, type CheckAutoModStatusResponse, type CheckUserSubscriptionParams, type CheckUserSubscriptionResponse, type Cheermote, type CheermoteImageFormat, type CheermoteImageTheme, type CheermoteImages, type Clip, type ContentClassificationLabel, type CreateChannelStreamScheduleSegmentBody, type CreateChannelStreamScheduleSegmentParams, type CreateChannelStreamScheduleSegmentResponse, type CreateClipParams, type CreateClipResponse, type CreateConduitsBody, type CreateConduitsResponse, type CreateCustomRewardsBody, type CreateCustomRewardsParams, type CreateCustomRewardsResponse, type CreateEventSubSubscriptionBody, type CreateEventSubSubscriptionResponse, type CreateExtensionSecretParams, type CreateExtensionSecretResponse, type CreateGuestStarSessionParams, type CreateGuestStarSessionResponse, type CreatePollBody, type CreatePollResponse, type CreatePredictionBody, type CreatePredictionResponse, type CreateStreamMarkerBody, type CreateStreamMarkerResponse, type CreatorGoal, type CustomReward, type CustomRewardRedemption, type DeleteChannelStreamScheduleSegmentParams, type DeleteChatMessagesParams, type DeleteConduitParams, type DeleteCustomRewardParams, type DeleteEventSubSubscriptionParams, type DeleteGuestStarInviteParams, type DeleteGuestStarSlotParams, type DeleteVideosParams, type DeleteVideosResponse, type DropsEntitlement, type DropsEntitlementUpdated, type Emote, type EndGuestStarSessionParams, type EndGuestStarSessionResponse, type EndPollBody, type EndPollResponse, type EndPredictionBody, type EndPredictionResponse, type EventSubSubscription, type Extension, type ExtensionAnalytics, type ExtensionBitsProduct, type ExtensionConfigurationSegment, type ExtensionIconUrls, type ExtensionLiveChannel, type ExtensionSecret, type ExtensionTransaction, type Game, type GameAnalytics, type GetAdScheduleParams, type GetAdScheduleResponse, type GetAllStreamTagsParams, type GetAllStreamTagsResponse, type GetAutoModSettingsParams, type GetAutoModSettingsResponse, type GetBannedUsersParams, type GetBannedUsersResponse, type GetBitsLeaderboardParams, type GetBitsLeaderboardResponse, type GetBlockedTermsParams, type GetBlockedTermsResponse, type GetBroadcasterSubscriptionsParams, type GetBroadcasterSubscriptionsResponse, type GetChannelChatBadgesParams, type GetChannelChatBadgesResponse, type GetChannelEditorsParams, type GetChannelEditorsResponse, type GetChannelEmotesParams, type GetChannelEmotesResponse, type GetChannelFollowersParams, type GetChannelFollowersResponse, type GetChannelGuestStarSettingsParams, type GetChannelGuestStarSettingsResponse, type GetChannelICalendarParams, type GetChannelInformationParams, type GetChannelInformationResponse, type GetChannelStreamScheduleParams, type GetChannelStreamScheduleResponse, type GetChannelTeamsParams, type GetChannelTeamsResponse, type GetCharityCampaignDonationsParams, type GetCharityCampaignDonationsResponse, type GetCharityCampaignParams, type GetCharityCampaignResponse, type GetChatSettingsParams, type GetChatSettingsResponse, type GetChattersParams, type GetChattersResponse, type GetCheermotesParams, type GetCheermotesResponse, type GetClipsParams, type GetClipsResponse, type GetConduitShardsParams, type GetConduitShardsResponse, type GetConduitsResponse, type GetContentClassificationLabelsParams, type GetContentClassificationLabelsResponse, type GetCreatorGoalsParams, type GetCreatorGoalsResponse, type GetCustomRewardParams, type GetCustomRewardRedemptionParams, type GetCustomRewardRedemptionResponse, type GetCustomRewardResponse, type GetDropsEntitlementsParams, type GetDropsEntitlementsResponse, type GetEmoteSetsParams, type GetEmoteSetsResponse, type GetEventSubSubscriptionsParams, type GetEventSubSubscriptionsResponse, type GetExtensionAnalyticsParams, type GetExtensionAnalyticsResponse, type GetExtensionBitsProductsParams, type GetExtensionBitsProductsResponse, type GetExtensionConfigurationSegmentParams, type GetExtensionConfigurationSegmentResponse, type GetExtensionLiveChannelsParams, type GetExtensionLiveChannelsResponse, type GetExtensionSecretsResponse, type GetExtensionTransactionsParams, type GetExtensionTransactionsResponse, type GetExtensionsParams, type GetExtensionsResponse, type GetFollowedChannelsParams, type GetFollowedChannelsResponse, type GetFollowedStreamsParams, type GetFollowedStreamsResponse, type GetGameAnalyticsParams, type GetGameAnalyticsResponse, type GetGamesParams, type GetGamesResponse, type GetGlobalChatBadgesResponse, type GetGlobalEmotesResponse, type GetGuestStarInvitesParams, type GetGuestStarInvitesResponse, type GetGuestStarSessionParams, type GetGuestStarSessionResponse, type GetHypeTrainEventsParams, type GetHypeTrainEventsResponse, type GetHypeTrainStatusParams, type GetHypeTrainStatusResponse, type GetModeratedChannelsParams, type GetModeratedChannelsResponse, type GetModeratorsParams, type GetModeratorsResponse, type GetPollsParams, type GetPollsResponse, type GetPredictionsParams, type GetPredictionsResponse, type GetReleasedExtensionsParams, type GetReleasedExtensionsResponse, type GetSharedChatSessionParams, type GetSharedChatSessionResponse, type GetShieldModeStatusParams, type GetShieldModeStatusResponse, type GetStreamKeyParams, type GetStreamKeyResponse, type GetStreamMarkersParams, type GetStreamMarkersResponse, type GetStreamTagsParams, type GetStreamTagsResponse, type GetStreamsParams, type GetStreamsResponse, type GetTeamsParams, type GetTeamsResponse, type GetTopGamesParams, type GetTopGamesResponse, type GetUnbanRequestsParams, type GetUnbanRequestsResponse, type GetUserActiveExtensionsParams, type GetUserActiveExtensionsResponse, type GetUserBlockListParams, type GetUserBlockListResponse, type GetUserChatColorParams, type GetUserChatColorResponse, type GetUserEmotesParams, type GetUserEmotesResponse, type GetUserExtensionsResponse, type GetUsersParams, type GetUsersResponse, type GetVIPsParams, type GetVIPsResponse, type GetVideosParams, type GetVideosResponse, type GlobalEmote, type Guest, type GuestStarInvite, type GuestStarSession, type HypeTrainEvent, type ManageHeldAutoModMessagesBody, type ModifyChannelInformationBody, type ModifyChannelInformationParams, type Poll, type Prediction, type PredictionOutcome, type RemoveBlockedTermParams, type RemoveChannelModeratorParams, type RemoveChannelVIPParams, type ResolveUnbanRequestsParams, type ResolveUnbanRequestsResponse, type SearchCategoriesParams, type SearchCategoriesResponse, type SearchChannelsParams, type SearchChannelsResponse, type SendChatAnnouncementBody, type SendChatAnnouncementParams, type SendChatMessageBody, type SendChatMessageResponse, type SendExtensionChatMessageBody, type SendExtensionChatMessageParams, type SendExtensionPubSubMessageBody, type SendGuestStarInviteParams, type SendShoutoutParams, type SendWhisperBody, type SendWhisperParams, type SetExtensionConfigurationSegmentBody, type SetExtensionRequiredConfigurationBody, type SetExtensionRequiredConfigurationParams, type SnoozeNextAdParams, type SnoozeNextAdResponse, type StartCommercialBody, type StartCommercialResponse, type StartRaidParams, type StartRaidResponse, type Stream, type StreamMarkerCreated, type StreamMarkers, type StreamTag, type Team, TwitchApi, type TwitchApiOptions, type UnbanUserParams, type UnblockUserParams, type UpdateAutoModSettingsBody, type UpdateAutoModSettingsParams, type UpdateAutoModSettingsResponse, type UpdateChannelGuestStarSettingsBody, type UpdateChannelGuestStarSettingsParams, type UpdateChannelStreamScheduleParams, type UpdateChannelStreamScheduleSegmentBody, type UpdateChannelStreamScheduleSegmentParams, type UpdateChannelStreamScheduleSegmentResponse, type UpdateChatSettingsBody, type UpdateChatSettingsParams, type UpdateChatSettingsResponse, type UpdateConduitShardsBody, type UpdateConduitShardsResponse, type UpdateConduitsBody, type UpdateConduitsResponse, type UpdateCustomRewardBody, type UpdateCustomRewardParams, type UpdateCustomRewardResponse, type UpdateDropsEntitlementsBody, type UpdateDropsEntitlementsResponse, type UpdateExtensionBitsProductBody, type UpdateExtensionBitsProductResponse, type UpdateGuestStarSlotParams, type UpdateGuestStarSlotSettingsParams, type UpdateRedemptionStatusBody, type UpdateRedemptionStatusParams, type UpdateRedemptionStatusResponse, type UpdateShieldModeStatusBody, type UpdateShieldModeStatusParams, type UpdateShieldModeStatusResponse, type UpdateUserChatColorParams, type UpdateUserExtensionsBody, type UpdateUserExtensionsResponse, type UpdateUserParams, type UpdateUserResponse, type User, type UserBlockList, type UserChatColor, type UserExtension, type UserExtensionComponent, type UserExtensionComponentUpdate, type UserExtensionOverlay, type UserExtensionOverlayUpdate, type UserExtensionPanel, type UserExtensionPanelUpdate, type UserModerator, type UserSubscription, type UserVip, type Video, type WarnChatUserBody, type WarnChatUserParams, type WarnChatUserResponse };
|
package/dist/index.js
CHANGED
|
@@ -1519,6 +1519,11 @@ var TwitchApi = class {
|
|
|
1519
1519
|
/**
|
|
1520
1520
|
* NEW Sends a message to the broadcaster’s chat room.
|
|
1521
1521
|
*
|
|
1522
|
+
* **NOTE:** When sending messages to a Shared Chat session, behaviors differ depending on your authentication token type:
|
|
1523
|
+
*
|
|
1524
|
+
* * When using an _App Access Token_, messages will only be sent to the source channel (defined by the `broadcaster_id` parameter) by default starting on May 19, 2025\. Messages can be sent to all channels by using the `for_source_only` parameter and setting it to `false`.
|
|
1525
|
+
* * When using a _User Access Token_, messages will be sent to all channels in the shared chat session, including the source channel. This behavior cannot be changed with this token type.
|
|
1526
|
+
*
|
|
1522
1527
|
* __Authorization:__
|
|
1523
1528
|
*
|
|
1524
1529
|
* Requires an [app access token](https://dev.twitch.tv/docs/authentication#app-access-tokens) or [user access token](https://dev.twitch.tv/docs/authentication#user-access-tokens) that includes the `user:write:chat` scope. If app access token used, then additionally requires `user:bot` scope from chatting user, and either `channel:bot` scope from broadcaster or moderator status.
|
|
@@ -1541,6 +1546,7 @@ var TwitchApi = class {
|
|
|
1541
1546
|
* * The ID in the _sender\_id_ query parameter is not valid.
|
|
1542
1547
|
* * The _text_ query parameter is required.
|
|
1543
1548
|
* * The ID in the _reply\_parent\_message\_id_ query parameter is not valid.
|
|
1549
|
+
* * Cannot set \*for\_source\_only\* if User Access Token is used.
|
|
1544
1550
|
*
|
|
1545
1551
|
* _401 Unauthorized_
|
|
1546
1552
|
*
|
|
@@ -2014,7 +2020,7 @@ var TwitchApi = class {
|
|
|
2014
2020
|
*
|
|
2015
2021
|
* __Authorization:__
|
|
2016
2022
|
*
|
|
2017
|
-
* Requires an [app access token](https://dev.twitch.tv/docs/authentication#app-access-tokens) or [user access token](https://dev.twitch.tv/docs/authentication#user-access-tokens). The
|
|
2023
|
+
* Requires an [app access token](https://dev.twitch.tv/docs/authentication#app-access-tokens) or [user access token](https://dev.twitch.tv/docs/authentication#user-access-tokens). The Client ID associated with the access token must be owned by a user who is a member of the [organization](https://dev.twitch.tv/docs/docs/companies/) that holds ownership of the game.
|
|
2018
2024
|
*
|
|
2019
2025
|
* __URL:__
|
|
2020
2026
|
*
|
|
@@ -2066,7 +2072,7 @@ var TwitchApi = class {
|
|
|
2066
2072
|
*
|
|
2067
2073
|
* __Authorization:__
|
|
2068
2074
|
*
|
|
2069
|
-
* Requires an [app access token](https://dev.twitch.tv/docs/authentication#app-access-tokens) or [user access token](https://dev.twitch.tv/docs/authentication#user-access-tokens). The
|
|
2075
|
+
* Requires an [app access token](https://dev.twitch.tv/docs/authentication#app-access-tokens) or [user access token](https://dev.twitch.tv/docs/authentication#user-access-tokens). The Client ID associated with the access token must be owned by a user who is a member of the [organization](https://dev.twitch.tv/docs/docs/companies/) that holds ownership of the game.
|
|
2070
2076
|
*
|
|
2071
2077
|
* __URL:__
|
|
2072
2078
|
*
|
|
@@ -2717,7 +2723,7 @@ var TwitchApi = class {
|
|
|
2717
2723
|
*
|
|
2718
2724
|
* __Request Query Parameters:__
|
|
2719
2725
|
*
|
|
2720
|
-
* Use the _status_, _type_, and
|
|
2726
|
+
* Use the _status_, _type_, _user\_id_, and _subscription\_id_ query parameters to filter the list of subscriptions that are returned. The filters are mutually exclusive; the request fails if you specify more than one filter.
|
|
2721
2727
|
*
|
|
2722
2728
|
* __URL:__
|
|
2723
2729
|
*
|
|
@@ -3325,6 +3331,45 @@ var TwitchApi = class {
|
|
|
3325
3331
|
path: "/hypetrain/events",
|
|
3326
3332
|
params,
|
|
3327
3333
|
options
|
|
3334
|
+
}),
|
|
3335
|
+
/**
|
|
3336
|
+
* BETA Get the status of a Hype Train for the specified broadcaster.
|
|
3337
|
+
*
|
|
3338
|
+
* __Authorization:__
|
|
3339
|
+
*
|
|
3340
|
+
* * Requires an [user access token](https://dev.twitch.tv/docs/authentication/#user-access-tokens).
|
|
3341
|
+
* * Requires OAuth Scope: `channel:read:hype_train`.
|
|
3342
|
+
* * Requires that `broadcaster_id` and `user_id` match in the User-Access token.
|
|
3343
|
+
*
|
|
3344
|
+
* __URL:__
|
|
3345
|
+
*
|
|
3346
|
+
* `GET https://api.twitch.tv/helix/hypetrain/status`
|
|
3347
|
+
*
|
|
3348
|
+
* __Response Codes:__
|
|
3349
|
+
*
|
|
3350
|
+
* _200 OK_
|
|
3351
|
+
*
|
|
3352
|
+
* Successfully retrieved the status object.
|
|
3353
|
+
*
|
|
3354
|
+
* _400 Bad Request_
|
|
3355
|
+
*
|
|
3356
|
+
* The ID in the `broadcaster_id` query parameter is not valid.
|
|
3357
|
+
*
|
|
3358
|
+
* _401 Unauthorized_
|
|
3359
|
+
*
|
|
3360
|
+
* * The OAuth token is not valid.
|
|
3361
|
+
* * The Authorization header is required and must contain a user access token.
|
|
3362
|
+
*
|
|
3363
|
+
* _500 Internal Server Error_
|
|
3364
|
+
*
|
|
3365
|
+
* Internal Server Error.
|
|
3366
|
+
*
|
|
3367
|
+
* @see https://dev.twitch.tv/docs/api/reference#get-hype-train-status
|
|
3368
|
+
*/
|
|
3369
|
+
getHypeTrainStatus: (params, options = {}) => this.callApi({
|
|
3370
|
+
path: "/hypetrain/status",
|
|
3371
|
+
params,
|
|
3372
|
+
options
|
|
3328
3373
|
})
|
|
3329
3374
|
};
|
|
3330
3375
|
moderation = {
|
|
@@ -5684,6 +5729,10 @@ var TwitchApi = class {
|
|
|
5684
5729
|
* * The access token is not valid.
|
|
5685
5730
|
* * The ID specified in the Client-Id header does not match the client ID specified in the access token.
|
|
5686
5731
|
*
|
|
5732
|
+
* _429 Too Many Requests_
|
|
5733
|
+
*
|
|
5734
|
+
* The app exceeded the number of requests that it may make.
|
|
5735
|
+
*
|
|
5687
5736
|
* @see https://dev.twitch.tv/docs/api/reference#update-user
|
|
5688
5737
|
*/
|
|
5689
5738
|
updateUser: (params = null, options = {}) => this.callApi({
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "ts-twitch-api",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.6",
|
|
4
4
|
"description": "Very simple TwitchApi class and TypeScript interfaces for all Twitch API endpoints",
|
|
5
5
|
"author": "DmitryScaletta",
|
|
6
6
|
"license": "MIT",
|
|
@@ -29,9 +29,9 @@
|
|
|
29
29
|
],
|
|
30
30
|
"type": "module",
|
|
31
31
|
"devDependencies": {
|
|
32
|
-
"@types/node": "^
|
|
33
|
-
"tsup": "^8.
|
|
34
|
-
"typescript": "^5.
|
|
32
|
+
"@types/node": "^24.3.0",
|
|
33
|
+
"tsup": "^8.5.0",
|
|
34
|
+
"typescript": "^5.9.2"
|
|
35
35
|
},
|
|
36
36
|
"scripts": {
|
|
37
37
|
"build": "pnpm build:src && tsup",
|