You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: .claude-plugin/plugin.json
+3Lines changed: 3 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -2,5 +2,8 @@
2
2
"name": "google-workspace-mcp",
3
3
"description": "Complete Google Workspace integration — connects Gmail, Drive, Calendar, Docs, Sheets, Slides, Forms, Tasks, Contacts, Chat, and Apps Script via MCP with workflow guidance.",
On Windows cmd.exe, use double quotes and escape inner quotes: `--args "{\"user_google_email\": \"USER_EMAIL\"}"`. PowerShell and Git Bash support single quotes as shown above.
34
+
35
35
Before calling a tool, read the relevant reference file for exact parameter names and types. Only use parameters documented there — do not invent parameters.
36
36
37
37
## First-Time Setup
38
38
39
+
If a tool call fails with a credential error, walk the user through this setup.
Direct the user to[Google Cloud Console](https://console.cloud.google.com/apis/credentials):
41
43
- Create OAuth 2.0 Client ID (Desktop application type)
42
-
- Enable the Google APIs you need (Gmail, Drive, Calendar, etc.)
44
+
- Enable the Google APIs they need (Gmail, Drive, Calendar, etc.)
45
+
- Copy the Client ID and Client Secret
43
46
44
-
### 2. Configure credentials
45
-
Credentials load in this priority order:
46
-
1. Environment variables
47
-
2.`.env` file in project root — **will not work with `uvx`** (uvx spawns a standalone process outside your repo). Either export env vars or point to the file directly.
48
-
3.`client_secret.json` via `GOOGLE_CLIENT_SECRET_PATH`
49
-
4. Default `client_secret.json` in project root
47
+
### 2. Store credentials
48
+
Ask the user for their Client ID and Client Secret, then write them to `~/.claude/settings.local.json` in the `env` block (this file is gitignored and never shared):
50
49
51
-
### 3. MCP config (recommended)
52
-
Pass credentials in the MCP `env` block:
53
50
```json
54
51
{
55
-
"command": "uvx",
56
-
"args": ["workspace-mcp"],
57
52
"env": {
58
-
"GOOGLE_OAUTH_CLIENT_ID": "your-client-id",
59
-
"GOOGLE_OAUTH_CLIENT_SECRET": "your-secret",
60
-
"OAUTHLIB_INSECURE_TRANSPORT": "1"
53
+
"GOOGLE_OAUTH_CLIENT_ID": "their-client-id",
54
+
"GOOGLE_OAUTH_CLIENT_SECRET": "their-secret",
55
+
"PYTHONIOENCODING": "utf-8"
61
56
}
62
57
}
63
58
```
64
-
`OAUTHLIB_INSECURE_TRANSPORT=1` is required for local (non-HTTPS) development.
65
59
66
-
### 4. Authenticate
60
+
`PYTHONIOENCODING=utf-8` prevents encoding errors on Windows when tool output contains non-ASCII characters.
61
+
62
+
Read the existing `~/.claude/settings.local.json` first — merge into the existing `env` object, do not overwrite other settings. These env vars are inherited by all MCP servers and CLI processes that Claude Code spawns.
63
+
64
+
### 3. Authenticate
67
65
-**MCP mode**: call `start_google_auth` to open the browser OAuth flow
68
66
-**CLI mode**: run any tool — the first invocation opens the OAuth flow
69
67
- Credentials are cached in `store_creds/` for future sessions
70
68
69
+
### Credential loading priority (for reference)
70
+
1. Environment variables (including those from `~/.claude/settings.json``env` block)
71
+
2.`.env` file in project root — **will not work with `uvx`** (uvx runs outside the repo directory)
72
+
3.`client_secret.json` via `GOOGLE_CLIENT_SECRET_PATH` env var
73
+
4. Default `client_secret.json` in project root
74
+
71
75
## Server Options
72
76
73
77
These mirror the MCP server's own flags. See the [README](https://github.com/taylorwilsdon/google_workspace_mcp) for full details.
@@ -114,7 +118,7 @@ Other services: `readonly`, `full`.
114
118
115
119
## Universal Patterns
116
120
117
-
-Every tool requires `user_google_email`.
121
+
-Almost every tool requires `user_google_email` (exception: `generate_trigger_code`).
118
122
- Paginated tools support `page_size` and `page_token`. Check for `next_page_token` when completeness matters.
119
123
- Consolidated "manage" tools use an `action` parameter for create/update/delete.
120
124
- Prefer batch tools when working with multiple items.
@@ -157,6 +161,7 @@ For parameters: [references/gmail.md](references/gmail.md)
Copy file name to clipboardExpand all lines: skills/google-workspace/references/apps-script.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
# Apps Script Tools Reference
2
2
3
-
MCP tools for Google Apps Script via the Google Workspace MCP server. All tools require `user_google_email` (string, required).
3
+
MCP tools for Google Apps Script via the Google Workspace MCP server. All tools require `user_google_email` (string, required) except `generate_trigger_code`.
Copy file name to clipboardExpand all lines: skills/google-workspace/references/drive.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -14,7 +14,7 @@ Search for files and folders across My Drive and shared drives.
14
14
|-----------|------|----------|---------|-------|
15
15
| query | string | yes || Google Drive search query (see operators below) |
16
16
| page_size | integer | no | 10 | Max results to return |
17
-
| page_token |string| no || Token from previous response for pagination |
17
+
| page_token |any| no || Token from previous response for pagination |
18
18
| drive_id | string | no || Shared drive ID to scope search |
19
19
| include_items_from_all_drives | boolean | no | true | Include shared drive items when no drive_id set |
20
20
| corpora | string | no ||`user`, `domain`, `drive`, or `allDrives`. Defaults to `drive` when drive_id is set. Prefer `user` or `drive` over `allDrives`|
@@ -29,7 +29,7 @@ List files and folders in a specific folder.
29
29
|-----------|------|----------|---------|-------|
30
30
| folder_id | string | no | root | Folder ID. Use shared drive ID for its root |
31
31
| page_size | integer | no | 100 | Max items to return |
32
-
| page_token |string| no || Pagination token |
32
+
| page_token |any| no || Pagination token |
33
33
| drive_id | string | no || Shared drive ID to scope listing |
34
34
| include_items_from_all_drives | boolean | no | true | Include shared drive items when no drive_id set |
35
35
| corpora | string | no ||`user`, `drive`, `allDrives`|
0 commit comments