I wrote a piece of code in python to upload a file to google drive, which 
was successful. But I cant able to fetch the file id after the upload. 
Could you guys please help me to get that.


.
.
.
DRIVE = build('drive', 'v2', http=http)

FILES = (
    ('sample.csv', True),
)

for filename,convert in FILES:
    metadata = {'title': filename}
    res = DRIVE.files().insert(convert=convert, body=metadata, 
media_body=filename,fields='mimeType').execute()
    print(res)
     print(a)
     if res:
         print('Uploaded "%s" (%s)' % (filename, res['mimeType']))




Thank you

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/198c01cd-1384-48f7-b3a3-fdf9645873b8%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
  • [google-appengine] G... Rameez Raja

Reply via email to