@fleetx_io/fleetx-mcp-server 1.0.0 → 1.0.1
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 +50 -77
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -14,16 +14,17 @@ An MCP (Model Context Protocol) server that gives AI agents access to the FleetX
|
|
|
14
14
|
|
|
15
15
|
## Quick Start
|
|
16
16
|
|
|
17
|
-
###
|
|
17
|
+
### Option A: Use directly with npx (no install)
|
|
18
18
|
|
|
19
19
|
```bash
|
|
20
|
-
|
|
20
|
+
npx -y @fleetx_io/fleetx-mcp-server
|
|
21
21
|
```
|
|
22
22
|
|
|
23
|
-
|
|
23
|
+
### Option B: Install globally
|
|
24
24
|
|
|
25
25
|
```bash
|
|
26
|
-
|
|
26
|
+
npm install -g @fleetx_io/fleetx-mcp-server
|
|
27
|
+
fleetx-mcp-server
|
|
27
28
|
```
|
|
28
29
|
|
|
29
30
|
---
|
|
@@ -34,6 +35,8 @@ npx @fleetx_io/fleetx-mcp-server
|
|
|
34
35
|
|
|
35
36
|
Add to `.cursor/mcp.json` in your project root:
|
|
36
37
|
|
|
38
|
+
**Using npx:**
|
|
39
|
+
|
|
37
40
|
```json
|
|
38
41
|
{
|
|
39
42
|
"mcpServers": {
|
|
@@ -45,6 +48,18 @@ Add to `.cursor/mcp.json` in your project root:
|
|
|
45
48
|
}
|
|
46
49
|
```
|
|
47
50
|
|
|
51
|
+
**Using global install:**
|
|
52
|
+
|
|
53
|
+
```json
|
|
54
|
+
{
|
|
55
|
+
"mcpServers": {
|
|
56
|
+
"fleetx": {
|
|
57
|
+
"command": "fleetx-mcp-server"
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
```
|
|
62
|
+
|
|
48
63
|
Then restart Cursor. The server will appear in **Settings > MCP**.
|
|
49
64
|
|
|
50
65
|
### Claude Desktop
|
|
@@ -54,6 +69,8 @@ Add to your `claude_desktop_config.json`:
|
|
|
54
69
|
**macOS:** `~/Library/Application Support/Claude/claude_desktop_config.json`
|
|
55
70
|
**Windows:** `%APPDATA%\Claude\claude_desktop_config.json`
|
|
56
71
|
|
|
72
|
+
**Using npx:**
|
|
73
|
+
|
|
57
74
|
```json
|
|
58
75
|
{
|
|
59
76
|
"mcpServers": {
|
|
@@ -65,10 +82,24 @@ Add to your `claude_desktop_config.json`:
|
|
|
65
82
|
}
|
|
66
83
|
```
|
|
67
84
|
|
|
85
|
+
**Using global install:**
|
|
86
|
+
|
|
87
|
+
```json
|
|
88
|
+
{
|
|
89
|
+
"mcpServers": {
|
|
90
|
+
"fleetx": {
|
|
91
|
+
"command": "fleetx-mcp-server"
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
```
|
|
96
|
+
|
|
68
97
|
### Windsurf
|
|
69
98
|
|
|
70
99
|
Add to your Windsurf MCP config:
|
|
71
100
|
|
|
101
|
+
**Using npx:**
|
|
102
|
+
|
|
72
103
|
```json
|
|
73
104
|
{
|
|
74
105
|
"mcpServers": {
|
|
@@ -80,22 +111,18 @@ Add to your Windsurf MCP config:
|
|
|
80
111
|
}
|
|
81
112
|
```
|
|
82
113
|
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
Run the server as a subprocess communicating over **stdio**:
|
|
86
|
-
|
|
87
|
-
```bash
|
|
88
|
-
npx @fleetx_io/fleetx-mcp-server
|
|
89
|
-
```
|
|
90
|
-
|
|
91
|
-
Or if installed globally:
|
|
114
|
+
**Using global install:**
|
|
92
115
|
|
|
93
|
-
```
|
|
94
|
-
|
|
116
|
+
```json
|
|
117
|
+
{
|
|
118
|
+
"mcpServers": {
|
|
119
|
+
"fleetx": {
|
|
120
|
+
"command": "fleetx-mcp-server"
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
}
|
|
95
124
|
```
|
|
96
125
|
|
|
97
|
-
The server speaks JSON-RPC over stdin/stdout. Logs go to stderr.
|
|
98
|
-
|
|
99
126
|
---
|
|
100
127
|
|
|
101
128
|
## Usage
|
|
@@ -126,32 +153,6 @@ The full list depends on your account's enabled APIs.
|
|
|
126
153
|
|
|
127
154
|
---
|
|
128
155
|
|
|
129
|
-
## Configuration (Optional)
|
|
130
|
-
|
|
131
|
-
By default, the server connects to the FleetX production API. Override with environment variables if needed:
|
|
132
|
-
|
|
133
|
-
```json
|
|
134
|
-
{
|
|
135
|
-
"mcpServers": {
|
|
136
|
-
"fleetx": {
|
|
137
|
-
"command": "npx",
|
|
138
|
-
"args": ["-y", "@fleetx_io/fleetx-mcp-server"],
|
|
139
|
-
"env": {
|
|
140
|
-
"LOGIN_URL": "https://api.fleetx.io/api/v1/login",
|
|
141
|
-
"API_DEFINITION_URL": "https://app.fleetx.io/napp/api-reference/apis"
|
|
142
|
-
}
|
|
143
|
-
}
|
|
144
|
-
}
|
|
145
|
-
}
|
|
146
|
-
```
|
|
147
|
-
|
|
148
|
-
| Variable | Default | Description |
|
|
149
|
-
|----------|---------|-------------|
|
|
150
|
-
| `LOGIN_URL` | `https://api.fleetx.io/api/v1/login` | Authentication endpoint |
|
|
151
|
-
| `API_DEFINITION_URL` | `https://app.fleetx.io/napp/api-reference/apis` | API definitions endpoint |
|
|
152
|
-
|
|
153
|
-
---
|
|
154
|
-
|
|
155
156
|
## Security
|
|
156
157
|
|
|
157
158
|
- Credentials are sent only to the FleetX login endpoint — never logged or stored on disk.
|
|
@@ -162,53 +163,25 @@ By default, the server connects to the FleetX production API. Override with envi
|
|
|
162
163
|
|
|
163
164
|
## Testing with MCP Inspector
|
|
164
165
|
|
|
165
|
-
|
|
166
|
+
**With npx (no install):**
|
|
166
167
|
|
|
167
168
|
```bash
|
|
168
|
-
npx @modelcontextprotocol/inspector npx @fleetx_io/fleetx-mcp-server
|
|
169
|
+
npx -y @modelcontextprotocol/inspector npx -y @fleetx_io/fleetx-mcp-server
|
|
169
170
|
```
|
|
170
171
|
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
---
|
|
174
|
-
|
|
175
|
-
## Development
|
|
172
|
+
**After installing the package globally:**
|
|
176
173
|
|
|
177
174
|
```bash
|
|
178
|
-
|
|
179
|
-
cd fleetx-mcp-server
|
|
180
|
-
npm install
|
|
175
|
+
npx -y @modelcontextprotocol/inspector fleetx-mcp-server
|
|
181
176
|
```
|
|
182
177
|
|
|
183
|
-
|
|
184
|
-
|---------|-------------|
|
|
185
|
-
| `npm run dev` | Start with hot-reload (ts-node-dev) |
|
|
186
|
-
| `npm run build` | Compile TypeScript to `dist/` |
|
|
187
|
-
| `npm start` | Run compiled output |
|
|
188
|
-
| `npm run startClient` | Launch with MCP Inspector (built) |
|
|
189
|
-
| `npm run startClientLive` | Launch with MCP Inspector (live reload) |
|
|
190
|
-
|
|
191
|
-
### Project Structure
|
|
192
|
-
|
|
193
|
-
```
|
|
194
|
-
src/
|
|
195
|
-
index.ts Stdio transport entrypoint
|
|
196
|
-
mcpServer.ts MCP server + login tool + dynamic tool registration
|
|
197
|
-
auth.ts Login flow + in-memory token store
|
|
198
|
-
apiDiscovery.ts Fetch API definitions from protected endpoint
|
|
199
|
-
toolGenerator.ts Convert API definitions into MCP tools
|
|
200
|
-
proxyCaller.ts Proxy calls to external APIs via Axios
|
|
201
|
-
schemaBuilder.ts Zod schema + JSON Schema generation from API metadata
|
|
202
|
-
utils.ts Logging + config helpers
|
|
203
|
-
types.ts Shared TypeScript interfaces
|
|
204
|
-
```
|
|
178
|
+
This opens a web UI where you can connect, call `login`, browse all discovered tools, and test them interactively.
|
|
205
179
|
|
|
206
180
|
---
|
|
207
181
|
|
|
208
182
|
## Requirements
|
|
209
183
|
|
|
210
|
-
- Node.js >=
|
|
211
|
-
- npm or npx
|
|
184
|
+
- Node.js >= 20
|
|
212
185
|
|
|
213
186
|
## License
|
|
214
187
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fleetx_io/fleetx-mcp-server",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.1",
|
|
4
4
|
"description": "MCP server that gives AI agents access to the FleetX REST API. Works with Cursor, Claude Desktop, Windsurf, and any MCP-compatible client.",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|