opkcm.blogg.se

How to share google drive file to public
How to share google drive file to public




I am asking about the UI interface primarily in this question, as it seems simpler to find out if I am expecting the correct result using what Google has made. The inserted permission if successful, None otherwise.įileId=file_id, body=new_permission).execute() Role: The value 'owner', 'writer' or 'reader'. Perm_type: The value 'user', 'group', 'domain' or 'default'. Value: User or group e-mail address, domain name or None for 'default' The method: def insert_permission(userNickName,file_id, value, perm_type, role):Ĭredentials = get_stored_credentials(userNickName)įile_id: ID of the file to insert permission for. I call the following method to set permissions using this: thePermission = insert_permission(userNickName,file,"me","anyone","reader") Also in this case, if I go to the link when not signed in to Google Apps, I am redirected to sign-in. I am trying to do the same thing through the API, and I am not getting the expected result either when setting the permissions to public, setting 'anyone' as 'reader,' and using the webContentLink value for the file as the published URL. I assumed this setting meant that no authentication would be required to view the file. If I open another browser, no cookies, and try to visit the link, I am redirected to sign-in page for Google.

how to share google drive file to public

I then copy the "link to share", in this case it is: Make sure no personally identifiable info is saved in the document metadata (ie, document properties like created by, etc). Upload or open the document you want to share to google docs. Using the Google Drive web interface, I right click on a file, select 'sharing', to get to "Sharing Settings." I set the file to "Public on the web - Anyone on the Internet can find and view." Log out of google (or open in private window) and create a new, random account.






How to share google drive file to public