I'm working in node on a server and I'm trying to use the YouTube Api to get a video url. The particular url isn't important, this is more of just an exercise. As far as I can tell with the docs, the best way to find a particular video is if it is associated with a channel or user. IE,
- query the api with a username(GoogleDevelopers for example)
- get it's channel id
- query again to get that channels playlists
- search a particular playlist to get a playlist item
- given a playlistid, search with that to get items(each should represent a video)
- item ids have a
videoId
field, search with that - get video info, but no url?
However, when I get to that point I feel like there should be a url to that video. The though process would be to send this url back to a front end to allow it to use some library to render the video.
QUESTION: Is there a better way to do this? If not, where am I missing the video URL,
part=snippet
in the request? – Idekind
,etag
,nextPageToken
etc. – Plossid
object with thevideoId
hopefully, and my answer will make sense – Ide