@crush-protocol/mcp-client 0.1.13 → 0.1.14

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 +25 -21
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -30,9 +30,20 @@ The AI agent calls the Crush Protocol MCP tools directly — no tab-switching, n
30
30
 
31
31
  ---
32
32
 
33
- ## Getting a Token
33
+ ## Authentication
34
34
 
35
- Tokens are issued from the Crush Protocol web app. After logging in, navigate to **Settings API Tokens** to create an `mcp_xxx` token.
35
+ Crush Protocol uses **Device Code Flow** a secure, browser-based login that works the same way GitHub CLI and Docker CLI authenticate.
36
+
37
+ ### How it works
38
+
39
+ 1. Run the login command in your terminal
40
+ 2. A browser window opens automatically
41
+ 3. Complete wallet authentication in the browser (Privy + wallet signature)
42
+ 4. The terminal receives the authorization and saves it locally
43
+
44
+ No manual token copy-pasting required.
45
+
46
+ > 🔐 Your credentials are stored locally and never shared with third parties.
36
47
 
37
48
  ---
38
49
 
@@ -40,20 +51,15 @@ Tokens are issued from the Crush Protocol web app. After logging in, navigate to
40
51
 
41
52
  ### Claude Code
42
53
 
43
- ```sh
44
- claude mcp add --scope user crush-protocol -- npx -y @crush-protocol/mcp-client
45
- ```
46
-
47
- Then set your credentials:
48
-
49
54
  ```sh
50
55
  claude mcp add --scope user crush-protocol \
51
56
  -- npx -y @crush-protocol/mcp-client \
52
- --url https://mcp.crush-protocol.com/mcp \
53
- --token mcp_xxx
57
+ --url https://mcp.crush-protocol.com/mcp
54
58
  ```
55
59
 
56
- Or via environment variables in `~/.claude.json`:
60
+ ### Cursor
61
+
62
+ Add to `~/.cursor/mcp.json`:
57
63
 
58
64
  ```json
59
65
  {
@@ -62,17 +68,16 @@ Or via environment variables in `~/.claude.json`:
62
68
  "command": "npx",
63
69
  "args": ["-y", "@crush-protocol/mcp-client"],
64
70
  "env": {
65
- "CRUSH_MCP_SERVER_URL": "https://mcp.crush-protocol.com/mcp",
66
- "CRUSH_MCP_TOKEN": "mcp_xxx"
71
+ "CRUSH_MCP_SERVER_URL": "https://mcp.crush-protocol.com/mcp"
67
72
  }
68
73
  }
69
74
  }
70
75
  }
71
76
  ```
72
77
 
73
- ### Cursor
78
+ ### Windsurf
74
79
 
75
- Add to `~/.cursor/mcp.json`:
80
+ Add to your MCP configuration:
76
81
 
77
82
  ```json
78
83
  {
@@ -81,14 +86,15 @@ Add to `~/.cursor/mcp.json`:
81
86
  "command": "npx",
82
87
  "args": ["-y", "@crush-protocol/mcp-client"],
83
88
  "env": {
84
- "CRUSH_MCP_SERVER_URL": "https://mcp.crush-protocol.com/mcp",
85
- "CRUSH_MCP_TOKEN": "mcp_xxx"
89
+ "CRUSH_MCP_SERVER_URL": "https://mcp.crush-protocol.com/mcp"
86
90
  }
87
91
  }
88
92
  }
89
93
  }
90
94
  ```
91
95
 
96
+ > On first use, the client will prompt you to log in via your browser.
97
+
92
98
  ---
93
99
 
94
100
  ## Available Tools
@@ -109,10 +115,9 @@ Add to `~/.cursor/mcp.json`:
109
115
 
110
116
  ## Environment Variables
111
117
 
112
- | Variable | Description |
113
- | ---------------------- | -------------------------------------------------------------- |
118
+ | Variable | Description |
119
+ | ---------------------- | --------------------------------------------------------------- |
114
120
  | `CRUSH_MCP_SERVER_URL` | MCP server URL (default: `https://mcp.crush-protocol.com/mcp`) |
115
- | `CRUSH_MCP_TOKEN` | MCP auth token (`mcp_xxx`) |
116
121
 
117
122
  ---
118
123
 
@@ -125,7 +130,6 @@ import { RemoteMcpClient, BacktestClient } from '@crush-protocol/mcp-client'
125
130
 
126
131
  const mcp = new RemoteMcpClient({
127
132
  serverUrl: 'https://mcp.crush-protocol.com/mcp',
128
- token: 'mcp_xxx',
129
133
  })
130
134
  await mcp.connect()
131
135
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@crush-protocol/mcp-client",
3
- "version": "0.1.13",
3
+ "version": "0.1.14",
4
4
  "description": "Crush MCP npm client package (remote Streamable HTTP + optional ClickHouse direct)",
5
5
  "type": "module",
6
6
  "license": "MIT",