Extract The Unique Image ID from Google Drive URL

September 9, 2020 ยท View on GitHub

Extract The Unique Image ID from Google Drive URL

Usage

python3 extract.py <drive_image_url>

Demo

The ID as a string, Example :

python3 extract.py https://drive.google.com/file/d/0BwZFRt1DatLLZUt4eF94dFh1ZXJubUthenY3MVZERU5yeV9z/view\?usp\=sharing

Output : 0BwZFRt1DatLLZUt4eF94dFh1ZXJubUthenY3MVZERU5yeV9z