leap-cn-mcp 0.1.2 → 0.1.3

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 CHANGED
@@ -145,14 +145,15 @@ bin/leap-cn-mcp.js
145
145
  "command": "npx",
146
146
  "args": ["--yes", "--package", "leap-cn-mcp", "leap-cn-mcp"],
147
147
  "env": {
148
- "LEAP_SESSION_FILE": "/absolute/path/to/.leap-session.json"
148
+ "LEAP_SESSION_FILE": "/absolute/path/to/.leap-session.json",
149
+ "LEAP_OPERATION_PASSWORD": "<操作密码>"
149
150
  }
150
151
  }
151
152
  }
152
153
  }
153
154
  ```
154
155
 
155
- `LEAP_SESSION_FILE` 请改成你自己的本地 session 文件路径。
156
+ `LEAP_SESSION_FILE` 请改成你自己的本地 session 文件路径。`LEAP_OPERATION_PASSWORD` 可选;tool 参数里的 `operationPassword` 优先级更高。
156
157
 
157
158
  MCP tools:
158
159
 
@@ -9,6 +9,7 @@ const client = createClientFromEnv({
9
9
  sessionFile: process.env.LEAP_SESSION_FILE || new URL('../.leap-session.json', import.meta.url).pathname,
10
10
  allowWrite: process.env.LEAP_ALLOW_WRITE === '1'
11
11
  });
12
+ const defaultOperationPassword = process.env.LEAP_OPERATION_PASSWORD || '';
12
13
 
13
14
  const tools = [
14
15
  tool('leap_session', 'Read current Leapmotor session summary.', {}),
@@ -157,7 +158,7 @@ function controlArgs(args) {
157
158
  value: args.value,
158
159
  cmdid: args.cmdid,
159
160
  stateJson: args.stateJson,
160
- operationPassword: args.operationPassword || ''
161
+ operationPassword: args.operationPassword || defaultOperationPassword
161
162
  };
162
163
  }
163
164
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "leap-cn-mcp",
3
- "version": "0.1.2",
3
+ "version": "0.1.3",
4
4
  "description": "MCP stdio server for Leapmotor China app APIs.",
5
5
  "type": "module",
6
6
  "bin": {