ts-twitch-api 0.2.7 → 0.2.8
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 +64 -1
- package/dist/index.d.cts +171 -12
- package/dist/index.d.ts +171 -12
- package/dist/index.js +64 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -1677,7 +1677,7 @@ var TwitchApi = class {
|
|
|
1677
1677
|
/**
|
|
1678
1678
|
* Creates a clip from the broadcaster’s stream.
|
|
1679
1679
|
*
|
|
1680
|
-
* This API captures up to 90 seconds of the broadcaster’s stream. The 90 seconds spans the point in the stream from when you called the API. For example, if you call the API at the 4:00 minute mark, the API captures from approximately the
|
|
1680
|
+
* This API captures up to 90 seconds of the broadcaster’s stream. The 90 seconds spans the point in the stream from when you called the API. For example, if you call the API at the 4:00 minute mark, the API captures from approximately the 2:35 mark to approximately the 4:05 minute mark. Twitch tries its best to capture 90 seconds of the stream, but the actual length may be less. This may occur if you begin capturing the clip near the beginning or end of the stream.
|
|
1681
1681
|
*
|
|
1682
1682
|
* By default, Twitch publishes up to the last 30 seconds of the 90 seconds window and provides a default title for the clip. To specify the title and the portion of the 90 seconds window that’s used for the clip, use the URL in the response’s `edit_url` field. You can specify a clip that’s from 5 seconds to 60 seconds in length. The URL is valid for up to 24 hours or until the clip is published, whichever comes first.
|
|
1683
1683
|
*
|
|
@@ -1701,6 +1701,8 @@ var TwitchApi = class {
|
|
|
1701
1701
|
*
|
|
1702
1702
|
* * The _broadcaster\_id_ query parameter is required.
|
|
1703
1703
|
* * The ID in the _broadcaster\_id_ query parameter was not found.
|
|
1704
|
+
* * The category is not clippable.
|
|
1705
|
+
* * The title did not pass AutoMod checks.
|
|
1704
1706
|
*
|
|
1705
1707
|
* _401 Unauthorized_
|
|
1706
1708
|
*
|
|
@@ -1713,6 +1715,7 @@ var TwitchApi = class {
|
|
|
1713
1715
|
*
|
|
1714
1716
|
* * The broadcaster has restricted the ability to capture clips to followers and/or subscribers only.
|
|
1715
1717
|
* * The specified broadcaster has not enabled clips on their channel.
|
|
1718
|
+
* * The user is banned or timed out from the broadcaster’s channel.
|
|
1716
1719
|
*
|
|
1717
1720
|
* _404 Not Found_
|
|
1718
1721
|
*
|
|
@@ -1771,6 +1774,66 @@ var TwitchApi = class {
|
|
|
1771
1774
|
params,
|
|
1772
1775
|
options
|
|
1773
1776
|
}),
|
|
1777
|
+
/**
|
|
1778
|
+
* BETA Creates a clip from a broadcaster’s VOD on behalf of the broadcaster or an editor of the channel. Since a live stream is actively creating a VOD, this endpoint can also be used to create a clip from earlier in the current stream.
|
|
1779
|
+
*
|
|
1780
|
+
* The duration of a clip can be from 5 seconds to 60 seconds in length, with a default of 30 seconds if not specified.
|
|
1781
|
+
*
|
|
1782
|
+
* `vod_offset` indicates where the clip will end. In other words, the clip will start at (`vod_offset` \- `duration`) and end at `vod_offset`. This means that the value of `vod_offset` must greater than or equal to the value of `duration`.
|
|
1783
|
+
*
|
|
1784
|
+
* The URL in the response’s `edit_url` field allows you to edit the clip’s title, feature the clip, create a portrait version of the clip, download the clip media, and share the clip directly to social platforms.
|
|
1785
|
+
*
|
|
1786
|
+
* __Authorization:__
|
|
1787
|
+
*
|
|
1788
|
+
* 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 **editor:manage:clips** or **channel:manage:clips** scope.
|
|
1789
|
+
*
|
|
1790
|
+
* __URL:__
|
|
1791
|
+
*
|
|
1792
|
+
* `POST https://api.twitch.tv/helix/videos/clips`
|
|
1793
|
+
*
|
|
1794
|
+
* __Response Codes:__
|
|
1795
|
+
*
|
|
1796
|
+
* _202 Accepted_
|
|
1797
|
+
*
|
|
1798
|
+
* Successfully started the clip process.
|
|
1799
|
+
*
|
|
1800
|
+
* _400 Bad Request_
|
|
1801
|
+
*
|
|
1802
|
+
* * Validation errors: Invalid source type, missing required fields.
|
|
1803
|
+
* * The broadcaster\_id query parameter is required.
|
|
1804
|
+
* * The ID in the broadcaster\_id query parameter was not found.
|
|
1805
|
+
* * The category is not clippable.
|
|
1806
|
+
* * The title did not pass AutoMod checks.
|
|
1807
|
+
* * Broadcaster is banned.
|
|
1808
|
+
*
|
|
1809
|
+
* _401 Unauthorized_
|
|
1810
|
+
*
|
|
1811
|
+
* * The Authorization header is required and must specify user access token.
|
|
1812
|
+
* * The user access token must include the **editor:manage:clips** or **channel:manage:clips** scope.
|
|
1813
|
+
* * The OAuth token is not valid.
|
|
1814
|
+
* * The ID in the Client-Id header must match the Client ID in the OAuth token.
|
|
1815
|
+
*
|
|
1816
|
+
* _403 Forbidden_
|
|
1817
|
+
*
|
|
1818
|
+
* * The broadcaster has restricted the ability to capture clips to followers and/or subscribers only.
|
|
1819
|
+
* * The specified broadcaster has not enabled clips on their channel.
|
|
1820
|
+
* * The user defined by the _editor\_id_ is not authorized to create Clips.
|
|
1821
|
+
* * The user is banned or timed out from the broadcaster's channel.
|
|
1822
|
+
*
|
|
1823
|
+
* _404 Not Found_
|
|
1824
|
+
*
|
|
1825
|
+
* * The broadcaster in the _broadcaster\_id_ query parameter must be broadcasting live.
|
|
1826
|
+
* * The VOD is not found..
|
|
1827
|
+
* * The _broadcaster\_id_ or the _editor\_id_ does not exist.
|
|
1828
|
+
*
|
|
1829
|
+
* @see https://dev.twitch.tv/docs/api/reference#create-clip-from-vod
|
|
1830
|
+
*/
|
|
1831
|
+
createClipFromVOD: (params, options = {}) => this.callApi({
|
|
1832
|
+
path: "/videos/clips",
|
|
1833
|
+
method: "POST",
|
|
1834
|
+
params,
|
|
1835
|
+
options
|
|
1836
|
+
}),
|
|
1774
1837
|
/**
|
|
1775
1838
|
* NEW Provides URLs to download the video file(s) for the specified clips. For information about clips, see [How to use clips](https://help.twitch.tv/s/article/how-to-use-clips).
|
|
1776
1839
|
*
|
package/dist/index.d.cts
CHANGED
|
@@ -1372,15 +1372,25 @@ interface components {
|
|
|
1372
1372
|
data: components["schemas"]["UserChatColor"][];
|
|
1373
1373
|
};
|
|
1374
1374
|
CreateClipResponse: {
|
|
1375
|
+
/** @description A list containing the created clip. */
|
|
1375
1376
|
data: {
|
|
1377
|
+
/** @description An ID that uniquely identifies the clip. */
|
|
1378
|
+
id: string;
|
|
1376
1379
|
/**
|
|
1377
1380
|
* @description A URL that you can use to edit the clip’s title, identify the part of the clip to publish, and publish the clip. [Learn More](https://help.twitch.tv/s/article/how-to-use-clips)
|
|
1378
1381
|
*
|
|
1379
1382
|
* The URL is valid for up to 24 hours or until the clip is published, whichever comes first.
|
|
1380
1383
|
*/
|
|
1381
1384
|
edit_url: string;
|
|
1385
|
+
}[];
|
|
1386
|
+
};
|
|
1387
|
+
CreateClipFromVODResponse: {
|
|
1388
|
+
/** @description A list containing the created clip. */
|
|
1389
|
+
data: {
|
|
1382
1390
|
/** @description An ID that uniquely identifies the clip. */
|
|
1383
1391
|
id: string;
|
|
1392
|
+
/** @description A URL you can use to edit the clip’s title, feature the clip, create a portrait version of the clip, download the clip media, and share the clip directly to third-party platforms. */
|
|
1393
|
+
edit_url: string;
|
|
1384
1394
|
}[];
|
|
1385
1395
|
};
|
|
1386
1396
|
Clip: {
|
|
@@ -2522,6 +2532,7 @@ interface components {
|
|
|
2522
2532
|
total: number;
|
|
2523
2533
|
};
|
|
2524
2534
|
};
|
|
2535
|
+
/** @deprecated */
|
|
2525
2536
|
GetHypeTrainEventsResponse: {
|
|
2526
2537
|
/** @description The list of Hype Train events. The list is empty if the broadcaster hasn’t run a Hype Train within the last 5 days. */
|
|
2527
2538
|
data: components["schemas"]["HypeTrainEvent"][];
|
|
@@ -3982,6 +3993,7 @@ interface components {
|
|
|
3982
3993
|
offline_image_url: string;
|
|
3983
3994
|
/**
|
|
3984
3995
|
* Format: int32
|
|
3996
|
+
* @deprecated
|
|
3985
3997
|
* @description The number of times the user's channel has been viewed.
|
|
3986
3998
|
*
|
|
3987
3999
|
* **NOTE**: This field has been deprecated (see [Get Users API endpoint – "view\_count" deprecation](https://discuss.dev.twitch.tv/t/get-users-api-endpoint-view-count-deprecation/37777)). Any data in this field is not valid and should not be used.
|
|
@@ -4009,7 +4021,7 @@ interface components {
|
|
|
4009
4021
|
};
|
|
4010
4022
|
GetAuthorizationByUserResponse: {
|
|
4011
4023
|
/** @description List of users and their authorized scopes. */
|
|
4012
|
-
data: {
|
|
4024
|
+
data: ({
|
|
4013
4025
|
/** @description The user’s ID. */
|
|
4014
4026
|
user_id: string;
|
|
4015
4027
|
/** @description The user’s display name. */
|
|
@@ -4017,8 +4029,8 @@ interface components {
|
|
|
4017
4029
|
/** @description The user’s login name. */
|
|
4018
4030
|
user_login: string;
|
|
4019
4031
|
/** @description An array of all the scopes the user has granted to the client ID. */
|
|
4020
|
-
scopes:
|
|
4021
|
-
}[];
|
|
4032
|
+
scopes: ("analytics:read:extensions" | "analytics:read:games" | "bits:read" | "channel:bot" | "channel:manage:ads" | "channel:read:ads" | "channel:manage:broadcast" | "channel:read:charity" | "channel:manage:clips" | "channel:edit:commercial" | "channel:read:editors" | "channel:manage:extensions" | "channel:read:goals" | "channel:read:guest_star" | "channel:manage:guest_star" | "channel:read:hype_train" | "channel:manage:moderators" | "channel:read:polls" | "channel:manage:polls" | "channel:read:predictions" | "channel:manage:predictions" | "channel:manage:raids" | "channel:read:redemptions" | "channel:manage:redemptions" | "channel:manage:schedule" | "channel:read:stream_key" | "channel:read:subscriptions" | "channel:manage:videos" | "channel:read:vips" | "channel:manage:vips" | "channel:moderate" | "clips:edit" | "editor:manage:clips" | "moderation:read" | "moderator:manage:announcements" | "moderator:manage:automod" | "moderator:read:automod_settings" | "moderator:manage:automod_settings" | "moderator:read:banned_users" | "moderator:manage:banned_users" | "moderator:read:blocked_terms" | "moderator:read:chat_messages" | "moderator:manage:blocked_terms" | "moderator:manage:chat_messages" | "moderator:read:chat_settings" | "moderator:manage:chat_settings" | "moderator:read:chatters" | "moderator:read:followers" | "moderator:read:guest_star" | "moderator:manage:guest_star" | "moderator:read:moderators" | "moderator:read:shield_mode" | "moderator:manage:shield_mode" | "moderator:read:shoutouts" | "moderator:manage:shoutouts" | "moderator:read:suspicious_users" | "moderator:read:unban_requests" | "moderator:manage:unban_requests" | "moderator:read:vips" | "moderator:read:warnings" | "moderator:manage:warnings" | "user:bot" | "user:edit" | "user:edit:broadcast" | "user:read:blocked_users" | "user:manage:blocked_users" | "user:read:broadcast" | "user:read:chat" | "user:manage:chat_color" | "user:read:email" | "user:read:emotes" | "user:read:follows" | "user:read:moderated_channels" | "user:read:subscriptions" | "user:read:whispers" | "user:manage:whispers" | "user:write:chat" | "chat:edit" | "chat:read" | "whispers:read")[];
|
|
4033
|
+
})[];
|
|
4022
4034
|
};
|
|
4023
4035
|
UserBlockList: {
|
|
4024
4036
|
/** @description An ID that identifies the blocked user. */
|
|
@@ -6383,7 +6395,7 @@ interface operations {
|
|
|
6383
6395
|
* Creates a clip from the broadcaster’s stream.
|
|
6384
6396
|
* @description Creates a clip from the broadcaster’s stream.
|
|
6385
6397
|
*
|
|
6386
|
-
* This API captures up to 90 seconds of the broadcaster’s stream. The 90 seconds spans the point in the stream from when you called the API. For example, if you call the API at the 4:00 minute mark, the API captures from approximately the
|
|
6398
|
+
* This API captures up to 90 seconds of the broadcaster’s stream. The 90 seconds spans the point in the stream from when you called the API. For example, if you call the API at the 4:00 minute mark, the API captures from approximately the 2:35 mark to approximately the 4:05 minute mark. Twitch tries its best to capture 90 seconds of the stream, but the actual length may be less. This may occur if you begin capturing the clip near the beginning or end of the stream.
|
|
6387
6399
|
*
|
|
6388
6400
|
* By default, Twitch publishes up to the last 30 seconds of the 90 seconds window and provides a default title for the clip. To specify the title and the portion of the 90 seconds window that’s used for the clip, use the URL in the response’s `edit_url` field. You can specify a clip that’s from 5 seconds to 60 seconds in length. The URL is valid for up to 24 hours or until the clip is published, whichever comes first.
|
|
6389
6401
|
*
|
|
@@ -6398,8 +6410,10 @@ interface operations {
|
|
|
6398
6410
|
query: {
|
|
6399
6411
|
/** @description The ID of the broadcaster whose stream you want to create a clip from. */
|
|
6400
6412
|
broadcaster_id: string;
|
|
6401
|
-
/** @description
|
|
6402
|
-
|
|
6413
|
+
/** @description The title of the clip. */
|
|
6414
|
+
title?: string;
|
|
6415
|
+
/** @description The length of the clip in seconds. Possible values range from 5 to 60 inclusively with a precision of 0.1\. The default is 30. */
|
|
6416
|
+
duration?: Record<string, never>;
|
|
6403
6417
|
};
|
|
6404
6418
|
};
|
|
6405
6419
|
responses: {
|
|
@@ -6412,6 +6426,8 @@ interface operations {
|
|
|
6412
6426
|
/**
|
|
6413
6427
|
* @description * The _broadcaster\_id_ query parameter is required.
|
|
6414
6428
|
* * The ID in the _broadcaster\_id_ query parameter was not found.
|
|
6429
|
+
* * The category is not clippable.
|
|
6430
|
+
* * The title did not pass AutoMod checks.
|
|
6415
6431
|
*/
|
|
6416
6432
|
400: {
|
|
6417
6433
|
content: never;
|
|
@@ -6428,6 +6444,7 @@ interface operations {
|
|
|
6428
6444
|
/**
|
|
6429
6445
|
* @description * The broadcaster has restricted the ability to capture clips to followers and/or subscribers only.
|
|
6430
6446
|
* * The specified broadcaster has not enabled clips on their channel.
|
|
6447
|
+
* * The user is banned or timed out from the broadcaster’s channel.
|
|
6431
6448
|
*/
|
|
6432
6449
|
403: {
|
|
6433
6450
|
content: never;
|
|
@@ -6438,6 +6455,83 @@ interface operations {
|
|
|
6438
6455
|
};
|
|
6439
6456
|
};
|
|
6440
6457
|
};
|
|
6458
|
+
/**
|
|
6459
|
+
* BETA Creates a clip from the broadcaster’s VOD.
|
|
6460
|
+
* @description BETA Creates a clip from a broadcaster’s VOD on behalf of the broadcaster or an editor of the channel. Since a live stream is actively creating a VOD, this endpoint can also be used to create a clip from earlier in the current stream.
|
|
6461
|
+
*
|
|
6462
|
+
* The duration of a clip can be from 5 seconds to 60 seconds in length, with a default of 30 seconds if not specified.
|
|
6463
|
+
*
|
|
6464
|
+
* `vod_offset` indicates where the clip will end. In other words, the clip will start at (`vod_offset` \- `duration`) and end at `vod_offset`. This means that the value of `vod_offset` must greater than or equal to the value of `duration`.
|
|
6465
|
+
*
|
|
6466
|
+
* The URL in the response’s `edit_url` field allows you to edit the clip’s title, feature the clip, create a portrait version of the clip, download the clip media, and share the clip directly to social platforms.
|
|
6467
|
+
*
|
|
6468
|
+
* __Authorization:__
|
|
6469
|
+
*
|
|
6470
|
+
* 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 **editor:manage:clips** or **channel:manage:clips** scope.
|
|
6471
|
+
*/
|
|
6472
|
+
"create-clip-from-vod": {
|
|
6473
|
+
parameters: {
|
|
6474
|
+
query: {
|
|
6475
|
+
/** @description The user ID of the editor for the channel you want to create a clip for. If using the broadcaster’s auth token, this is the same as broadcaster\_id. This must match the user\_id in the user access token. */
|
|
6476
|
+
editor_id: string;
|
|
6477
|
+
/** @description The user ID for the channel you want to create a clip for. */
|
|
6478
|
+
broadcaster_id: string;
|
|
6479
|
+
/** @description ID of the VOD the user wants to clip. */
|
|
6480
|
+
vod_id: string;
|
|
6481
|
+
/** @description Offset in the VOD to create the clip. See notes above. */
|
|
6482
|
+
vod_offset: number;
|
|
6483
|
+
/** @description The length of the clip, in seconds. Precision is 0.1\. Defaults to 30\. Min: 5 seconds, Max: 60 seconds. */
|
|
6484
|
+
duration?: Record<string, never>;
|
|
6485
|
+
/** @description The title of the clip. */
|
|
6486
|
+
title: string;
|
|
6487
|
+
};
|
|
6488
|
+
};
|
|
6489
|
+
responses: {
|
|
6490
|
+
/** @description Successfully started the clip process. */
|
|
6491
|
+
202: {
|
|
6492
|
+
content: {
|
|
6493
|
+
"application/json": components["schemas"]["CreateClipFromVODResponse"];
|
|
6494
|
+
};
|
|
6495
|
+
};
|
|
6496
|
+
/**
|
|
6497
|
+
* @description * Validation errors: Invalid source type, missing required fields.
|
|
6498
|
+
* * The broadcaster\_id query parameter is required.
|
|
6499
|
+
* * The ID in the broadcaster\_id query parameter was not found.
|
|
6500
|
+
* * The category is not clippable.
|
|
6501
|
+
* * The title did not pass AutoMod checks.
|
|
6502
|
+
* * Broadcaster is banned.
|
|
6503
|
+
*/
|
|
6504
|
+
400: {
|
|
6505
|
+
content: never;
|
|
6506
|
+
};
|
|
6507
|
+
/**
|
|
6508
|
+
* @description * The Authorization header is required and must specify user access token.
|
|
6509
|
+
* * The user access token must include the **editor:manage:clips** or **channel:manage:clips** scope.
|
|
6510
|
+
* * The OAuth token is not valid.
|
|
6511
|
+
* * The ID in the Client-Id header must match the Client ID in the OAuth token.
|
|
6512
|
+
*/
|
|
6513
|
+
401: {
|
|
6514
|
+
content: never;
|
|
6515
|
+
};
|
|
6516
|
+
/**
|
|
6517
|
+
* @description * The broadcaster has restricted the ability to capture clips to followers and/or subscribers only.
|
|
6518
|
+
* * The specified broadcaster has not enabled clips on their channel.
|
|
6519
|
+
* * The user defined by the _editor\_id_ is not authorized to create Clips.
|
|
6520
|
+
* * The user is banned or timed out from the broadcaster's channel.
|
|
6521
|
+
*/
|
|
6522
|
+
403: {
|
|
6523
|
+
content: never;
|
|
6524
|
+
};
|
|
6525
|
+
/**
|
|
6526
|
+
* @description * The broadcaster in the _broadcaster\_id_ query parameter must be broadcasting live.
|
|
6527
|
+
* * The VOD is not found..
|
|
6528
|
+
* * The _broadcaster\_id_ or the _editor\_id_ does not exist.
|
|
6529
|
+
*/
|
|
6530
|
+
404: {
|
|
6531
|
+
content: never;
|
|
6532
|
+
};
|
|
6533
|
+
};
|
|
6534
|
+
};
|
|
6441
6535
|
/**
|
|
6442
6536
|
* NEW Provides URLs to download the video file(s) for the specified clips.
|
|
6443
6537
|
* @description NEW Provides URLs to download the video file(s) for the specified clips. For information about clips, see [How to use clips](https://help.twitch.tv/s/article/how-to-use-clips).
|
|
@@ -12126,6 +12220,7 @@ type GetUserChatColorParams = ParamsSchema<'get-user-chat-color'>;
|
|
|
12126
12220
|
type UpdateUserChatColorParams = ParamsSchema<'update-user-chat-color'>;
|
|
12127
12221
|
type CreateClipParams = ParamsSchema<'create-clip'>;
|
|
12128
12222
|
type GetClipsParams = ParamsSchema<'get-clips'>;
|
|
12223
|
+
type CreateClipFromVODParams = ParamsSchema<'create-clip-from-vod'>;
|
|
12129
12224
|
type GetClipsDownloadParams = ParamsSchema<'get-clips-download'>;
|
|
12130
12225
|
type DeleteConduitParams = ParamsSchema<'delete-conduit'>;
|
|
12131
12226
|
type GetConduitShardsParams = ParamsSchema<'get-conduit-shards'>;
|
|
@@ -12274,6 +12369,7 @@ type SendChatMessageResponse = Schema<'SendChatMessageResponse'>;
|
|
|
12274
12369
|
type UserChatColor = Schema<'UserChatColor'>;
|
|
12275
12370
|
type GetUserChatColorResponse = Schema<'GetUserChatColorResponse'>;
|
|
12276
12371
|
type CreateClipResponse = Schema<'CreateClipResponse'>;
|
|
12372
|
+
type CreateClipFromVODResponse = Schema<'CreateClipFromVODResponse'>;
|
|
12277
12373
|
type Clip = Schema<'Clip'>;
|
|
12278
12374
|
type GetClipsResponse = Schema<'GetClipsResponse'>;
|
|
12279
12375
|
type GetClipsDownloadResponse = Schema<'GetClipsDownloadResponse'>;
|
|
@@ -14038,7 +14134,7 @@ declare class TwitchApi {
|
|
|
14038
14134
|
/**
|
|
14039
14135
|
* Creates a clip from the broadcaster’s stream.
|
|
14040
14136
|
*
|
|
14041
|
-
* This API captures up to 90 seconds of the broadcaster’s stream. The 90 seconds spans the point in the stream from when you called the API. For example, if you call the API at the 4:00 minute mark, the API captures from approximately the
|
|
14137
|
+
* This API captures up to 90 seconds of the broadcaster’s stream. The 90 seconds spans the point in the stream from when you called the API. For example, if you call the API at the 4:00 minute mark, the API captures from approximately the 2:35 mark to approximately the 4:05 minute mark. Twitch tries its best to capture 90 seconds of the stream, but the actual length may be less. This may occur if you begin capturing the clip near the beginning or end of the stream.
|
|
14042
14138
|
*
|
|
14043
14139
|
* By default, Twitch publishes up to the last 30 seconds of the 90 seconds window and provides a default title for the clip. To specify the title and the portion of the 90 seconds window that’s used for the clip, use the URL in the response’s `edit_url` field. You can specify a clip that’s from 5 seconds to 60 seconds in length. The URL is valid for up to 24 hours or until the clip is published, whichever comes first.
|
|
14044
14140
|
*
|
|
@@ -14062,6 +14158,8 @@ declare class TwitchApi {
|
|
|
14062
14158
|
*
|
|
14063
14159
|
* * The _broadcaster\_id_ query parameter is required.
|
|
14064
14160
|
* * The ID in the _broadcaster\_id_ query parameter was not found.
|
|
14161
|
+
* * The category is not clippable.
|
|
14162
|
+
* * The title did not pass AutoMod checks.
|
|
14065
14163
|
*
|
|
14066
14164
|
* _401 Unauthorized_
|
|
14067
14165
|
*
|
|
@@ -14074,6 +14172,7 @@ declare class TwitchApi {
|
|
|
14074
14172
|
*
|
|
14075
14173
|
* * The broadcaster has restricted the ability to capture clips to followers and/or subscribers only.
|
|
14076
14174
|
* * The specified broadcaster has not enabled clips on their channel.
|
|
14175
|
+
* * The user is banned or timed out from the broadcaster’s channel.
|
|
14077
14176
|
*
|
|
14078
14177
|
* _404 Not Found_
|
|
14079
14178
|
*
|
|
@@ -14083,8 +14182,8 @@ declare class TwitchApi {
|
|
|
14083
14182
|
*/
|
|
14084
14183
|
createClip: (params: CreateClipParams, options?: CallApiOptions["options"]) => ApiResponse<{
|
|
14085
14184
|
data: {
|
|
14086
|
-
edit_url: string;
|
|
14087
14185
|
id: string;
|
|
14186
|
+
edit_url: string;
|
|
14088
14187
|
}[];
|
|
14089
14188
|
}, 202, 400 | 401 | 403 | 404>;
|
|
14090
14189
|
/**
|
|
@@ -14133,6 +14232,66 @@ declare class TwitchApi {
|
|
|
14133
14232
|
cursor?: string;
|
|
14134
14233
|
};
|
|
14135
14234
|
}, 200, 400 | 401 | 404>;
|
|
14235
|
+
/**
|
|
14236
|
+
* BETA Creates a clip from a broadcaster’s VOD on behalf of the broadcaster or an editor of the channel. Since a live stream is actively creating a VOD, this endpoint can also be used to create a clip from earlier in the current stream.
|
|
14237
|
+
*
|
|
14238
|
+
* The duration of a clip can be from 5 seconds to 60 seconds in length, with a default of 30 seconds if not specified.
|
|
14239
|
+
*
|
|
14240
|
+
* `vod_offset` indicates where the clip will end. In other words, the clip will start at (`vod_offset` \- `duration`) and end at `vod_offset`. This means that the value of `vod_offset` must greater than or equal to the value of `duration`.
|
|
14241
|
+
*
|
|
14242
|
+
* The URL in the response’s `edit_url` field allows you to edit the clip’s title, feature the clip, create a portrait version of the clip, download the clip media, and share the clip directly to social platforms.
|
|
14243
|
+
*
|
|
14244
|
+
* __Authorization:__
|
|
14245
|
+
*
|
|
14246
|
+
* 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 **editor:manage:clips** or **channel:manage:clips** scope.
|
|
14247
|
+
*
|
|
14248
|
+
* __URL:__
|
|
14249
|
+
*
|
|
14250
|
+
* `POST https://api.twitch.tv/helix/videos/clips`
|
|
14251
|
+
*
|
|
14252
|
+
* __Response Codes:__
|
|
14253
|
+
*
|
|
14254
|
+
* _202 Accepted_
|
|
14255
|
+
*
|
|
14256
|
+
* Successfully started the clip process.
|
|
14257
|
+
*
|
|
14258
|
+
* _400 Bad Request_
|
|
14259
|
+
*
|
|
14260
|
+
* * Validation errors: Invalid source type, missing required fields.
|
|
14261
|
+
* * The broadcaster\_id query parameter is required.
|
|
14262
|
+
* * The ID in the broadcaster\_id query parameter was not found.
|
|
14263
|
+
* * The category is not clippable.
|
|
14264
|
+
* * The title did not pass AutoMod checks.
|
|
14265
|
+
* * Broadcaster is banned.
|
|
14266
|
+
*
|
|
14267
|
+
* _401 Unauthorized_
|
|
14268
|
+
*
|
|
14269
|
+
* * The Authorization header is required and must specify user access token.
|
|
14270
|
+
* * The user access token must include the **editor:manage:clips** or **channel:manage:clips** scope.
|
|
14271
|
+
* * The OAuth token is not valid.
|
|
14272
|
+
* * The ID in the Client-Id header must match the Client ID in the OAuth token.
|
|
14273
|
+
*
|
|
14274
|
+
* _403 Forbidden_
|
|
14275
|
+
*
|
|
14276
|
+
* * The broadcaster has restricted the ability to capture clips to followers and/or subscribers only.
|
|
14277
|
+
* * The specified broadcaster has not enabled clips on their channel.
|
|
14278
|
+
* * The user defined by the _editor\_id_ is not authorized to create Clips.
|
|
14279
|
+
* * The user is banned or timed out from the broadcaster's channel.
|
|
14280
|
+
*
|
|
14281
|
+
* _404 Not Found_
|
|
14282
|
+
*
|
|
14283
|
+
* * The broadcaster in the _broadcaster\_id_ query parameter must be broadcasting live.
|
|
14284
|
+
* * The VOD is not found..
|
|
14285
|
+
* * The _broadcaster\_id_ or the _editor\_id_ does not exist.
|
|
14286
|
+
*
|
|
14287
|
+
* @see https://dev.twitch.tv/docs/api/reference#create-clip-from-vod
|
|
14288
|
+
*/
|
|
14289
|
+
createClipFromVOD: (params: CreateClipFromVODParams, options?: CallApiOptions["options"]) => ApiResponse<{
|
|
14290
|
+
data: {
|
|
14291
|
+
id: string;
|
|
14292
|
+
edit_url: string;
|
|
14293
|
+
}[];
|
|
14294
|
+
}, 202, 400 | 401 | 403 | 404>;
|
|
14136
14295
|
/**
|
|
14137
14296
|
* NEW Provides URLs to download the video file(s) for the specified clips. For information about clips, see [How to use clips](https://help.twitch.tv/s/article/how-to-use-clips).
|
|
14138
14297
|
*
|
|
@@ -18157,12 +18316,12 @@ declare class TwitchApi {
|
|
|
18157
18316
|
* @see https://dev.twitch.tv/docs/api/reference#get-authorization-by-user
|
|
18158
18317
|
*/
|
|
18159
18318
|
getAuthorizationByUser: (params: GetAuthorizationByUserParams, options?: CallApiOptions["options"]) => ApiResponse<{
|
|
18160
|
-
data: {
|
|
18319
|
+
data: ({
|
|
18161
18320
|
user_id: string;
|
|
18162
18321
|
user_name: string;
|
|
18163
18322
|
user_login: string;
|
|
18164
|
-
scopes:
|
|
18165
|
-
}[];
|
|
18323
|
+
scopes: ("analytics:read:extensions" | "analytics:read:games" | "bits:read" | "channel:bot" | "channel:manage:ads" | "channel:read:ads" | "channel:manage:broadcast" | "channel:read:charity" | "channel:manage:clips" | "channel:edit:commercial" | "channel:read:editors" | "channel:manage:extensions" | "channel:read:goals" | "channel:read:guest_star" | "channel:manage:guest_star" | "channel:read:hype_train" | "channel:manage:moderators" | "channel:read:polls" | "channel:manage:polls" | "channel:read:predictions" | "channel:manage:predictions" | "channel:manage:raids" | "channel:read:redemptions" | "channel:manage:redemptions" | "channel:manage:schedule" | "channel:read:stream_key" | "channel:read:subscriptions" | "channel:manage:videos" | "channel:read:vips" | "channel:manage:vips" | "channel:moderate" | "clips:edit" | "editor:manage:clips" | "moderation:read" | "moderator:manage:announcements" | "moderator:manage:automod" | "moderator:read:automod_settings" | "moderator:manage:automod_settings" | "moderator:read:banned_users" | "moderator:manage:banned_users" | "moderator:read:blocked_terms" | "moderator:read:chat_messages" | "moderator:manage:blocked_terms" | "moderator:manage:chat_messages" | "moderator:read:chat_settings" | "moderator:manage:chat_settings" | "moderator:read:chatters" | "moderator:read:followers" | "moderator:read:guest_star" | "moderator:manage:guest_star" | "moderator:read:moderators" | "moderator:read:shield_mode" | "moderator:manage:shield_mode" | "moderator:read:shoutouts" | "moderator:manage:shoutouts" | "moderator:read:suspicious_users" | "moderator:read:unban_requests" | "moderator:manage:unban_requests" | "moderator:read:vips" | "moderator:read:warnings" | "moderator:manage:warnings" | "user:bot" | "user:edit" | "user:edit:broadcast" | "user:read:blocked_users" | "user:manage:blocked_users" | "user:read:broadcast" | "user:read:chat" | "user:manage:chat_color" | "user:read:email" | "user:read:emotes" | "user:read:follows" | "user:read:moderated_channels" | "user:read:subscriptions" | "user:read:whispers" | "user:manage:whispers" | "user:write:chat" | "chat:edit" | "chat:read" | "whispers:read")[];
|
|
18324
|
+
})[];
|
|
18166
18325
|
}, 200, 400 | 401 | 403 | 500>;
|
|
18167
18326
|
/**
|
|
18168
18327
|
* 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)
|
|
@@ -18537,4 +18696,4 @@ declare class TwitchApi {
|
|
|
18537
18696
|
};
|
|
18538
18697
|
}
|
|
18539
18698
|
|
|
18540
|
-
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 GetAuthorizationByUserParams, type GetAuthorizationByUserResponse, 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 GetClipsDownloadParams, type GetClipsDownloadResponse, 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 };
|
|
18699
|
+
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 CreateClipFromVODParams, type CreateClipFromVODResponse, 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 GetAuthorizationByUserParams, type GetAuthorizationByUserResponse, 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 GetClipsDownloadParams, type GetClipsDownloadResponse, 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
|
@@ -1372,15 +1372,25 @@ interface components {
|
|
|
1372
1372
|
data: components["schemas"]["UserChatColor"][];
|
|
1373
1373
|
};
|
|
1374
1374
|
CreateClipResponse: {
|
|
1375
|
+
/** @description A list containing the created clip. */
|
|
1375
1376
|
data: {
|
|
1377
|
+
/** @description An ID that uniquely identifies the clip. */
|
|
1378
|
+
id: string;
|
|
1376
1379
|
/**
|
|
1377
1380
|
* @description A URL that you can use to edit the clip’s title, identify the part of the clip to publish, and publish the clip. [Learn More](https://help.twitch.tv/s/article/how-to-use-clips)
|
|
1378
1381
|
*
|
|
1379
1382
|
* The URL is valid for up to 24 hours or until the clip is published, whichever comes first.
|
|
1380
1383
|
*/
|
|
1381
1384
|
edit_url: string;
|
|
1385
|
+
}[];
|
|
1386
|
+
};
|
|
1387
|
+
CreateClipFromVODResponse: {
|
|
1388
|
+
/** @description A list containing the created clip. */
|
|
1389
|
+
data: {
|
|
1382
1390
|
/** @description An ID that uniquely identifies the clip. */
|
|
1383
1391
|
id: string;
|
|
1392
|
+
/** @description A URL you can use to edit the clip’s title, feature the clip, create a portrait version of the clip, download the clip media, and share the clip directly to third-party platforms. */
|
|
1393
|
+
edit_url: string;
|
|
1384
1394
|
}[];
|
|
1385
1395
|
};
|
|
1386
1396
|
Clip: {
|
|
@@ -2522,6 +2532,7 @@ interface components {
|
|
|
2522
2532
|
total: number;
|
|
2523
2533
|
};
|
|
2524
2534
|
};
|
|
2535
|
+
/** @deprecated */
|
|
2525
2536
|
GetHypeTrainEventsResponse: {
|
|
2526
2537
|
/** @description The list of Hype Train events. The list is empty if the broadcaster hasn’t run a Hype Train within the last 5 days. */
|
|
2527
2538
|
data: components["schemas"]["HypeTrainEvent"][];
|
|
@@ -3982,6 +3993,7 @@ interface components {
|
|
|
3982
3993
|
offline_image_url: string;
|
|
3983
3994
|
/**
|
|
3984
3995
|
* Format: int32
|
|
3996
|
+
* @deprecated
|
|
3985
3997
|
* @description The number of times the user's channel has been viewed.
|
|
3986
3998
|
*
|
|
3987
3999
|
* **NOTE**: This field has been deprecated (see [Get Users API endpoint – "view\_count" deprecation](https://discuss.dev.twitch.tv/t/get-users-api-endpoint-view-count-deprecation/37777)). Any data in this field is not valid and should not be used.
|
|
@@ -4009,7 +4021,7 @@ interface components {
|
|
|
4009
4021
|
};
|
|
4010
4022
|
GetAuthorizationByUserResponse: {
|
|
4011
4023
|
/** @description List of users and their authorized scopes. */
|
|
4012
|
-
data: {
|
|
4024
|
+
data: ({
|
|
4013
4025
|
/** @description The user’s ID. */
|
|
4014
4026
|
user_id: string;
|
|
4015
4027
|
/** @description The user’s display name. */
|
|
@@ -4017,8 +4029,8 @@ interface components {
|
|
|
4017
4029
|
/** @description The user’s login name. */
|
|
4018
4030
|
user_login: string;
|
|
4019
4031
|
/** @description An array of all the scopes the user has granted to the client ID. */
|
|
4020
|
-
scopes:
|
|
4021
|
-
}[];
|
|
4032
|
+
scopes: ("analytics:read:extensions" | "analytics:read:games" | "bits:read" | "channel:bot" | "channel:manage:ads" | "channel:read:ads" | "channel:manage:broadcast" | "channel:read:charity" | "channel:manage:clips" | "channel:edit:commercial" | "channel:read:editors" | "channel:manage:extensions" | "channel:read:goals" | "channel:read:guest_star" | "channel:manage:guest_star" | "channel:read:hype_train" | "channel:manage:moderators" | "channel:read:polls" | "channel:manage:polls" | "channel:read:predictions" | "channel:manage:predictions" | "channel:manage:raids" | "channel:read:redemptions" | "channel:manage:redemptions" | "channel:manage:schedule" | "channel:read:stream_key" | "channel:read:subscriptions" | "channel:manage:videos" | "channel:read:vips" | "channel:manage:vips" | "channel:moderate" | "clips:edit" | "editor:manage:clips" | "moderation:read" | "moderator:manage:announcements" | "moderator:manage:automod" | "moderator:read:automod_settings" | "moderator:manage:automod_settings" | "moderator:read:banned_users" | "moderator:manage:banned_users" | "moderator:read:blocked_terms" | "moderator:read:chat_messages" | "moderator:manage:blocked_terms" | "moderator:manage:chat_messages" | "moderator:read:chat_settings" | "moderator:manage:chat_settings" | "moderator:read:chatters" | "moderator:read:followers" | "moderator:read:guest_star" | "moderator:manage:guest_star" | "moderator:read:moderators" | "moderator:read:shield_mode" | "moderator:manage:shield_mode" | "moderator:read:shoutouts" | "moderator:manage:shoutouts" | "moderator:read:suspicious_users" | "moderator:read:unban_requests" | "moderator:manage:unban_requests" | "moderator:read:vips" | "moderator:read:warnings" | "moderator:manage:warnings" | "user:bot" | "user:edit" | "user:edit:broadcast" | "user:read:blocked_users" | "user:manage:blocked_users" | "user:read:broadcast" | "user:read:chat" | "user:manage:chat_color" | "user:read:email" | "user:read:emotes" | "user:read:follows" | "user:read:moderated_channels" | "user:read:subscriptions" | "user:read:whispers" | "user:manage:whispers" | "user:write:chat" | "chat:edit" | "chat:read" | "whispers:read")[];
|
|
4033
|
+
})[];
|
|
4022
4034
|
};
|
|
4023
4035
|
UserBlockList: {
|
|
4024
4036
|
/** @description An ID that identifies the blocked user. */
|
|
@@ -6383,7 +6395,7 @@ interface operations {
|
|
|
6383
6395
|
* Creates a clip from the broadcaster’s stream.
|
|
6384
6396
|
* @description Creates a clip from the broadcaster’s stream.
|
|
6385
6397
|
*
|
|
6386
|
-
* This API captures up to 90 seconds of the broadcaster’s stream. The 90 seconds spans the point in the stream from when you called the API. For example, if you call the API at the 4:00 minute mark, the API captures from approximately the
|
|
6398
|
+
* This API captures up to 90 seconds of the broadcaster’s stream. The 90 seconds spans the point in the stream from when you called the API. For example, if you call the API at the 4:00 minute mark, the API captures from approximately the 2:35 mark to approximately the 4:05 minute mark. Twitch tries its best to capture 90 seconds of the stream, but the actual length may be less. This may occur if you begin capturing the clip near the beginning or end of the stream.
|
|
6387
6399
|
*
|
|
6388
6400
|
* By default, Twitch publishes up to the last 30 seconds of the 90 seconds window and provides a default title for the clip. To specify the title and the portion of the 90 seconds window that’s used for the clip, use the URL in the response’s `edit_url` field. You can specify a clip that’s from 5 seconds to 60 seconds in length. The URL is valid for up to 24 hours or until the clip is published, whichever comes first.
|
|
6389
6401
|
*
|
|
@@ -6398,8 +6410,10 @@ interface operations {
|
|
|
6398
6410
|
query: {
|
|
6399
6411
|
/** @description The ID of the broadcaster whose stream you want to create a clip from. */
|
|
6400
6412
|
broadcaster_id: string;
|
|
6401
|
-
/** @description
|
|
6402
|
-
|
|
6413
|
+
/** @description The title of the clip. */
|
|
6414
|
+
title?: string;
|
|
6415
|
+
/** @description The length of the clip in seconds. Possible values range from 5 to 60 inclusively with a precision of 0.1\. The default is 30. */
|
|
6416
|
+
duration?: Record<string, never>;
|
|
6403
6417
|
};
|
|
6404
6418
|
};
|
|
6405
6419
|
responses: {
|
|
@@ -6412,6 +6426,8 @@ interface operations {
|
|
|
6412
6426
|
/**
|
|
6413
6427
|
* @description * The _broadcaster\_id_ query parameter is required.
|
|
6414
6428
|
* * The ID in the _broadcaster\_id_ query parameter was not found.
|
|
6429
|
+
* * The category is not clippable.
|
|
6430
|
+
* * The title did not pass AutoMod checks.
|
|
6415
6431
|
*/
|
|
6416
6432
|
400: {
|
|
6417
6433
|
content: never;
|
|
@@ -6428,6 +6444,7 @@ interface operations {
|
|
|
6428
6444
|
/**
|
|
6429
6445
|
* @description * The broadcaster has restricted the ability to capture clips to followers and/or subscribers only.
|
|
6430
6446
|
* * The specified broadcaster has not enabled clips on their channel.
|
|
6447
|
+
* * The user is banned or timed out from the broadcaster’s channel.
|
|
6431
6448
|
*/
|
|
6432
6449
|
403: {
|
|
6433
6450
|
content: never;
|
|
@@ -6438,6 +6455,83 @@ interface operations {
|
|
|
6438
6455
|
};
|
|
6439
6456
|
};
|
|
6440
6457
|
};
|
|
6458
|
+
/**
|
|
6459
|
+
* BETA Creates a clip from the broadcaster’s VOD.
|
|
6460
|
+
* @description BETA Creates a clip from a broadcaster’s VOD on behalf of the broadcaster or an editor of the channel. Since a live stream is actively creating a VOD, this endpoint can also be used to create a clip from earlier in the current stream.
|
|
6461
|
+
*
|
|
6462
|
+
* The duration of a clip can be from 5 seconds to 60 seconds in length, with a default of 30 seconds if not specified.
|
|
6463
|
+
*
|
|
6464
|
+
* `vod_offset` indicates where the clip will end. In other words, the clip will start at (`vod_offset` \- `duration`) and end at `vod_offset`. This means that the value of `vod_offset` must greater than or equal to the value of `duration`.
|
|
6465
|
+
*
|
|
6466
|
+
* The URL in the response’s `edit_url` field allows you to edit the clip’s title, feature the clip, create a portrait version of the clip, download the clip media, and share the clip directly to social platforms.
|
|
6467
|
+
*
|
|
6468
|
+
* __Authorization:__
|
|
6469
|
+
*
|
|
6470
|
+
* 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 **editor:manage:clips** or **channel:manage:clips** scope.
|
|
6471
|
+
*/
|
|
6472
|
+
"create-clip-from-vod": {
|
|
6473
|
+
parameters: {
|
|
6474
|
+
query: {
|
|
6475
|
+
/** @description The user ID of the editor for the channel you want to create a clip for. If using the broadcaster’s auth token, this is the same as broadcaster\_id. This must match the user\_id in the user access token. */
|
|
6476
|
+
editor_id: string;
|
|
6477
|
+
/** @description The user ID for the channel you want to create a clip for. */
|
|
6478
|
+
broadcaster_id: string;
|
|
6479
|
+
/** @description ID of the VOD the user wants to clip. */
|
|
6480
|
+
vod_id: string;
|
|
6481
|
+
/** @description Offset in the VOD to create the clip. See notes above. */
|
|
6482
|
+
vod_offset: number;
|
|
6483
|
+
/** @description The length of the clip, in seconds. Precision is 0.1\. Defaults to 30\. Min: 5 seconds, Max: 60 seconds. */
|
|
6484
|
+
duration?: Record<string, never>;
|
|
6485
|
+
/** @description The title of the clip. */
|
|
6486
|
+
title: string;
|
|
6487
|
+
};
|
|
6488
|
+
};
|
|
6489
|
+
responses: {
|
|
6490
|
+
/** @description Successfully started the clip process. */
|
|
6491
|
+
202: {
|
|
6492
|
+
content: {
|
|
6493
|
+
"application/json": components["schemas"]["CreateClipFromVODResponse"];
|
|
6494
|
+
};
|
|
6495
|
+
};
|
|
6496
|
+
/**
|
|
6497
|
+
* @description * Validation errors: Invalid source type, missing required fields.
|
|
6498
|
+
* * The broadcaster\_id query parameter is required.
|
|
6499
|
+
* * The ID in the broadcaster\_id query parameter was not found.
|
|
6500
|
+
* * The category is not clippable.
|
|
6501
|
+
* * The title did not pass AutoMod checks.
|
|
6502
|
+
* * Broadcaster is banned.
|
|
6503
|
+
*/
|
|
6504
|
+
400: {
|
|
6505
|
+
content: never;
|
|
6506
|
+
};
|
|
6507
|
+
/**
|
|
6508
|
+
* @description * The Authorization header is required and must specify user access token.
|
|
6509
|
+
* * The user access token must include the **editor:manage:clips** or **channel:manage:clips** scope.
|
|
6510
|
+
* * The OAuth token is not valid.
|
|
6511
|
+
* * The ID in the Client-Id header must match the Client ID in the OAuth token.
|
|
6512
|
+
*/
|
|
6513
|
+
401: {
|
|
6514
|
+
content: never;
|
|
6515
|
+
};
|
|
6516
|
+
/**
|
|
6517
|
+
* @description * The broadcaster has restricted the ability to capture clips to followers and/or subscribers only.
|
|
6518
|
+
* * The specified broadcaster has not enabled clips on their channel.
|
|
6519
|
+
* * The user defined by the _editor\_id_ is not authorized to create Clips.
|
|
6520
|
+
* * The user is banned or timed out from the broadcaster's channel.
|
|
6521
|
+
*/
|
|
6522
|
+
403: {
|
|
6523
|
+
content: never;
|
|
6524
|
+
};
|
|
6525
|
+
/**
|
|
6526
|
+
* @description * The broadcaster in the _broadcaster\_id_ query parameter must be broadcasting live.
|
|
6527
|
+
* * The VOD is not found..
|
|
6528
|
+
* * The _broadcaster\_id_ or the _editor\_id_ does not exist.
|
|
6529
|
+
*/
|
|
6530
|
+
404: {
|
|
6531
|
+
content: never;
|
|
6532
|
+
};
|
|
6533
|
+
};
|
|
6534
|
+
};
|
|
6441
6535
|
/**
|
|
6442
6536
|
* NEW Provides URLs to download the video file(s) for the specified clips.
|
|
6443
6537
|
* @description NEW Provides URLs to download the video file(s) for the specified clips. For information about clips, see [How to use clips](https://help.twitch.tv/s/article/how-to-use-clips).
|
|
@@ -12126,6 +12220,7 @@ type GetUserChatColorParams = ParamsSchema<'get-user-chat-color'>;
|
|
|
12126
12220
|
type UpdateUserChatColorParams = ParamsSchema<'update-user-chat-color'>;
|
|
12127
12221
|
type CreateClipParams = ParamsSchema<'create-clip'>;
|
|
12128
12222
|
type GetClipsParams = ParamsSchema<'get-clips'>;
|
|
12223
|
+
type CreateClipFromVODParams = ParamsSchema<'create-clip-from-vod'>;
|
|
12129
12224
|
type GetClipsDownloadParams = ParamsSchema<'get-clips-download'>;
|
|
12130
12225
|
type DeleteConduitParams = ParamsSchema<'delete-conduit'>;
|
|
12131
12226
|
type GetConduitShardsParams = ParamsSchema<'get-conduit-shards'>;
|
|
@@ -12274,6 +12369,7 @@ type SendChatMessageResponse = Schema<'SendChatMessageResponse'>;
|
|
|
12274
12369
|
type UserChatColor = Schema<'UserChatColor'>;
|
|
12275
12370
|
type GetUserChatColorResponse = Schema<'GetUserChatColorResponse'>;
|
|
12276
12371
|
type CreateClipResponse = Schema<'CreateClipResponse'>;
|
|
12372
|
+
type CreateClipFromVODResponse = Schema<'CreateClipFromVODResponse'>;
|
|
12277
12373
|
type Clip = Schema<'Clip'>;
|
|
12278
12374
|
type GetClipsResponse = Schema<'GetClipsResponse'>;
|
|
12279
12375
|
type GetClipsDownloadResponse = Schema<'GetClipsDownloadResponse'>;
|
|
@@ -14038,7 +14134,7 @@ declare class TwitchApi {
|
|
|
14038
14134
|
/**
|
|
14039
14135
|
* Creates a clip from the broadcaster’s stream.
|
|
14040
14136
|
*
|
|
14041
|
-
* This API captures up to 90 seconds of the broadcaster’s stream. The 90 seconds spans the point in the stream from when you called the API. For example, if you call the API at the 4:00 minute mark, the API captures from approximately the
|
|
14137
|
+
* This API captures up to 90 seconds of the broadcaster’s stream. The 90 seconds spans the point in the stream from when you called the API. For example, if you call the API at the 4:00 minute mark, the API captures from approximately the 2:35 mark to approximately the 4:05 minute mark. Twitch tries its best to capture 90 seconds of the stream, but the actual length may be less. This may occur if you begin capturing the clip near the beginning or end of the stream.
|
|
14042
14138
|
*
|
|
14043
14139
|
* By default, Twitch publishes up to the last 30 seconds of the 90 seconds window and provides a default title for the clip. To specify the title and the portion of the 90 seconds window that’s used for the clip, use the URL in the response’s `edit_url` field. You can specify a clip that’s from 5 seconds to 60 seconds in length. The URL is valid for up to 24 hours or until the clip is published, whichever comes first.
|
|
14044
14140
|
*
|
|
@@ -14062,6 +14158,8 @@ declare class TwitchApi {
|
|
|
14062
14158
|
*
|
|
14063
14159
|
* * The _broadcaster\_id_ query parameter is required.
|
|
14064
14160
|
* * The ID in the _broadcaster\_id_ query parameter was not found.
|
|
14161
|
+
* * The category is not clippable.
|
|
14162
|
+
* * The title did not pass AutoMod checks.
|
|
14065
14163
|
*
|
|
14066
14164
|
* _401 Unauthorized_
|
|
14067
14165
|
*
|
|
@@ -14074,6 +14172,7 @@ declare class TwitchApi {
|
|
|
14074
14172
|
*
|
|
14075
14173
|
* * The broadcaster has restricted the ability to capture clips to followers and/or subscribers only.
|
|
14076
14174
|
* * The specified broadcaster has not enabled clips on their channel.
|
|
14175
|
+
* * The user is banned or timed out from the broadcaster’s channel.
|
|
14077
14176
|
*
|
|
14078
14177
|
* _404 Not Found_
|
|
14079
14178
|
*
|
|
@@ -14083,8 +14182,8 @@ declare class TwitchApi {
|
|
|
14083
14182
|
*/
|
|
14084
14183
|
createClip: (params: CreateClipParams, options?: CallApiOptions["options"]) => ApiResponse<{
|
|
14085
14184
|
data: {
|
|
14086
|
-
edit_url: string;
|
|
14087
14185
|
id: string;
|
|
14186
|
+
edit_url: string;
|
|
14088
14187
|
}[];
|
|
14089
14188
|
}, 202, 400 | 401 | 403 | 404>;
|
|
14090
14189
|
/**
|
|
@@ -14133,6 +14232,66 @@ declare class TwitchApi {
|
|
|
14133
14232
|
cursor?: string;
|
|
14134
14233
|
};
|
|
14135
14234
|
}, 200, 400 | 401 | 404>;
|
|
14235
|
+
/**
|
|
14236
|
+
* BETA Creates a clip from a broadcaster’s VOD on behalf of the broadcaster or an editor of the channel. Since a live stream is actively creating a VOD, this endpoint can also be used to create a clip from earlier in the current stream.
|
|
14237
|
+
*
|
|
14238
|
+
* The duration of a clip can be from 5 seconds to 60 seconds in length, with a default of 30 seconds if not specified.
|
|
14239
|
+
*
|
|
14240
|
+
* `vod_offset` indicates where the clip will end. In other words, the clip will start at (`vod_offset` \- `duration`) and end at `vod_offset`. This means that the value of `vod_offset` must greater than or equal to the value of `duration`.
|
|
14241
|
+
*
|
|
14242
|
+
* The URL in the response’s `edit_url` field allows you to edit the clip’s title, feature the clip, create a portrait version of the clip, download the clip media, and share the clip directly to social platforms.
|
|
14243
|
+
*
|
|
14244
|
+
* __Authorization:__
|
|
14245
|
+
*
|
|
14246
|
+
* 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 **editor:manage:clips** or **channel:manage:clips** scope.
|
|
14247
|
+
*
|
|
14248
|
+
* __URL:__
|
|
14249
|
+
*
|
|
14250
|
+
* `POST https://api.twitch.tv/helix/videos/clips`
|
|
14251
|
+
*
|
|
14252
|
+
* __Response Codes:__
|
|
14253
|
+
*
|
|
14254
|
+
* _202 Accepted_
|
|
14255
|
+
*
|
|
14256
|
+
* Successfully started the clip process.
|
|
14257
|
+
*
|
|
14258
|
+
* _400 Bad Request_
|
|
14259
|
+
*
|
|
14260
|
+
* * Validation errors: Invalid source type, missing required fields.
|
|
14261
|
+
* * The broadcaster\_id query parameter is required.
|
|
14262
|
+
* * The ID in the broadcaster\_id query parameter was not found.
|
|
14263
|
+
* * The category is not clippable.
|
|
14264
|
+
* * The title did not pass AutoMod checks.
|
|
14265
|
+
* * Broadcaster is banned.
|
|
14266
|
+
*
|
|
14267
|
+
* _401 Unauthorized_
|
|
14268
|
+
*
|
|
14269
|
+
* * The Authorization header is required and must specify user access token.
|
|
14270
|
+
* * The user access token must include the **editor:manage:clips** or **channel:manage:clips** scope.
|
|
14271
|
+
* * The OAuth token is not valid.
|
|
14272
|
+
* * The ID in the Client-Id header must match the Client ID in the OAuth token.
|
|
14273
|
+
*
|
|
14274
|
+
* _403 Forbidden_
|
|
14275
|
+
*
|
|
14276
|
+
* * The broadcaster has restricted the ability to capture clips to followers and/or subscribers only.
|
|
14277
|
+
* * The specified broadcaster has not enabled clips on their channel.
|
|
14278
|
+
* * The user defined by the _editor\_id_ is not authorized to create Clips.
|
|
14279
|
+
* * The user is banned or timed out from the broadcaster's channel.
|
|
14280
|
+
*
|
|
14281
|
+
* _404 Not Found_
|
|
14282
|
+
*
|
|
14283
|
+
* * The broadcaster in the _broadcaster\_id_ query parameter must be broadcasting live.
|
|
14284
|
+
* * The VOD is not found..
|
|
14285
|
+
* * The _broadcaster\_id_ or the _editor\_id_ does not exist.
|
|
14286
|
+
*
|
|
14287
|
+
* @see https://dev.twitch.tv/docs/api/reference#create-clip-from-vod
|
|
14288
|
+
*/
|
|
14289
|
+
createClipFromVOD: (params: CreateClipFromVODParams, options?: CallApiOptions["options"]) => ApiResponse<{
|
|
14290
|
+
data: {
|
|
14291
|
+
id: string;
|
|
14292
|
+
edit_url: string;
|
|
14293
|
+
}[];
|
|
14294
|
+
}, 202, 400 | 401 | 403 | 404>;
|
|
14136
14295
|
/**
|
|
14137
14296
|
* NEW Provides URLs to download the video file(s) for the specified clips. For information about clips, see [How to use clips](https://help.twitch.tv/s/article/how-to-use-clips).
|
|
14138
14297
|
*
|
|
@@ -18157,12 +18316,12 @@ declare class TwitchApi {
|
|
|
18157
18316
|
* @see https://dev.twitch.tv/docs/api/reference#get-authorization-by-user
|
|
18158
18317
|
*/
|
|
18159
18318
|
getAuthorizationByUser: (params: GetAuthorizationByUserParams, options?: CallApiOptions["options"]) => ApiResponse<{
|
|
18160
|
-
data: {
|
|
18319
|
+
data: ({
|
|
18161
18320
|
user_id: string;
|
|
18162
18321
|
user_name: string;
|
|
18163
18322
|
user_login: string;
|
|
18164
|
-
scopes:
|
|
18165
|
-
}[];
|
|
18323
|
+
scopes: ("analytics:read:extensions" | "analytics:read:games" | "bits:read" | "channel:bot" | "channel:manage:ads" | "channel:read:ads" | "channel:manage:broadcast" | "channel:read:charity" | "channel:manage:clips" | "channel:edit:commercial" | "channel:read:editors" | "channel:manage:extensions" | "channel:read:goals" | "channel:read:guest_star" | "channel:manage:guest_star" | "channel:read:hype_train" | "channel:manage:moderators" | "channel:read:polls" | "channel:manage:polls" | "channel:read:predictions" | "channel:manage:predictions" | "channel:manage:raids" | "channel:read:redemptions" | "channel:manage:redemptions" | "channel:manage:schedule" | "channel:read:stream_key" | "channel:read:subscriptions" | "channel:manage:videos" | "channel:read:vips" | "channel:manage:vips" | "channel:moderate" | "clips:edit" | "editor:manage:clips" | "moderation:read" | "moderator:manage:announcements" | "moderator:manage:automod" | "moderator:read:automod_settings" | "moderator:manage:automod_settings" | "moderator:read:banned_users" | "moderator:manage:banned_users" | "moderator:read:blocked_terms" | "moderator:read:chat_messages" | "moderator:manage:blocked_terms" | "moderator:manage:chat_messages" | "moderator:read:chat_settings" | "moderator:manage:chat_settings" | "moderator:read:chatters" | "moderator:read:followers" | "moderator:read:guest_star" | "moderator:manage:guest_star" | "moderator:read:moderators" | "moderator:read:shield_mode" | "moderator:manage:shield_mode" | "moderator:read:shoutouts" | "moderator:manage:shoutouts" | "moderator:read:suspicious_users" | "moderator:read:unban_requests" | "moderator:manage:unban_requests" | "moderator:read:vips" | "moderator:read:warnings" | "moderator:manage:warnings" | "user:bot" | "user:edit" | "user:edit:broadcast" | "user:read:blocked_users" | "user:manage:blocked_users" | "user:read:broadcast" | "user:read:chat" | "user:manage:chat_color" | "user:read:email" | "user:read:emotes" | "user:read:follows" | "user:read:moderated_channels" | "user:read:subscriptions" | "user:read:whispers" | "user:manage:whispers" | "user:write:chat" | "chat:edit" | "chat:read" | "whispers:read")[];
|
|
18324
|
+
})[];
|
|
18166
18325
|
}, 200, 400 | 401 | 403 | 500>;
|
|
18167
18326
|
/**
|
|
18168
18327
|
* 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)
|
|
@@ -18537,4 +18696,4 @@ declare class TwitchApi {
|
|
|
18537
18696
|
};
|
|
18538
18697
|
}
|
|
18539
18698
|
|
|
18540
|
-
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 GetAuthorizationByUserParams, type GetAuthorizationByUserResponse, 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 GetClipsDownloadParams, type GetClipsDownloadResponse, 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 };
|
|
18699
|
+
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 CreateClipFromVODParams, type CreateClipFromVODResponse, 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 GetAuthorizationByUserParams, type GetAuthorizationByUserResponse, 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 GetClipsDownloadParams, type GetClipsDownloadResponse, 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
|
@@ -1651,7 +1651,7 @@ var TwitchApi = class {
|
|
|
1651
1651
|
/**
|
|
1652
1652
|
* Creates a clip from the broadcaster’s stream.
|
|
1653
1653
|
*
|
|
1654
|
-
* This API captures up to 90 seconds of the broadcaster’s stream. The 90 seconds spans the point in the stream from when you called the API. For example, if you call the API at the 4:00 minute mark, the API captures from approximately the
|
|
1654
|
+
* This API captures up to 90 seconds of the broadcaster’s stream. The 90 seconds spans the point in the stream from when you called the API. For example, if you call the API at the 4:00 minute mark, the API captures from approximately the 2:35 mark to approximately the 4:05 minute mark. Twitch tries its best to capture 90 seconds of the stream, but the actual length may be less. This may occur if you begin capturing the clip near the beginning or end of the stream.
|
|
1655
1655
|
*
|
|
1656
1656
|
* By default, Twitch publishes up to the last 30 seconds of the 90 seconds window and provides a default title for the clip. To specify the title and the portion of the 90 seconds window that’s used for the clip, use the URL in the response’s `edit_url` field. You can specify a clip that’s from 5 seconds to 60 seconds in length. The URL is valid for up to 24 hours or until the clip is published, whichever comes first.
|
|
1657
1657
|
*
|
|
@@ -1675,6 +1675,8 @@ var TwitchApi = class {
|
|
|
1675
1675
|
*
|
|
1676
1676
|
* * The _broadcaster\_id_ query parameter is required.
|
|
1677
1677
|
* * The ID in the _broadcaster\_id_ query parameter was not found.
|
|
1678
|
+
* * The category is not clippable.
|
|
1679
|
+
* * The title did not pass AutoMod checks.
|
|
1678
1680
|
*
|
|
1679
1681
|
* _401 Unauthorized_
|
|
1680
1682
|
*
|
|
@@ -1687,6 +1689,7 @@ var TwitchApi = class {
|
|
|
1687
1689
|
*
|
|
1688
1690
|
* * The broadcaster has restricted the ability to capture clips to followers and/or subscribers only.
|
|
1689
1691
|
* * The specified broadcaster has not enabled clips on their channel.
|
|
1692
|
+
* * The user is banned or timed out from the broadcaster’s channel.
|
|
1690
1693
|
*
|
|
1691
1694
|
* _404 Not Found_
|
|
1692
1695
|
*
|
|
@@ -1745,6 +1748,66 @@ var TwitchApi = class {
|
|
|
1745
1748
|
params,
|
|
1746
1749
|
options
|
|
1747
1750
|
}),
|
|
1751
|
+
/**
|
|
1752
|
+
* BETA Creates a clip from a broadcaster’s VOD on behalf of the broadcaster or an editor of the channel. Since a live stream is actively creating a VOD, this endpoint can also be used to create a clip from earlier in the current stream.
|
|
1753
|
+
*
|
|
1754
|
+
* The duration of a clip can be from 5 seconds to 60 seconds in length, with a default of 30 seconds if not specified.
|
|
1755
|
+
*
|
|
1756
|
+
* `vod_offset` indicates where the clip will end. In other words, the clip will start at (`vod_offset` \- `duration`) and end at `vod_offset`. This means that the value of `vod_offset` must greater than or equal to the value of `duration`.
|
|
1757
|
+
*
|
|
1758
|
+
* The URL in the response’s `edit_url` field allows you to edit the clip’s title, feature the clip, create a portrait version of the clip, download the clip media, and share the clip directly to social platforms.
|
|
1759
|
+
*
|
|
1760
|
+
* __Authorization:__
|
|
1761
|
+
*
|
|
1762
|
+
* 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 **editor:manage:clips** or **channel:manage:clips** scope.
|
|
1763
|
+
*
|
|
1764
|
+
* __URL:__
|
|
1765
|
+
*
|
|
1766
|
+
* `POST https://api.twitch.tv/helix/videos/clips`
|
|
1767
|
+
*
|
|
1768
|
+
* __Response Codes:__
|
|
1769
|
+
*
|
|
1770
|
+
* _202 Accepted_
|
|
1771
|
+
*
|
|
1772
|
+
* Successfully started the clip process.
|
|
1773
|
+
*
|
|
1774
|
+
* _400 Bad Request_
|
|
1775
|
+
*
|
|
1776
|
+
* * Validation errors: Invalid source type, missing required fields.
|
|
1777
|
+
* * The broadcaster\_id query parameter is required.
|
|
1778
|
+
* * The ID in the broadcaster\_id query parameter was not found.
|
|
1779
|
+
* * The category is not clippable.
|
|
1780
|
+
* * The title did not pass AutoMod checks.
|
|
1781
|
+
* * Broadcaster is banned.
|
|
1782
|
+
*
|
|
1783
|
+
* _401 Unauthorized_
|
|
1784
|
+
*
|
|
1785
|
+
* * The Authorization header is required and must specify user access token.
|
|
1786
|
+
* * The user access token must include the **editor:manage:clips** or **channel:manage:clips** scope.
|
|
1787
|
+
* * The OAuth token is not valid.
|
|
1788
|
+
* * The ID in the Client-Id header must match the Client ID in the OAuth token.
|
|
1789
|
+
*
|
|
1790
|
+
* _403 Forbidden_
|
|
1791
|
+
*
|
|
1792
|
+
* * The broadcaster has restricted the ability to capture clips to followers and/or subscribers only.
|
|
1793
|
+
* * The specified broadcaster has not enabled clips on their channel.
|
|
1794
|
+
* * The user defined by the _editor\_id_ is not authorized to create Clips.
|
|
1795
|
+
* * The user is banned or timed out from the broadcaster's channel.
|
|
1796
|
+
*
|
|
1797
|
+
* _404 Not Found_
|
|
1798
|
+
*
|
|
1799
|
+
* * The broadcaster in the _broadcaster\_id_ query parameter must be broadcasting live.
|
|
1800
|
+
* * The VOD is not found..
|
|
1801
|
+
* * The _broadcaster\_id_ or the _editor\_id_ does not exist.
|
|
1802
|
+
*
|
|
1803
|
+
* @see https://dev.twitch.tv/docs/api/reference#create-clip-from-vod
|
|
1804
|
+
*/
|
|
1805
|
+
createClipFromVOD: (params, options = {}) => this.callApi({
|
|
1806
|
+
path: "/videos/clips",
|
|
1807
|
+
method: "POST",
|
|
1808
|
+
params,
|
|
1809
|
+
options
|
|
1810
|
+
}),
|
|
1748
1811
|
/**
|
|
1749
1812
|
* NEW Provides URLs to download the video file(s) for the specified clips. For information about clips, see [How to use clips](https://help.twitch.tv/s/article/how-to-use-clips).
|
|
1750
1813
|
*
|