@multi-agent-protocol/sdk 0.0.8 → 0.0.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/dist/{index-BVvyY2kb.d.cts → index-C7Jyk_qT.d.cts} +433 -99
- package/dist/{index-BVvyY2kb.d.ts → index-C7Jyk_qT.d.ts} +433 -99
- package/dist/index.cjs +73 -6
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +17 -9
- package/dist/index.d.ts +17 -9
- package/dist/index.js +73 -7
- package/dist/index.js.map +1 -1
- package/dist/testing.cjs +31 -1
- package/dist/testing.cjs.map +1 -1
- package/dist/testing.d.cts +1 -1
- package/dist/testing.d.ts +1 -1
- package/dist/testing.js +31 -1
- package/dist/testing.js.map +1 -1
- package/package.json +6 -2
package/dist/testing.d.cts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { P as ParticipantCapabilities,
|
|
1
|
+
import { P as ParticipantCapabilities, gY as SystemExposure, d as FederationRoutingConfig, S as Stream, cy as BaseConnection, f as SessionId, A as AgentId, n as Agent, m as ScopeId, o as Scope, c as Message, r as Event, k as ParticipantId, N as SubscriptionId, cF as ClientConnectionOptions, cE as ClientConnection, c3 as AgentsListRequestParams, fv as ScopesListRequestParams, q as SubscriptionFilter, fV as Subscription, e as EventType, bM as AgentConnectionOptions, X as AgentConnection } from './index-C7Jyk_qT.cjs';
|
|
2
2
|
import 'events';
|
|
3
3
|
|
|
4
4
|
/**
|
package/dist/testing.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { P as ParticipantCapabilities,
|
|
1
|
+
import { P as ParticipantCapabilities, gY as SystemExposure, d as FederationRoutingConfig, S as Stream, cy as BaseConnection, f as SessionId, A as AgentId, n as Agent, m as ScopeId, o as Scope, c as Message, r as Event, k as ParticipantId, N as SubscriptionId, cF as ClientConnectionOptions, cE as ClientConnection, c3 as AgentsListRequestParams, fv as ScopesListRequestParams, q as SubscriptionFilter, fV as Subscription, e as EventType, bM as AgentConnectionOptions, X as AgentConnection } from './index-C7Jyk_qT.js';
|
|
2
2
|
import 'events';
|
|
3
3
|
|
|
4
4
|
/**
|
package/dist/testing.js
CHANGED
|
@@ -263,7 +263,11 @@ var FEDERATION_ERROR_CODES = {
|
|
|
263
263
|
/** Message has already visited this system (loop detected) */
|
|
264
264
|
FEDERATION_LOOP_DETECTED: 5010,
|
|
265
265
|
/** Message exceeded maximum hop count */
|
|
266
|
-
FEDERATION_MAX_HOPS_EXCEEDED: 5011
|
|
266
|
+
FEDERATION_MAX_HOPS_EXCEEDED: 5011,
|
|
267
|
+
/** DID document resolution failed (network error, invalid document, etc.) */
|
|
268
|
+
FEDERATION_DID_RESOLUTION_FAILED: 5004,
|
|
269
|
+
/** DID proof verification failed (bad signature, expired, wrong challenge, etc.) */
|
|
270
|
+
FEDERATION_DID_PROOF_INVALID: 5005
|
|
267
271
|
};
|
|
268
272
|
var MAIL_ERROR_CODES = {
|
|
269
273
|
MAIL_CONVERSATION_NOT_FOUND: 1e4,
|
|
@@ -4001,6 +4005,32 @@ var ClientConnection = class _ClientConnection {
|
|
|
4001
4005
|
return this.#connection.sendRequest(STATE_METHODS.AGENTS_RESUME, { agentId });
|
|
4002
4006
|
}
|
|
4003
4007
|
// ===========================================================================
|
|
4008
|
+
// Extensions
|
|
4009
|
+
// ===========================================================================
|
|
4010
|
+
/**
|
|
4011
|
+
* Call a server extension method directly via JSON-RPC.
|
|
4012
|
+
*
|
|
4013
|
+
* Extension methods (prefixed with `_macro/` or similar) are registered on the
|
|
4014
|
+
* server's RPC handler and callable as standard JSON-RPC methods. This bypasses
|
|
4015
|
+
* ACP-over-MAP messaging — use this for simple request/response operations that
|
|
4016
|
+
* don't need ACP session semantics.
|
|
4017
|
+
*
|
|
4018
|
+
* @param method - The extension method name (e.g., "_macro/workspace/files/search")
|
|
4019
|
+
* @param params - Parameters to pass to the extension method
|
|
4020
|
+
* @returns The result from the extension method
|
|
4021
|
+
*
|
|
4022
|
+
* @example
|
|
4023
|
+
* ```typescript
|
|
4024
|
+
* const result = await client.callExtension('_macro/workspace/files/search', {
|
|
4025
|
+
* agentId: 'agent-1',
|
|
4026
|
+
* query: 'app.tsx',
|
|
4027
|
+
* });
|
|
4028
|
+
* ```
|
|
4029
|
+
*/
|
|
4030
|
+
async callExtension(method, params) {
|
|
4031
|
+
return this.#connection.sendRequest(method, params);
|
|
4032
|
+
}
|
|
4033
|
+
// ===========================================================================
|
|
4004
4034
|
// Mail
|
|
4005
4035
|
// ===========================================================================
|
|
4006
4036
|
/**
|