@orq-ai/node 4.17.4 → 4.17.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.
Files changed (91) hide show
  1. package/jsr.json +1 -1
  2. package/lib/config.d.ts +2 -2
  3. package/lib/config.js +2 -2
  4. package/models/components/reasoningpart.js +1 -1
  5. package/models/operations/createtool.js +4 -4
  6. package/models/operations/getalltools.js +4 -4
  7. package/models/operations/getv2humanevalsets.js +2 -2
  8. package/models/operations/getv2humanevalsetsid.js +2 -2
  9. package/models/operations/listdeploymentversions.js +1 -1
  10. package/models/operations/patchv2humanevalsetsid.js +2 -2
  11. package/models/operations/postv2humanevalsets.js +2 -2
  12. package/models/operations/retrievetool.js +4 -4
  13. package/models/operations/runagent.js +1 -1
  14. package/models/operations/streamrunagent.js +1 -1
  15. package/models/operations/updatetool.js +4 -4
  16. package/package.json +5 -5
  17. package/packages/orq-rc/src/funcs/feedbackCreate.ts +3 -0
  18. package/packages/orq-rc/src/funcs/feedbackRemove.ts +3 -0
  19. package/packages/orq-rc/src/lib/config.ts +3 -3
  20. package/packages/orq-rc/src/models/components/agentstartedstreamingevent.ts +1 -1
  21. package/packages/orq-rc/src/models/components/autorouterconfig.ts +21 -0
  22. package/packages/orq-rc/src/models/components/autorouterv2config.ts +54 -0
  23. package/packages/orq-rc/src/models/components/autorouterv2creatorconfig.ts +9 -0
  24. package/packages/orq-rc/src/models/components/autorouterv2effortconfig.ts +18 -0
  25. package/packages/orq-rc/src/models/components/budgetmatch.ts +1 -1
  26. package/packages/orq-rc/src/models/components/classifyretryconfig.ts +5 -5
  27. package/packages/orq-rc/src/models/components/createmcpgatewayrequest.ts +18 -0
  28. package/packages/orq-rc/src/models/components/createmcpserverrequest.ts +11 -0
  29. package/packages/orq-rc/src/models/components/creatememorystorerequest.ts +1 -1
  30. package/packages/orq-rc/src/models/components/embeddingretryconfig.ts +5 -5
  31. package/packages/orq-rc/src/models/components/evaluatorcalltimeout.ts +42 -0
  32. package/packages/orq-rc/src/models/components/evaluatorretryconfig.ts +45 -0
  33. package/packages/orq-rc/src/models/components/index.ts +5 -0
  34. package/packages/orq-rc/src/models/components/invokeevaluatorrequest.ts +19 -0
  35. package/packages/orq-rc/src/models/components/loadbalancerconfig.ts +24 -2
  36. package/packages/orq-rc/src/models/components/mcpconnectiontype.ts +1 -0
  37. package/packages/orq-rc/src/models/components/mcpgateway.ts +12 -0
  38. package/packages/orq-rc/src/models/components/mcpgatewaytool.ts +6 -0
  39. package/packages/orq-rc/src/models/components/mcpicon.ts +77 -0
  40. package/packages/orq-rc/src/models/components/mcpopenapiconfig.ts +54 -0
  41. package/packages/orq-rc/src/models/components/mcpopenapiconfiginput.ts +51 -0
  42. package/packages/orq-rc/src/models/components/mcpserver.ts +21 -0
  43. package/packages/orq-rc/src/models/components/mcptool.ts +46 -0
  44. package/packages/orq-rc/src/models/components/memorystore.ts +1 -1
  45. package/packages/orq-rc/src/models/components/modelmetadata.ts +6 -0
  46. package/packages/orq-rc/src/models/components/reasoning.ts +14 -0
  47. package/packages/orq-rc/src/models/components/reasoningparam.ts +14 -0
  48. package/packages/orq-rc/src/models/components/reasoningpart.ts +1 -1
  49. package/packages/orq-rc/src/models/components/responseretryconfig.ts +5 -5
  50. package/packages/orq-rc/src/models/components/updatemcpgatewayrequest.ts +25 -0
  51. package/packages/orq-rc/src/models/components/updatemcpserverrequest.ts +11 -0
  52. package/packages/orq-rc/src/models/operations/createagentrequest.ts +2 -2
  53. package/packages/orq-rc/src/models/operations/createprompt.ts +1 -0
  54. package/packages/orq-rc/src/models/operations/createtool.ts +4 -4
  55. package/packages/orq-rc/src/models/operations/deploymentinvoke.ts +1 -0
  56. package/packages/orq-rc/src/models/operations/deployments.ts +2 -1
  57. package/packages/orq-rc/src/models/operations/deploymentstream.ts +1 -0
  58. package/packages/orq-rc/src/models/operations/getallprompts.ts +1 -0
  59. package/packages/orq-rc/src/models/operations/getalltools.ts +4 -4
  60. package/packages/orq-rc/src/models/operations/getoneprompt.ts +1 -0
  61. package/packages/orq-rc/src/models/operations/getpromptversion.ts +1 -0
  62. package/packages/orq-rc/src/models/operations/getv2humanevalsets.ts +2 -2
  63. package/packages/orq-rc/src/models/operations/getv2humanevalsetsid.ts +2 -2
  64. package/packages/orq-rc/src/models/operations/listagents.ts +1 -1
  65. package/packages/orq-rc/src/models/operations/listdeploymentversions.ts +3 -1
  66. package/packages/orq-rc/src/models/operations/listpromptversions.ts +1 -0
  67. package/packages/orq-rc/src/models/operations/modelcreateawsbedrock.ts +6 -0
  68. package/packages/orq-rc/src/models/operations/modelupdateawsbedrock.ts +6 -0
  69. package/packages/orq-rc/src/models/operations/patchv2humanevalsetsid.ts +2 -2
  70. package/packages/orq-rc/src/models/operations/postv2humanevalsets.ts +2 -2
  71. package/packages/orq-rc/src/models/operations/retrieveagentrequest.ts +1 -1
  72. package/packages/orq-rc/src/models/operations/retrievetool.ts +4 -4
  73. package/packages/orq-rc/src/models/operations/runagent.ts +2 -2
  74. package/packages/orq-rc/src/models/operations/streamrunagent.ts +2 -2
  75. package/packages/orq-rc/src/models/operations/updateagent.ts +1 -1
  76. package/packages/orq-rc/src/models/operations/updateprompt.ts +1 -0
  77. package/packages/orq-rc/src/models/operations/updatetool.ts +4 -4
  78. package/packages/orq-rc/src/sdk/feedback.ts +6 -0
  79. package/src/lib/config.ts +2 -2
  80. package/src/models/components/reasoningpart.ts +1 -1
  81. package/src/models/operations/createtool.ts +4 -4
  82. package/src/models/operations/getalltools.ts +4 -4
  83. package/src/models/operations/getv2humanevalsets.ts +2 -2
  84. package/src/models/operations/getv2humanevalsetsid.ts +2 -2
  85. package/src/models/operations/listdeploymentversions.ts +1 -1
  86. package/src/models/operations/patchv2humanevalsetsid.ts +2 -2
  87. package/src/models/operations/postv2humanevalsets.ts +2 -2
  88. package/src/models/operations/retrievetool.ts +4 -4
  89. package/src/models/operations/runagent.ts +1 -1
  90. package/src/models/operations/streamrunagent.ts +1 -1
  91. package/src/models/operations/updatetool.ts +4 -4
