Product
Introducing SSO
Streamline your login process and enhance security by enabling Single Sign-On (SSO) on the Socket platform, now available for all customers on the Enterprise plan, supporting 20+ identity providers.
Python Client for Google's Private InnerTube API. Works with Youtube, YouTube Music and more!
Readme
Python Client for Google's Private InnerTube API. Works with YouTube, YouTube Music, YouTube Kids, YouTube Studio and more!
This library handles low-level interactions with the underlying InnerTube API used by each of the YouTube services.
Here are a few articles available online relating to the InnerTube API:
innertube
uses Poetry under the hood and can easily be installed from source or from PyPI using pip.
pip install innertube
pip install git+https://github.com/tombulled/innertube@develop
>>> import innertube
>>>
>>> # Construct a client
>>> client = innertube.InnerTube("WEB")
>>>
>>> # Get some data!
>>> data = client.search(query="foo fighters")
>>>
>>> # Power user? No problem, dispatch requests yourself
>>> data = client("browse", body={"browseId": "FEwhat_to_watch"})
>>>
>>> # The core endpoints are implemented, so the above is equivalent to:
>>> data = client.browse("FEwhat_to_watch")
The InnerTube API provides access to data you can't get from the Data API, however it comes at somewhat of a cost (explained below).
This Library | YouTube Data API | |
---|---|---|
Google account required | No | Yes |
Request limit | No | Yes |
Clean data | No | Yes |
The InnerTube API is used by a variety of YouTube services and is not designed for consumption by users. Therefore, the data returned by the InnerTube API will need to be parsed and sanitised to extract data of interest.
Currently only the following core, unauthenticated endpoints are implemented:
YouTube | YouTubeMusic | YouTubeKids | YouTubeStudio | |
---|---|---|---|---|
config | ✓ | ✓ | ✓ | ✓ |
browse | ✓ | ✓ | ✓ | ✓ |
player | ✓ | ✓ | ✓ | ✓ |
next | ✓ | ✓ | ✓ | |
search | ✓ | ✓ | ✓ | |
guide | ✓ | ✓ | ||
get_transcript | ✓ | |||
music/get_search_suggestions | ✓ | |||
music/get_queue | ✓ |
The InnerTube API uses OAuth2, however this has not yet been implemented, therefore this library currently only provides unauthenticated API access.
FAQs
Python Client for Google's Private InnerTube API. Works with Youtube, YouTube Music and more!
We found that innertube demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Product
Streamline your login process and enhance security by enabling Single Sign-On (SSO) on the Socket platform, now available for all customers on the Enterprise plan, supporting 20+ identity providers.
Security News
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
Security News
As cyber threats become more autonomous, AI-powered defenses are crucial for businesses to stay ahead of attackers who can exploit software vulnerabilities at scale.