@agentclientprotocol/claude-agent-acp 0.85.2-preview.15 → 0.85.2-preview.16
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/dist/v2/initialize.d.ts
CHANGED
|
@@ -14,11 +14,8 @@ export declare function v1InitializeRequest(request: v2.InitializeRequest): Init
|
|
|
14
14
|
/**
|
|
15
15
|
* The v2 `initialize` response for the v1 response of the agent.
|
|
16
16
|
*
|
|
17
|
-
* It
|
|
18
|
-
*
|
|
19
|
-
* `resume`, `close`, `prompt`, `cancel`, and `update`), and the v2 surface of
|
|
20
|
-
* the adapter does not serve it yet. Nor does it advertise the unstable
|
|
21
|
-
* `providers` methods, which the v2 surface does not serve yet either.
|
|
17
|
+
* It does not advertise the unstable `providers` methods, which the v2
|
|
18
|
+
* surface does not serve yet.
|
|
22
19
|
*/
|
|
23
20
|
export declare function v2InitializeResponse(response: InitializeResponse): v2.InitializeResponse;
|
|
24
21
|
//# sourceMappingURL=initialize.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"initialize.d.ts","sourceRoot":"","sources":["../../src/v2/initialize.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AACH,OAAO,EAGL,KAAK,iBAAiB,EACtB,KAAK,kBAAkB,EACxB,MAAM,0BAA0B,CAAC;AAClC,OAAO,KAAK,EAAE,MAAM,0CAA0C,CAAC;AAE/D,0DAA0D;AAC1D,wBAAgB,mBAAmB,CAAC,OAAO,EAAE,EAAE,CAAC,iBAAiB,GAAG,iBAAiB,CAwBpF;AAED
|
|
1
|
+
{"version":3,"file":"initialize.d.ts","sourceRoot":"","sources":["../../src/v2/initialize.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AACH,OAAO,EAGL,KAAK,iBAAiB,EACtB,KAAK,kBAAkB,EACxB,MAAM,0BAA0B,CAAC;AAClC,OAAO,KAAK,EAAE,MAAM,0CAA0C,CAAC;AAE/D,0DAA0D;AAC1D,wBAAgB,mBAAmB,CAAC,OAAO,EAAE,EAAE,CAAC,iBAAiB,GAAG,iBAAiB,CAwBpF;AAED;;;;;GAKG;AACH,wBAAgB,oBAAoB,CAAC,QAAQ,EAAE,kBAAkB,GAAG,EAAE,CAAC,kBAAkB,CAiBxF"}
|
package/dist/v2/initialize.js
CHANGED
|
@@ -38,11 +38,8 @@ export function v1InitializeRequest(request) {
|
|
|
38
38
|
/**
|
|
39
39
|
* The v2 `initialize` response for the v1 response of the agent.
|
|
40
40
|
*
|
|
41
|
-
* It
|
|
42
|
-
*
|
|
43
|
-
* `resume`, `close`, `prompt`, `cancel`, and `update`), and the v2 surface of
|
|
44
|
-
* the adapter does not serve it yet. Nor does it advertise the unstable
|
|
45
|
-
* `providers` methods, which the v2 surface does not serve yet either.
|
|
41
|
+
* It does not advertise the unstable `providers` methods, which the v2
|
|
42
|
+
* surface does not serve yet.
|
|
46
43
|
*/
|
|
47
44
|
export function v2InitializeResponse(response) {
|
|
48
45
|
if (!response.agentInfo) {
|
|
@@ -54,11 +51,31 @@ export function v2InitializeResponse(response) {
|
|
|
54
51
|
info: response.agentInfo,
|
|
55
52
|
// v1 `auth.logout` has no v2 counterpart: a v2 agent that advertises auth
|
|
56
53
|
// methods must serve `auth/logout`.
|
|
57
|
-
capabilities:
|
|
54
|
+
capabilities: {
|
|
55
|
+
session: V2_SESSION_CAPABILITIES,
|
|
56
|
+
...(meta != null ? { _meta: meta } : {}),
|
|
57
|
+
},
|
|
58
58
|
authMethods: (response.authMethods ?? []).map(v2AuthMethod),
|
|
59
59
|
...(response._meta != null ? { _meta: response._meta } : {}),
|
|
60
60
|
};
|
|
61
61
|
}
|
|
62
|
+
/**
|
|
63
|
+
* The session capabilities of the v2 surface, which serves each through a v1
|
|
64
|
+
* method of the agent.
|
|
65
|
+
*
|
|
66
|
+
* - The session baseline: `session/new`, `list`, `resume` (with replay),
|
|
67
|
+
* `close`, `prompt`, `cancel`, and `update`.
|
|
68
|
+
* - `session/delete` and `additionalDirectories`. Not `session/fork` yet.
|
|
69
|
+
* - The prompt content and MCP transports that the agent's v1 `initialize`
|
|
70
|
+
* lists: images, embedded context, and HTTP servers. Stdio servers are in the
|
|
71
|
+
* v1 baseline; v2 has no SSE transport.
|
|
72
|
+
*/
|
|
73
|
+
const V2_SESSION_CAPABILITIES = {
|
|
74
|
+
prompt: { image: {}, embeddedContext: {} },
|
|
75
|
+
mcp: { stdio: {}, http: {} },
|
|
76
|
+
delete: {},
|
|
77
|
+
additionalDirectories: {},
|
|
78
|
+
};
|
|
62
79
|
/** v2 names the id of a method `methodId`, requires `type`, and lists `env` as name and value pairs. */
|
|
63
80
|
function v2AuthMethod(method) {
|
|
64
81
|
if ("type" in method && method.type === "terminal") {
|
package/package.json
CHANGED