When you’re researching something or maybe studying, you might use a whole bunch of YouTube videos as resources for your research and sure, you can keep all of those videos in a playlist but if you really think about that, that is really inefficient. You may ask why. Well, when you save to a playlist, you can’t keep any notes and stuff. I am planning to solve that issue using the extension we’re planning to build throughout this tutorial.
Click here if you want to check out the video tutorial.
Activate the extension
If you still want to use this and not build it on your own, feel free to use it from the marketplace. If you want to build it yourself, feel free to continue with the tutorial.
Step 1: Prepare the Google sheet
First, you have to create the google sheet that you want to organize your data in and in the first row, make sure to add the column headings like this.
We have the Video URL in one column and notes in the second column. In the next steps, we’re gonna feed the data from Pixiebrix to this.
Step 2: Open the PixieBrix page editor
Make sure you have the PixieBrix extension installed and head on to any youtube video, then click on Inspect and open PixieBrix from there.
Note: You need to have PixieBrix quickbar configured in order to build this extension. Refer to this document if you don’t know how to do that.
Step 3: Configure the Quickbar with the action in it
For this use case, I am planning to go forward with a quickbar but you could basically use any type of trigger to do the same thing. Maybe you can create a button or a context menu.
First, click on the Add button in the top left of the Pixiebrix editor and choose quickbar. Then you can give any name to your extension and to your quickbar action. You can also set an icon to make it look a little nicer. Also, ensure that the Sites input box has exactly https://www.youtube.com/*
.
Once you have done those things, your configuration should look something like this.
Step 4: Build the workflow
Our workflow will be something like this. After it is triggered by the quickbar,
- Show a model to get the description from the user
- Add that information to a Google sheet
Show the Modal
Firstly, we will use the brick called Show a modal or sidebar form. We will use this to get the description of the video from the user. I am using the following options. I am only using one paragraph text input field called description to collect the note from the user and note the Location property, you can set it to either modal or sidebar.
Parse YouTube URL
Next, we just have to save that data to a Google sheet but right before doing that, we have to format the YouTube URL to make it a little bit clean.
Add the Parse URL brick and set the URL to @input.documentUrl
. What this brick will essentially do is, it will grab the URL from the page and separate that URL into different components so that in the next step, we can just get the video ID from the page.
Save To Google Sheet
Now, all we have to do is save this data to our own Google sheet. To do that, first, add the Add Google sheet row brick and choose the Google sheet to which you need to save your data and the Tab name, tab name will most probably be Sheet1.
Then, in the row values field, Video URL should be https://youtu.be/{{@parsedUrl.searchParams.v}}
(What we’re doing here is getting the video ID from the URL and putting that together with the prefixes) and Notes should be @form.description
.
Now, once you trigger the quickbar widget and give it a note, it should add that entry to the Google Sheet.
Confetti
Well, if you want to make the whole thing a little bit fancy, just add the Show Confetti brick and it will show some Confetti when the workflow is done running.
Bonus
I have demonstrated to you how to do this in the most basic way but you can play around with PixieBrix a little bit, learn some more stuff and add some more features like adding video title, duration, view count, channel etc. to the spreadsheet. I will leave that out for you to do.
Thanks for reading!