I am working on youtube data api v3 to upload an image and an audio as video with image will be displayed as a video.
I can able to upload videos as it is already given as an example.
I tried thumbnail: $('#file_image').val(),
to set video thumbnail. But it didn't work as I expected. I also search over the internet to get an idea. But didn't get any idea.
UploadVideo.prototype.uploadFile = function(file) {
var metadata = {
snippet: {
title: $('#title').val(),
description: $('#description').text(),
tags: this.tags,
thumbnail: $('#file_image').val(),
categoryId: this.categoryId
},
Is this feature achievable using youtube data api? I knew that we can upload an image and audio together works as video in youtube (not through API).
Youtube reference url
Youtube data api Reference
UPDATE:
Using ffmpeg we can able to create a video by combining audio and image. The created video uploaded to Youtube via Youtube DATA API. It works. Now I am trying to automate the following scenario using a script.
Upload Image and Audio. Create the video using ffmpeg. Once video successfully created, upload the video using Youtube DATA API.
I can able to create a video using ffmpeg commands in command line. But when I try to use PHP
code, the command is not executing.
You can use ffmpeg to make a slideshow. Then upload the resulting video. https://trac.ffmpeg.org/wiki/Create%20a%20video%20slideshow%20from%20images
At the moment, no, unfortunately. According to the support article you posted, "Upload audio or image files", there is no API to upload images and audio separately and let YouTube combine them for you. You have to either:
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With