TwitchLib 3.5.3
Loading...
Searching...
No Matches
TwitchLib.Api.Helix.Clips Class Reference

Clips related APIs More...

Inheritance diagram for TwitchLib.Api.Helix.Clips:
TwitchLib.Api.Core.ApiBase

Public Member Functions

 Clips (IApiSettings settings, IRateLimiter rateLimiter, IHttpCallHandler http)
 
Task< GetClipsResponseGetClipsAsync (List< string > clipIds=null, string gameId=null, string broadcasterId=null, string before=null, string after=null, DateTime? startedAt=null, DateTime? endedAt=null, int first=20, string accessToken=null)
 Gets clip information by clip ID (one or more), broadcaster ID (one only), or game ID (one only). More...
 
Task< CreatedClipResponseCreateClipAsync (string broadcasterId, string accessToken=null)
 Creates a clip programmatically. This returns both an ID and an edit URL for the new clip. More...
 
- Public Member Functions inherited from TwitchLib.Api.Core.ApiBase
 ApiBase (IApiSettings settings, IRateLimiter rateLimiter, IHttpCallHandler http)
 
async ValueTask< string > GetAccessTokenAsync (string accessToken=null)
 

Additional Inherited Members

- Protected Member Functions inherited from TwitchLib.Api.Core.ApiBase
async Task< string > TwitchGetAsync (string resource, ApiVersion api, List< KeyValuePair< string, string > > getParams=null, string accessToken=null, string clientId=null, string customBase=null)
 
async Task< T > TwitchGetGenericAsync< T > (string resource, ApiVersion api, List< KeyValuePair< string, string > > getParams=null, string accessToken=null, string clientId=null, string customBase=null)
 
async Task< T > TwitchPatchGenericAsync< T > (string resource, ApiVersion api, string payload, List< KeyValuePair< string, string > > getParams=null, string accessToken=null, string clientId=null, string customBase=null)
 
async Task< string > TwitchPatchAsync (string resource, ApiVersion api, string payload, List< KeyValuePair< string, string > > getParams=null, string accessToken=null, string clientId=null, string customBase=null)
 
async Task< KeyValuePair< int, string > > TwitchDeleteAsync (string resource, ApiVersion api, List< KeyValuePair< string, string > > getParams=null, string accessToken=null, string clientId=null, string customBase=null)
 
async Task< T > TwitchPostGenericAsync< T > (string resource, ApiVersion api, string payload, List< KeyValuePair< string, string > > getParams=null, string accessToken=null, string clientId=null, string customBase=null)
 
async Task< T > TwitchPostGenericModelAsync< T > (string resource, ApiVersion api, RequestModel model, string accessToken=null, string clientId=null, string customBase=null)
 
async Task< T > TwitchDeleteGenericAsync< T > (string resource, ApiVersion api, List< KeyValuePair< string, string > > getParams=null, string accessToken=null, string clientId=null, string customBase=null)
 
async Task< T > TwitchPutGenericAsync< T > (string resource, ApiVersion api, string payload=null, List< KeyValuePair< string, string > > getParams=null, string accessToken=null, string clientId=null, string customBase=null)
 
async Task< string > TwitchPutAsync (string resource, ApiVersion api, string payload, List< KeyValuePair< string, string > > getParams=null, string accessToken=null, string clientId=null, string customBase=null)
 
async Task< KeyValuePair< int, string > > TwitchPostAsync (string resource, ApiVersion api, string payload, List< KeyValuePair< string, string > > getParams=null, string accessToken=null, string clientId=null, string customBase=null)
 
Task PutBytesAsync (string url, byte[] payload)
 
async Task< T > GetGenericAsync< T > (string url, List< KeyValuePair< string, string > > getParams=null, string accessToken=null, ApiVersion api=ApiVersion.Helix, string clientId=null)
 
- Protected Attributes inherited from TwitchLib.Api.Core.ApiBase
readonly IApiSettings Settings
 

Detailed Description

Clips related APIs

Constructor & Destructor Documentation

◆ Clips()

TwitchLib.Api.Helix.Clips.Clips ( IApiSettings  settings,
IRateLimiter  rateLimiter,
IHttpCallHandler  http 
)

Member Function Documentation

◆ CreateClipAsync()

Task< CreatedClipResponse > TwitchLib.Api.Helix.Clips.CreateClipAsync ( string  broadcasterId,
string  accessToken = null 
)

Creates a clip programmatically. This returns both an ID and an edit URL for the new clip.

Clip creation takes time. We recommend that you query Get Clips, with the clip ID that is returned here.

If Get Clips returns a valid clip, your clip creation was successful.

If, after 15 seconds, you still have not gotten back a valid clip from Get Clips, assume that the clip was not created and retry Create Clip.

This endpoint has a global rate limit, across all callers.

Required scope: clips:edit

Parameters
broadcasterIdID of the stream from which the clip will be made.
accessTokenoptional access token to override the use of the stored one in the TwitchAPI instance
Returns

◆ GetClipsAsync()

Task< GetClipsResponse > TwitchLib.Api.Helix.Clips.GetClipsAsync ( List< string >  clipIds = null,
string  gameId = null,
string  broadcasterId = null,
string  before = null,
string  after = null,
DateTime?  startedAt = null,
DateTime?  endedAt = null,
int  first = 20,
string  accessToken = null 
)

Gets clip information by clip ID (one or more), broadcaster ID (one only), or game ID (one only).

Note: The clips service returns a maximum of 1000 clips.

Parameters
clipIdsIDs of the clips to query. Limit: 100.
gameIdID of the game for which clips are returned.

The number of clips returned is determined by the first query-string parameter (default: 20).

Results are ordered by view count.

Parameters
broadcasterIdID of the broadcaster for which clips are returned.

The number of clips returned is determined by the first query-string parameter (default: 20).

Results are ordered by view count.

Parameters
beforeCursor for backward pagination: tells the server where to start fetching the next set of results, in a multi-page response.

This applies only to queries specifying broadcaster_id or game_id

Parameters
afterCursor for forward pagination: tells the server where to start fetching the next set of results, in a multi-page response.

This applies only to queries specifying broadcaster_id or game_id

Parameters
startedAtStarting date/time for returned clips, in RFC3339 format. (The seconds value is ignored.)

If this is specified, ended_at also should be specified; otherwise, the ended_at date/time will be 1 week after the started_at value.

Parameters
endedAtEnding date/time for returned clips, in RFC3339 format. (Note that the seconds value is ignored.)

If this is specified, started_at also must be specified; otherwise, the time period is ignored.

Parameters
firstMaximum number of objects to return. Maximum: 100. Default: 20.
accessTokenoptional access token to override the use of the stored one in the TwitchAPI instance
Returns
Exceptions
BadParameterException

The documentation for this class was generated from the following file: