@smithery/api 0.1.0-alpha.10 → 0.1.0-alpha.11

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.
Files changed (70) hide show
  1. package/CHANGELOG.md +8 -0
  2. package/client.d.mts +6 -0
  3. package/client.d.mts.map +1 -1
  4. package/client.d.ts +6 -0
  5. package/client.d.ts.map +1 -1
  6. package/client.js +6 -0
  7. package/client.js.map +1 -1
  8. package/client.mjs +6 -0
  9. package/client.mjs.map +1 -1
  10. package/package.json +1 -1
  11. package/resources/index.d.mts +2 -0
  12. package/resources/index.d.mts.map +1 -1
  13. package/resources/index.d.ts +2 -0
  14. package/resources/index.d.ts.map +1 -1
  15. package/resources/index.js +5 -1
  16. package/resources/index.js.map +1 -1
  17. package/resources/index.mjs +2 -0
  18. package/resources/index.mjs.map +1 -1
  19. package/resources/namespaces.d.mts +45 -0
  20. package/resources/namespaces.d.mts.map +1 -0
  21. package/resources/namespaces.d.ts +45 -0
  22. package/resources/namespaces.d.ts.map +1 -0
  23. package/resources/namespaces.js +33 -0
  24. package/resources/namespaces.js.map +1 -0
  25. package/resources/namespaces.mjs +29 -0
  26. package/resources/namespaces.mjs.map +1 -0
  27. package/resources/search.d.mts +115 -0
  28. package/resources/search.d.mts.map +1 -0
  29. package/resources/search.d.ts +115 -0
  30. package/resources/search.d.ts.map +1 -0
  31. package/resources/search.js +21 -0
  32. package/resources/search.js.map +1 -0
  33. package/resources/search.mjs +17 -0
  34. package/resources/search.mjs.map +1 -0
  35. package/resources/servers/index.d.mts +1 -0
  36. package/resources/servers/index.d.mts.map +1 -1
  37. package/resources/servers/index.d.ts +1 -0
  38. package/resources/servers/index.d.ts.map +1 -1
  39. package/resources/servers/index.js +3 -1
  40. package/resources/servers/index.js.map +1 -1
  41. package/resources/servers/index.mjs +1 -0
  42. package/resources/servers/index.mjs.map +1 -1
  43. package/resources/servers/secrets.d.mts +42 -0
  44. package/resources/servers/secrets.d.mts.map +1 -0
  45. package/resources/servers/secrets.d.ts +42 -0
  46. package/resources/servers/secrets.d.ts.map +1 -0
  47. package/resources/servers/secrets.js +30 -0
  48. package/resources/servers/secrets.js.map +1 -0
  49. package/resources/servers/secrets.mjs +26 -0
  50. package/resources/servers/secrets.mjs.map +1 -0
  51. package/resources/servers/servers.d.mts +8 -0
  52. package/resources/servers/servers.d.mts.map +1 -1
  53. package/resources/servers/servers.d.ts +8 -0
  54. package/resources/servers/servers.d.ts.map +1 -1
  55. package/resources/servers/servers.js +15 -0
  56. package/resources/servers/servers.js.map +1 -1
  57. package/resources/servers/servers.mjs +15 -0
  58. package/resources/servers/servers.mjs.map +1 -1
  59. package/src/client.ts +24 -0
  60. package/src/resources/index.ts +7 -0
  61. package/src/resources/namespaces.ts +63 -0
  62. package/src/resources/search.ts +200 -0
  63. package/src/resources/servers/index.ts +8 -0
  64. package/src/resources/servers/secrets.ts +73 -0
  65. package/src/resources/servers/servers.ts +32 -0
  66. package/src/version.ts +1 -1
  67. package/version.d.mts +1 -1
  68. package/version.d.ts +1 -1
  69. package/version.js +1 -1
  70. package/version.mjs +1 -1
@@ -8,13 +8,17 @@ const DeploymentsAPI = tslib_1.__importStar(require("./deployments.js"));
8
8
  const deployments_1 = require("./deployments.js");
