@orq-ai/node 4.7.5 → 4.7.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 (189) hide show
  1. package/funcs/filesCreate.js +3 -2
  2. package/funcs/filesCreate.js.map +1 -1
  3. package/funcs/routerAudioTranscriptionsCreate.js +3 -2
  4. package/funcs/routerAudioTranscriptionsCreate.js.map +1 -1
  5. package/funcs/routerAudioTranslationsCreate.js +3 -2
  6. package/funcs/routerAudioTranslationsCreate.js.map +1 -1
  7. package/jsr.json +1 -1
  8. package/lib/config.d.ts +3 -3
  9. package/lib/config.js +3 -3
  10. package/lib/config.js.map +1 -1
  11. package/lib/encodings.d.ts +1 -0
  12. package/lib/encodings.d.ts.map +1 -1
  13. package/lib/encodings.js +7 -0
  14. package/lib/encodings.js.map +1 -1
  15. package/models/components/reasoningpart.js +1 -1
  16. package/models/operations/createcontact.js +1 -1
  17. package/models/operations/createdataset.js +1 -1
  18. package/models/operations/createdatasetitem.js +4 -4
  19. package/models/operations/createdatasource.js +1 -1
  20. package/models/operations/createeval.js +16 -16
  21. package/models/operations/createidentity.js +1 -1
  22. package/models/operations/createtool.js +6 -6
  23. package/models/operations/getalltools.js +6 -6
  24. package/models/operations/getevals.js +16 -16
  25. package/models/operations/getv2humanevals.js +6 -6
  26. package/models/operations/getv2humanevalsets.js +2 -2
  27. package/models/operations/getv2humanevalsetsid.js +2 -2
  28. package/models/operations/getv2humanevalsid.js +6 -6
  29. package/models/operations/listdatasetdatapoints.js +4 -4
  30. package/models/operations/listdatasets.js +1 -1
  31. package/models/operations/listdatasources.js +1 -1
  32. package/models/operations/listidentities.js +1 -1
  33. package/models/operations/patchv2humanevalsetsid.js +2 -2
  34. package/models/operations/patchv2humanevalsid.js +12 -12
  35. package/models/operations/postv2feedbackevaluation.js +3 -3
  36. package/models/operations/postv2humanevals.js +12 -12
  37. package/models/operations/postv2humanevalsets.js +2 -2
  38. package/models/operations/retrievedatapoint.js +4 -4
  39. package/models/operations/retrievedataset.js +1 -1
  40. package/models/operations/retrievedatasource.js +1 -1
  41. package/models/operations/retrieveidentity.js +1 -1
  42. package/models/operations/retrievetool.js +6 -6
  43. package/models/operations/runagent.js +1 -1
  44. package/models/operations/streamrunagent.js +1 -1
  45. package/models/operations/updatedatapoint.js +4 -4
  46. package/models/operations/updatedataset.js +1 -1
  47. package/models/operations/updatedatasource.js +1 -1
  48. package/models/operations/updateeval.js +16 -16
  49. package/models/operations/updateidentity.js +1 -1
  50. package/models/operations/updatetool.js +7 -7
  51. package/package.json +1 -1
  52. package/packages/orq-rc/src/funcs/agentsCreate.ts +2 -2
  53. package/packages/orq-rc/src/funcs/filesCreate.ts +4 -3
  54. package/packages/orq-rc/src/funcs/guardrailRulesCreate.ts +161 -0
  55. package/packages/orq-rc/src/funcs/guardrailRulesDelete.ts +170 -0
  56. package/packages/orq-rc/src/funcs/guardrailRulesGet.ts +168 -0
  57. package/packages/orq-rc/src/funcs/guardrailRulesList.ts +170 -0
  58. package/packages/orq-rc/src/funcs/guardrailRulesUpdate.ts +170 -0
  59. package/packages/orq-rc/src/funcs/policiesCreate.ts +160 -0
  60. package/packages/orq-rc/src/funcs/policiesDelete.ts +166 -0
  61. package/packages/orq-rc/src/funcs/policiesGet.ts +165 -0
  62. package/packages/orq-rc/src/funcs/policiesList.ts +168 -0
  63. package/packages/orq-rc/src/funcs/policiesUpdate.ts +166 -0
  64. package/packages/orq-rc/src/funcs/routerAudioTranscriptionsCreate.ts +4 -3
  65. package/packages/orq-rc/src/funcs/routerAudioTranslationsCreate.ts +4 -3
  66. package/packages/orq-rc/src/funcs/routingRulesCreate.ts +161 -0
  67. package/packages/orq-rc/src/funcs/routingRulesDelete.ts +166 -0
  68. package/packages/orq-rc/src/funcs/routingRulesGet.ts +165 -0
  69. package/packages/orq-rc/src/funcs/routingRulesList.ts +168 -0
  70. package/packages/orq-rc/src/funcs/routingRulesUpdate.ts +166 -0
  71. package/packages/orq-rc/src/lib/config.ts +3 -3
  72. package/packages/orq-rc/src/lib/encodings.ts +9 -0
  73. package/packages/orq-rc/src/models/components/agentstartedstreamingevent.ts +9 -6
  74. package/packages/orq-rc/src/models/components/budgetlimit.ts +83 -0
  75. package/packages/orq-rc/src/models/components/evaluatorref.ts +89 -0
  76. package/packages/orq-rc/src/models/components/expression.ts +51 -0
  77. package/packages/orq-rc/src/models/components/guardrailref.ts +75 -0
  78. package/packages/orq-rc/src/models/components/guardrailruledocument.ts +66 -0
  79. package/packages/orq-rc/src/models/components/index.ts +13 -0
  80. package/packages/orq-rc/src/models/components/limits.ts +70 -0
  81. package/packages/orq-rc/src/models/components/modelref.ts +64 -0
  82. package/packages/orq-rc/src/models/components/modelsconfig.ts +73 -0
  83. package/packages/orq-rc/src/models/components/policydocument.ts +76 -0
  84. package/packages/orq-rc/src/models/components/reasoningpart.ts +1 -1
  85. package/packages/orq-rc/src/models/components/requestlimit.ts +69 -0
  86. package/packages/orq-rc/src/models/components/retryconfig.ts +60 -0
  87. package/packages/orq-rc/src/models/components/routingruledocument.ts +67 -0
  88. package/packages/orq-rc/src/models/components/tokenlimit.ts +69 -0
  89. package/packages/orq-rc/src/models/operations/createagentrequest.ts +0 -3
  90. package/packages/orq-rc/src/models/operations/createcontact.ts +1 -1
  91. package/packages/orq-rc/src/models/operations/createdataset.ts +1 -1
  92. package/packages/orq-rc/src/models/operations/createdatasetitem.ts +4 -4
  93. package/packages/orq-rc/src/models/operations/createdatasource.ts +1 -1
  94. package/packages/orq-rc/src/models/operations/createeval.ts +958 -132
  95. package/packages/orq-rc/src/models/operations/createidentity.ts +1 -1
  96. package/packages/orq-rc/src/models/operations/createtool.ts +6 -21
  97. package/packages/orq-rc/src/models/operations/getalltools.ts +6 -21
  98. package/packages/orq-rc/src/models/operations/getevals.ts +447 -16
  99. package/packages/orq-rc/src/models/operations/getv2humanevals.ts +6 -6
  100. package/packages/orq-rc/src/models/operations/getv2humanevalsets.ts +2 -2
  101. package/packages/orq-rc/src/models/operations/getv2humanevalsetsid.ts +2 -2
  102. package/packages/orq-rc/src/models/operations/getv2humanevalsid.ts +6 -6
  103. package/packages/orq-rc/src/models/operations/guardrailrulecreate.ts +124 -0
  104. package/packages/orq-rc/src/models/operations/guardrailruledelete.ts +39 -0
  105. package/packages/orq-rc/src/models/operations/guardrailruleget.ts +102 -0
  106. package/packages/orq-rc/src/models/operations/guardrailrulelist.ts +94 -0
  107. package/packages/orq-rc/src/models/operations/guardrailruleupdate.ts +153 -0
  108. package/packages/orq-rc/src/models/operations/index.ts +15 -0
  109. package/packages/orq-rc/src/models/operations/listagents.ts +0 -3
  110. package/packages/orq-rc/src/models/operations/listdatasetdatapoints.ts +4 -4
  111. package/packages/orq-rc/src/models/operations/listdatasets.ts +1 -1
  112. package/packages/orq-rc/src/models/operations/listdatasources.ts +1 -1
  113. package/packages/orq-rc/src/models/operations/listidentities.ts +1 -1
  114. package/packages/orq-rc/src/models/operations/patchv2humanevalsetsid.ts +2 -2
  115. package/packages/orq-rc/src/models/operations/patchv2humanevalsid.ts +12 -12
  116. package/packages/orq-rc/src/models/operations/policycreate.ts +138 -0
  117. package/packages/orq-rc/src/models/operations/policydelete.ts +39 -0
  118. package/packages/orq-rc/src/models/operations/policyget.ts +110 -0
  119. package/packages/orq-rc/src/models/operations/policylist.ts +94 -0
  120. package/packages/orq-rc/src/models/operations/policyupdate.ts +167 -0
  121. package/packages/orq-rc/src/models/operations/postv2agentsa2a.ts +0 -3
  122. package/packages/orq-rc/src/models/operations/postv2feedbackevaluation.ts +3 -3
  123. package/packages/orq-rc/src/models/operations/postv2humanevals.ts +12 -12
  124. package/packages/orq-rc/src/models/operations/postv2humanevalsets.ts +2 -2
  125. package/packages/orq-rc/src/models/operations/retrieveagentrequest.ts +0 -3
  126. package/packages/orq-rc/src/models/operations/retrievedatapoint.ts +4 -4
  127. package/packages/orq-rc/src/models/operations/retrievedataset.ts +1 -1
  128. package/packages/orq-rc/src/models/operations/retrievedatasource.ts +1 -1
  129. package/packages/orq-rc/src/models/operations/retrieveidentity.ts +1 -1
  130. package/packages/orq-rc/src/models/operations/retrievetool.ts +6 -21
  131. package/packages/orq-rc/src/models/operations/routingrulecreate.ts +124 -0
  132. package/packages/orq-rc/src/models/operations/routingruledelete.ts +39 -0
  133. package/packages/orq-rc/src/models/operations/routingruleget.ts +102 -0
  134. package/packages/orq-rc/src/models/operations/routingrulelist.ts +94 -0
  135. package/packages/orq-rc/src/models/operations/routingruleupdate.ts +154 -0
  136. package/packages/orq-rc/src/models/operations/runagent.ts +1 -1
  137. package/packages/orq-rc/src/models/operations/streamrunagent.ts +1 -1
  138. package/packages/orq-rc/src/models/operations/updateagent.ts +0 -3
  139. package/packages/orq-rc/src/models/operations/updatedatapoint.ts +4 -4
  140. package/packages/orq-rc/src/models/operations/updatedataset.ts +1 -1
  141. package/packages/orq-rc/src/models/operations/updatedatasource.ts +1 -1
  142. package/packages/orq-rc/src/models/operations/updateeval.ts +646 -16
  143. package/packages/orq-rc/src/models/operations/updateidentity.ts +1 -1
  144. package/packages/orq-rc/src/models/operations/updatetool.ts +7 -22
  145. package/packages/orq-rc/src/sdk/guardrailrules.ts +99 -0
  146. package/packages/orq-rc/src/sdk/policies.ts +99 -0
  147. package/packages/orq-rc/src/sdk/routingrules.ts +99 -0
  148. package/packages/orq-rc/src/sdk/sdk.ts +18 -0
  149. package/src/funcs/filesCreate.ts +4 -3
  150. package/src/funcs/routerAudioTranscriptionsCreate.ts +4 -3
  151. package/src/funcs/routerAudioTranslationsCreate.ts +4 -3
  152. package/src/lib/config.ts +3 -3
  153. package/src/lib/encodings.ts +9 -0
  154. package/src/models/components/reasoningpart.ts +1 -1
  155. package/src/models/operations/createcontact.ts +1 -1
  156. package/src/models/operations/createdataset.ts +1 -1
  157. package/src/models/operations/createdatasetitem.ts +4 -4
  158. package/src/models/operations/createdatasource.ts +1 -1
  159. package/src/models/operations/createeval.ts +16 -16
  160. package/src/models/operations/createidentity.ts +1 -1
  161. package/src/models/operations/createtool.ts +6 -6
  162. package/src/models/operations/getalltools.ts +6 -6
  163. package/src/models/operations/getevals.ts +16 -16
  164. package/src/models/operations/getv2humanevals.ts +6 -6
  165. package/src/models/operations/getv2humanevalsets.ts +2 -2
  166. package/src/models/operations/getv2humanevalsetsid.ts +2 -2
  167. package/src/models/operations/getv2humanevalsid.ts +6 -6
  168. package/src/models/operations/listdatasetdatapoints.ts +4 -4
  169. package/src/models/operations/listdatasets.ts +1 -1
  170. package/src/models/operations/listdatasources.ts +1 -1
  171. package/src/models/operations/listidentities.ts +1 -1
  172. package/src/models/operations/patchv2humanevalsetsid.ts +2 -2
  173. package/src/models/operations/patchv2humanevalsid.ts +12 -12
  174. package/src/models/operations/postv2feedbackevaluation.ts +3 -3
  175. package/src/models/operations/postv2humanevals.ts +12 -12
  176. package/src/models/operations/postv2humanevalsets.ts +2 -2
  177. package/src/models/operations/retrievedatapoint.ts +4 -4
  178. package/src/models/operations/retrievedataset.ts +1 -1
  179. package/src/models/operations/retrievedatasource.ts +1 -1
  180. package/src/models/operations/retrieveidentity.ts +1 -1
  181. package/src/models/operations/retrievetool.ts +6 -6
  182. package/src/models/operations/runagent.ts +1 -1
  183. package/src/models/operations/streamrunagent.ts +1 -1
  184. package/src/models/operations/updatedatapoint.ts +4 -4
  185. package/src/models/operations/updatedataset.ts +1 -1
  186. package/src/models/operations/updatedatasource.ts +1 -1
  187. package/src/models/operations/updateeval.ts +16 -16
  188. package/src/models/operations/updateidentity.ts +1 -1
  189. package/src/models/operations/updatetool.ts +7 -7
