Help

Re: YouTube clipper

Solved
Jump to Solution
1997 0
cancel
Showing results for 
Search instead for 
Did you mean: 
Chris_Conley
5 - Automation Enthusiast
5 - Automation Enthusiast

Here is a simple clipper intended to be used with YouTube to pull basic video info

{
"schemaVersion": 3,
"fieldMappings": [
    {
        "fieldName": "Video Title",
        "fieldType": "singleLineText",
        "defaultValue": {
            "type": "cssSelector",
            "opts": {
                "cssSelector": "h1.title"
            }
        }
    },
    {
        "fieldName": "Video Description",
        "fieldType": "multilineText",
        "defaultValue": {
            "type": "cssSelector",
            "opts": {
                "cssSelector": "#description > yt-formatted-string"
            }
        }
    },
    {
        "fieldName": "Video URL",
        "fieldType": "singleLineText",
        "defaultValue": {
            "type": "pageUrl",
            "opts": null
        }
    },
    {
        "fieldName": "Video Duration",
        "fieldType": "singleLineText",
        "defaultValue": {
            "type": "cssSelector",
            "opts": {
                "cssSelector": "#movie_player > div.ytp-chrome-bottom > div.ytp-chrome-controls > div.ytp-left-controls > div > span.ytp-time-duration"
            }
        }
    },
    {
        "fieldName": "View Count",
        "fieldType": "singleLineText",
        "defaultValue": {
            "type": "cssSelector",
            "opts": {
                "cssSelector": "#count > yt-view-count-renderer > span.view-count.style-scope.yt-view-count-renderer"
            }
        }
    }
]

}

1 Solution

Accepted Solutions
Paolo_Perrone
6 - Interface Innovator
6 - Interface Innovator

Hey Chris, would this script download all videos from a channel or just new ones?

See Solution in Thread

4 Replies 4
Bill_C
4 - Data Explorer
4 - Data Explorer

Hey Chris. Two quick question if you have time:

  • What would be the code to populate the channel URL instead of video URL?

  • Is there a way to populate a field in Airtable with the email address a user lists on their channel’s About page?

Many thanks in advance.

I am not sure how to clip the email address from the YT about page; but it looks like you can clip the YT channel URL by using HTML attribute by CSS selector with the following values
CSS selector: a.ytd-video-owner-renderer
Attribute name: href

Paolo_Perrone
6 - Interface Innovator
6 - Interface Innovator

Hey Chris, would this script download all videos from a channel or just new ones?

@Paolo_Perrone This is actually not a script but the schema used to create a web clipper. The web clipper only pulls information from the page you have loaded in the browser so, it only works one video at a time.