agents 0.8.4 → 0.8.6
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/agents.tsconfig.json +1 -1
- package/dist/client.d.ts +1 -1
- package/dist/experimental/forever.d.ts +2 -1
- package/dist/{index-BADmcFuB.d.ts → index-DynYigzs.d.ts} +2 -2
- package/dist/index.d.ts +1 -1
- package/dist/index.js +4 -1
- package/dist/index.js.map +1 -1
- package/dist/mcp/client.d.ts +1 -1
- package/dist/mcp/index.d.ts +1 -1
- package/dist/mcp/index.js +8 -2
- package/dist/mcp/index.js.map +1 -1
- package/dist/react.d.ts +1 -1
- package/dist/workflows.d.ts +1 -1
- package/dist/workflows.js +0 -1
- package/dist/workflows.js.map +1 -1
- package/package.json +5 -5
package/agents.tsconfig.json
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
"jsx": "react-jsx",
|
|
6
6
|
"module": "ES2022",
|
|
7
7
|
"moduleResolution": "bundler",
|
|
8
|
-
"types": ["node", "@cloudflare/workers-types"],
|
|
8
|
+
"types": ["node", "@cloudflare/workers-types", "vite/client"],
|
|
9
9
|
"allowImportingTsExtensions": true,
|
|
10
10
|
"noEmit": true,
|
|
11
11
|
"isolatedModules": true,
|
package/dist/client.d.ts
CHANGED
|
@@ -720,7 +720,7 @@ declare class MCPClientConnection {
|
|
|
720
720
|
*/
|
|
721
721
|
getTransport(
|
|
722
722
|
transportType: BaseTransportType
|
|
723
|
-
):
|
|
723
|
+
): RPCClientTransport | SSEClientTransport | StreamableHTTPClientTransport;
|
|
724
724
|
private tryConnect;
|
|
725
725
|
private _capabilityErrorHandler;
|
|
726
726
|
}
|
|
@@ -2865,4 +2865,4 @@ export {
|
|
|
2865
2865
|
Schedule as y,
|
|
2866
2866
|
MCPServerOptions as z
|
|
2867
2867
|
};
|
|
2868
|
-
//# sourceMappingURL=index-
|
|
2868
|
+
//# sourceMappingURL=index-DynYigzs.d.ts.map
|
package/dist/index.d.ts
CHANGED
package/dist/index.js
CHANGED
|
@@ -2713,10 +2713,13 @@ var Agent = class Agent extends Server {
|
|
|
2713
2713
|
}
|
|
2714
2714
|
if (!this._resolvedOptions.sendIdentityOnConnect && resolvedCallbackHost && !resolvedCallbackPath) throw new Error("callbackPath is required in addMcpServer options when sendIdentityOnConnect is false — the default callback URL would expose the instance name. Provide a callbackPath and route the callback request to this agent via getAgentByName.");
|
|
2715
2715
|
if (!resolvedCallbackHost) {
|
|
2716
|
-
const { request } = getCurrentAgent();
|
|
2716
|
+
const { request, connection } = getCurrentAgent();
|
|
2717
2717
|
if (request) {
|
|
2718
2718
|
const requestUrl = new URL(request.url);
|
|
2719
2719
|
resolvedCallbackHost = `${requestUrl.protocol}//${requestUrl.host}`;
|
|
2720
|
+
} else if (connection?.uri) {
|
|
2721
|
+
const connectionUrl = new URL(connection.uri);
|
|
2722
|
+
resolvedCallbackHost = `${connectionUrl.protocol}//${connectionUrl.host}`;
|
|
2720
2723
|
}
|
|
2721
2724
|
}
|
|
2722
2725
|
let callbackUrl;
|