@@ -167,7 +167,7 @@ export const UpdateIdentityResponseBody$inboundSchema: z.ZodType<
167
167
  created: z.string().datetime({ offset: true }).transform(v => new Date(v))
168
168
  .optional(),
169
169
  updated: z.string().datetime({ offset: true }).default(
170
- "2026-04-09T16:36:01.331Z",
170
+ "2026-04-14T08:16:52.325Z",
171
171
  ).transform(v => new Date(v)),
172
172
  }).transform((v) => {
173
173
  return remap$(v, {
@@ -749,7 +749,6 @@ export type UpdateToolResponseBodyCodeExecutionTool = {
749
749
  * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
750
750
  */
751
751
  status: UpdateToolResponseBodyToolsResponse200ApplicationJSONStatus;
752
- versionHash?: string | undefined;
753
752
  type: "code";
754
753
  codeTool: UpdateToolResponseBodyCodeTool;
755
754
  };
@@ -874,7 +873,6 @@ export type UpdateToolResponseBodyMCPTool = {
874
873
  * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
875
874
  */
876
875
  status: UpdateToolResponseBodyToolsResponse200Status;
877
- versionHash?: string | undefined;
878
876
  type: "mcp";
879
877
  mcp: UpdateToolResponseBodyMcp;
880
878
  };
@@ -1034,7 +1032,6 @@ export type UpdateToolResponseBodyHTTPTool = {
1034
1032
  * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
1035
1033
  */
1036
1034
  status: UpdateToolResponseBodyToolsResponseStatus;
1037
- versionHash?: string | undefined;
1038
1035
  type: "http";
1039
1036
  http: UpdateToolResponseBodyHttp;
1040
1037
  };
@@ -1136,7 +1133,6 @@ export type UpdateToolResponseBodyJSONSchemaTool = {
1136
1133
  * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
1137
1134
  */
1138
1135
  status: UpdateToolResponseBodyToolsStatus;
1139
- versionHash?: string | undefined;
1140
1136
  type: "json_schema";
1141
1137
  jsonSchema: UpdateToolResponseBodyJsonSchema;
1142
1138
  };
@@ -1250,7 +1246,6 @@ export type UpdateToolResponseBodyFunctionTool = {
1250
1246
  * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
1251
1247
  */
1252
1248
  status: UpdateToolResponseBodyStatus;
1253
- versionHash?: string | undefined;
1254
1249
  type: "function";
1255
1250
  function: UpdateToolResponseBodyFunction;
1256
1251
  };
@@ -1477,7 +1472,7 @@ export const RequestBodyTools$outboundSchema: z.ZodType<
1477
1472
  z.ZodTypeDef,
1478
1473
  RequestBodyTools
1479
1474
  > = z.object({
1480
- id: z.string().default("01KNSHM13FAM1HHM1YQFA48EN3"),
1475
+ id: z.string().default("01KP5H1MMR9E1DVX93BX5C9YP2"),
1481
1476
  name: z.string(),
1482
1477
  description: z.string().optional(),
1483
1478
  schema: z.lazy(() => UpdateToolRequestBodyToolsSchema$outboundSchema),
@@ -2198,7 +2193,7 @@ export const UpdateToolResponseBodyCodeExecutionTool$inboundSchema: z.ZodType<
2198
2193
  z.ZodTypeDef,
2199
2194
  unknown
2200
2195
  > = z.object({
2201
- _id: z.string().default("tool_01KNSHM13AEW47GSX2AMAK0DH1"),
2196
+ _id: z.string().default("tool_01KP5H1MMHXTJP46A0EFEKWH3R"),
2202
2197
  path: z.string(),
2203
2198
  key: z.string(),
2204
2199
  display_name: z.string().optional(),
@@ -2212,7 +2207,6 @@ export const UpdateToolResponseBodyCodeExecutionTool$inboundSchema: z.ZodType<
2212
2207
  status:
2213
2208
  UpdateToolResponseBodyToolsResponse200ApplicationJSONStatus$inboundSchema
2214
2209
  .default("live"),
2215
- version_hash: z.string().optional(),
2216
2210
  type: z.literal("code"),
2217
2211
  code_tool: z.lazy(() => UpdateToolResponseBodyCodeTool$inboundSchema),
2218
2212
  }).transform((v) => {
@@ -2223,7 +2217,6 @@ export const UpdateToolResponseBodyCodeExecutionTool$inboundSchema: z.ZodType<
2223
2217
  "updated_by_id": "updatedById",
2224
2218
  "project_id": "projectId",
2225
2219
  "workspace_id": "workspaceId",
2226
- "version_hash": "versionHash",
2227
2220
  "code_tool": "codeTool",
2228
2221
  });
2229
2222
  });
@@ -2303,7 +2296,7 @@ export const UpdateToolResponseBodyTools$inboundSchema: z.ZodType<
2303
2296
  z.ZodTypeDef,
2304
2297
  unknown
2305
2298
  > = z.object({
2306
- id: z.string().default("01KNSHM13A5739N85K40G9AW86"),
2299
+ id: z.string().default("01KP5H1MMA4B9H3DCS7YQHT16G"),
2307
2300
  name: z.string(),
2308
2301
  description: z.string().optional(),
2309
2302
  schema: z.lazy(() => UpdateToolResponseBodyToolsSchema$inboundSchema),
@@ -2361,7 +2354,7 @@ export const UpdateToolResponseBodyMCPTool$inboundSchema: z.ZodType<
2361
2354
  z.ZodTypeDef,
2362
2355
  unknown
2363
2356
  > = z.object({
2364
- _id: z.string().default("tool_01KNSHM139BHMFG4B3XKV0MMW6"),
2357
+ _id: z.string().default("tool_01KP5H1MM9YEX1DE9ZRJEDTXTS"),
2365
2358
  path: z.string(),
2366
2359
  key: z.string(),
2367
2360
  display_name: z.string().optional(),
@@ -2375,7 +2368,6 @@ export const UpdateToolResponseBodyMCPTool$inboundSchema: z.ZodType<
2375
2368
  status: UpdateToolResponseBodyToolsResponse200Status$inboundSchema.default(
2376
2369
  "live",
2377
2370
  ),
2378
- version_hash: z.string().optional(),
2379
2371
  type: z.literal("mcp"),
2380
2372
  mcp: z.lazy(() => UpdateToolResponseBodyMcp$inboundSchema),
2381
2373
  }).transform((v) => {
@@ -2386,7 +2378,6 @@ export const UpdateToolResponseBodyMCPTool$inboundSchema: z.ZodType<
2386
2378
  "updated_by_id": "updatedById",
2387
2379
  "project_id": "projectId",
2388
2380
  "workspace_id": "workspaceId",
2389
- "version_hash": "versionHash",
2390
2381
  });
2391
2382
  });
2392
2383
 
@@ -2552,7 +2543,7 @@ export const UpdateToolResponseBodyHTTPTool$inboundSchema: z.ZodType<
2552
2543
  z.ZodTypeDef,
2553
2544
  unknown
2554
2545
  > = z.object({
2555
- _id: z.string().default("tool_01KNSHM137MV1K6FK5C76T64YW"),
2546
+ _id: z.string().default("tool_01KP5H1MM7ZNESEW8CBVNHF60Y"),
2556
2547
  path: z.string(),
2557
2548
  key: z.string(),
2558
2549
  display_name: z.string().optional(),
@@ -2566,7 +2557,6 @@ export const UpdateToolResponseBodyHTTPTool$inboundSchema: z.ZodType<
2566
2557
  status: UpdateToolResponseBodyToolsResponseStatus$inboundSchema.default(
2567
2558
  "live",
2568
2559
  ),
2569
- version_hash: z.string().optional(),
2570
2560
  type: z.literal("http"),
2571
2561
  http: z.lazy(() => UpdateToolResponseBodyHttp$inboundSchema),
2572
2562
  }).transform((v) => {
@@ -2577,7 +2567,6 @@ export const UpdateToolResponseBodyHTTPTool$inboundSchema: z.ZodType<
2577
2567
  "updated_by_id": "updatedById",
2578
2568
  "project_id": "projectId",
2579
2569
  "workspace_id": "workspaceId",
2580
- "version_hash": "versionHash",
2581
2570
  });
2582
2571
  });
2583
2572
 
@@ -2649,7 +2638,7 @@ export const UpdateToolResponseBodyJSONSchemaTool$inboundSchema: z.ZodType<
2649
2638
  z.ZodTypeDef,
2650
2639
  unknown
2651
2640
  > = z.object({
2652
- _id: z.string().default("tool_01KNSHM1361PVZCWZ592QHC3H1"),
2641
+ _id: z.string().default("tool_01KP5H1MM6K733C7D93HE4EB4A"),
2653
2642
  path: z.string(),
2654
2643
  key: z.string(),
2655
2644
  display_name: z.string().optional(),
@@ -2661,7 +2650,6 @@ export const UpdateToolResponseBodyJSONSchemaTool$inboundSchema: z.ZodType<
2661
2650
  created: z.string(),
2662
2651
  updated: z.string(),
2663
2652
  status: UpdateToolResponseBodyToolsStatus$inboundSchema.default("live"),
2664
- version_hash: z.string().optional(),
2665
2653
  type: z.literal("json_schema"),
2666
2654
  json_schema: z.lazy(() => UpdateToolResponseBodyJsonSchema$inboundSchema),
2667
2655
  }).transform((v) => {
@@ -2672,7 +2660,6 @@ export const UpdateToolResponseBodyJSONSchemaTool$inboundSchema: z.ZodType<
2672
2660
  "updated_by_id": "updatedById",
2673
2661
  "project_id": "projectId",
2674
2662
  "workspace_id": "workspaceId",
2675
- "version_hash": "versionHash",
2676
2663
  "json_schema": "jsonSchema",
2677
2664
  });
2678
2665
  });