9
9
  const LogsAPI = tslib_1.__importStar(require("./logs.js"));
10
10
  const logs_1 = require("./logs.js");
11
+ const SecretsAPI = tslib_1.__importStar(require("./secrets.js"));
12
+ const secrets_1 = require("./secrets.js");
11
13
  const pagination_1 = require("../../core/pagination.js");
14
+ const headers_1 = require("../../internal/headers.js");
12
15
  const path_1 = require("../../internal/utils/path.js");
13
16
  class Servers extends resource_1.APIResource {
14
17
  constructor() {
15
18
  super(...arguments);
16
19
  this.deployments = new DeploymentsAPI.Deployments(this._client);
17
20
  this.logs = new LogsAPI.Logs(this._client);
21
+ this.secrets = new SecretsAPI.Secrets(this._client);
18
22
  }
19
23
  /**
20
24
  * Get a single server by its qualified name.
@@ -28,8 +32,19 @@ class Servers extends resource_1.APIResource {
28
32
  list(query = {}, options) {
29
33
  return this._client.getAPIList('/servers', (pagination_1.SmitheryPage), { query, ...options });
30
34
  }
35
+ /**
36
+ * Download the MCPB bundle for the latest successful stdio deployment
37
+ */
38
+ download(qualifiedName, options) {
39
+ return this._client.get((0, path_1.path) `/servers/${qualifiedName}/download`, {
40
+ ...options,
41
+ headers: (0, headers_1.buildHeaders)([{ Accept: 'application/zip' }, options?.headers]),
42
+ __binaryResponse: true,
43
+ });
44
+ }
31
45
  }
32
46
  exports.Servers = Servers;
33
47
  Servers.Deployments = deployments_1.Deployments;
34
48
  Servers.Logs = logs_1.Logs;
49
+ Servers.Secrets = secrets_1.Secrets;
35
50
  //# sourceMappingURL=servers.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"servers.js","sourceRoot":"","sources":["../../src/resources/servers/servers.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;;AAEtF,qDAAkD;AAClD,yEAAgD;AAChD,kDAcuB;AACvB,2DAAkC;AAClC,oCAA8D;AAE9D,yDAA2F;AAE3F,uDAAiD;AAEjD,MAAa,OAAQ,SAAQ,sBAAW;IAAxC;;QACE,gBAAW,GAA+B,IAAI,cAAc,CAAC,WAAW,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;QACvF,SAAI,GAAiB,IAAI,OAAO,CAAC,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IAkBtD,CAAC;IAhBC;;OAEG;IACH,QAAQ,CAAC,aAAqB,EAAE,OAAwB;QACtD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAA,WAAI,EAAA,YAAY,aAAa,EAAE,EAAE,OAAO,CAAC,CAAC;IACpE,CAAC;IAED;;OAEG;IACH,IAAI,CACF,QAA6C,EAAE,EAC/C,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,UAAU,CAAC,UAAU,EAAE,CAAA,yBAAgC,CAAA,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACtG,CAAC;CACF;AApBD,0BAoBC;AA4FD,OAAO,CAAC,WAAW,GAAG,yBAAW,CAAC;AAClC,OAAO,CAAC,IAAI,GAAG,WAAI,CAAC"}