@@ -14,6 +14,11 @@ import {
14
14
  McpConnection$Outbound,
15
15
  McpConnection$outboundSchema,
16
16
  } from "./mcpconnection.js";
17
+ import {
18
+ McpOpenApiConfigInput,
19
+ McpOpenApiConfigInput$Outbound,
20
+ McpOpenApiConfigInput$outboundSchema,
21
+ } from "./mcpopenapiconfiginput.js";
17
22
  import {
18
23
  McpToolExposure,
19
24
  McpToolExposure$Outbound,
@@ -54,6 +59,10 @@ export type CreateMcpServerRequest = {
54
59
  * Which projects in the workspace may use this server. Defaults to every project.
55
60
  */
56
61
  sharing?: Sharing | undefined;
62
+ /**
63
+ * Required when `connection.type` is `MCP_CONNECTION_TYPE_OPENAPI`; set `document` or `document_url`.
64
+ */
65
+ openapi?: McpOpenApiConfigInput | undefined;
57
66
  };
58
67
 
59
68
  /** @internal */
@@ -65,6 +74,7 @@ export type CreateMcpServerRequest$Outbound = {
65
74
  auth: McpAuthConfig$Outbound;
66
75
  default_tool_exposure: McpToolExposure$Outbound;
67
76
  sharing?: Sharing$Outbound | undefined;
77
+ openapi?: McpOpenApiConfigInput$Outbound | undefined;
68
78
  };
69
79
 
70
80
  /** @internal */
@@ -80,6 +90,7 @@ export const CreateMcpServerRequest$outboundSchema: z.ZodType<
80
90
  auth: McpAuthConfig$outboundSchema,
81
91
  defaultToolExposure: McpToolExposure$outboundSchema,
82
92
  sharing: Sharing$outboundSchema.optional(),
93
+ openapi: McpOpenApiConfigInput$outboundSchema.optional(),
83
94
  }).transform((v) => {
84
95
  return remap$(v, {
85
96
  displayName: "display_name",
@@ -12,7 +12,7 @@ import {
12
12
 
13
13
  export type CreateMemoryStoreRequest = {
14
14
  /**
15
- * The unique key of the memory store. The key is unique and inmmutable and cannot be repeated within the same workspace.
15
+ * The unique key of the memory store. The key is unique and immutable and cannot be repeated within the same workspace.
16
16
  */
17
17
  key: string;
18
18
  embeddingConfig: MemoryStoreEmbeddingConfig;
@@ -7,19 +7,19 @@ import { remap as remap$ } from "../../lib/primitives.js";
7
7
 
8
8
  export type EmbeddingRetryConfig = {
9
9
  /**
10
- * Number of retry attempts (1-5).
10
+ * Number of retries per model after the initial attempt (0-5). Set 0 to disable retries. When retry is omitted, the gateway retries twice.
11
11
  */
12
12
  count: number;
13
13
  /**
14
- * HTTP status codes that trigger retry logic.
14
+ * HTTP status codes that trigger a retry. Defaults to [408, 429, 500, 502, 503, 504, 529].
15
15
  */
16
- onCodes: Array<number> | null;
16
+ onCodes?: Array<number> | null | undefined;
17
17
  };
18
18
 
19
19
  /** @internal */
20
20
  export type EmbeddingRetryConfig$Outbound = {
21
21
  count: number;
22
- on_codes: Array<number> | null;
22
+ on_codes?: Array<number> | null | undefined;
23
23
  };
24
24
 
25
25
  /** @internal */
@@ -29,7 +29,7 @@ export const EmbeddingRetryConfig$outboundSchema: z.ZodType<
29
29
  EmbeddingRetryConfig
30
30
  > = z.object({
31
31
  count: z.number().int(),
32
- onCodes: z.nullable(z.array(z.number().int())),
32
+ onCodes: z.nullable(z.array(z.number().int())).optional(),
33
33
  }).transform((v) => {
34
34
  return remap$(v, {
35
35
  onCodes: "on_codes",
@@ -0,0 +1,42 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod/v3";
6
+ import { remap as remap$ } from "../../lib/primitives.js";
7
+
8
+ export type EvaluatorCallTimeout = {
9
+ /**
10
+ * Maximum milliseconds per provider attempt (or execution for non-LLM evaluators).
11
+ *
12
+ * @remarks
13
+ * Omitted uses the server default (120000). The server caps each invocation at ten minutes.
14
+ */
15
+ callTimeout?: number | undefined;
16
+ };
17
+
18
+ /** @internal */
19
+ export type EvaluatorCallTimeout$Outbound = {
20
+ call_timeout?: number | undefined;
21
+ };
22
+
23
+ /** @internal */
24
+ export const EvaluatorCallTimeout$outboundSchema: z.ZodType<
25
+ EvaluatorCallTimeout$Outbound,
26
+ z.ZodTypeDef,
27
+ EvaluatorCallTimeout
28
+ > = z.object({
29
+ callTimeout: z.number().int().optional(),
30
+ }).transform((v) => {
31
+ return remap$(v, {
32
+ callTimeout: "call_timeout",
33
+ });
34
+ });
35
+
36
+ export function evaluatorCallTimeoutToJSON(
37
+ evaluatorCallTimeout: EvaluatorCallTimeout,
38
+ ): string {
39
+ return JSON.stringify(
40
+ EvaluatorCallTimeout$outboundSchema.parse(evaluatorCallTimeout),
41
+ );
42
+ }
@@ -0,0 +1,45 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod/v3";
6
+ import { remap as remap$ } from "../../lib/primitives.js";
7
+
8
+ export type EvaluatorRetryConfig = {
9
+ /**
10
+ * Retries after the first attempt. Zero disables retries; omitted retry preserves existing policy.
11
+ */
12
+ count?: number | undefined;
13
+ /**
14
+ * Omitted uses the gateway's default transient status codes.
15
+ */
16
+ onCodes?: Array<number> | undefined;
17
+ };
18
+
19
+ /** @internal */
20
+ export type EvaluatorRetryConfig$Outbound = {
21
+ count?: number | undefined;
22
+ on_codes?: Array<number> | undefined;
23
+ };
24
+
25
+ /** @internal */
26
+ export const EvaluatorRetryConfig$outboundSchema: z.ZodType<
27
+ EvaluatorRetryConfig$Outbound,
28
+ z.ZodTypeDef,
29
+ EvaluatorRetryConfig
30
+ > = z.object({
31
+ count: z.number().int().optional(),
32
+ onCodes: z.array(z.number().int()).optional(),
33
+ }).transform((v) => {
34
+ return remap$(v, {
35
+ onCodes: "on_codes",
36
+ });
37
+ });
38
+
39
+ export function evaluatorRetryConfigToJSON(
40
+ evaluatorRetryConfig: EvaluatorRetryConfig,
41
+ ): string {
42
+ return JSON.stringify(
43
+ EvaluatorRetryConfig$outboundSchema.parse(evaluatorRetryConfig),
44
+ );
45
+ }
@@ -229,6 +229,7 @@ export * from "./errorpart.js";
229
229
  export * from "./errorstreamingevent.js";
230
230
  export * from "./evaluationcontext.js";
231
231
  export * from "./evaluationresult.js";
232
+ export * from "./evaluatorcalltimeout.js";
232
233
  export * from "./evaluatorfilter.js";
233
234
  export * from "./evaluatorref.js";
234
235
  export * from "./evaluatorresponsefunction.js";
@@ -238,6 +239,7 @@ export * from "./evaluatorresponsellm.js";
238
239
  export * from "./evaluatorresponsepython.js";
239
240
  export * from "./evaluatorresponseragas.js";
240
241
  export * from "./evaluatorresponsetypescript.js";
242
+ export * from "./evaluatorretryconfig.js";
241
243
  export * from "./executionnamedstreamingevent.js";
242
244
  export * from "./executionreviewedstreamingevent.js";
243
245
  export * from "./executionreviewrequiredstreamingevent.js";
@@ -420,8 +422,11 @@ export * from "./mcpgatewaytool.js";
420
422
  export * from "./mcpgatewaytooltestresult.js";
421
423
  export * from "./mcpheadersecret.js";
422
424
  export * from "./mcpheadersecretoutput.js";
425
+ export * from "./mcpicon.js";
423
426
  export * from "./mcpoauthconfig.js";
424
427
  export * from "./mcpoauthconfigoutput.js";
428
+ export * from "./mcpopenapiconfig.js";
429
+ export * from "./mcpopenapiconfiginput.js";
425
430
  export * from "./mcpserver.js";
426
431
  export * from "./mcpskill.js";
427
432
  export * from "./mcpskillexposure.js";
@@ -8,6 +8,16 @@ import {
8
8
  EvaluationContext$Outbound,
9
9
  EvaluationContext$outboundSchema,
10
10
  } from "./evaluationcontext.js";
11
+ import {
12
+ EvaluatorCallTimeout,
13
+ EvaluatorCallTimeout$Outbound,
14
+ EvaluatorCallTimeout$outboundSchema,
15
+ } from "./evaluatorcalltimeout.js";
16
+ import {
17
+ EvaluatorRetryConfig,
18
+ EvaluatorRetryConfig$Outbound,
19
+ EvaluatorRetryConfig$outboundSchema,
20
+ } from "./evaluatorretryconfig.js";
11
21
 
12
22
  /**
13
23
  * Accepts two shapes. `context` names its fields after the template variables
@@ -71,6 +81,11 @@ export type InvokeEvaluatorRequest = {
71
81
  * `context.variables`.
72
82
  */
73
83
  variables?: { [k: string]: any } | undefined;
84
+ /**
85
+ * Overrides llm_eval provider retries for this invocation, including every jury judge.
86
+ */
87
+ retry?: EvaluatorRetryConfig | undefined;
88
+ timeout?: EvaluatorCallTimeout | undefined;
74
89
  };
75
90
 
76
91
  /** @internal */
@@ -83,6 +98,8 @@ export type InvokeEvaluatorRequest$Outbound = {
83
98
  retrievals?: Array<string> | undefined;
84
99
  messages?: Array<{ [k: string]: any }> | undefined;
85
100
  variables?: { [k: string]: any } | undefined;
101
+ retry?: EvaluatorRetryConfig$Outbound | undefined;
102
+ timeout?: EvaluatorCallTimeout$Outbound | undefined;
86
103
  };
87
104
 
88
105
  /** @internal */
@@ -99,6 +116,8 @@ export const InvokeEvaluatorRequest$outboundSchema: z.ZodType<
99
116
  retrievals: z.array(z.string()).optional(),
100
117
  messages: z.array(z.record(z.any())).optional(),
101
118
  variables: z.record(z.any()).optional(),
119
+ retry: EvaluatorRetryConfig$outboundSchema.optional(),
120
+ timeout: EvaluatorCallTimeout$outboundSchema.optional(),
102
121
  });
103
122
 
104
123
  export function invokeEvaluatorRequestToJSON(
@@ -3,17 +3,39 @@
3
3
  */
4
4
 
5
5
  import * as z from "zod/v3";
6
+ import { ClosedEnum } from "../../types/enums.js";
6
7
  import {
7
8
  LoadBalancerModelConfig,
8
9
  LoadBalancerModelConfig$Outbound,
9
10
  LoadBalancerModelConfig$outboundSchema,
10
11
  } from "./loadbalancermodelconfig.js";
11
12
 
13
+ /**
14
+ * Strategy used to pick a model: weight_based splits traffic by weight, round_robin rotates through the list, latency_based favors the fastest model. An unrecognized value falls back to weight_based.
15
+ */
16
+ export const LoadBalancerConfigType = {
17
+ WeightBased: "weight_based",
18
+ RoundRobin: "round_robin",
19
+ LatencyBased: "latency_based",
20
+ } as const;
21
+ /**
22
+ * Strategy used to pick a model: weight_based splits traffic by weight, round_robin rotates through the list, latency_based favors the fastest model. An unrecognized value falls back to weight_based.
23
+ */
24
+ export type LoadBalancerConfigType = ClosedEnum<typeof LoadBalancerConfigType>;
25
+
12
26
  export type LoadBalancerConfig = {
13
27
  models: Array<LoadBalancerModelConfig> | null;
14
- type: string;
28
+ /**
29
+ * Strategy used to pick a model: weight_based splits traffic by weight, round_robin rotates through the list, latency_based favors the fastest model. An unrecognized value falls back to weight_based.
30
+ */
31
+ type: LoadBalancerConfigType;
15
32
  };
16
33
 
34
+ /** @internal */
35
+ export const LoadBalancerConfigType$outboundSchema: z.ZodNativeEnum<
36
+ typeof LoadBalancerConfigType
37
+ > = z.nativeEnum(LoadBalancerConfigType);
38
+
17
39
  /** @internal */
18
40
  export type LoadBalancerConfig$Outbound = {
19
41
  models: Array<LoadBalancerModelConfig$Outbound> | null;
@@ -27,7 +49,7 @@ export const LoadBalancerConfig$outboundSchema: z.ZodType<
27
49
  LoadBalancerConfig
28
50
  > = z.object({
29
51
  models: z.nullable(z.array(LoadBalancerModelConfig$outboundSchema)),
30
- type: z.string(),
52
+ type: LoadBalancerConfigType$outboundSchema,
31
53
  });
32
54
 
33
55
  export function loadBalancerConfigToJSON(
@@ -9,6 +9,7 @@ export const McpConnectionType = {
9
9
  McpConnectionTypeHttp: "MCP_CONNECTION_TYPE_HTTP",
10
10
  McpConnectionTypeSse: "MCP_CONNECTION_TYPE_SSE",
11
11
  McpConnectionTypeStdio: "MCP_CONNECTION_TYPE_STDIO",
12
+ McpConnectionTypeOpenapi: "MCP_CONNECTION_TYPE_OPENAPI",
12
13
  } as const;
13
14
  export type McpConnectionType = ClosedEnum<typeof McpConnectionType>;
14
15
 
@@ -19,6 +19,7 @@ import {
19
19
  McpGatewayServerLink,
20
20
  McpGatewayServerLink$inboundSchema,
21
21
  } from "./mcpgatewayserverlink.js";
22
+ import { McpIcon, McpIcon$inboundSchema } from "./mcpicon.js";
22
23
  import { McpToolNaming, McpToolNaming$inboundSchema } from "./mcptoolnaming.js";
23
24
  import { Sharing, Sharing$inboundSchema } from "./sharing.js";
24
25
 
@@ -73,6 +74,14 @@ export type McpGateway = {
73
74
  * Workspace skills this gateway serves to MCP clients through the MCP Skills extension.
74
75
  */
75
76
  skillIds?: Array<string> | undefined;
77
+ /**
78
+ * Icons advertised to MCP clients; defaults to ORQ branding when empty.
79
+ */
80
+ icons?: Array<McpIcon> | undefined;
81
+ /**
82
+ * Website advertised to MCP clients; defaults to ORQ documentation when empty.
83
+ */
84
+ websiteUrl?: string | undefined;
76
85
  };
77
86
 
78
87
  /** @internal */
@@ -95,6 +104,8 @@ export const McpGateway$inboundSchema: z.ZodType<
95
104
  sharing: Sharing$inboundSchema.optional(),
96
105
  plugins: z.array(McpGatewayPlugin$inboundSchema).optional(),
97
106
  skill_ids: z.array(z.string()).optional(),
107
+ icons: z.array(McpIcon$inboundSchema).optional(),
108
+ website_url: z.string().optional(),
98
109
  }).transform((v) => {
99
110
  return remap$(v, {
100
111
  "display_name": "displayName",
@@ -103,6 +114,7 @@ export const McpGateway$inboundSchema: z.ZodType<
103
114
  "public_url": "publicUrl",
104
115
  "exposed_tools_count": "exposedToolsCount",
105
116
  "skill_ids": "skillIds",
117
+ "website_url": "websiteUrl",
106
118
  });
107
119
  });
108
120
 
@@ -7,6 +7,7 @@ import { remap as remap$ } from "../../lib/primitives.js";
7
7
  import { safeParse } from "../../lib/schemas.js";
8
8
  import { Result as SafeParseResult } from "../../types/fp.js";
9
9
  import { SDKValidationError } from "../errors/sdkvalidationerror.js";
10
+ import { McpIcon, McpIcon$inboundSchema } from "./mcpicon.js";
10
11
  import {
11
12
  McpToolAnnotations,
12
13
  McpToolAnnotations$inboundSchema,
@@ -54,6 +55,10 @@ export type McpGatewayTool = {
54
55
  * Behaviour hints claimed by the upstream server.
55
56
  */
56
57
  annotations?: McpToolAnnotations | undefined;
58
+ /**
59
+ * Icons advertised by the upstream tool.
60
+ */
61
+ icons?: Array<McpIcon> | undefined;
57
62
  };
58
63
 
59
64
  /** @internal */
@@ -88,6 +93,7 @@ export const McpGatewayTool$inboundSchema: z.ZodType<
88
93
  upstream_tool_name: z.string().optional(),
89
94
  title: z.string().optional(),
90
95
  annotations: McpToolAnnotations$inboundSchema.optional(),
96
+ icons: z.array(McpIcon$inboundSchema).optional(),
91
97
  }).transform((v) => {
92
98
  return remap$(v, {
93
99
  "server_key": "serverKey",
@@ -0,0 +1,77 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod/v3";
6
+ import { remap as remap$ } from "../../lib/primitives.js";
7
+ import { safeParse } from "../../lib/schemas.js";
8
+ import { Result as SafeParseResult } from "../../types/fp.js";
9
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
10
+
11
+ export type McpIcon = {
12
+ /**
13
+ * Icon URI, including HTTPS URLs and base64 data URIs.
14
+ */
15
+ src?: string | undefined;
16
+ /**
17
+ * Optional MIME type override.
18
+ */
19
+ mimeType?: string | undefined;
20
+ /**
21
+ * Supported sizes such as "48x48" or "any".
22
+ */
23
+ sizes?: Array<string> | undefined;
24
+ /**
25
+ * Optional background theme this icon was designed for.
26
+ */
27
+ theme?: string | undefined;
28
+ };
29
+
30
+ /** @internal */
31
+ export const McpIcon$inboundSchema: z.ZodType<McpIcon, z.ZodTypeDef, unknown> =
32
+ z.object({
33
+ src: z.string().optional(),
34
+ mime_type: z.string().optional(),
35
+ sizes: z.array(z.string()).optional(),
36
+ theme: z.string().optional(),
37
+ }).transform((v) => {
38
+ return remap$(v, {
39
+ "mime_type": "mimeType",
40
+ });
41
+ });
42
+ /** @internal */
43
+ export type McpIcon$Outbound = {
44
+ src?: string | undefined;
45
+ mime_type?: string | undefined;
46
+ sizes?: Array<string> | undefined;
47
+ theme?: string | undefined;
48
+ };
49
+
50
+ /** @internal */
51
+ export const McpIcon$outboundSchema: z.ZodType<
52
+ McpIcon$Outbound,
53
+ z.ZodTypeDef,
54
+ McpIcon
55
+ > = z.object({
56
+ src: z.string().optional(),
57
+ mimeType: z.string().optional(),
58
+ sizes: z.array(z.string()).optional(),
59
+ theme: z.string().optional(),
60
+ }).transform((v) => {
61
+ return remap$(v, {
62
+ mimeType: "mime_type",
63
+ });
64
+ });
65
+
66
+ export function mcpIconToJSON(mcpIcon: McpIcon): string {
67
+ return JSON.stringify(McpIcon$outboundSchema.parse(mcpIcon));
68
+ }
69
+ export function mcpIconFromJSON(
70
+ jsonString: string,
71
+ ): SafeParseResult<McpIcon, SDKValidationError> {
72
+ return safeParse(
73
+ jsonString,
74
+ (x) => McpIcon$inboundSchema.parse(JSON.parse(x)),
75
+ `Failed to parse 'McpIcon' from JSON`,
76
+ );
77
+ }
@@ -0,0 +1,54 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod/v3";
6
+ import { remap as remap$ } from "../../lib/primitives.js";
7
+ import { safeParse } from "../../lib/schemas.js";
8
+ import { Result as SafeParseResult } from "../../types/fp.js";
9
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
10
+
11
+ export type McpOpenApiConfig = {
12
+ /**
13
+ * URL the document is fetched from; `:sync` fetches it again.
14
+ */
15
+ documentUrl?: string | undefined;
16
+ /**
17
+ * Tool names of the operations to expose; empty exposes every operation.
18
+ */
19
+ operations?: Array<string> | undefined;
20
+ /**
21
+ * `info.title` of the compiled document.
22
+ */
23
+ title?: string | undefined;
24
+ /**
25
+ * `info.version` of the compiled document.
26
+ */
27
+ version?: string | undefined;
28
+ };
29
+
30
+ /** @internal */
31
+ export const McpOpenApiConfig$inboundSchema: z.ZodType<
32
+ McpOpenApiConfig,
33
+ z.ZodTypeDef,
34
+ unknown
35
+ > = z.object({
36
+ document_url: z.string().optional(),
37
+ operations: z.array(z.string()).optional(),
38
+ title: z.string().optional(),
39
+ version: z.string().optional(),
40
+ }).transform((v) => {
41
+ return remap$(v, {
42
+ "document_url": "documentUrl",
43
+ });
44
+ });
45
+
46
+ export function mcpOpenApiConfigFromJSON(
47
+ jsonString: string,
48
+ ): SafeParseResult<McpOpenApiConfig, SDKValidationError> {
49
+ return safeParse(
50
+ jsonString,
51
+ (x) => McpOpenApiConfig$inboundSchema.parse(JSON.parse(x)),
52
+ `Failed to parse 'McpOpenApiConfig' from JSON`,
53
+ );
54
+ }
@@ -0,0 +1,51 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod/v3";
6
+ import { remap as remap$ } from "../../lib/primitives.js";
7
+
8
+ export type McpOpenApiConfigInput = {
9
+ /**
10
+ * OpenAPI 3.x document as JSON or YAML; accepted on write and never stored or returned.
11
+ */
12
+ document?: string | undefined;
13
+ /**
14
+ * URL the document is fetched from; `:sync` fetches it again.
15
+ */
16
+ documentUrl?: string | undefined;
17
+ /**
18
+ * Tool names of the operations to expose; empty exposes every operation.
19
+ */
20
+ operations?: Array<string> | undefined;
21
+ };
22
+
23
+ /** @internal */
24
+ export type McpOpenApiConfigInput$Outbound = {
25
+ document?: string | undefined;
26
+ document_url?: string | undefined;
27
+ operations?: Array<string> | undefined;
28
+ };
29
+
30
+ /** @internal */
31
+ export const McpOpenApiConfigInput$outboundSchema: z.ZodType<
32
+ McpOpenApiConfigInput$Outbound,
33
+ z.ZodTypeDef,
34
+ McpOpenApiConfigInput
35
+ > = z.object({
36
+ document: z.string().optional(),
37
+ documentUrl: z.string().optional(),
38
+ operations: z.array(z.string()).optional(),
39
+ }).transform((v) => {
40
+ return remap$(v, {
41
+ documentUrl: "document_url",
42
+ });
43
+ });
44
+
45
+ export function mcpOpenApiConfigInputToJSON(
46
+ mcpOpenApiConfigInput: McpOpenApiConfigInput,
47
+ ): string {
48
+ return JSON.stringify(
49
+ McpOpenApiConfigInput$outboundSchema.parse(mcpOpenApiConfigInput),
50
+ );
51
+ }
@@ -12,6 +12,11 @@ import {
12
12
  McpAuthConfigOutput$inboundSchema,
13
13
  } from "./mcpauthconfigoutput.js";
14
14
  import { McpConnection, McpConnection$inboundSchema } from "./mcpconnection.js";
15
+ import { McpIcon, McpIcon$inboundSchema } from "./mcpicon.js";
16
+ import {
17
+ McpOpenApiConfig,
18
+ McpOpenApiConfig$inboundSchema,
19
+ } from "./mcpopenapiconfig.js";
15
20
  import { McpSkill, McpSkill$inboundSchema } from "./mcpskill.js";
16
21
  import { McpSyncState, McpSyncState$inboundSchema } from "./mcpsyncstate.js";
17
22
  import { McpTool, McpTool$inboundSchema } from "./mcptool.js";
@@ -78,6 +83,18 @@ export type McpServer = {
78
83
  * Skills the upstream publishes through the MCP Skills extension, discovered by the last successful `:sync`.
79
84
  */
80
85
  skills?: Array<McpSkill> | undefined;
86
+ /**
87
+ * Source of the tools of an `MCP_CONNECTION_TYPE_OPENAPI` server.
88
+ */
89
+ openapi?: McpOpenApiConfig | undefined;
90
+ /**
91
+ * Icons advertised by the upstream server during discovery.
92
+ */
93
+ icons?: Array<McpIcon> | undefined;
94
+ /**
95
+ * Website advertised by the upstream server during discovery.
96
+ */
97
+ websiteUrl?: string | undefined;
81
98
  };
82
99
 
83
100
  /** @internal */
@@ -100,12 +117,16 @@ export const McpServer$inboundSchema: z.ZodType<
100
117
  sharing: Sharing$inboundSchema.optional(),
101
118
  created_by_id: z.string().optional(),
102
119
  skills: z.array(McpSkill$inboundSchema).optional(),
120
+ openapi: McpOpenApiConfig$inboundSchema.optional(),
121
+ icons: z.array(McpIcon$inboundSchema).optional(),
122
+ website_url: z.string().optional(),
103
123
  }).transform((v) => {
104
124
  return remap$(v, {
105
125
  "display_name": "displayName",
106
126
  "default_tool_exposure": "defaultToolExposure",
107
127
  "sync_state": "syncState",
108
128
  "created_by_id": "createdById",
129
+ "website_url": "websiteUrl",
109
130
  });
110
131
  });
111
132
 
@@ -7,6 +7,7 @@ import { remap as remap$ } from "../../lib/primitives.js";
7
7
  import { safeParse } from "../../lib/schemas.js";
8
8
  import { Result as SafeParseResult } from "../../types/fp.js";
9
9
  import { SDKValidationError } from "../errors/sdkvalidationerror.js";
10
+ import { McpIcon, McpIcon$inboundSchema } from "./mcpicon.js";
10
11
  import {
11
12
  McpToolAnnotations,
12
13
  McpToolAnnotations$inboundSchema,
@@ -17,6 +18,20 @@ import {
17
18
  */
18
19
  export type McpToolInputSchema = {};
19
20
 
21
+ /**
22
+ * OpenAPI operation the tool calls, for `MCP_CONNECTION_TYPE_OPENAPI` servers.
23
+ */
24
+ export type HttpOperation = {
25
+ /**
26
+ * HTTP method, upper case.
27
+ */
28
+ method?: string | undefined;
29
+ /**
30
+ * Path template relative to the server base URL.
31
+ */
32
+ path?: string | undefined;
33
+ };
34
+
20
35
  export type McpTool = {
21
36
  /**
22
37
  * Bare tool name as advertised by the upstream server.
@@ -46,6 +61,14 @@ export type McpTool = {
46
61
  * Behaviour hints claimed by the upstream server.
47
62
  */
48
63
  annotations?: McpToolAnnotations | undefined;
64
+ /**
65
+ * OpenAPI operation the tool calls, for `MCP_CONNECTION_TYPE_OPENAPI` servers.
66
+ */
67
+ httpOperation?: HttpOperation | undefined;
68
+ /**
69
+ * Icons advertised by the upstream tool.
70
+ */
71
+ icons?: Array<McpIcon> | undefined;
49
72
  };
50
73
 
51
74
  /** @internal */
@@ -65,6 +88,26 @@ export function mcpToolInputSchemaFromJSON(
65
88
  );
66
89
  }
67
90
 
91
+ /** @internal */
92
+ export const HttpOperation$inboundSchema: z.ZodType<
93
+ HttpOperation,
94
+ z.ZodTypeDef,
95
+ unknown
96
+ > = z.object({
97
+ method: z.string().optional(),
98
+ path: z.string().optional(),
99
+ });
100
+
101
+ export function httpOperationFromJSON(
102
+ jsonString: string,
103
+ ): SafeParseResult<HttpOperation, SDKValidationError> {
104
+ return safeParse(
105
+ jsonString,
106
+ (x) => HttpOperation$inboundSchema.parse(JSON.parse(x)),
107
+ `Failed to parse 'HttpOperation' from JSON`,
108
+ );
109
+ }
110
+
68
111
  /** @internal */
69
112
  export const McpTool$inboundSchema: z.ZodType<McpTool, z.ZodTypeDef, unknown> =
70
113
  z.object({
@@ -75,9 +118,12 @@ export const McpTool$inboundSchema: z.ZodType<McpTool, z.ZodTypeDef, unknown> =
75
118
  id: z.string().optional(),
76
119
  title: z.string().optional(),
77
120
  annotations: McpToolAnnotations$inboundSchema.optional(),
121
+ http_operation: z.lazy(() => HttpOperation$inboundSchema).optional(),
122
+ icons: z.array(McpIcon$inboundSchema).optional(),
78
123
  }).transform((v) => {
79
124
  return remap$(v, {
80
125
  "input_schema": "inputSchema",
126
+ "http_operation": "httpOperation",
81
127
  });
82
128
  });
83
129