Clips

class twitch.api.clips.Clips

This class provides methods for easy access to Twitch Clips API.

classmethod get_by_slug(slug)

Gets a clip object based on the slug provided

Parameters:slug (string) – Twitch Slug.
classmethod get_top(channel, cursor, game, language, limit, period, trending)

Gets all clips emoticons in one or more specified sets.

Parameters:
  • channel (string) – Channel name. If this is specified, top clips for only this channel are returned; otherwise, top clips for all channels are returned. If both channel and game are specified, game is ignored.
  • cursor (string) – Tells the server where to start fetching the next set of results, in a multi-page response.
  • game (string) – Game name. (Game names can be retrieved with the Search Games endpoint.) If this is specified, top clips for only this game are returned; otherwise, top clips for all games are returned. If both channel and game are specified, game is ignored.
  • language (string) – Comma-separated list of languages, which constrains the languages of videos returned. Examples: es, en,es,th. If no language is specified, all languages are returned.
  • limit (int) – Maximum number of most-recent objects to return. Default: 10. Maximum: 100.
  • period (string) – The window of time to search for clips. Valid values: day, week, month, all. Default: week.
  • trending (boolean) – If True, the clips returned are ordered by popularity; otherwise, by viewcount. Default: False.
classmethod followed()

Gets top clips for games followed by the user identified by OAuth token. Results are ordered by popularity.

Parameters:
  • limit (int) – Maximum number of most-recent objects to return. Default: 10. Maximum: 100.
  • cursor (string) – Tells the server where to start fetching the next set of results, in a multi-page response.
  • trending (boolean) – If true, the clips returned are ordered by popularity; otherwise, by viewcount. Default: false.