Ruby on Rails Wednesday, April 26, 2017

Hello ,

    I have created a Rails app which allows user to upload files to my Google Drive. 
        session = GoogleDrive::Session.from_config("config.json")
        session.upload_from_file(params[:file].path.to_s, "a_desired_file_name",convert: false)

    I want to make these uploaded files accessible to all, I want to do it using some Ruby code only. I don't wanna do it manually. 

    My motto to do it is my application has a View which lists the links of the files from Google Drive, and those links are useless unless they are 'shareable links.' .

I have used the following gems.
    gem 'google_drive'
    gem 'google-api-client'

'create_permission' method is a listed solution for this problem, but unfortunately it only works with Team Drive which comes with G-Suit.

I hope for your kind assistance.


it is made mandatory for me to use Google Drive for this purpose.

You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to
To post to this group, send email to
To view this discussion on the web visit
For more options, visit

No comments:

Post a Comment