@smithery/api 0.18.0 → 0.20.0
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 +31 -0
- package/package.json +1 -1
- package/resources/beta/connect/connect.d.mts +4 -8
- package/resources/beta/connect/connect.d.mts.map +1 -1
- package/resources/beta/connect/connect.d.ts +4 -8
- package/resources/beta/connect/connect.d.ts.map +1 -1
- package/resources/beta/connect/connect.js +0 -4
- package/resources/beta/connect/connect.js.map +1 -1
- package/resources/beta/connect/connect.mjs +1 -5
- package/resources/beta/connect/connect.mjs.map +1 -1
- package/resources/beta/connect/connections.d.mts +8 -96
- package/resources/beta/connect/connections.d.mts.map +1 -1
- package/resources/beta/connect/connections.d.ts +8 -96
- package/resources/beta/connect/connections.d.ts.map +1 -1
- package/resources/beta/connect/connections.js +0 -72
- package/resources/beta/connect/connections.js.map +1 -1
- package/resources/beta/connect/connections.mjs +0 -72
- package/resources/beta/connect/connections.mjs.map +1 -1
- package/resources/beta/connect/index.d.mts +2 -3
- package/resources/beta/connect/index.d.mts.map +1 -1
- package/resources/beta/connect/index.d.ts +2 -3
- package/resources/beta/connect/index.d.ts.map +1 -1
- package/resources/beta/connect/index.js +1 -3
- package/resources/beta/connect/index.js.map +1 -1
- package/resources/beta/connect/index.mjs +0 -1
- package/resources/beta/connect/index.mjs.map +1 -1
- package/resources/beta/connect/rpc.d.mts +1 -42
- package/resources/beta/connect/rpc.d.mts.map +1 -1
- package/resources/beta/connect/rpc.d.ts +1 -42
- package/resources/beta/connect/rpc.d.ts.map +1 -1
- package/resources/beta/connect/rpc.js +0 -24
- package/resources/beta/connect/rpc.js.map +1 -1
- package/resources/beta/connect/rpc.mjs +0 -24
- package/resources/beta/connect/rpc.mjs.map +1 -1
- package/resources/beta/tools.d.mts +0 -10
- package/resources/beta/tools.d.mts.map +1 -1
- package/resources/beta/tools.d.ts +0 -10
- package/resources/beta/tools.d.ts.map +1 -1
- package/resources/beta/tools.js +0 -10
- package/resources/beta/tools.js.map +1 -1
- package/resources/beta/tools.mjs +0 -10
- package/resources/beta/tools.mjs.map +1 -1
- package/src/resources/beta/connect/connect.ts +3 -32
- package/src/resources/beta/connect/connections.ts +11 -136
- package/src/resources/beta/connect/index.ts +1 -11
- package/src/resources/beta/connect/rpc.ts +2 -60
- package/src/resources/beta/tools.ts +0 -10
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
- package/resources/beta/connect/namespaces.d.mts +0 -76
- package/resources/beta/connect/namespaces.d.mts.map +0 -1
- package/resources/beta/connect/namespaces.d.ts +0 -76
- package/resources/beta/connect/namespaces.d.ts.map +0 -1
- package/resources/beta/connect/namespaces.js +0 -61
- package/resources/beta/connect/namespaces.js.map +0 -1
- package/resources/beta/connect/namespaces.mjs +0 -57
- package/resources/beta/connect/namespaces.mjs.map +0 -1
- package/src/resources/beta/connect/namespaces.ts +0 -101
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
export { Connect } from "./connect.mjs";
|
|
2
|
-
export { Connections, type Connection, type ConnectionsListResponse, type CreateConnectionRequest,
|
|
3
|
-
export {
|
|
4
|
-
export { Rpc, type JsonRpcRequest, type JsonRpcResponse, type RpcCallParams } from "./rpc.mjs";
|
|
2
|
+
export { Connections, type Connection, type ConnectionsListResponse, type CreateConnectionRequest, } from "./connections.mjs";
|
|
3
|
+
export { Rpc, type JsonRpcRequest, type JsonRpcResponse } from "./rpc.mjs";
|
|
5
4
|
//# sourceMappingURL=index.d.mts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.mts","sourceRoot":"","sources":["../../../src/resources/beta/connect/index.ts"],"names":[],"mappings":"OAEO,EAAE,OAAO,EAAE;OACX,EACL,WAAW,EACX,KAAK,UAAU,EACf,KAAK,uBAAuB,EAC5B,KAAK,uBAAuB,
|
|
1
|
+
{"version":3,"file":"index.d.mts","sourceRoot":"","sources":["../../../src/resources/beta/connect/index.ts"],"names":[],"mappings":"OAEO,EAAE,OAAO,EAAE;OACX,EACL,WAAW,EACX,KAAK,UAAU,EACf,KAAK,uBAAuB,EAC5B,KAAK,uBAAuB,GAC7B;OACM,EAAE,GAAG,EAAE,KAAK,cAAc,EAAE,KAAK,eAAe,EAAE"}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
export { Connect } from "./connect.js";
|
|
2
|
-
export { Connections, type Connection, type ConnectionsListResponse, type CreateConnectionRequest,
|
|
3
|
-
export {
|
|
4
|
-
export { Rpc, type JsonRpcRequest, type JsonRpcResponse, type RpcCallParams } from "./rpc.js";
|
|
2
|
+
export { Connections, type Connection, type ConnectionsListResponse, type CreateConnectionRequest, } from "./connections.js";
|
|
3
|
+
export { Rpc, type JsonRpcRequest, type JsonRpcResponse } from "./rpc.js";
|
|
5
4
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/resources/beta/connect/index.ts"],"names":[],"mappings":"OAEO,EAAE,OAAO,EAAE;OACX,EACL,WAAW,EACX,KAAK,UAAU,EACf,KAAK,uBAAuB,EAC5B,KAAK,uBAAuB,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/resources/beta/connect/index.ts"],"names":[],"mappings":"OAEO,EAAE,OAAO,EAAE;OACX,EACL,WAAW,EACX,KAAK,UAAU,EACf,KAAK,uBAAuB,EAC5B,KAAK,uBAAuB,GAC7B;OACM,EAAE,GAAG,EAAE,KAAK,cAAc,EAAE,KAAK,eAAe,EAAE"}
|
|
@@ -1,13 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
3
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
-
exports.Rpc = exports.
|
|
4
|
+
exports.Rpc = exports.Connections = exports.Connect = void 0;
|
|
5
5
|
var connect_1 = require("./connect.js");
|
|
6
6
|
Object.defineProperty(exports, "Connect", { enumerable: true, get: function () { return connect_1.Connect; } });
|
|
7
7
|
var connections_1 = require("./connections.js");
|
|
8
8
|
Object.defineProperty(exports, "Connections", { enumerable: true, get: function () { return connections_1.Connections; } });
|
|
9
|
-
var namespaces_1 = require("./namespaces.js");
|
|
10
|
-
Object.defineProperty(exports, "Namespaces", { enumerable: true, get: function () { return namespaces_1.Namespaces; } });
|
|
11
9
|
var rpc_1 = require("./rpc.js");
|
|
12
10
|
Object.defineProperty(exports, "Rpc", { enumerable: true, get: function () { return rpc_1.Rpc; } });
|
|
13
11
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/resources/beta/connect/index.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,wCAAoC;AAA3B,kGAAA,OAAO,OAAA;AAChB,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/resources/beta/connect/index.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,wCAAoC;AAA3B,kGAAA,OAAO,OAAA;AAChB,gDAKuB;AAJrB,0GAAA,WAAW,OAAA;AAKb,gCAAuE;AAA9D,0FAAA,GAAG,OAAA"}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
export { Connect } from "./connect.mjs";
|
|
3
3
|
export { Connections, } from "./connections.mjs";
|
|
4
|
-
export { Namespaces, } from "./namespaces.mjs";
|
|
5
4
|
export { Rpc } from "./rpc.mjs";
|
|
6
5
|
//# sourceMappingURL=index.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","sourceRoot":"","sources":["../../../src/resources/beta/connect/index.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,OAAO,EAAE;OACX,EACL,WAAW,
|
|
1
|
+
{"version":3,"file":"index.mjs","sourceRoot":"","sources":["../../../src/resources/beta/connect/index.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,OAAO,EAAE;OACX,EACL,WAAW,GAIZ;OACM,EAAE,GAAG,EAA6C"}
|
|
@@ -1,24 +1,5 @@
|
|
|
1
1
|
import { APIResource } from "../../../core/resource.mjs";
|
|
2
|
-
import { APIPromise } from "../../../core/api-promise.mjs";
|
|
3
|
-
import { RequestOptions } from "../../../internal/request-options.mjs";
|
|
4
2
|
export declare class Rpc extends APIResource {
|
|
5
|
-
/**
|
|
6
|
-
* Execute a JSON-RPC call on an MCP connection. Requires service token with rpc
|
|
7
|
-
* scope.
|
|
8
|
-
*
|
|
9
|
-
* @example
|
|
10
|
-
* ```ts
|
|
11
|
-
* const jsonRpcResponse = await client.beta.connect.rpc.call(
|
|
12
|
-
* 'connectionId',
|
|
13
|
-
* {
|
|
14
|
-
* namespaceId: 'namespaceId',
|
|
15
|
-
* jsonrpc: '2.0',
|
|
16
|
-
* method: 'tools/list',
|
|
17
|
-
* },
|
|
18
|
-
* );
|
|
19
|
-
* ```
|
|
20
|
-
*/
|
|
21
|
-
call(connectionID: string, params: RpcCallParams, options?: RequestOptions): APIPromise<JsonRpcResponse>;
|
|
22
3
|
}
|
|
23
4
|
export interface JsonRpcRequest {
|
|
24
5
|
jsonrpc: '2.0';
|
|
@@ -37,29 +18,7 @@ export interface JsonRpcResponse {
|
|
|
37
18
|
jsonrpc: '2.0';
|
|
38
19
|
result?: unknown;
|
|
39
20
|
}
|
|
40
|
-
export interface RpcCallParams {
|
|
41
|
-
/**
|
|
42
|
-
* Path param
|
|
43
|
-
*/
|
|
44
|
-
namespaceId: string;
|
|
45
|
-
/**
|
|
46
|
-
* Body param
|
|
47
|
-
*/
|
|
48
|
-
jsonrpc: '2.0';
|
|
49
|
-
/**
|
|
50
|
-
* Body param: MCP method to call
|
|
51
|
-
*/
|
|
52
|
-
method: string;
|
|
53
|
-
/**
|
|
54
|
-
* Body param
|
|
55
|
-
*/
|
|
56
|
-
id?: string | number;
|
|
57
|
-
/**
|
|
58
|
-
* Body param: Method parameters
|
|
59
|
-
*/
|
|
60
|
-
params?: unknown;
|
|
61
|
-
}
|
|
62
21
|
export declare namespace Rpc {
|
|
63
|
-
export { type JsonRpcRequest as JsonRpcRequest, type JsonRpcResponse as JsonRpcResponse
|
|
22
|
+
export { type JsonRpcRequest as JsonRpcRequest, type JsonRpcResponse as JsonRpcResponse };
|
|
64
23
|
}
|
|
65
24
|
//# sourceMappingURL=rpc.d.mts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"rpc.d.mts","sourceRoot":"","sources":["../../../src/resources/beta/connect/rpc.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;
|
|
1
|
+
{"version":3,"file":"rpc.d.mts","sourceRoot":"","sources":["../../../src/resources/beta/connect/rpc.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;AAEtB,qBAAa,GAAI,SAAQ,WAAW;CAAG;AAEvC,MAAM,WAAW,cAAc;IAC7B,OAAO,EAAE,KAAK,CAAC;IAEf;;OAEG;IACH,MAAM,EAAE,MAAM,CAAC;IAEf,EAAE,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IAErB;;OAEG;IACH,MAAM,CAAC,EAAE,OAAO,CAAC;CAClB;AAED,MAAM,WAAW,eAAe;IAC9B,EAAE,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI,CAAC;IAE3B,OAAO,EAAE,KAAK,CAAC;IAEf,MAAM,CAAC,EAAE,OAAO,CAAC;CAClB;AAED,MAAM,CAAC,OAAO,WAAW,GAAG,CAAC;IAC3B,OAAO,EAAE,KAAK,cAAc,IAAI,cAAc,EAAE,KAAK,eAAe,IAAI,eAAe,EAAE,CAAC;CAC3F"}
|
|
@@ -1,24 +1,5 @@
|
|
|
1
1
|
import { APIResource } from "../../../core/resource.js";
|
|
2
|
-
import { APIPromise } from "../../../core/api-promise.js";
|
|
3
|
-
import { RequestOptions } from "../../../internal/request-options.js";
|
|
4
2
|
export declare class Rpc extends APIResource {
|
|
5
|
-
/**
|
|
6
|
-
* Execute a JSON-RPC call on an MCP connection. Requires service token with rpc
|
|
7
|
-
* scope.
|
|
8
|
-
*
|
|
9
|
-
* @example
|
|
10
|
-
* ```ts
|
|
11
|
-
* const jsonRpcResponse = await client.beta.connect.rpc.call(
|
|
12
|
-
* 'connectionId',
|
|
13
|
-
* {
|
|
14
|
-
* namespaceId: 'namespaceId',
|
|
15
|
-
* jsonrpc: '2.0',
|
|
16
|
-
* method: 'tools/list',
|
|
17
|
-
* },
|
|
18
|
-
* );
|
|
19
|
-
* ```
|
|
20
|
-
*/
|
|
21
|
-
call(connectionID: string, params: RpcCallParams, options?: RequestOptions): APIPromise<JsonRpcResponse>;
|
|
22
3
|
}
|
|
23
4
|
export interface JsonRpcRequest {
|
|
24
5
|
jsonrpc: '2.0';
|
|
@@ -37,29 +18,7 @@ export interface JsonRpcResponse {
|
|
|
37
18
|
jsonrpc: '2.0';
|
|
38
19
|
result?: unknown;
|
|
39
20
|
}
|
|
40
|
-
export interface RpcCallParams {
|
|
41
|
-
/**
|
|
42
|
-
* Path param
|
|
43
|
-
*/
|
|
44
|
-
namespaceId: string;
|
|
45
|
-
/**
|
|
46
|
-
* Body param
|
|
47
|
-
*/
|
|
48
|
-
jsonrpc: '2.0';
|
|
49
|
-
/**
|
|
50
|
-
* Body param: MCP method to call
|
|
51
|
-
*/
|
|
52
|
-
method: string;
|
|
53
|
-
/**
|
|
54
|
-
* Body param
|
|
55
|
-
*/
|
|
56
|
-
id?: string | number;
|
|
57
|
-
/**
|
|
58
|
-
* Body param: Method parameters
|
|
59
|
-
*/
|
|
60
|
-
params?: unknown;
|
|
61
|
-
}
|
|
62
21
|
export declare namespace Rpc {
|
|
63
|
-
export { type JsonRpcRequest as JsonRpcRequest, type JsonRpcResponse as JsonRpcResponse
|
|
22
|
+
export { type JsonRpcRequest as JsonRpcRequest, type JsonRpcResponse as JsonRpcResponse };
|
|
64
23
|
}
|
|
65
24
|
//# sourceMappingURL=rpc.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"rpc.d.ts","sourceRoot":"","sources":["../../../src/resources/beta/connect/rpc.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;
|
|
1
|
+
{"version":3,"file":"rpc.d.ts","sourceRoot":"","sources":["../../../src/resources/beta/connect/rpc.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;AAEtB,qBAAa,GAAI,SAAQ,WAAW;CAAG;AAEvC,MAAM,WAAW,cAAc;IAC7B,OAAO,EAAE,KAAK,CAAC;IAEf;;OAEG;IACH,MAAM,EAAE,MAAM,CAAC;IAEf,EAAE,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IAErB;;OAEG;IACH,MAAM,CAAC,EAAE,OAAO,CAAC;CAClB;AAED,MAAM,WAAW,eAAe;IAC9B,EAAE,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI,CAAC;IAE3B,OAAO,EAAE,KAAK,CAAC;IAEf,MAAM,CAAC,EAAE,OAAO,CAAC;CAClB;AAED,MAAM,CAAC,OAAO,WAAW,GAAG,CAAC;IAC3B,OAAO,EAAE,KAAK,cAAc,IAAI,cAAc,EAAE,KAAK,eAAe,IAAI,eAAe,EAAE,CAAC;CAC3F"}
|
|
@@ -3,31 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
4
|
exports.Rpc = void 0;
|
|
5
5
|
const resource_1 = require("../../../core/resource.js");
|
|
6
|
-
const path_1 = require("../../../internal/utils/path.js");
|
|
7
6
|
class Rpc extends resource_1.APIResource {
|
|
8
|
-
/**
|
|
9
|
-
* Execute a JSON-RPC call on an MCP connection. Requires service token with rpc
|
|
10
|
-
* scope.
|
|
11
|
-
*
|
|
12
|
-
* @example
|
|
13
|
-
* ```ts
|
|
14
|
-
* const jsonRpcResponse = await client.beta.connect.rpc.call(
|
|
15
|
-
* 'connectionId',
|
|
16
|
-
* {
|
|
17
|
-
* namespaceId: 'namespaceId',
|
|
18
|
-
* jsonrpc: '2.0',
|
|
19
|
-
* method: 'tools/list',
|
|
20
|
-
* },
|
|
21
|
-
* );
|
|
22
|
-
* ```
|
|
23
|
-
*/
|
|
24
|
-
call(connectionID, params, options) {
|
|
25
|
-
const { namespaceId, ...body } = params;
|
|
26
|
-
return this._client.post((0, path_1.path) `/connect/namespaces/${namespaceId}/connections/${connectionID}/rpc`, {
|
|
27
|
-
body,
|
|
28
|
-
...options,
|
|
29
|
-
});
|
|
30
|
-
}
|
|
31
7
|
}
|
|
32
8
|
exports.Rpc = Rpc;
|
|
33
9
|
//# sourceMappingURL=rpc.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"rpc.js","sourceRoot":"","sources":["../../../src/resources/beta/connect/rpc.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,wDAAqD;
|
|
1
|
+
{"version":3,"file":"rpc.js","sourceRoot":"","sources":["../../../src/resources/beta/connect/rpc.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,wDAAqD;AAErD,MAAa,GAAI,SAAQ,sBAAW;CAAG;AAAvC,kBAAuC"}
|
|
@@ -1,29 +1,5 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
import { APIResource } from "../../../core/resource.mjs";
|
|
3
|
-
import { path } from "../../../internal/utils/path.mjs";
|
|
4
3
|
export class Rpc extends APIResource {
|
|
5
|
-
/**
|
|
6
|
-
* Execute a JSON-RPC call on an MCP connection. Requires service token with rpc
|
|
7
|
-
* scope.
|
|
8
|
-
*
|
|
9
|
-
* @example
|
|
10
|
-
* ```ts
|
|
11
|
-
* const jsonRpcResponse = await client.beta.connect.rpc.call(
|
|
12
|
-
* 'connectionId',
|
|
13
|
-
* {
|
|
14
|
-
* namespaceId: 'namespaceId',
|
|
15
|
-
* jsonrpc: '2.0',
|
|
16
|
-
* method: 'tools/list',
|
|
17
|
-
* },
|
|
18
|
-
* );
|
|
19
|
-
* ```
|
|
20
|
-
*/
|
|
21
|
-
call(connectionID, params, options) {
|
|
22
|
-
const { namespaceId, ...body } = params;
|
|
23
|
-
return this._client.post(path `/connect/namespaces/${namespaceId}/connections/${connectionID}/rpc`, {
|
|
24
|
-
body,
|
|
25
|
-
...options,
|
|
26
|
-
});
|
|
27
|
-
}
|
|
28
4
|
}
|
|
29
5
|
//# sourceMappingURL=rpc.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"rpc.mjs","sourceRoot":"","sources":["../../../src/resources/beta/connect/rpc.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;
|
|
1
|
+
{"version":3,"file":"rpc.mjs","sourceRoot":"","sources":["../../../src/resources/beta/connect/rpc.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;AAEtB,MAAM,OAAO,GAAI,SAAQ,WAAW;CAAG"}
|
|
@@ -5,16 +5,6 @@ export declare class Tools extends APIResource {
|
|
|
5
5
|
/**
|
|
6
6
|
* Get a paginated list of all MCP tools across servers. Use the `q` parameter for
|
|
7
7
|
* semantic search.
|
|
8
|
-
*
|
|
9
|
-
* @example
|
|
10
|
-
* ```ts
|
|
11
|
-
* // Automatically fetches more pages as needed.
|
|
12
|
-
* for await (const toolListResponse of client.beta.tools.list(
|
|
13
|
-
* { q: 'x' },
|
|
14
|
-
* )) {
|
|
15
|
-
* // ...
|
|
16
|
-
* }
|
|
17
|
-
* ```
|
|
18
8
|
*/
|
|
19
9
|
list(query: ToolListParams, options?: RequestOptions): PagePromise<ToolListResponsesToolsPage, ToolListResponse>;
|
|
20
10
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tools.d.mts","sourceRoot":"","sources":["../../src/resources/beta/tools.ts"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;AAED,MAAM,WAAW,cAAe,SAAQ,eAAe;IACrD,CAAC,EAAE,MAAM,CAAC;IAEV,eAAe,CAAC,EAAE,GAAG,GAAG,GAAG,GAAG,MAAM,GAAG,OAAO,CAAC;IAE/C,cAAc,CAAC,EAAE,GAAG,GAAG,GAAG,GAAG,MAAM,GAAG,OAAO,CAAC;IAE9C,YAAY,CAAC,EAAE,GAAG,GAAG,GAAG,GAAG,MAAM,GAAG,OAAO,CAAC;IAE5C,QAAQ,CAAC,EAAE,MAAM,CAAC;IAElB,gBAAgB,CAAC,EAAE,GAAG,GAAG,GAAG,GAAG,MAAM,GAAG,OAAO,CAAC;IAEhD,mBAAmB,CAAC,EAAE,MAAM,CAAC;IAE7B,cAAc,CAAC,EAAE,GAAG,GAAG,GAAG,GAAG,MAAM,GAAG,OAAO,CAAC;IAE9C,IAAI,CAAC,EAAE,MAAM,CAAC;CACf;AAED,MAAM,CAAC,OAAO,WAAW,KAAK,CAAC;IAC7B,OAAO,EACL,KAAK,gBAAgB,IAAI,gBAAgB,EACzC,KAAK,0BAA0B,IAAI,0BAA0B,EAC7D,KAAK,cAAc,IAAI,cAAc,GACtC,CAAC;CACH"}
|
|
@@ -5,16 +5,6 @@ export declare class Tools extends APIResource {
|
|
|
5
5
|
/**
|
|
6
6
|
* Get a paginated list of all MCP tools across servers. Use the `q` parameter for
|
|
7
7
|
* semantic search.
|
|
8
|
-
*
|
|
9
|
-
* @example
|
|
10
|
-
* ```ts
|
|
11
|
-
* // Automatically fetches more pages as needed.
|
|
12
|
-
* for await (const toolListResponse of client.beta.tools.list(
|
|
13
|
-
* { q: 'x' },
|
|
14
|
-
* )) {
|
|
15
|
-
* // ...
|
|
16
|
-
* }
|
|
17
|
-
* ```
|
|
18
8
|
*/
|
|
19
9
|
list(query: ToolListParams, options?: RequestOptions): PagePromise<ToolListResponsesToolsPage, ToolListResponse>;
|
|
20
10
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tools.d.ts","sourceRoot":"","sources":["../../src/resources/beta/tools.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,EAAE,WAAW,EAAE,SAAS,EAAE,KAAK,eAAe,EAAE;OAChD,EAAE,cAAc,EAAE;AAEzB,qBAAa,KAAM,SAAQ,WAAW;IACpC
|
|
1
|
+
{"version":3,"file":"tools.d.ts","sourceRoot":"","sources":["../../src/resources/beta/tools.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,EAAE,WAAW,EAAE,SAAS,EAAE,KAAK,eAAe,EAAE;OAChD,EAAE,cAAc,EAAE;AAEzB,qBAAa,KAAM,SAAQ,WAAW;IACpC;;;OAGG;IACH,IAAI,CACF,KAAK,EAAE,cAAc,EACrB,OAAO,CAAC,EAAE,cAAc,GACvB,WAAW,CAAC,0BAA0B,EAAE,gBAAgB,CAAC;CAG7D;AAED,MAAM,MAAM,0BAA0B,GAAG,SAAS,CAAC,gBAAgB,CAAC,CAAC;AAErE,MAAM,WAAW,gBAAgB;IAC/B,EAAE,EAAE,MAAM,CAAC;IAEX,MAAM,EAAE,gBAAgB,CAAC,MAAM,CAAC;IAEhC,IAAI,EAAE,gBAAgB,CAAC,IAAI,CAAC;CAC7B;AAED,yBAAiB,gBAAgB,CAAC;IAChC,UAAiB,MAAM;QACrB,EAAE,EAAE,MAAM,CAAC;QAEX,WAAW,EAAE,MAAM,CAAC;QAEpB,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;QAEvB,UAAU,EAAE,OAAO,CAAC;QAEpB,aAAa,EAAE,MAAM,CAAC;QAEtB,QAAQ,EAAE,OAAO,CAAC;KACnB;IAED,UAAiB,IAAI;QACnB,WAAW,EAAE,IAAI,CAAC,WAAW,CAAC;QAE9B,IAAI,EAAE,MAAM,CAAC;QAEb,KAAK,CAAC,EAAE;YAAE,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAA;SAAE,CAAC;QAEnC,WAAW,CAAC,EAAE,IAAI,CAAC,WAAW,CAA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,GAAG,OAAO,CAAC;SACtB;KACF;CACF;AAED,MAAM,WAAW,cAAe,SAAQ,eAAe;IACrD,CAAC,EAAE,MAAM,CAAC;IAEV,eAAe,CAAC,EAAE,GAAG,GAAG,GAAG,GAAG,MAAM,GAAG,OAAO,CAAC;IAE/C,cAAc,CAAC,EAAE,GAAG,GAAG,GAAG,GAAG,MAAM,GAAG,OAAO,CAAC;IAE9C,YAAY,CAAC,EAAE,GAAG,GAAG,GAAG,GAAG,MAAM,GAAG,OAAO,CAAC;IAE5C,QAAQ,CAAC,EAAE,MAAM,CAAC;IAElB,gBAAgB,CAAC,EAAE,GAAG,GAAG,GAAG,GAAG,MAAM,GAAG,OAAO,CAAC;IAEhD,mBAAmB,CAAC,EAAE,MAAM,CAAC;IAE7B,cAAc,CAAC,EAAE,GAAG,GAAG,GAAG,GAAG,MAAM,GAAG,OAAO,CAAC;IAE9C,IAAI,CAAC,EAAE,MAAM,CAAC;CACf;AAED,MAAM,CAAC,OAAO,WAAW,KAAK,CAAC;IAC7B,OAAO,EACL,KAAK,gBAAgB,IAAI,gBAAgB,EACzC,KAAK,0BAA0B,IAAI,0BAA0B,EAC7D,KAAK,cAAc,IAAI,cAAc,GACtC,CAAC;CACH"}
|
package/resources/beta/tools.js
CHANGED
|
@@ -8,16 +8,6 @@ class Tools extends resource_1.APIResource {
|
|
|
8
8
|
/**
|
|
9
9
|
* Get a paginated list of all MCP tools across servers. Use the `q` parameter for
|
|
10
10
|
* semantic search.
|
|
11
|
-
*
|
|
12
|
-
* @example
|
|
13
|
-
* ```ts
|
|
14
|
-
* // Automatically fetches more pages as needed.
|
|
15
|
-
* for await (const toolListResponse of client.beta.tools.list(
|
|
16
|
-
* { q: 'x' },
|
|
17
|
-
* )) {
|
|
18
|
-
* // ...
|
|
19
|
-
* }
|
|
20
|
-
* ```
|
|
21
11
|
*/
|
|
22
12
|
list(query, options) {
|
|
23
13
|
return this._client.getAPIList('/tools', (pagination_1.ToolsPage), { query, ...options });
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tools.js","sourceRoot":"","sources":["../../src/resources/beta/tools.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,qDAAkD;AAClD,yDAAqF;AAGrF,MAAa,KAAM,SAAQ,sBAAW;IACpC
|
|
1
|
+
{"version":3,"file":"tools.js","sourceRoot":"","sources":["../../src/resources/beta/tools.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,qDAAkD;AAClD,yDAAqF;AAGrF,MAAa,KAAM,SAAQ,sBAAW;IACpC;;;OAGG;IACH,IAAI,CACF,KAAqB,EACrB,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,UAAU,CAAC,QAAQ,EAAE,CAAA,sBAA2B,CAAA,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAC/F,CAAC;CACF;AAXD,sBAWC"}
|
package/resources/beta/tools.mjs
CHANGED
|
@@ -5,16 +5,6 @@ export class Tools extends APIResource {
|
|
|
5
5
|
/**
|
|
6
6
|
* Get a paginated list of all MCP tools across servers. Use the `q` parameter for
|
|
7
7
|
* semantic search.
|
|
8
|
-
*
|
|
9
|
-
* @example
|
|
10
|
-
* ```ts
|
|
11
|
-
* // Automatically fetches more pages as needed.
|
|
12
|
-
* for await (const toolListResponse of client.beta.tools.list(
|
|
13
|
-
* { q: 'x' },
|
|
14
|
-
* )) {
|
|
15
|
-
* // ...
|
|
16
|
-
* }
|
|
17
|
-
* ```
|
|
18
8
|
*/
|
|
19
9
|
list(query, options) {
|
|
20
10
|
return this._client.getAPIList('/tools', (ToolsPage), { query, ...options });
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tools.mjs","sourceRoot":"","sources":["../../src/resources/beta/tools.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OACf,EAAe,SAAS,EAAwB;AAGvD,MAAM,OAAO,KAAM,SAAQ,WAAW;IACpC
|
|
1
|
+
{"version":3,"file":"tools.mjs","sourceRoot":"","sources":["../../src/resources/beta/tools.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OACf,EAAe,SAAS,EAAwB;AAGvD,MAAM,OAAO,KAAM,SAAQ,WAAW;IACpC;;;OAGG;IACH,IAAI,CACF,KAAqB,EACrB,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,UAAU,CAAC,QAAQ,EAAE,CAAA,SAA2B,CAAA,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAC/F,CAAC;CACF"}
|
|
@@ -2,54 +2,25 @@
|
|
|
2
2
|
|
|
3
3
|
import { APIResource } from '../../../core/resource';
|
|
4
4
|
import * as ConnectionsAPI from './connections';
|
|
5
|
-
import {
|
|
6
|
-
Connection,
|
|
7
|
-
ConnectionCreateParams,
|
|
8
|
-
ConnectionDeleteParams,
|
|
9
|
-
ConnectionDeleteResponse,
|
|
10
|
-
ConnectionRetrieveParams,
|
|
11
|
-
Connections,
|
|
12
|
-
ConnectionsListResponse,
|
|
13
|
-
CreateConnectionRequest,
|
|
14
|
-
} from './connections';
|
|
15
|
-
import * as NamespacesAPI from './namespaces';
|
|
16
|
-
import { Namespace, NamespaceDeleteResponse, NamespaceListResponse, Namespaces } from './namespaces';
|
|
5
|
+
import { Connection, Connections, ConnectionsListResponse, CreateConnectionRequest } from './connections';
|
|
17
6
|
import * as RpcAPI from './rpc';
|
|
18
|
-
import { JsonRpcRequest, JsonRpcResponse, Rpc
|
|
7
|
+
import { JsonRpcRequest, JsonRpcResponse, Rpc } from './rpc';
|
|
19
8
|
|
|
20
9
|
export class Connect extends APIResource {
|
|
21
|
-
namespaces: NamespacesAPI.Namespaces = new NamespacesAPI.Namespaces(this._client);
|
|
22
10
|
connections: ConnectionsAPI.Connections = new ConnectionsAPI.Connections(this._client);
|
|
23
11
|
rpc: RpcAPI.Rpc = new RpcAPI.Rpc(this._client);
|
|
24
12
|
}
|
|
25
13
|
|
|
26
|
-
Connect.Namespaces = Namespaces;
|
|
27
14
|
Connect.Connections = Connections;
|
|
28
15
|
Connect.Rpc = Rpc;
|
|
29
16
|
|
|
30
17
|
export declare namespace Connect {
|
|
31
|
-
export {
|
|
32
|
-
Namespaces as Namespaces,
|
|
33
|
-
type Namespace as Namespace,
|
|
34
|
-
type NamespaceListResponse as NamespaceListResponse,
|
|
35
|
-
type NamespaceDeleteResponse as NamespaceDeleteResponse,
|
|
36
|
-
};
|
|
37
|
-
|
|
38
18
|
export {
|
|
39
19
|
Connections as Connections,
|
|
40
20
|
type Connection as Connection,
|
|
41
21
|
type ConnectionsListResponse as ConnectionsListResponse,
|
|
42
22
|
type CreateConnectionRequest as CreateConnectionRequest,
|
|
43
|
-
type ConnectionDeleteResponse as ConnectionDeleteResponse,
|
|
44
|
-
type ConnectionCreateParams as ConnectionCreateParams,
|
|
45
|
-
type ConnectionRetrieveParams as ConnectionRetrieveParams,
|
|
46
|
-
type ConnectionDeleteParams as ConnectionDeleteParams,
|
|
47
23
|
};
|
|
48
24
|
|
|
49
|
-
export {
|
|
50
|
-
Rpc as Rpc,
|
|
51
|
-
type JsonRpcRequest as JsonRpcRequest,
|
|
52
|
-
type JsonRpcResponse as JsonRpcResponse,
|
|
53
|
-
type RpcCallParams as RpcCallParams,
|
|
54
|
-
};
|
|
25
|
+
export { Rpc as Rpc, type JsonRpcRequest as JsonRpcRequest, type JsonRpcResponse as JsonRpcResponse };
|
|
55
26
|
}
|
|
@@ -1,102 +1,12 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
|
|
3
3
|
import { APIResource } from '../../../core/resource';
|
|
4
|
-
import { APIPromise } from '../../../core/api-promise';
|
|
5
|
-
import { RequestOptions } from '../../../internal/request-options';
|
|
6
|
-
import { path } from '../../../internal/utils/path';
|
|
7
4
|
|
|
8
|
-
export class Connections extends APIResource {
|
|
9
|
-
/**
|
|
10
|
-
* Create a new MCP connection with the given ID. Requires API key and namespace
|
|
11
|
-
* ownership.
|
|
12
|
-
*
|
|
13
|
-
* @example
|
|
14
|
-
* ```ts
|
|
15
|
-
* const connection =
|
|
16
|
-
* await client.beta.connect.connections.create(
|
|
17
|
-
* 'connectionId',
|
|
18
|
-
* {
|
|
19
|
-
* namespaceId: 'namespaceId',
|
|
20
|
-
* mcpUrl: 'https://mcp.example.com/sse',
|
|
21
|
-
* name: 'My MCP Server',
|
|
22
|
-
* },
|
|
23
|
-
* );
|
|
24
|
-
* ```
|
|
25
|
-
*/
|
|
26
|
-
create(
|
|
27
|
-
connectionID: string,
|
|
28
|
-
params: ConnectionCreateParams,
|
|
29
|
-
options?: RequestOptions,
|
|
30
|
-
): APIPromise<Connection> {
|
|
31
|
-
const { namespaceId, ...body } = params;
|
|
32
|
-
return this._client.put(path`/connect/namespaces/${namespaceId}/connections/${connectionID}`, {
|
|
33
|
-
body,
|
|
34
|
-
...options,
|
|
35
|
-
});
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
/**
|
|
39
|
-
* Get details for a specific connection. Requires service token with
|
|
40
|
-
* connections:read scope.
|
|
41
|
-
*
|
|
42
|
-
* @example
|
|
43
|
-
* ```ts
|
|
44
|
-
* const connection =
|
|
45
|
-
* await client.beta.connect.connections.retrieve(
|
|
46
|
-
* 'connectionId',
|
|
47
|
-
* { namespaceId: 'namespaceId' },
|
|
48
|
-
* );
|
|
49
|
-
* ```
|
|
50
|
-
*/
|
|
51
|
-
retrieve(
|
|
52
|
-
connectionID: string,
|
|
53
|
-
params: ConnectionRetrieveParams,
|
|
54
|
-
options?: RequestOptions,
|
|
55
|
-
): APIPromise<Connection> {
|
|
56
|
-
const { namespaceId } = params;
|
|
57
|
-
return this._client.get(path`/connect/namespaces/${namespaceId}/connections/${connectionID}`, options);
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
/**
|
|
61
|
-
* List all connections in a namespace. Requires service token with
|
|
62
|
-
* connections:read scope.
|
|
63
|
-
*
|
|
64
|
-
* @example
|
|
65
|
-
* ```ts
|
|
66
|
-
* const connectionsListResponse =
|
|
67
|
-
* await client.beta.connect.connections.list('namespaceId');
|
|
68
|
-
* ```
|
|
69
|
-
*/
|
|
70
|
-
list(namespaceID: string, options?: RequestOptions): APIPromise<ConnectionsListResponse> {
|
|
71
|
-
return this._client.get(path`/connect/namespaces/${namespaceID}/connections`, options);
|
|
72
|
-
}
|
|
73
|
-
|
|
74
|
-
/**
|
|
75
|
-
* Delete a connection and terminate its MCP session. Requires API key and
|
|
76
|
-
* namespace ownership.
|
|
77
|
-
*
|
|
78
|
-
* @example
|
|
79
|
-
* ```ts
|
|
80
|
-
* const connection =
|
|
81
|
-
* await client.beta.connect.connections.delete(
|
|
82
|
-
* 'connectionId',
|
|
83
|
-
* { namespaceId: 'namespaceId' },
|
|
84
|
-
* );
|
|
85
|
-
* ```
|
|
86
|
-
*/
|
|
87
|
-
delete(
|
|
88
|
-
connectionID: string,
|
|
89
|
-
params: ConnectionDeleteParams,
|
|
90
|
-
options?: RequestOptions,
|
|
91
|
-
): APIPromise<ConnectionDeleteResponse> {
|
|
92
|
-
const { namespaceId } = params;
|
|
93
|
-
return this._client.delete(path`/connect/namespaces/${namespaceId}/connections/${connectionID}`, options);
|
|
94
|
-
}
|
|
95
|
-
}
|
|
5
|
+
export class Connections extends APIResource {}
|
|
96
6
|
|
|
97
7
|
export interface Connection {
|
|
98
8
|
/**
|
|
99
|
-
*
|
|
9
|
+
* Connection ID (auto-generated or developer-defined)
|
|
100
10
|
*/
|
|
101
11
|
connectionId: string;
|
|
102
12
|
|
|
@@ -122,15 +32,18 @@ export interface Connection {
|
|
|
122
32
|
/**
|
|
123
33
|
* Connection status after initialization (only returned on create)
|
|
124
34
|
*/
|
|
125
|
-
status?:
|
|
35
|
+
status?:
|
|
36
|
+
| Connection.ConnectConnectionStatusConnected
|
|
37
|
+
| Connection.ConnectConnectionStatusAuthRequired
|
|
38
|
+
| Connection.ConnectConnectionStatusError;
|
|
126
39
|
}
|
|
127
40
|
|
|
128
41
|
export namespace Connection {
|
|
129
|
-
export interface
|
|
42
|
+
export interface ConnectConnectionStatusConnected {
|
|
130
43
|
state: 'connected';
|
|
131
44
|
}
|
|
132
45
|
|
|
133
|
-
export interface
|
|
46
|
+
export interface ConnectConnectionStatusAuthRequired {
|
|
134
47
|
state: 'auth_required';
|
|
135
48
|
|
|
136
49
|
/**
|
|
@@ -139,7 +52,7 @@ export namespace Connection {
|
|
|
139
52
|
authorizationUrl?: string;
|
|
140
53
|
}
|
|
141
54
|
|
|
142
|
-
export interface
|
|
55
|
+
export interface ConnectConnectionStatusError {
|
|
143
56
|
/**
|
|
144
57
|
* Error message
|
|
145
58
|
*/
|
|
@@ -164,49 +77,15 @@ export interface CreateConnectionRequest {
|
|
|
164
77
|
*/
|
|
165
78
|
mcpUrl: string;
|
|
166
79
|
|
|
167
|
-
/**
|
|
168
|
-
* Human-readable name
|
|
169
|
-
*/
|
|
170
|
-
name: string;
|
|
171
|
-
|
|
172
80
|
/**
|
|
173
81
|
* Custom metadata for filtering connections
|
|
174
82
|
*/
|
|
175
83
|
metadata?: { [key: string]: unknown };
|
|
176
|
-
}
|
|
177
|
-
|
|
178
|
-
export interface ConnectionDeleteResponse {
|
|
179
|
-
success: true;
|
|
180
|
-
}
|
|
181
|
-
|
|
182
|
-
export interface ConnectionCreateParams {
|
|
183
|
-
/**
|
|
184
|
-
* Path param
|
|
185
|
-
*/
|
|
186
|
-
namespaceId: string;
|
|
187
|
-
|
|
188
|
-
/**
|
|
189
|
-
* Body param: URL of the MCP server
|
|
190
|
-
*/
|
|
191
|
-
mcpUrl: string;
|
|
192
|
-
|
|
193
|
-
/**
|
|
194
|
-
* Body param: Human-readable name
|
|
195
|
-
*/
|
|
196
|
-
name: string;
|
|
197
84
|
|
|
198
85
|
/**
|
|
199
|
-
*
|
|
86
|
+
* Human-readable name (optional, defaults to connection ID)
|
|
200
87
|
*/
|
|
201
|
-
|
|
202
|
-
}
|
|
203
|
-
|
|
204
|
-
export interface ConnectionRetrieveParams {
|
|
205
|
-
namespaceId: string;
|
|
206
|
-
}
|
|
207
|
-
|
|
208
|
-
export interface ConnectionDeleteParams {
|
|
209
|
-
namespaceId: string;
|
|
88
|
+
name?: string;
|
|
210
89
|
}
|
|
211
90
|
|
|
212
91
|
export declare namespace Connections {
|
|
@@ -214,9 +93,5 @@ export declare namespace Connections {
|
|
|
214
93
|
type Connection as Connection,
|
|
215
94
|
type ConnectionsListResponse as ConnectionsListResponse,
|
|
216
95
|
type CreateConnectionRequest as CreateConnectionRequest,
|
|
217
|
-
type ConnectionDeleteResponse as ConnectionDeleteResponse,
|
|
218
|
-
type ConnectionCreateParams as ConnectionCreateParams,
|
|
219
|
-
type ConnectionRetrieveParams as ConnectionRetrieveParams,
|
|
220
|
-
type ConnectionDeleteParams as ConnectionDeleteParams,
|
|
221
96
|
};
|
|
222
97
|
}
|
|
@@ -6,15 +6,5 @@ export {
|
|
|
6
6
|
type Connection,
|
|
7
7
|
type ConnectionsListResponse,
|
|
8
8
|
type CreateConnectionRequest,
|
|
9
|
-
type ConnectionDeleteResponse,
|
|
10
|
-
type ConnectionCreateParams,
|
|
11
|
-
type ConnectionRetrieveParams,
|
|
12
|
-
type ConnectionDeleteParams,
|
|
13
9
|
} from './connections';
|
|
14
|
-
export {
|
|
15
|
-
Namespaces,
|
|
16
|
-
type Namespace,
|
|
17
|
-
type NamespaceListResponse,
|
|
18
|
-
type NamespaceDeleteResponse,
|
|
19
|
-
} from './namespaces';
|
|
20
|
-
export { Rpc, type JsonRpcRequest, type JsonRpcResponse, type RpcCallParams } from './rpc';
|
|
10
|
+
export { Rpc, type JsonRpcRequest, type JsonRpcResponse } from './rpc';
|