Skip to content
Alessandro Strada edited this page Sep 20, 2019 · 4 revisions

As an alternative for headless devices, you can use OAuth2 for Devices. It allows users to go to a simple URL and enter a short verification code. To enable this authorization method you have to specify the -device command line option along with -id and -secret the first time you run google-drive-ocamlfuse to get the access tokens. The only drawback is that with this OAuth2 flow you cannot access all the files in you Drive, but are limited to file created by google-drive-ocamlfuse. The first time you mount your Drive, after getting the access token, google-drive-ocamlfuse will create a folder named gdfuse. The application will have access only to that folder and only to files you will create/copy in the mounted drive.

Note that when you create the API credentials, you should set application type to Other.

Clone this wiki locally