1
+ {"version":3,"file":"servers.js","sourceRoot":"","sources":["../../src/resources/servers/servers.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;;AAEtF,qDAAkD;AAClD,yEAAgD;AAChD,kDAcuB;AACvB,2DAAkC;AAClC,oCAA8D;AAC9D,iEAAwC;AACxC,0CAOmB;AAEnB,yDAA2F;AAC3F,uDAAsD;AAEtD,uDAAiD;AAEjD,MAAa,OAAQ,SAAQ,sBAAW;IAAxC;;QACE,gBAAW,GAA+B,IAAI,cAAc,CAAC,WAAW,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;QACvF,SAAI,GAAiB,IAAI,OAAO,CAAC,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;QACpD,YAAO,GAAuB,IAAI,UAAU,CAAC,OAAO,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IA6BrE,CAAC;IA3BC;;OAEG;IACH,QAAQ,CAAC,aAAqB,EAAE,OAAwB;QACtD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAA,WAAI,EAAA,YAAY,aAAa,EAAE,EAAE,OAAO,CAAC,CAAC;IACpE,CAAC;IAED;;OAEG;IACH,IAAI,CACF,QAA6C,EAAE,EAC/C,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,UAAU,CAAC,UAAU,EAAE,CAAA,yBAAgC,CAAA,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACtG,CAAC;IAED;;OAEG;IACH,QAAQ,CAAC,aAAqB,EAAE,OAAwB;QACtD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAA,WAAI,EAAA,YAAY,aAAa,WAAW,EAAE;YAChE,GAAG,OAAO;YACV,OAAO,EAAE,IAAA,sBAAY,EAAC,CAAC,EAAE,MAAM,EAAE,iBAAiB,EAAE,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC;YACxE,gBAAgB,EAAE,IAAI;SACvB,CAAC,CAAC;IACL,CAAC;CACF;AAhCD,0BAgCC;AA4FD,OAAO,CAAC,WAAW,GAAG,yBAAW,CAAC;AAClC,OAAO,CAAC,IAAI,GAAG,WAAI,CAAC;AACpB,OAAO,CAAC,OAAO,GAAG,iBAAO,CAAC"}
@@ -4,13 +4,17 @@ import * as DeploymentsAPI from "./deployments.mjs";
4
4
  import { Deployments, } from "./deployments.mjs";
5
5
  import * as LogsAPI from "./logs.mjs";
6
6
  import { Logs } from "./logs.mjs";
7
+ import * as SecretsAPI from "./secrets.mjs";
8
+ import { Secrets, } from "./secrets.mjs";
7
9
  import { SmitheryPage } from "../../core/pagination.mjs";
10
+ import { buildHeaders } from "../../internal/headers.mjs";
8
11
  import { path } from "../../internal/utils/path.mjs";
9
12
  export class Servers extends APIResource {
10
13
  constructor() {
11
14
  super(...arguments);
12
15
  this.deployments = new DeploymentsAPI.Deployments(this._client);
13
16
  this.logs = new LogsAPI.Logs(this._client);
17
+ this.secrets = new SecretsAPI.Secrets(this._client);
14
18
  }
15
19
  /**
16
20
  * Get a single server by its qualified name.
@@ -24,7 +28,18 @@ export class Servers extends APIResource {
24
28
  list(query = {}, options) {
25
29
  return this._client.getAPIList('/servers', (SmitheryPage), { query, ...options });
26
30
  }
31
+ /**
32
+ * Download the MCPB bundle for the latest successful stdio deployment
33
+ */
34
+ download(qualifiedName, options) {
35
+ return this._client.get(path `/servers/${qualifiedName}/download`, {
36
+ ...options,
37
+ headers: buildHeaders([{ Accept: 'application/zip' }, options?.headers]),
38
+ __binaryResponse: true,
39
+ });
40
+ }
27
41
  }
28
42
  Servers.Deployments = Deployments;
29
43
  Servers.Logs = Logs;
44
+ Servers.Secrets = Secrets;
30
45
  //# sourceMappingURL=servers.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"servers.mjs","sourceRoot":"","sources":["../../src/resources/servers/servers.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OACf,KAAK,cAAc;OACnB,EASL,WAAW,GAKZ;OACM,KAAK,OAAO;OACZ,EAAkC,IAAI,EAAE;OAExC,EAAe,YAAY,EAA2B;OAEtD,EAAE,IAAI,EAAE;AAEf,MAAM,OAAO,OAAQ,SAAQ,WAAW;IAAxC;;QACE,gBAAW,GAA+B,IAAI,cAAc,CAAC,WAAW,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;QACvF,SAAI,GAAiB,IAAI,OAAO,CAAC,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IAkBtD,CAAC;IAhBC;;OAEG;IACH,QAAQ,CAAC,aAAqB,EAAE,OAAwB;QACtD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAA,YAAY,aAAa,EAAE,EAAE,OAAO,CAAC,CAAC;IACpE,CAAC;IAED;;OAEG;IACH,IAAI,CACF,QAA6C,EAAE,EAC/C,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,UAAU,CAAC,UAAU,EAAE,CAAA,YAAgC,CAAA,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACtG,CAAC;CACF;AA4FD,OAAO,CAAC,WAAW,GAAG,WAAW,CAAC;AAClC,OAAO,CAAC,IAAI,GAAG,IAAI,CAAC"}
1
+ {"version":3,"file":"servers.mjs","sourceRoot":"","sources":["../../src/resources/servers/servers.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OACf,KAAK,cAAc;OACnB,EASL,WAAW,GAKZ;OACM,KAAK,OAAO;OACZ,EAAkC,IAAI,EAAE;OACxC,KAAK,UAAU;OACf,EAML,OAAO,GACR;OAEM,EAAe,YAAY,EAA2B;OACtD,EAAE,YAAY,EAAE;OAEhB,EAAE,IAAI,EAAE;AAEf,MAAM,OAAO,OAAQ,SAAQ,WAAW;IAAxC;;QACE,gBAAW,GAA+B,IAAI,cAAc,CAAC,WAAW,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;QACvF,SAAI,GAAiB,IAAI,OAAO,CAAC,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;QACpD,YAAO,GAAuB,IAAI,UAAU,CAAC,OAAO,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IA6BrE,CAAC;IA3BC;;OAEG;IACH,QAAQ,CAAC,aAAqB,EAAE,OAAwB;QACtD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAA,YAAY,aAAa,EAAE,EAAE,OAAO,CAAC,CAAC;IACpE,CAAC;IAED;;OAEG;IACH,IAAI,CACF,QAA6C,EAAE,EAC/C,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,UAAU,CAAC,UAAU,EAAE,CAAA,YAAgC,CAAA,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACtG,CAAC;IAED;;OAEG;IACH,QAAQ,CAAC,aAAqB,EAAE,OAAwB;QACtD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAA,YAAY,aAAa,WAAW,EAAE;YAChE,GAAG,OAAO;YACV,OAAO,EAAE,YAAY,CAAC,CAAC,EAAE,MAAM,EAAE,iBAAiB,EAAE,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC;YACxE,gBAAgB,EAAE,IAAI;SACvB,CAAC,CAAC;IACL,CAAC;CACF;AA4FD,OAAO,CAAC,WAAW,GAAG,WAAW,CAAC;AAClC,OAAO,CAAC,IAAI,GAAG,IAAI,CAAC;AACpB,OAAO,CAAC,OAAO,GAAG,OAAO,CAAC"}
package/src/client.ts CHANGED
@@ -19,6 +19,13 @@ import * as Uploads from './core/uploads';
19
19
  import * as API from './resources/index';
20
20
  import { APIPromise } from './core/api-promise';
21
21
  import { Health, HealthCheckResponse } from './resources/health';
22
+ import {
23
+ NamespaceCreateParams,
24
+ NamespaceCreateResponse,
25
+ NamespaceListResponse,
26
+ Namespaces,
27
+ } from './resources/namespaces';
28
+ import { Search, SearchRetrieveServersResponse, SearchRetrieveSkillsResponse } from './resources/search';
22
29
  import { Uplink, UplinkCreateTokenResponse } from './resources/uplink';
23
30
  import {
24
31
  ServerListParams,
@@ -746,11 +753,15 @@ export class Smithery {
746
753
  health: API.Health = new API.Health(this);
747
754
  servers: API.Servers = new API.Servers(this);
748
755
  uplink: API.Uplink = new API.Uplink(this);
756
+ search: API.Search = new API.Search(this);
757
+ namespaces: API.Namespaces = new API.Namespaces(this);
749
758
  }
750
759
 
751
760
  Smithery.Health = Health;
752
761
  Smithery.Servers = Servers;
753
762
  Smithery.Uplink = Uplink;
763
+ Smithery.Search = Search;
764
+ Smithery.Namespaces = Namespaces;
754
765
 
755
766
  export declare namespace Smithery {
756
767
  export type RequestOptions = Opts.RequestOptions;
@@ -769,4 +780,17 @@ export declare namespace Smithery {
769
780
  };
770
781
 
771
782
  export { Uplink as Uplink, type UplinkCreateTokenResponse as UplinkCreateTokenResponse };
783
+
784
+ export {
785
+ Search as Search,
786
+ type SearchRetrieveServersResponse as SearchRetrieveServersResponse,
787
+ type SearchRetrieveSkillsResponse as SearchRetrieveSkillsResponse,
788
+ };
789
+
790
+ export {
791
+ Namespaces as Namespaces,
792
+ type NamespaceCreateResponse as NamespaceCreateResponse,
793
+ type NamespaceListResponse as NamespaceListResponse,
794
+ type NamespaceCreateParams as NamespaceCreateParams,
795
+ };
772
796
  }
@@ -1,6 +1,13 @@
1
1
  // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
2
 
3
3
  export { Health, type HealthCheckResponse } from './health';
4
+ export {
5
+ Namespaces,
6
+ type NamespaceCreateResponse,
7
+ type NamespaceListResponse,
8
+ type NamespaceCreateParams,
9
+ } from './namespaces';
10
+ export { Search, type SearchRetrieveServersResponse, type SearchRetrieveSkillsResponse } from './search';
4
11
  export {
5
12
  Servers,
6
13
  type ServerRetrieveResponse,
@@ -0,0 +1,63 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ import { APIResource } from '../core/resource';
4
+ import { APIPromise } from '../core/api-promise';
5
+ import { RequestOptions } from '../internal/request-options';
6
+
7
+ export class Namespaces extends APIResource {
8
+ /**
9
+ * Create a new namespace owned by the authenticated user
10
+ *
11
+ * @example
12
+ * ```ts
13
+ * const namespace = await client.namespaces.create({
14
+ * name: 'myorg',
15
+ * });
16
+ * ```
17
+ */
18
+ create(body: NamespaceCreateParams, options?: RequestOptions): APIPromise<NamespaceCreateResponse> {
19
+ return this._client.put('/namespaces', { body, ...options });
20
+ }
21
+
22
+ /**
23
+ * Get a list of all namespaces owned by the authenticated user
24
+ *
25
+ * @example
26
+ * ```ts
27
+ * const namespaces = await client.namespaces.list();
28
+ * ```
29
+ */
30
+ list(options?: RequestOptions): APIPromise<NamespaceListResponse> {
31
+ return this._client.get('/namespaces', options);
32
+ }
33
+ }
34
+
35
+ export interface NamespaceCreateResponse {
36
+ createdAt: string;
37
+
38
+ name: string;
39
+ }
40
+
41
+ export interface NamespaceListResponse {
42
+ namespaces: Array<NamespaceListResponse.Namespace>;
43
+ }
44
+
45
+ export namespace NamespaceListResponse {
46
+ export interface Namespace {
47
+ createdAt: string;
48
+
49
+ name: string;
50
+ }
51
+ }
52
+
53
+ export interface NamespaceCreateParams {
54
+ name: string;
55
+ }
56
+
57
+ export declare namespace Namespaces {
58
+ export {
59
+ type NamespaceCreateResponse as NamespaceCreateResponse,
60
+ type NamespaceListResponse as NamespaceListResponse,
61
+ type NamespaceCreateParams as NamespaceCreateParams,
62
+ };
63
+ }
@@ -0,0 +1,200 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ import { APIResource } from '../core/resource';
4
+ import { APIPromise } from '../core/api-promise';
5
+ import { RequestOptions } from '../internal/request-options';
6
+
7
+ export class Search extends APIResource {
8
+ /**
9
+ * Search for MCP servers using hybrid BM25 + vector search
10
+ */
11
+ retrieveServers(options?: RequestOptions): APIPromise<SearchRetrieveServersResponse> {
12
+ return this._client.get('/search/servers', options);
13
+ }
14
+
15
+ /**
16
+ * Search for skills using hybrid BM25 + vector search
17
+ */
18
+ retrieveSkills(options?: RequestOptions): APIPromise<SearchRetrieveSkillsResponse> {
19
+ return this._client.get('/search/skills', options);
20
+ }
21
+ }
22
+
23
+ export interface SearchRetrieveServersResponse {
24
+ data: Array<SearchRetrieveServersResponse.UnionMember0 | SearchRetrieveServersResponse.UnionMember1>;
25
+
26
+ pagination: SearchRetrieveServersResponse.Pagination;
27
+
28
+ debug?: SearchRetrieveServersResponse.Debug;
29
+ }
30
+
31
+ export namespace SearchRetrieveServersResponse {
32
+ export interface UnionMember0 {
33
+ id: string;
34
+
35
+ description: string;
36
+
37
+ displayName: string;
38
+
39
+ namespace: string;
40
+
41
+ qualityScore: number;
42
+
43
+ score: number;
44
+
45
+ slug: string;
46
+
47
+ type: 'skill';
48
+
49
+ categories?: Array<string>;
50
+
51
+ externalStars?: number;
52
+
53
+ gitUrl?: string;
54
+
55
+ totalActivations?: number;
56
+ }
57
+
58
+ export interface UnionMember1 {
59
+ id: string;
60
+
61
+ description: string;
62
+
63
+ displayName: string;
64
+
65
+ featured: boolean;
66
+
67
+ isDeployed: boolean;
68
+
69
+ qualifiedName: string;
70
+
71
+ qualityScore: number;
72
+
73
+ score: number;
74
+
75
+ type: 'server';
76
+
77
+ verified: boolean;
78
+
79
+ remote?: boolean;
80
+
81
+ repoName?: string;
82
+
83
+ repoOwner?: string;
84
+
85
+ useCount?: number;
86
+ }
87
+
88
+ export interface Pagination {
89
+ page: number;
90
+
91
+ pageSize: number;
92
+
93
+ total: number;
94
+ }
95
+
96
+ export interface Debug {
97
+ embeddingMs?: number;
98
+
99
+ region?: string;
100
+
101
+ rrfMs?: number;
102
+
103
+ searchMs?: number;
104
+
105
+ totalMs?: number;
106
+ }
107
+ }
108
+
109
+ export interface SearchRetrieveSkillsResponse {
110
+ data: Array<SearchRetrieveSkillsResponse.UnionMember0 | SearchRetrieveSkillsResponse.UnionMember1>;
111
+
112
+ pagination: SearchRetrieveSkillsResponse.Pagination;
113
+
114
+ debug?: SearchRetrieveSkillsResponse.Debug;
115
+ }
116
+
117
+ export namespace SearchRetrieveSkillsResponse {
118
+ export interface UnionMember0 {
119
+ id: string;
120
+
121
+ description: string;
122
+
123
+ displayName: string;
124
+
125
+ namespace: string;
126
+
127
+ qualityScore: number;
128
+
129
+ score: number;
130
+
131
+ slug: string;
132
+
133
+ type: 'skill';
134
+
135
+ categories?: Array<string>;
136
+
137
+ externalStars?: number;
138
+
139
+ gitUrl?: string;
140
+
141
+ totalActivations?: number;
142
+ }
143
+
144
+ export interface UnionMember1 {
145
+ id: string;
146
+
147
+ description: string;
148
+
149
+ displayName: string;
150
+
151
+ featured: boolean;
152
+
153
+ isDeployed: boolean;
154
+
155
+ qualifiedName: string;
156
+
157
+ qualityScore: number;
158
+
159
+ score: number;
160
+
161
+ type: 'server';
162
+
163
+ verified: boolean;
164
+
165
+ remote?: boolean;
166
+
167
+ repoName?: string;
168
+
169
+ repoOwner?: string;
170
+
171
+ useCount?: number;
172
+ }
173
+
174
+ export interface Pagination {
175
+ page: number;
176
+
177
+ pageSize: number;
178
+
179
+ total: number;
180
+ }
181
+
182
+ export interface Debug {
183
+ embeddingMs?: number;
184
+
185
+ region?: string;
186
+
187
+ rrfMs?: number;
188
+
189
+ searchMs?: number;
190
+
191
+ totalMs?: number;
192
+ }
193
+ }
194
+
195
+ export declare namespace Search {
196
+ export {
197
+ type SearchRetrieveServersResponse as SearchRetrieveServersResponse,
198
+ type SearchRetrieveSkillsResponse as SearchRetrieveSkillsResponse,
199
+ };
200
+ }
@@ -16,6 +16,14 @@ export {
16
16
  type DeploymentResumeParams,
17
17
  } from './deployments';
18
18
  export { Logs, type LogListResponse, type LogListParams } from './logs';
19
+ export {
20
+ Secrets,
21
+ type SecretListResponse,
22
+ type SecretDeleteResponse,
23
+ type SecretSetResponse,
24
+ type SecretDeleteParams,
25
+ type SecretSetParams,
26
+ } from './secrets';
19
27
  export {
20
28
  Servers,
21
29
  type ServerRetrieveResponse,
@@ -0,0 +1,73 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
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
+
8
+ export class Secrets extends APIResource {
9
+ /**
10
+ * Fetch secret names for the server's deployed Worker (requires ownership). Values
11
+ * are not returned.
12
+ */
13
+ list(qualifiedName: string, options?: RequestOptions): APIPromise<SecretListResponse> {
14
+ return this._client.get(path`/servers/${qualifiedName}/secrets`, options);
15
+ }
16
+
17
+ /**
18
+ * Delete a secret by name from the server's deployed Worker (requires ownership).
19
+ */
20
+ delete(
21
+ secretName: string,
22
+ params: SecretDeleteParams,
23
+ options?: RequestOptions,
24
+ ): APIPromise<SecretDeleteResponse> {
25
+ const { qualifiedName } = params;
26
+ return this._client.delete(path`/servers/${qualifiedName}/secrets/${secretName}`, options);
27
+ }
28
+
29
+ /**
30
+ * Set a secret value for the server's deployed Worker (requires ownership).
31
+ */
32
+ set(qualifiedName: string, body: SecretSetParams, options?: RequestOptions): APIPromise<SecretSetResponse> {
33
+ return this._client.put(path`/servers/${qualifiedName}/secrets`, { body, ...options });
34
+ }
35
+ }
36
+
37
+ export type SecretListResponse = Array<SecretListResponse.SecretListResponseItem>;
38
+
39
+ export namespace SecretListResponse {
40
+ export interface SecretListResponseItem {
41
+ name: string;
42
+
43
+ type: string;
44
+ }
45
+ }
46
+
47
+ export interface SecretDeleteResponse {
48
+ success: boolean;
49
+ }
50
+
51
+ export interface SecretSetResponse {
52
+ success: boolean;
53
+ }
54
+
55
+ export interface SecretDeleteParams {
56
+ qualifiedName: string;
57
+ }
58
+
59
+ export interface SecretSetParams {
60
+ name: string;
61
+
62
+ value: string;
63
+ }
64
+
65
+ export declare namespace Secrets {
66
+ export {
67
+ type SecretListResponse as SecretListResponse,
68
+ type SecretDeleteResponse as SecretDeleteResponse,
69
+ type SecretSetResponse as SecretSetResponse,
70
+ type SecretDeleteParams as SecretDeleteParams,
71
+ type SecretSetParams as SecretSetParams,
72
+ };
73
+ }
@@ -19,14 +19,25 @@ import {
19
19
  } from './deployments';
20
20
  import * as LogsAPI from './logs';
21
21
  import { LogListParams, LogListResponse, Logs } from './logs';
22
+ import * as SecretsAPI from './secrets';
23
+ import {
24
+ SecretDeleteParams,
25
+ SecretDeleteResponse,
26
+ SecretListResponse,
27
+ SecretSetParams,
28
+ SecretSetResponse,
29
+ Secrets,
30
+ } from './secrets';
22
31
  import { APIPromise } from '../../core/api-promise';
23
32
  import { PagePromise, SmitheryPage, type SmitheryPageParams } from '../../core/pagination';
33
+ import { buildHeaders } from '../../internal/headers';
24
34
  import { RequestOptions } from '../../internal/request-options';
25
35
  import { path } from '../../internal/utils/path';
26
36
 
27
37
  export class Servers extends APIResource {
28
38
  deployments: DeploymentsAPI.Deployments = new DeploymentsAPI.Deployments(this._client);
29
39
  logs: LogsAPI.Logs = new LogsAPI.Logs(this._client);
40
+ secrets: SecretsAPI.Secrets = new SecretsAPI.Secrets(this._client);
30
41
 
31
42
  /**
32
43
  * Get a single server by its qualified name.
@@ -44,6 +55,17 @@ export class Servers extends APIResource {
44
55
  ): PagePromise<ServerListResponsesSmitheryPage, ServerListResponse> {
45
56
  return this._client.getAPIList('/servers', SmitheryPage<ServerListResponse>, { query, ...options });
46
57
  }
58
+
59
+ /**
60
+ * Download the MCPB bundle for the latest successful stdio deployment
61
+ */
62
+ download(qualifiedName: string, options?: RequestOptions): APIPromise<Response> {
63
+ return this._client.get(path`/servers/${qualifiedName}/download`, {
64
+ ...options,
65
+ headers: buildHeaders([{ Accept: 'application/zip' }, options?.headers]),
66
+ __binaryResponse: true,
67
+ });
68
+ }
47
69
  }
48
70
 
49
71
  export type ServerListResponsesSmitheryPage = SmitheryPage<ServerListResponse>;
@@ -138,6 +160,7 @@ export interface ServerListParams extends SmitheryPageParams {
138
160
 
139
161
  Servers.Deployments = Deployments;
140
162
  Servers.Logs = Logs;
163
+ Servers.Secrets = Secrets;
141
164
 
142
165
  export declare namespace Servers {
143
166
  export {
@@ -164,4 +187,13 @@ export declare namespace Servers {
164
187
  };
165
188
 
166
189
  export { Logs as Logs, type LogListResponse as LogListResponse, type LogListParams as LogListParams };
190
+
191
+ export {
192
+ Secrets as Secrets,
193
+ type SecretListResponse as SecretListResponse,
194
+ type SecretDeleteResponse as SecretDeleteResponse,
195
+ type SecretSetResponse as SecretSetResponse,
196
+ type SecretDeleteParams as SecretDeleteParams,
197
+ type SecretSetParams as SecretSetParams,
198
+ };
167
199
  }
package/src/version.ts CHANGED
@@ -1 +1 @@
1
- export const VERSION = '0.1.0-alpha.10'; // x-release-please-version
1
+ export const VERSION = '0.1.0-alpha.11'; // x-release-please-version
package/version.d.mts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "0.1.0-alpha.10";
1
+ export declare const VERSION = "0.1.0-alpha.11";
2
2
  //# sourceMappingURL=version.d.mts.map
package/version.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "0.1.0-alpha.10";
1
+ export declare const VERSION = "0.1.0-alpha.11";
2
2
  //# sourceMappingURL=version.d.ts.map
package/version.js CHANGED
@@ -1,5 +1,5 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.VERSION = void 0;
4
- exports.VERSION = '0.1.0-alpha.10'; // x-release-please-version
4
+ exports.VERSION = '0.1.0-alpha.11'; // x-release-please-version
5
5
  //# sourceMappingURL=version.js.map
package/version.mjs CHANGED
@@ -1,2 +1,2 @@
1
- export const VERSION = '0.1.0-alpha.10'; // x-release-please-version
1
+ export const VERSION = '0.1.0-alpha.11'; // x-release-please-version
2
2
  //# sourceMappingURL=version.mjs.map