google.youtube
Platypush documentation
google.youtube
- class platypush.plugins.google.youtube.GoogleYoutubePlugin(*args, **kwargs)[source]
Bases:
GooglePlugin
YouTube plugin.
Requires:
google-api-python-client (
pip install google-api-python-client
)oauth2client (
pip install oauth2client
)
- __init__(*args, **kwargs)[source]
Initialized the Google plugin with the required scopes.
- Parameters:
scopes (list) – List of required scopes
- search(parts=None, query='', types=None, max_results=25, **kwargs)[source]
Search for YouTube content.
- Parameters:
parts (list[str] or str) – List of parts to get (default: snippet). See the Getting started - Part.
query (str) – Query string (default: empty string)
types (list[str] or str) – List of types to retrieve (default: video). See the Getting started - Resources.
max_results (int) – Maximum number of items that will be returned (default: 25).
kwargs – Any extra arguments that will be transparently passed to the YouTube API. See the Getting started - parameters.
- Returns:
A list of YouTube resources. See the Getting started - Resource.