Python offers multiple options for developing GUI (Graphical User Interface). Out of all the GUI methods, Tkinter is the most commonly used method. It is a standard Python interface to the Tk GUI toolkit shipped with Python. Python with Tkinter is the fastest and easiest way to create GUI applications.
In this article, we will learn how can we obtain data (like title, views, likes, dislikes, etc) from any YouTube video Using YouTube API in Python.
Below is the GUI to be created:
Before proceeding one should properly go through YouTube API in order to install the required modules and enable required functionalities as mentioned in the article.
Import required modules.
# Import Module
We will use the build(), list(), execute() method, it will give Video Details.
Inside list method, pass snippet and statistics in part property and in videoId property pass VideoID of VideoURL.
# creating youtube resource object
youtube =build('youtube','v3', developerKey="Enter API Key")
# retrieve youtube video results
id="Enter Video ID"
Get Title, views, likes from video_response.
Please Login to comment...