@@ -2754,7 +2741,7 @@ export const UpdateToolResponseBodyFunctionTool$inboundSchema: z.ZodType<
2754
2741
  z.ZodTypeDef,
2755
2742
  unknown
2756
2743
  > = z.object({
2757
- _id: z.string().default("tool_01KNSHM135F52B3DCGWHTDBS3G"),
2744
+ _id: z.string().default("tool_01KP5H1MM54F8CSJZV3T2QCN6K"),
2758
2745
  path: z.string(),
2759
2746
  key: z.string(),
2760
2747
  display_name: z.string().optional(),
@@ -2766,7 +2753,6 @@ export const UpdateToolResponseBodyFunctionTool$inboundSchema: z.ZodType<
2766
2753
  created: z.string(),
2767
2754
  updated: z.string(),
2768
2755
  status: UpdateToolResponseBodyStatus$inboundSchema.default("live"),
2769
- version_hash: z.string().optional(),
2770
2756
  type: z.literal("function"),
2771
2757
  function: z.lazy(() => UpdateToolResponseBodyFunction$inboundSchema),
2772
2758
  }).transform((v) => {
@@ -2777,7 +2763,6 @@ export const UpdateToolResponseBodyFunctionTool$inboundSchema: z.ZodType<
2777
2763
  "updated_by_id": "updatedById",
2778
2764
  "project_id": "projectId",
2779
2765
  "workspace_id": "workspaceId",
2780
- "version_hash": "versionHash",
2781
2766
  });
