@anthropic-ai/claude-agent-sdk 0.1.8 → 0.1.10
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/cli.js +1060 -1040
- package/package.json +4 -1
- package/sdk.mjs +2 -10
- package/sdkTypes.d.ts +1 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@anthropic-ai/claude-agent-sdk",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.10",
|
|
4
4
|
"main": "sdk.mjs",
|
|
5
5
|
"types": "sdk.d.ts",
|
|
6
6
|
"engines": {
|
|
@@ -27,6 +27,9 @@
|
|
|
27
27
|
"prepare": "node -e \"if (!process.env.AUTHORIZED) { console.error('ERROR: Direct publishing is not allowed.\\nPlease use the publish-agent-sdk.sh script to publish this package.'); process.exit(1); }\""
|
|
28
28
|
},
|
|
29
29
|
"dependencies": {},
|
|
30
|
+
"peerDependencies": {
|
|
31
|
+
"zod": "^3.24.1"
|
|
32
|
+
},
|
|
30
33
|
"optionalDependencies": {
|
|
31
34
|
"@img/sharp-darwin-arm64": "^0.33.5",
|
|
32
35
|
"@img/sharp-darwin-x64": "^0.33.5",
|
package/sdk.mjs
CHANGED
|
@@ -1,12 +1,10 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
|
|
3
2
|
// (c) Anthropic PBC. All rights reserved. Use is subject to Anthropic's Commercial Terms of Service (https://www.anthropic.com/legal/commercial-terms).
|
|
4
3
|
|
|
5
|
-
// Version: 0.1.
|
|
4
|
+
// Version: 0.1.10
|
|
6
5
|
|
|
7
6
|
// Want to see the unminified source? We're hiring!
|
|
8
7
|
// https://job-boards.greenhouse.io/anthropic/jobs/4816199008
|
|
9
|
-
|
|
10
8
|
var __create = Object.create;
|
|
11
9
|
var __getProtoOf = Object.getPrototypeOf;
|
|
12
10
|
var __defProp = Object.defineProperty;
|
|
@@ -6222,15 +6220,9 @@ import { createInterface } from "readline";
|
|
|
6222
6220
|
import * as fs from "fs";
|
|
6223
6221
|
import { stat as statPromise, open } from "fs/promises";
|
|
6224
6222
|
var NodeFsOperations = {
|
|
6225
|
-
accessSync(fsPath, mode) {
|
|
6226
|
-
fs.accessSync(fsPath, mode);
|
|
6227
|
-
},
|
|
6228
6223
|
cwd() {
|
|
6229
6224
|
return process.cwd();
|
|
6230
6225
|
},
|
|
6231
|
-
chmodSync(fsPath, mode) {
|
|
6232
|
-
fs.chmodSync(fsPath, mode);
|
|
6233
|
-
},
|
|
6234
6226
|
existsSync(fsPath) {
|
|
6235
6227
|
return fs.existsSync(fsPath);
|
|
6236
6228
|
},
|
|
@@ -14160,7 +14152,7 @@ function query({
|
|
|
14160
14152
|
const dirname = join(filename, "..");
|
|
14161
14153
|
pathToClaudeCodeExecutable = join(dirname, "cli.js");
|
|
14162
14154
|
}
|
|
14163
|
-
process.env.CLAUDE_AGENT_SDK_VERSION = "0.1.
|
|
14155
|
+
process.env.CLAUDE_AGENT_SDK_VERSION = "0.1.10";
|
|
14164
14156
|
return createSharedQuery({
|
|
14165
14157
|
prompt,
|
|
14166
14158
|
options: {
|
package/sdkTypes.d.ts
CHANGED
|
@@ -204,6 +204,7 @@ export type SyncHookJSONOutput = {
|
|
|
204
204
|
hookEventName: 'PreToolUse';
|
|
205
205
|
permissionDecision?: 'allow' | 'deny' | 'ask';
|
|
206
206
|
permissionDecisionReason?: string;
|
|
207
|
+
updatedInput?: Record<string, unknown>;
|
|
207
208
|
} | {
|
|
208
209
|
hookEventName: 'UserPromptSubmit';
|
|
209
210
|
additionalContext?: string;
|