How to upload a file with google drive api?

Send a request to receive a url for downloading a file through the files file?mimeType=application/

Then get the answer with the available url, I need to download these 2.
"thumbnailLink": ""


Tried this but instead of the docs file I get the layout of the page
$url = '';
 $content = file_get_contents($url);
 $fp = fopen(ROOT.'public/imasge.docx', 'w');
fwrite($fp, $content);

How to upload a file to a folder?
June 14th 19 at 18:22
1 answer
June 14th 19 at 18:24

Find more questions by tags APIGoogleGoogle DrivePHP