2782
2767
  });
2783
2768
 
@@ -0,0 +1,99 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import { guardrailRulesCreate } from "../funcs/guardrailRulesCreate.js";
6
+ import { guardrailRulesDelete } from "../funcs/guardrailRulesDelete.js";
7
+ import { guardrailRulesGet } from "../funcs/guardrailRulesGet.js";
8
+ import { guardrailRulesList } from "../funcs/guardrailRulesList.js";
9
+ import { guardrailRulesUpdate } from "../funcs/guardrailRulesUpdate.js";
10
+ import { ClientSDK, RequestOptions } from "../lib/sdks.js";
11
+ import * as operations from "../models/operations/index.js";
12
+ import { unwrapAsync } from "../types/fp.js";
13
+
14
+ export class GuardrailRules extends ClientSDK {
15
+ /**
16
+ * List guardrail rules
17
+ *
18
+ * @remarks
19
+ * Returns a paginated list of guardrail rules for the current project.
20
+ */
21
+ async list(
22
+ request?: operations.GuardrailRuleListRequest | undefined,
23
+ options?: RequestOptions,
24
+ ): Promise<operations.GuardrailRuleListResponseBody> {
25
+ return unwrapAsync(guardrailRulesList(
26
+ this,
27
+ request,
28
+ options,
29
+ ));
30
+ }
31
+
32
+ /**
33
+ * Create guardrail rule
34
+ *
35
+ * @remarks
36
+ * Creates a new guardrail rule with expression, guardrails configuration, and timeout settings.
37
+ */
38
+ async create(
39
+ request: operations.GuardrailRuleCreateRequestBody,
40
+ options?: RequestOptions,
41
+ ): Promise<operations.GuardrailRuleCreateResponseBody> {
42
+ return unwrapAsync(guardrailRulesCreate(
43
+ this,
44
+ request,
45
+ options,
46
+ ));
47
+ }
48
+
49
+ /**
50
+ * Delete guardrail rule
51
+ *
52
+ * @remarks
53
+ * Deletes an existing guardrail rule by ID.
54
+ */
55
+ async delete(
56
+ request: operations.GuardrailRuleDeleteRequest,
57
+ options?: RequestOptions,
58
+ ): Promise<void> {
59
+ return unwrapAsync(guardrailRulesDelete(
60
+ this,
61
+ request,
62
+ options,
63
+ ));
64
+ }
65
+
66
+ /**
67
+ * Get guardrail rule
68
+ *
69
+ * @remarks
70
+ * Retrieves the details of an existing guardrail rule by ID.
71
+ */
72
+ async get(
73
+ request: operations.GuardrailRuleGetRequest,
74
+ options?: RequestOptions,
75
+ ): Promise<operations.GuardrailRuleGetResponseBody> {
76
+ return unwrapAsync(guardrailRulesGet(
77
+ this,
78
+ request,
79
+ options,
80
+ ));
81
+ }
82
+
83
+ /**
84
+ * Update guardrail rule
85
+ *
86
+ * @remarks
87
+ * Partially updates an existing guardrail rule. Only provided fields are updated.
88
+ */
89
+ async update(
90
+ request: operations.GuardrailRuleUpdateRequest,
91
+ options?: RequestOptions,
92
+ ): Promise<operations.GuardrailRuleUpdateResponseBody> {
93
+ return unwrapAsync(guardrailRulesUpdate(
94
+ this,
95
+ request,
96
+ options,
97
+ ));
98
+ }
99
+ }
@@ -0,0 +1,99 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import { policiesCreate } from "../funcs/policiesCreate.js";
6
+ import { policiesDelete } from "../funcs/policiesDelete.js";
7
+ import { policiesGet } from "../funcs/policiesGet.js";
8
+ import { policiesList } from "../funcs/policiesList.js";
9
+ import { policiesUpdate } from "../funcs/policiesUpdate.js";
10
+ import { ClientSDK, RequestOptions } from "../lib/sdks.js";
11
+ import * as operations from "../models/operations/index.js";
12
+ import { unwrapAsync } from "../types/fp.js";
13
+
14
+ export class Policies extends ClientSDK {
15
+ /**
16
+ * List policies
17
+ *
18
+ * @remarks
19
+ * Returns a paginated list of policies for the current project.
20
+ */
21
+ async list(
22
+ request?: operations.PolicyListRequest | undefined,
23
+ options?: RequestOptions,
24
+ ): Promise<operations.PolicyListResponseBody> {
25
+ return unwrapAsync(policiesList(
26
+ this,
27
+ request,
28
+ options,
29
+ ));
30
+ }
31
+
32
+ /**
33
+ * Create policy
34
+ *
35
+ * @remarks
36
+ * Creates a new router policy with model configuration, evaluators, retry settings, and limits.
37
+ */
38
+ async create(
39
+ request: operations.PolicyCreateRequestBody,
40
+ options?: RequestOptions,
41
+ ): Promise<operations.PolicyCreateResponseBody> {
42
+ return unwrapAsync(policiesCreate(
43
+ this,
44
+ request,
45
+ options,
46
+ ));
47
+ }
48
+
49
+ /**
50
+ * Delete policy
51
+ *
52
+ * @remarks
53
+ * Deletes an existing policy by ID.
54
+ */
55
+ async delete(
56
+ request: operations.PolicyDeleteRequest,
57
+ options?: RequestOptions,
58
+ ): Promise<void> {
59
+ return unwrapAsync(policiesDelete(
60
+ this,
61
+ request,
62
+ options,
63
+ ));
64
+ }
65
+
66
+ /**
67
+ * Get policy
68
+ *
69
+ * @remarks
70
+ * Retrieves the details of an existing policy by ID.
71
+ */
72
+ async get(
73
+ request: operations.PolicyGetRequest,
74
+ options?: RequestOptions,
75
+ ): Promise<operations.PolicyGetResponseBody> {
76
+ return unwrapAsync(policiesGet(
77
+ this,
78
+ request,
79
+ options,
80
+ ));
81
+ }
82
+
83
+ /**
84
+ * Update policy
85
+ *
86
+ * @remarks
87
+ * Partially updates an existing policy. Only provided fields are updated.
88
+ */
89
+ async update(
90
+ request: operations.PolicyUpdateRequest,
91
+ options?: RequestOptions,
92
+ ): Promise<operations.PolicyUpdateResponseBody> {
93
+ return unwrapAsync(policiesUpdate(
94
+ this,
95
+ request,
96
+ options,
97
+ ));
98
+ }
99
+ }
@@ -0,0 +1,99 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import { routingRulesCreate } from "../funcs/routingRulesCreate.js";
6
+ import { routingRulesDelete } from "../funcs/routingRulesDelete.js";
7
+ import { routingRulesGet } from "../funcs/routingRulesGet.js";
8
+ import { routingRulesList } from "../funcs/routingRulesList.js";
9
+ import { routingRulesUpdate } from "../funcs/routingRulesUpdate.js";
10
+ import { ClientSDK, RequestOptions } from "../lib/sdks.js";
11
+ import * as operations from "../models/operations/index.js";
12
+ import { unwrapAsync } from "../types/fp.js";
13
+
14
+ export class RoutingRules extends ClientSDK {
15
+ /**
16
+ * List routing rules
17
+ *
18
+ * @remarks
19
+ * Returns a paginated list of routing rules for the current project, ordered by priority ascending.
20
+ */
21
+ async list(
22
+ request?: operations.RoutingRuleListRequest | undefined,
23
+ options?: RequestOptions,
24
+ ): Promise<operations.RoutingRuleListResponseBody> {
25
+ return unwrapAsync(routingRulesList(
26
+ this,
27
+ request,
28
+ options,
29
+ ));
30
+ }
31
+
32
+ /**
33
+ * Create routing rule
34
+ *
35
+ * @remarks
36
+ * Creates a new routing rule with expression, models configuration, and priority settings.
37
+ */
38
+ async create(
39
+ request: operations.RoutingRuleCreateRequestBody,
40
+ options?: RequestOptions,
41
+ ): Promise<operations.RoutingRuleCreateResponseBody> {
42
+ return unwrapAsync(routingRulesCreate(
43
+ this,
44
+ request,
45
+ options,
46
+ ));
47
+ }
48
+
49
+ /**
50
+ * Delete routing rule
51
+ *
52
+ * @remarks
53
+ * Deletes an existing routing rule by ID.
54
+ */
55
+ async delete(
56
+ request: operations.RoutingRuleDeleteRequest,
57
+ options?: RequestOptions,
58
+ ): Promise<void> {
59
+ return unwrapAsync(routingRulesDelete(
60
+ this,
61
+ request,
62
+ options,
63
+ ));
64
+ }
65
+
66
+ /**
67
+ * Get routing rule
68
+ *
69
+ * @remarks
70
+ * Retrieves the details of an existing routing rule by ID.
71
+ */
72
+ async get(
73
+ request: operations.RoutingRuleGetRequest,
74
+ options?: RequestOptions,
75
+ ): Promise<operations.RoutingRuleGetResponseBody> {
76
+ return unwrapAsync(routingRulesGet(
77
+ this,
78
+ request,
79
+ options,
80
+ ));
81
+ }
82
+
83
+ /**
84
+ * Update routing rule
85
+ *
86
+ * @remarks
87
+ * Partially updates an existing routing rule. Only provided fields are updated.
88
+ */
89
+ async update(
90
+ request: operations.RoutingRuleUpdateRequest,
91
+ options?: RequestOptions,
92
+ ): Promise<operations.RoutingRuleUpdateResponseBody> {
93
+ return unwrapAsync(routingRulesUpdate(
94
+ this,
95
+ request,
96
+ options,
97
+ ));
98
+ }
99
+ }
@@ -23,14 +23,17 @@ import { Deployments } from "./deployments.js";
23
23
  import { Evals } from "./evals.js";
