Upload in Dailymotion using Google Drive or via email - google-drive-api

I have some video in google drive. Can I upload them directly from Google Drive to dailymotion ? or can I upload file via email as attachment ?

Upload via email is not a possible option, but if your videos have a public url, you can upload them to dailymotion directly using the api.
See the documentation at https://developer.dailymotion.com/api#upload-publish-video. Skip steps 2 and 3, and directly post the video using the url field (set to your video source url). basically, you have to make a POST request to https://api.dailymotion.com/me/videos with the required parameters, among which url=<YOUR_VIDEO_URL>

Related

How do I upload to a specific folder using the VIMEO API?

I am using a PULL request with the VIMEO PHP Library but I can not find in the docs anywhere how to set the destination folder.
It just sends it to the "Videos" folder by default.
$response = $lib->request('/me/videos', ['upload'=>["approach"=>"pull",'link'=>$url], "name"=>$video['video_title']], 'POST');
You have to upload the video to your account first, then make an additional request that adds the video to the folder:
https://developer.vimeo.com/api/reference/folders#add_video_to_project

can i embed a private file of google drive api on my website? (the file has read permission of domain the my website)

the file has read permissions for my domain
but when embedding the file on my google website
reject the embed
code of iframe
<iframe src="https://drive.google.com/file/d/172YjAlA4ZtXzaaHGXORRX-687k78Rsra/preview" width="640" height="480">
I appreciate any help, and if you ask me why I want to show a private file on my website, it is because there is a login through which I only let my users enter
YOu can not embed a private google drive on your website because in order to access that drive a user would need to have permission to it.
You are probably using the webContentLink as the link you are trying to display there is also no way to send authorization in the form of an access token along with this link. THe user themself must have access to the file to be able to download it.
You could try creating a sharable link manually on the Google Drive website and use that link you can set that link to be valid for anyone with the link. But this will be a manual thing as far as i know you can not create these types of links though the website.

Using vimeo API, can I get the video URL before upload is complete?

When having users upload videos to my vimeo via a form in a WordPress blog, can vimeo return the video URL (to use in the code) before the video upload is actually finished?
No, this is not possible.
The resources required to define an upload url are all created during the completion step of an upload (in POST uploads this is the first redirect to vimeo.com, in PUT uploads this is the DELETE request).
This allows us to verify that you have uploaded a video (and not a text file, or image), and verify that the upload has completed, and is successful, before assigning a URL.

google drive preview generation while uploading document

Can a google drive application generate a preview for a file (which is not handled by google drive by default) when a file of that type is uploaded by the user, rather than creating it using that application?(Assuming the user has authorized that application)
Unfortunately, no, sorry.
The closest we have is being able to generate a third party thumbnail for a file. Your app can decide how the file will appear in the Google Drive thumbnail view by uploading the necessary image(s).
The video here explains it: http://www.youtube.com/watch?v=jG5-9zlaPL8

Does Google Drive API support providing link direct to a file which is available in Dropbox API

If I want to let some thirdparty user to download file directly from some Dropbox account I can ask Dropbox to provide direct link, which expires after 4 hours via this /media method.
In Google Drive there is downloadUrl property but it requires passing accessToken. Is there any other way to make Google Drive behave a little more like Dropbox?
Yes, there is the webContentLink field in a file that you can pass to a user to download the file in their browser.