nos
nos

Reputation: 20872

youtube api v3 fetch all videos from a channel that are newer than a video

I already have a script to get all videos information from a youtube channel and store them in a database. Now I want to update my database in case new videos have been uploaded to that channel. How do I retrieve videos that are newer than the newest video in my database?

I have the channelTitle of the channel, videoId and publishedAt of the newest video in the database.

Upvotes: 2

Views: 1125

Answers (1)

johnh10
johnh10

Reputation: 4185

Use the publishedAfter parameter for your search query. See https://developers.google.com/youtube/v3/docs/search/list#parameters

Upvotes: 2

Related Questions