@leo000001/claude-code-mcp 2.0.0 → 2.0.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/CHANGELOG.md +96 -82
- package/README.md +512 -486
- package/dist/index.js +314 -175
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,82 +1,96 @@
|
|
|
1
|
-
# Changelog
|
|
2
|
-
|
|
3
|
-
## Unreleased
|
|
4
|
-
|
|
5
|
-
### Breaking Changes
|
|
6
|
-
|
|
7
|
-
-
|
|
8
|
-
-
|
|
9
|
-
-
|
|
10
|
-
|
|
11
|
-
- `
|
|
12
|
-
- `
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
- New module: `src/
|
|
19
|
-
- New module: `src/
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
- `claude_code_check`:
|
|
27
|
-
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
- `
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
-
|
|
56
|
-
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
-
|
|
64
|
-
-
|
|
65
|
-
-
|
|
66
|
-
-
|
|
67
|
-
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
-
|
|
73
|
-
-
|
|
74
|
-
-
|
|
75
|
-
-
|
|
76
|
-
-
|
|
77
|
-
-
|
|
78
|
-
-
|
|
79
|
-
-
|
|
80
|
-
-
|
|
81
|
-
|
|
82
|
-
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
## Unreleased
|
|
4
|
+
|
|
5
|
+
### Breaking Changes
|
|
6
|
+
|
|
7
|
+
- `claude_code` and `claude_code_reply` now start asynchronously and return `{ sessionId, status: "running", pollInterval }`. Use `claude_code_check` to poll events and fetch the final `result`.
|
|
8
|
+
- Removed tool: `claude_code_configure`
|
|
9
|
+
- New tool: `claude_code_check` (poll + respond_permission)
|
|
10
|
+
- **Parameter nesting refactor**: low-frequency parameters have been folded into nested objects to reduce top-level clutter. This is a breaking change for callers that pass these parameters at the top level:
|
|
11
|
+
- `claude_code`: 22 low-frequency params moved into `advanced` object (e.g. `effort` → `advanced.effort`, `tools` → `advanced.tools`, `agents` → `advanced.agents`, `env` → `advanced.env`)
|
|
12
|
+
- `claude_code_reply`: 28 disk-resume params moved into `diskResumeConfig` object (e.g. `resumeToken` → `diskResumeConfig.resumeToken`, `cwd` → `diskResumeConfig.cwd`)
|
|
13
|
+
- `claude_code_check`: 9 poll control params moved into `pollOptions` object (e.g. `includeTools` → `pollOptions.includeTools`); 2 permission response params moved into `permissionOptions` object (e.g. `updatedInput` → `permissionOptions.updatedInput`)
|
|
14
|
+
- Schema descriptions for nested object fields have been compacted (self-explanatory fields no longer carry `.describe()` text; object-level descriptions enhanced as summaries) to reduce token overhead for calling models
|
|
15
|
+
|
|
16
|
+
### Features
|
|
17
|
+
|
|
18
|
+
- New module: `src/tools/query-consumer.ts` — shared background query consumer (`consumeQuery`) for start, resume, and disk-resume code paths
|
|
19
|
+
- New module: `src/tools/tool-discovery.ts` — runtime tool discovery with `TOOL_CATALOG`, `ToolDiscoveryCache`, and dynamic `claude_code` description generation
|
|
20
|
+
- New module: `src/utils/build-options.ts` — centralized SDK `Partial<Options>` construction from flat input objects
|
|
21
|
+
- New module: `src/utils/race-with-abort.ts` — race a promise against an AbortSignal with cleanup
|
|
22
|
+
- New module: `src/utils/resume-token.ts` — HMAC-SHA256 resume token generation/validation for secure disk resume
|
|
23
|
+
|
|
24
|
+
### Improvements
|
|
25
|
+
|
|
26
|
+
- `claude_code_check`: default `responseMode="minimal"` to reduce payload size; supports `maxEvents` pagination with `truncated`/`truncatedFields`
|
|
27
|
+
- `claude_code_check`: minimal mode now slims assistant message events (strips `usage`, `model`, `id`, `cache_control` from content blocks)
|
|
28
|
+
- `claude_code_check`: minimal mode filters out noisy progress events (`tool_progress`, `auth_status`); use `includeProgressEvents: true` to restore
|
|
29
|
+
- `claude_code_check`: minimal mode omits `lastEventId`/`lastToolUseId` from top-level response and `durationApiMs`/`sessionTotalTurns`/`sessionTotalCostUsd` from AgentResult
|
|
30
|
+
- `claude_code_check`: includes lightweight session diagnostics (`cancelledAt`/`cancelledReason`/`cancelledSource`, `lastEventId`, `lastToolUseId`)
|
|
31
|
+
- `claude_code_check`: permission actions now include `timeoutMs`, `expiresAt`, and best-effort `remainingMs`
|
|
32
|
+
- Permission result events now include `toolName`, and denial details (`message`, `interrupt`) when applicable
|
|
33
|
+
- Disk resume security: disk resume fallback requires `CLAUDE_CODE_MCP_RESUME_SECRET` + `resumeToken`
|
|
34
|
+
- MCP resources: server info, internal tool catalog, and gotchas
|
|
35
|
+
|
|
36
|
+
## 1.6.0 (2026-02-12)
|
|
37
|
+
|
|
38
|
+
### Bug Fixes
|
|
39
|
+
|
|
40
|
+
- Windows: fixed Git Bash auto-detection path derivation and improved candidate search
|
|
41
|
+
|
|
42
|
+
### Security
|
|
43
|
+
|
|
44
|
+
- `claude_code_session includeSensitive=true` no longer leaks extra fields (e.g. `env`, `debugFile`, `mcpServers`, `sandbox`) beyond the documented sensitive set
|
|
45
|
+
|
|
46
|
+
### Documentation
|
|
47
|
+
|
|
48
|
+
- README: clarify `Task` is required for subagent invocation and how `allowedTools` interacts with `mcpServers`
|
|
49
|
+
- README: clarify `includePartialMessages` is not streamed over MCP responses
|
|
50
|
+
|
|
51
|
+
## 1.4.0 (2026-02-11)
|
|
52
|
+
|
|
53
|
+
### Features
|
|
54
|
+
|
|
55
|
+
- New tool: `claude_code_configure` for runtime bypass mode management (enable/disable without restart)
|
|
56
|
+
- New parameters for `claude_code`: `additionalDirectories`, `outputFormat`, `thinking`, `tools`, `timeout`
|
|
57
|
+
- New parameters for `claude_code` and `claude_code_reply`: `pathToClaudeCodeExecutable`, `agent`, `mcpServers`, `sandbox`, `fallbackModel`, `enableFileCheckpointing`, `includePartialMessages`, `strictMcpConfig`, `settingSources`, `debug`, `debugFile`, `env`
|
|
58
|
+
- Effort level now supports `"max"` in addition to low/medium/high
|
|
59
|
+
- `AgentResult` now includes `structuredOutput`, `stopReason`, `errorSubtype`, `usage`, `modelUsage`, `permissionDenials`
|
|
60
|
+
|
|
61
|
+
### Improvements
|
|
62
|
+
|
|
63
|
+
- README: Added Prerequisites section clarifying Claude Code CLI dependency
|
|
64
|
+
- README/DESIGN.md: Updated parameter tables to include all supported parameters
|
|
65
|
+
- DESIGN.md: Updated to reflect 4-tool architecture and current security model
|
|
66
|
+
- SECURITY.md: Fixed inaccurate references to system CLI and env vars
|
|
67
|
+
- Moved `clearTimeout` into `finally` blocks for safer resource cleanup
|
|
68
|
+
- Added `break` after result processing in `claude_code_reply` for consistency
|
|
69
|
+
|
|
70
|
+
### Bug Fixes
|
|
71
|
+
|
|
72
|
+
- Fixed `claude_code_reply` not passing `cwd`/`permissionMode`/`allowDangerouslySkipPermissions` to SDK
|
|
73
|
+
- Fixed falsy filtering dropping valid values like empty arrays and zero
|
|
74
|
+
- Removed unsafe `as any` type assertions where possible
|
|
75
|
+
- Fixed fork overwriting original session status (now restores pre-fork status)
|
|
76
|
+
- Fixed `cancel()` allowing cancellation of non-running sessions
|
|
77
|
+
- Fixed `destroy()` clearing session map while in-flight operations still reference sessions
|
|
78
|
+
- Improved abort detection using SDK's `AbortError` class
|
|
79
|
+
- Added session overwrite guard in `create()`
|
|
80
|
+
- Added `lastActiveAt` update when aborting stuck sessions in cleanup
|
|
81
|
+
|
|
82
|
+
## 1.0.0 (2026-02-11)
|
|
83
|
+
|
|
84
|
+
### Features
|
|
85
|
+
|
|
86
|
+
- Initial release
|
|
87
|
+
- 3 MCP tools: `claude_code`, `claude_code_reply`, `claude_code_session`
|
|
88
|
+
- Session management with resume and fork support
|
|
89
|
+
- Fine-grained permission control (default, acceptEdits, bypassPermissions, plan, delegate, dontAsk)
|
|
90
|
+
- Custom subagent definitions
|
|
91
|
+
- Effort level control (low, medium, high)
|
|
92
|
+
- Beta features support (e.g., 1M context window)
|
|
93
|
+
- Cost and turn tracking per session
|
|
94
|
+
- Session cancellation via AbortController
|
|
95
|
+
- Auto-cleanup for idle (30min) and stuck running (4h) sessions
|
|
96
|
+
- Security: bypassPermissions disabled by default
|