24
24
  import { Evaluators } from "./evaluators.js";
25
25
  import { Files } from "./files.js";
26
+ import { GuardrailRules } from "./guardrailrules.js";
26
27
  import { HumanReviewSets } from "./humanreviewsets.js";
27
28
  import { Identities } from "./identities.js";
28
29
  import { Knowledge } from "./knowledge.js";
29
30
  import { MemoryStores } from "./memorystores.js";
30
31
  import { Models } from "./models.js";
32
+ import { Policies } from "./policies.js";
31
33
  import { Prompts } from "./prompts.js";
32
34
  import { Remoteconfigs } from "./remoteconfigs.js";
33
35
  import { Router } from "./router.js";
36
+ import { RoutingRules } from "./routingrules.js";
34
37
  import { Tools } from "./tools.js";
35
38
 
36
39
  export class Orq extends ClientSDK {
@@ -124,6 +127,21 @@ export class Orq extends ClientSDK {
124
127
  return (this._files ??= new Files(this._options));
125
128
  }
126
129
 
130
+ private _guardrailRules?: GuardrailRules;
131
+ get guardrailRules(): GuardrailRules {
132
+ return (this._guardrailRules ??= new GuardrailRules(this._options));
133
+ }
134
+
135
+ private _policies?: Policies;
136
+ get policies(): Policies {
137
+ return (this._policies ??= new Policies(this._options));
138
+ }
139
+
140
+ private _routingRules?: RoutingRules;
141
+ get routingRules(): RoutingRules {
142
+ return (this._routingRules ??= new RoutingRules(this._options));
143
+ }
144
+
127
145
  async postV2Feedback(
128
146
  request?: operations.PostV2FeedbackRequestBody | undefined,
129
147
  options?: RequestOptions,
@@ -3,7 +3,7 @@
3
3
  */
4
4
 
5
5
  import { OrqCore } from "../core.js";
6
- import { appendForm } from "../lib/encodings.js";
6
+ import { appendForm, normalizeBlob } from "../lib/encodings.js";
7
7
  import {
8
8
  bytesToBlob,
9
9
  getContentTypeFromFileName,
@@ -93,8 +93,9 @@ async function $do(
93
93
  const body = new FormData();
94
94
 
95
95
  if (isBlobLike(payload.file)) {
96
- const blob = payload.file;
97
- const name = "name" in blob ? (blob.name as string) : undefined;
96
+ const file = payload.file;
97
+ const blob = await normalizeBlob(file);
98
+ const name = "name" in file ? (file.name as string) : undefined;
98
99
  appendForm(body, "file", blob, name);
99
100
  } else if (isReadableStream(payload.file.content)) {
100
101
  const buffer = await readableStreamToArrayBuffer(payload.file.content);
@@ -3,7 +3,7 @@
3
3
  */
4
4
 
5
5
  import { OrqCore } from "../core.js";
6
- import { appendForm, encodeJSON } from "../lib/encodings.js";
6
+ import { appendForm, encodeJSON, normalizeBlob } from "../lib/encodings.js";
7
7
  import {
8
8
  bytesToBlob,
9
9
  getContentTypeFromFileName,
@@ -109,8 +109,9 @@ async function $do(
109
109
  }
110
110
  if (payload.file !== undefined) {
111
111
  if (isBlobLike(payload.file)) {
112
- const blob = payload.file;
113
- const name = "name" in blob ? (blob.name as string) : undefined;
112
+ const file = payload.file;
113
+ const blob = await normalizeBlob(file);
114
+ const name = "name" in file ? (file.name as string) : undefined;
114
115
  appendForm(body, "file", blob, name);
115
116
  } else if (isReadableStream(payload.file.content)) {
116
117
  const buffer = await readableStreamToArrayBuffer(payload.file.content);
@@ -3,7 +3,7 @@
3
3
  */
4
4
 
5
5
  import { OrqCore } from "../core.js";
6
- import { appendForm, encodeJSON } from "../lib/encodings.js";
6
+ import { appendForm, encodeJSON, normalizeBlob } from "../lib/encodings.js";
7
7
  import {
8
8
  bytesToBlob,
9
9
  getContentTypeFromFileName,
@@ -109,8 +109,9 @@ async function $do(
109
109
  }
110
110
  if (payload.file !== undefined) {
111
111
  if (isBlobLike(payload.file)) {
112
- const blob = payload.file;
113
- const name = "name" in blob ? (blob.name as string) : undefined;
112
+ const file = payload.file;
113
+ const blob = await normalizeBlob(file);
114
+ const name = "name" in file ? (file.name as string) : undefined;
114
115
  appendForm(body, "file", blob, name);
115
116
  } else if (isReadableStream(payload.file.content)) {
116
117
  const buffer = await readableStreamToArrayBuffer(payload.file.content);
package/src/lib/config.ts CHANGED
@@ -68,7 +68,7 @@ export function serverURLFromOptions(options: SDKOptions): URL | null {
68
68
  export const SDK_METADATA = {
69
69
  language: "typescript",
70
70
  openapiDocVersion: "2.0",
71
- sdkVersion: "4.7.5",
72
- genVersion: "2.879.6",
73
- userAgent: "speakeasy-sdk/typescript 4.7.5 2.879.6 2.0 @orq-ai/node",
71
+ sdkVersion: "4.7.6",
72
+ genVersion: "2.879.13",
73
+ userAgent: "speakeasy-sdk/typescript 4.7.6 2.879.13 2.0 @orq-ai/node",
74
74
  } as const;
@@ -514,3 +514,12 @@ export function appendForm(
514
514
  fd.append(key, String(value));
515
515
  }
516
516
  }
517
+
518
+ export async function normalizeBlob(
519
+ value: Pick<Blob, "arrayBuffer" | "type">,
520
+ ): Promise<Blob> {
521
+ if (value instanceof Blob) {
522
+ return value;
523
+ }
524
+ return new Blob([await value.arrayBuffer()], { type: value.type });
525
+ }
@@ -40,7 +40,7 @@ export const ReasoningPart$inboundSchema: z.ZodType<
40
40
  z.ZodTypeDef,
41
41
  unknown
42
42
  > = z.object({
43
- _id: z.string().default("reasoning_01knv43015xg22zx0rzz15fmsd"),
43
+ _id: z.string().default("reasoning_01kp5jtawvdv4a0zn2mt9xfc1y"),
44
44
  metadata: z.record(z.any()).optional(),
45
45
  kind: z.literal("reasoning"),
46
46
  reasoning: z.string(),
@@ -134,7 +134,7 @@ export const CreateContactResponseBody$inboundSchema: z.ZodType<
134
134
  created: z.string().datetime({ offset: true }).transform(v => new Date(v))
135
135
  .optional(),
136
136
  updated: z.string().datetime({ offset: true }).default(
137
- "2026-04-10T07:18:00.925Z",
137
+ "2026-04-14T08:47:49.740Z",
138
138
  ).transform(v => new Date(v)),
139
139
  }).transform((v) => {
140
140
  return remap$(v, {
@@ -138,7 +138,7 @@ export const CreateDatasetResponseBody$inboundSchema: z.ZodType<
138
138
  created: z.string().datetime({ offset: true }).transform(v => new Date(v))
139
139
  .optional(),
140
140
  updated: z.string().datetime({ offset: true }).default(
141
- "2026-04-10T07:18:00.925Z",
141
+ "2026-04-14T08:47:49.740Z",
142
142
  ).transform(v => new Date(v)),
143
143
  }).transform((v) => {
144
144
  return remap$(v, {
@@ -2355,7 +2355,7 @@ export const Evaluations3$inboundSchema: z.ZodType<
2355
2355
  ),
2356
2356
  reviewed_by_id: z.string(),
2357
2357
  reviewed_at: z.string().datetime({ offset: true }).default(
2358
- "2026-04-10T07:18:18.091Z",
2358
+ "2026-04-14T08:48:07.274Z",
2359
2359
  ).transform(v => new Date(v)),
2360
2360
  type: z.literal("string_array"),
2361
2361
  values: z.array(z.string()),
@@ -2400,7 +2400,7 @@ export const Evaluations2$inboundSchema: z.ZodType<
2400
2400
  source: CreateDatasetItemEvaluationsSource$inboundSchema.default("orq"),
2401
2401
  reviewed_by_id: z.string(),
2402
2402
  reviewed_at: z.string().datetime({ offset: true }).default(
2403
- "2026-04-10T07:18:18.091Z",
2403
+ "2026-04-14T08:48:07.274Z",
2404
2404
  ).transform(v => new Date(v)),
2405
2405
  type: z.literal("number"),
2406
2406
  value: z.number(),
@@ -2446,7 +2446,7 @@ export const Evaluations1$inboundSchema: z.ZodType<
2446
2446
  source: EvaluationsSource$inboundSchema.default("orq"),
2447
2447
  reviewed_by_id: z.string(),
2448
2448
  reviewed_at: z.string().datetime({ offset: true }).default(
2449
- "2026-04-10T07:18:18.090Z",
2449
+ "2026-04-14T08:48:07.273Z",
2450
2450
  ).transform(v => new Date(v)),
2451
2451
  type: z.literal("string"),
2452
2452
  value: z.string(),
@@ -2529,7 +2529,7 @@ export const CreateDatasetItemResponseBody$inboundSchema: z.ZodType<
2529
2529
  created: z.string().datetime({ offset: true }).transform(v => new Date(v))
2530
2530
  .optional(),
2531
2531
  updated: z.string().datetime({ offset: true }).default(
2532
- "2026-04-10T07:18:00.925Z",
2532
+ "2026-04-14T08:47:49.740Z",
2533
2533
  ).transform(v => new Date(v)),
2534
2534
  }).transform((v) => {
2535
2535
  return remap$(v, {