@cli4ai/gmail 1.0.6 → 1.0.7
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/cli4ai.json +11 -1
- package/lib/api.ts +1 -1
- package/package.json +1 -1
package/cli4ai.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "gmail",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.7",
|
|
4
4
|
"description": "Gmail CLI tool for messages, threads, and drafts",
|
|
5
5
|
"author": "cliforai",
|
|
6
6
|
"license": "MIT",
|
|
@@ -39,6 +39,16 @@
|
|
|
39
39
|
"google-auth-library": "^9.0.0",
|
|
40
40
|
"commander": "^14.0.0"
|
|
41
41
|
},
|
|
42
|
+
"env": {
|
|
43
|
+
"GMAIL_CREDENTIALS_PATH": {
|
|
44
|
+
"required": true,
|
|
45
|
+
"description": "Path to Google OAuth credentials.json file (download from Google Cloud Console)"
|
|
46
|
+
},
|
|
47
|
+
"GMAIL_TOKEN_PATH": {
|
|
48
|
+
"required": false,
|
|
49
|
+
"description": "Path to store OAuth token (defaults to package directory)"
|
|
50
|
+
}
|
|
51
|
+
},
|
|
42
52
|
"mcp": {
|
|
43
53
|
"enabled": true,
|
|
44
54
|
"transport": "stdio"
|
package/lib/api.ts
CHANGED
|
@@ -114,7 +114,7 @@ export async function authorize(): Promise<OAuth2Client> {
|
|
|
114
114
|
if (authClient) return authClient;
|
|
115
115
|
|
|
116
116
|
if (!fs.existsSync(CREDENTIALS_PATH)) {
|
|
117
|
-
throw new Error(`Credentials not found at ${CREDENTIALS_PATH}.
|
|
117
|
+
throw new Error(`Credentials not found at ${CREDENTIALS_PATH}. Run: cli4ai secrets init gmail`);
|
|
118
118
|
}
|
|
119
119
|
|
|
120
120
|
const content = fs.readFileSync(CREDENTIALS_PATH, 'utf-8');
|