user3541631
user3541631

Reputation: 4008

Checking if videos from youtube can be used embeded

In a site I have multiple Youtube embedded videos, (with permission) at that time.

Later, after 1-2 years, some of the videos are marked as Youtube only, or are deleted from youtube.

I'm looking for a way to use python: - to see which video from a list are still available, - which can be used embedded - is a video or playlist

If a package exist, better.

Upvotes: 0

Views: 126

Answers (1)

richflow
richflow

Reputation: 2144

The youtube API should return to you whether a video is embeddable or not:

Calling on their video endpoint should return you a representation that includes:

  "status": {
    ...
    "embeddable": boolean,
    "publicStatsViewable": boolean
  },

You can use any library you like to hit the API like urllib

Upvotes: 1

Related Questions