Skip to content

Effortlessly generate Google Drive API tokens on Android with Termux! This repository provides a streamlined Python script to authenticate and securely save credentials (token.pickle) for seamless Google Drive integration.

Notifications You must be signed in to change notification settings

rjriajul/TokenPickle

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 

Repository files navigation

Generate Token Pickle on Android (Google OAuth 2.0 Update)

Follow these steps to generate the token.pickle file on Android using Termux.


Steps

1. Install Termux

Download and install Termux.

2. Set Up Termux

Open Termux and run this command to update, install necessary packages, and set up Python:

pkg update && pkg upgrade -y && pkg install git python python-pip -y && python -m pip install --upgrade pip && pip install google-api-python-client google-auth-httplib2 google-auth-oauthlib

2. Clone the Repository (Directly in internal Storage)

First, Give Termux storage access:

termux-setup-storage

Now nevigate to the Internal Storage:

cd /sdcard

Run the following to clone the TokenPickle repository:

git clone https://github.com/rjriajul/TokenPickle
cd TokenPickle

3. Add credentials.json

Then Move the credentials.json file to your phone’s internal storage.

cp /sdcard/credentials.json /data/data/com.termux/files/home/TokenPickle

4. Generate the Token

Navigate to the project folder and run the script:

python3 generate_token.py

Copy the URL displayed, open it in a browser, and log in to your Google account. After successful authentication, you’ll see the message:
“The authentication flow has completed. You may close this window.”

5. Save token.pickle

Copy the generated token to your phone's storage:

cp token.pickle /sdcard

Done! 🎉

You’ll find token.pickle in your phone’s internal storage.

Credit

SilentDemonSD

About

Effortlessly generate Google Drive API tokens on Android with Termux! This repository provides a streamlined Python script to authenticate and securely save credentials (token.pickle) for seamless Google Drive integration.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages