@muggleai/mcp 1.0.21 → 1.0.23

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.
Files changed (2) hide show
  1. package/README.md +88 -0
  2. package/package.json +2 -2
package/README.md CHANGED
@@ -67,6 +67,16 @@ Authentication happens automatically when you first use a tool that requires it:
67
67
 
68
68
  Your credentials are stored in `~/.muggle-ai/credentials.json` and persist across sessions.
69
69
 
70
+ ### Handling Expired Tokens
71
+
72
+ Tokens expire after a period of time. When this happens:
73
+
74
+ 1. **Check status**: Run `muggle-mcp status` or call `muggle-remote-auth-status` to see expiration
75
+ 2. **Re-authenticate**: Run `muggle-mcp login` or call `muggle-remote-auth-login` to get fresh tokens
76
+ 3. **If login fails with "unauthorized_client"**: Check your runtime target configuration (see Troubleshooting)
77
+
78
+ The MCP server will attempt to auto-refresh tokens when possible, but manual re-authentication may be required if the refresh token has also expired.
79
+
70
80
  ## Available Tools
71
81
 
72
82
  ### Cloud QA Tools (muggle-remote-*)
@@ -155,6 +165,84 @@ npm run lint:check # Check only
155
165
  2. Run the `release-electron-app.yml` workflow manually
156
166
  3. Or create a tag: `git tag electron-app@1.0.1 && git push --tags`
157
167
 
168
+ ## Troubleshooting
169
+
170
+ ### Expired Token Errors
171
+
172
+ If you see authentication errors like "Not authenticated" or token expiration messages:
173
+
174
+ 1. **Check auth status**:
175
+ ```bash
176
+ muggle-mcp status
177
+ ```
178
+
179
+ 2. **Re-authenticate**:
180
+ ```bash
181
+ muggle-mcp login
182
+ ```
183
+
184
+ 3. **Clear and retry** (if login keeps failing):
185
+ ```bash
186
+ muggle-mcp logout
187
+ muggle-mcp login
188
+ ```
189
+
190
+ ### "unauthorized_client" Error During Login
191
+
192
+ This error indicates a mismatch between your Auth0 client configuration and the target environment.
193
+
194
+ **Cause**: The MCP is configured for one environment (dev/production) but trying to authenticate against another.
195
+
196
+ **Fix**: Ensure your MCP configuration matches your intended environment by setting the `MUGGLE_MCP_PROMPT_SERVICE_TARGET` environment variable in your MCP config:
197
+
198
+ **For Production** (`~/.cursor/mcp.json`):
199
+ ```json
200
+ {
201
+ "mcpServers": {
202
+ "muggle": {
203
+ "command": "muggle-mcp",
204
+ "args": ["serve"],
205
+ "env": {
206
+ "MUGGLE_MCP_PROMPT_SERVICE_TARGET": "production"
207
+ }
208
+ }
209
+ }
210
+ }
211
+ ```
212
+
213
+ **For Development** (local services):
214
+ ```json
215
+ {
216
+ "mcpServers": {
217
+ "muggle": {
218
+ "command": "muggle-mcp",
219
+ "args": ["serve"],
220
+ "env": {
221
+ "MUGGLE_MCP_PROMPT_SERVICE_TARGET": "dev"
222
+ }
223
+ }
224
+ }
225
+ }
226
+ ```
227
+
228
+ After changing the configuration, restart your MCP client (e.g., restart Cursor).
229
+
230
+ ### Credential Files
231
+
232
+ Credentials are stored in `~/.muggle-ai/`:
233
+
234
+ | File | Purpose |
235
+ | :--- | :------ |
236
+ | `auth.json` | OAuth tokens (access token, refresh token, expiry) |
237
+ | `credentials.json` | API key for service calls |
238
+
239
+ If you need to reset authentication completely:
240
+ ```bash
241
+ rm ~/.muggle-ai/auth.json
242
+ rm ~/.muggle-ai/credentials.json
243
+ muggle-mcp login
244
+ ```
245
+
158
246
  ## License
159
247
 
160
248
  MIT
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@muggleai/mcp",
3
- "version": "1.0.21",
3
+ "version": "1.0.23",
4
4
  "description": "Unified MCP server for Muggle AI - Cloud QA and Local Testing tools",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
@@ -26,7 +26,7 @@
26
26
  "test:watch": "vitest"
27
27
  },
28
28
  "muggleConfig": {
29
- "electronAppVersion": "1.0.8",
29
+ "electronAppVersion": "1.0.11",
30
30
  "downloadBaseUrl": "https://github.com/multiplex-ai/muggle-ai-mcp/releases/download",
31
31
  "runtimeTargetDefault": "production",
32
32
  "checksums": {