mirror of
https://github.com/mudabbir-ahmad/Media-Aggregation-and-Sorting-System.git
synced 2026-10-07 19:40:20 +00:00
feat: migrate to Google Photos Picker API and update related documentation due to normal library api being depricated (kept for added media from app)
This commit is contained in:
1 parent
f6c61ab829
commit
5c096fbab4
5 files changed
+363
-201
No files matched your search
@@ -5,10 +5,11 @@
|
||||
2. Click **Select a project** → **New Project**
|
||||
3. Name it and click **Create**
|
||||
|
||||
## Step 2: Enable the Photos Library API
|
||||
## Step 2: Enable the Photos Picker API
|
||||
1. Go to **APIs & Services** → **Library**
|
||||
2. Search for **Photos Library API** → **Enable** it
|
||||
3. ⚠️ This step is **required** — without it, all Photos API calls return 403
|
||||
2. Search for **Photos Picker API** → **Enable** it
|
||||
3. ⚠️ This step is **required** — without it, all Picker API calls fail
|
||||
4. (The old "Photos Library API" is deprecated and no longer works)
|
||||
|
||||
## Step 3: Configure the OAuth Consent Screen
|
||||
1. Go to **APIs & Services** → **OAuth consent screen**
|
||||
@@ -19,13 +20,12 @@
|
||||
- **Developer contact**: your email
|
||||
4. **Scopes** → Add or Remove Scopes → add these:
|
||||
- `openid`
|
||||
- `https://www.googleapis.com/auth/photoslibrary`
|
||||
- `https://www.googleapis.com/auth/photospicker.mediaitems.readonly`
|
||||
- `https://www.googleapis.com/auth/userinfo.email`
|
||||
- `https://www.googleapis.com/auth/userinfo.profile`
|
||||
5. **Test users** → **Add your Google account email address**
|
||||
- ⚠️ This is **critical** — if your email is not listed as a test user,
|
||||
Google will silently strip the Photos scope from the granted token,
|
||||
causing a 403 "insufficient authentication scopes" error.
|
||||
Google will silently strip the Photos Picker scope from the granted token.
|
||||
|
||||
## Step 4: Create an Android OAuth Client ID
|
||||
1. Go to **APIs & Services** → **Credentials**
|
||||
|
||||
Reference in new issue
Block a user