@piotr-agier/google-drive-mcp 2.0.2 → 2.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +16 -2
- package/dist/index.js +460 -102
- package/dist/index.js.map +4 -4
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -292,6 +292,16 @@ Notes:
|
|
|
292
292
|
`drive`, `drive.file`, `drive.readonly`, `documents`, `spreadsheets`, `presentations`, `calendar`, `calendar.events`.
|
|
293
293
|
- Changing scopes usually requires re-authentication.
|
|
294
294
|
|
|
295
|
+
### Auth Server Port Configuration
|
|
296
|
+
|
|
297
|
+
During OAuth authentication, a local HTTP server is started to receive the callback. By default it tries ports 3000–3004. If those conflict with other services (e.g., a dev server), you can change the starting port:
|
|
298
|
+
|
|
299
|
+
```bash
|
|
300
|
+
export GOOGLE_DRIVE_MCP_AUTH_PORT=3100
|
|
301
|
+
```
|
|
302
|
+
|
|
303
|
+
The server will try 5 consecutive ports starting from the configured value (e.g., 3100–3104).
|
|
304
|
+
|
|
295
305
|
### Token Storage
|
|
296
306
|
|
|
297
307
|
Authentication tokens are stored securely following the XDG Base Directory specification:
|
|
@@ -1104,7 +1114,7 @@ OAuth credentials not found. Please provide credentials using one of these metho
|
|
|
1104
1114
|
#### "Authentication failed" or Browser doesn't open
|
|
1105
1115
|
**Possible causes:**
|
|
1106
1116
|
1. **Wrong credential type**: Must be "Desktop app", not "Web application"
|
|
1107
|
-
2. **Port blocked**: Ports 3000-3004 must be available
|
|
1117
|
+
2. **Port blocked**: Ports 3000-3004 must be available (or custom range if `GOOGLE_DRIVE_MCP_AUTH_PORT` is set)
|
|
1108
1118
|
3. **Test user not added**: Add your email in OAuth consent screen
|
|
1109
1119
|
|
|
1110
1120
|
**Solution:**
|
|
@@ -1112,9 +1122,12 @@ OAuth credentials not found. Please provide credentials using one of these metho
|
|
|
1112
1122
|
# Check if ports are in use
|
|
1113
1123
|
lsof -i :3000-3004
|
|
1114
1124
|
|
|
1115
|
-
# Kill processes if needed
|
|
1125
|
+
# Option 1: Kill processes if needed
|
|
1116
1126
|
kill -9 <PID>
|
|
1117
1127
|
|
|
1128
|
+
# Option 2: Use a different port range
|
|
1129
|
+
export GOOGLE_DRIVE_MCP_AUTH_PORT=3100
|
|
1130
|
+
|
|
1118
1131
|
# Re-run authentication
|
|
1119
1132
|
npx @piotr-agier/google-drive-mcp auth
|
|
1120
1133
|
```
|
|
@@ -1309,6 +1322,7 @@ npm run typecheck # Type checking without compilation
|
|
|
1309
1322
|
| Variable | Description | Default | Example |
|
|
1310
1323
|
|----------|-------------|---------|---------|
|
|
1311
1324
|
| `GOOGLE_DRIVE_MCP_TOKEN_PATH` | Override token storage location | `~/.config/google-drive-mcp/tokens.json` | `/custom/path/tokens.json` |
|
|
1325
|
+
| `GOOGLE_DRIVE_MCP_AUTH_PORT` | Starting port for OAuth callback server (uses 5 consecutive ports) | `3000` | `3100` |
|
|
1312
1326
|
| `DEBUG` | Enable debug logging | (disabled) | `google-drive-mcp:*` |
|
|
1313
1327
|
|
|
1314
1328
|
**External Authentication** (alternative to local OAuth flow):
|