@orq-ai/node 3.2.8 → 3.3.0-rc.1

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 (215) hide show
  1. package/bin/mcp-server.js +32 -35
  2. package/bin/mcp-server.js.map +20 -20
  3. package/jsr.json +1 -1
  4. package/lib/config.d.ts +2 -2
  5. package/lib/config.js +2 -2
  6. package/lib/config.js.map +1 -1
  7. package/mcp-server/mcp-server.js +1 -1
  8. package/mcp-server/mcp-server.js.map +1 -1
  9. package/mcp-server/server.js +1 -1
  10. package/mcp-server/server.js.map +1 -1
  11. package/models/operations/bulkcreatedatapoints.js +2 -2
  12. package/models/operations/createcontact.js +2 -2
  13. package/models/operations/createdataset.js +2 -2
  14. package/models/operations/createdatasetitem.js +2 -2
  15. package/models/operations/fileget.js +2 -2
  16. package/models/operations/filelist.js +2 -2
  17. package/models/operations/fileupload.js +2 -2
  18. package/models/operations/listdatasetdatapoints.js +2 -2
  19. package/models/operations/listdatasets.js +2 -2
  20. package/models/operations/retrievedatapoint.js +2 -2
  21. package/models/operations/retrievedataset.js +2 -2
  22. package/models/operations/updatedatapoint.js +2 -2
  23. package/models/operations/updatedataset.js +2 -2
  24. package/package.json +3 -2
  25. package/src/lib/config.ts +2 -2
  26. package/src/mcp-server/mcp-server.ts +1 -1
  27. package/src/mcp-server/server.ts +1 -1
  28. package/src/models/operations/bulkcreatedatapoints.ts +2 -2
  29. package/src/models/operations/createcontact.ts +2 -2
  30. package/src/models/operations/createdataset.ts +2 -2
  31. package/src/models/operations/createdatasetitem.ts +2 -2
  32. package/src/models/operations/fileget.ts +2 -2
  33. package/src/models/operations/filelist.ts +2 -2
  34. package/src/models/operations/fileupload.ts +2 -2
  35. package/src/models/operations/listdatasetdatapoints.ts +2 -2
  36. package/src/models/operations/listdatasets.ts +2 -2
  37. package/src/models/operations/retrievedatapoint.ts +2 -2
  38. package/src/models/operations/retrievedataset.ts +2 -2
  39. package/src/models/operations/updatedatapoint.ts +2 -2
  40. package/src/models/operations/updatedataset.ts +2 -2
  41. package/packages/orq-rc/FUNCTIONS.md +0 -106
  42. package/packages/orq-rc/README.md +0 -660
  43. package/packages/orq-rc/RUNTIMES.md +0 -48
  44. package/packages/orq-rc/docs/sdks/contacts/README.md +0 -84
  45. package/packages/orq-rc/docs/sdks/datasets/README.md +0 -934
  46. package/packages/orq-rc/docs/sdks/deployments/README.md +0 -316
  47. package/packages/orq-rc/docs/sdks/feedback/README.md +0 -92
  48. package/packages/orq-rc/docs/sdks/files/README.md +0 -305
  49. package/packages/orq-rc/docs/sdks/metrics/README.md +0 -86
  50. package/packages/orq-rc/docs/sdks/orq/README.md +0 -10
  51. package/packages/orq-rc/docs/sdks/prompts/README.md +0 -608
  52. package/packages/orq-rc/docs/sdks/remoteconfigs/README.md +0 -80
  53. package/packages/orq-rc/jsr.json +0 -28
  54. package/packages/orq-rc/package-lock.json +0 -3217
  55. package/packages/orq-rc/package.json +0 -45
  56. package/packages/orq-rc/src/core.ts +0 -13
  57. package/packages/orq-rc/src/funcs/contactsCreate.ts +0 -154
  58. package/packages/orq-rc/src/funcs/datasetsClear.ts +0 -161
  59. package/packages/orq-rc/src/funcs/datasetsCreate.ts +0 -159
  60. package/packages/orq-rc/src/funcs/datasetsCreateDatapoint.ts +0 -161
  61. package/packages/orq-rc/src/funcs/datasetsCreateDatapoints.ts +0 -165
  62. package/packages/orq-rc/src/funcs/datasetsDelete.ts +0 -161
  63. package/packages/orq-rc/src/funcs/datasetsDeleteDatapoint.ts +0 -176
  64. package/packages/orq-rc/src/funcs/datasetsList.ts +0 -162
  65. package/packages/orq-rc/src/funcs/datasetsListDatapoints.ts +0 -169
  66. package/packages/orq-rc/src/funcs/datasetsRetrieve.ts +0 -169
  67. package/packages/orq-rc/src/funcs/datasetsRetrieveDatapoint.ts +0 -175
  68. package/packages/orq-rc/src/funcs/datasetsUpdate.ts +0 -170
  69. package/packages/orq-rc/src/funcs/datasetsUpdateDatapoint.ts +0 -173
  70. package/packages/orq-rc/src/funcs/deploymentsGetConfig.ts +0 -162
  71. package/packages/orq-rc/src/funcs/deploymentsInvoke.ts +0 -170
  72. package/packages/orq-rc/src/funcs/deploymentsList.ts +0 -171
  73. package/packages/orq-rc/src/funcs/deploymentsMetricsCreate.ts +0 -162
  74. package/packages/orq-rc/src/funcs/deploymentsStream.ts +0 -178
  75. package/packages/orq-rc/src/funcs/feedbackCreate.ts +0 -154
  76. package/packages/orq-rc/src/funcs/filesCreate.ts +0 -177
  77. package/packages/orq-rc/src/funcs/filesDelete.ts +0 -158
  78. package/packages/orq-rc/src/funcs/filesGet.ts +0 -160
  79. package/packages/orq-rc/src/funcs/filesList.ts +0 -162
  80. package/packages/orq-rc/src/funcs/promptsCreate.ts +0 -154
  81. package/packages/orq-rc/src/funcs/promptsDelete.ts +0 -158
  82. package/packages/orq-rc/src/funcs/promptsGetVersion.ts +0 -175
  83. package/packages/orq-rc/src/funcs/promptsList.ts +0 -162
  84. package/packages/orq-rc/src/funcs/promptsListVersions.ts +0 -168
  85. package/packages/orq-rc/src/funcs/promptsRetrieve.ts +0 -160
  86. package/packages/orq-rc/src/funcs/promptsUpdate.ts +0 -167
  87. package/packages/orq-rc/src/funcs/remoteconfigsRetrieve.ts +0 -155
  88. package/packages/orq-rc/src/hooks/global.ts +0 -44
  89. package/packages/orq-rc/src/hooks/hooks.ts +0 -132
  90. package/packages/orq-rc/src/hooks/index.ts +0 -6
  91. package/packages/orq-rc/src/hooks/registration.ts +0 -15
  92. package/packages/orq-rc/src/hooks/types.ts +0 -110
  93. package/packages/orq-rc/src/index.ts +0 -7
  94. package/packages/orq-rc/src/lib/base64.ts +0 -37
  95. package/packages/orq-rc/src/lib/config.ts +0 -70
  96. package/packages/orq-rc/src/lib/dlv.ts +0 -53
  97. package/packages/orq-rc/src/lib/encodings.ts +0 -483
  98. package/packages/orq-rc/src/lib/env.ts +0 -73
  99. package/packages/orq-rc/src/lib/event-streams.ts +0 -264
  100. package/packages/orq-rc/src/lib/files.ts +0 -40
  101. package/packages/orq-rc/src/lib/http.ts +0 -323
  102. package/packages/orq-rc/src/lib/is-plain-object.ts +0 -43
  103. package/packages/orq-rc/src/lib/logger.ts +0 -9
  104. package/packages/orq-rc/src/lib/matchers.ts +0 -325
  105. package/packages/orq-rc/src/lib/primitives.ts +0 -150
  106. package/packages/orq-rc/src/lib/retries.ts +0 -218
  107. package/packages/orq-rc/src/lib/schemas.ts +0 -91
  108. package/packages/orq-rc/src/lib/sdks.ts +0 -395
  109. package/packages/orq-rc/src/lib/security.ts +0 -261
  110. package/packages/orq-rc/src/lib/url.ts +0 -33
  111. package/packages/orq-rc/src/mcp-server/cli/start/command.ts +0 -125
  112. package/packages/orq-rc/src/mcp-server/cli/start/impl.ts +0 -140
  113. package/packages/orq-rc/src/mcp-server/cli.ts +0 -13
  114. package/packages/orq-rc/src/mcp-server/console-logger.ts +0 -71
  115. package/packages/orq-rc/src/mcp-server/extensions.ts +0 -17
  116. package/packages/orq-rc/src/mcp-server/mcp-server.ts +0 -26
  117. package/packages/orq-rc/src/mcp-server/prompts.ts +0 -110
  118. package/packages/orq-rc/src/mcp-server/resources.ts +0 -158
  119. package/packages/orq-rc/src/mcp-server/scopes.ts +0 -7
  120. package/packages/orq-rc/src/mcp-server/server.ts +0 -125
  121. package/packages/orq-rc/src/mcp-server/shared.ts +0 -75
  122. package/packages/orq-rc/src/mcp-server/tools/contactsCreate.ts +0 -37
  123. package/packages/orq-rc/src/mcp-server/tools/datasetsClear.ts +0 -35
  124. package/packages/orq-rc/src/mcp-server/tools/datasetsCreate.ts +0 -37
  125. package/packages/orq-rc/src/mcp-server/tools/datasetsCreateDatapoint.ts +0 -37
  126. package/packages/orq-rc/src/mcp-server/tools/datasetsCreateDatapoints.ts +0 -37
  127. package/packages/orq-rc/src/mcp-server/tools/datasetsDelete.ts +0 -35
  128. package/packages/orq-rc/src/mcp-server/tools/datasetsDeleteDatapoint.ts +0 -35
  129. package/packages/orq-rc/src/mcp-server/tools/datasetsList.ts +0 -37
  130. package/packages/orq-rc/src/mcp-server/tools/datasetsListDatapoints.ts +0 -37
  131. package/packages/orq-rc/src/mcp-server/tools/datasetsRetrieve.ts +0 -37
  132. package/packages/orq-rc/src/mcp-server/tools/datasetsRetrieveDatapoint.ts +0 -37
  133. package/packages/orq-rc/src/mcp-server/tools/datasetsUpdate.ts +0 -37
  134. package/packages/orq-rc/src/mcp-server/tools/datasetsUpdateDatapoint.ts +0 -35
  135. package/packages/orq-rc/src/mcp-server/tools/deploymentsGetConfig.ts +0 -37
  136. package/packages/orq-rc/src/mcp-server/tools/deploymentsInvoke.ts +0 -37
  137. package/packages/orq-rc/src/mcp-server/tools/deploymentsList.ts +0 -37
  138. package/packages/orq-rc/src/mcp-server/tools/deploymentsMetricsCreate.ts +0 -37
  139. package/packages/orq-rc/src/mcp-server/tools/deploymentsStream.ts +0 -37
  140. package/packages/orq-rc/src/mcp-server/tools/feedbackCreate.ts +0 -37
  141. package/packages/orq-rc/src/mcp-server/tools/filesCreate.ts +0 -37
  142. package/packages/orq-rc/src/mcp-server/tools/filesDelete.ts +0 -33
  143. package/packages/orq-rc/src/mcp-server/tools/filesGet.ts +0 -37
  144. package/packages/orq-rc/src/mcp-server/tools/filesList.ts +0 -37
  145. package/packages/orq-rc/src/mcp-server/tools/promptsCreate.ts +0 -35
  146. package/packages/orq-rc/src/mcp-server/tools/promptsDelete.ts +0 -33
  147. package/packages/orq-rc/src/mcp-server/tools/promptsGetVersion.ts +0 -37
  148. package/packages/orq-rc/src/mcp-server/tools/promptsList.ts +0 -37
  149. package/packages/orq-rc/src/mcp-server/tools/promptsListVersions.ts +0 -37
  150. package/packages/orq-rc/src/mcp-server/tools/promptsRetrieve.ts +0 -37
  151. package/packages/orq-rc/src/mcp-server/tools/promptsUpdate.ts +0 -35
  152. package/packages/orq-rc/src/mcp-server/tools/remoteconfigsRetrieve.ts +0 -36
  153. package/packages/orq-rc/src/mcp-server/tools.ts +0 -126
  154. package/packages/orq-rc/src/models/components/deployments.ts +0 -4164
  155. package/packages/orq-rc/src/models/components/index.ts +0 -6
  156. package/packages/orq-rc/src/models/components/security.ts +0 -71
  157. package/packages/orq-rc/src/models/errors/apierror.ts +0 -27
  158. package/packages/orq-rc/src/models/errors/getpromptversion.ts +0 -71
  159. package/packages/orq-rc/src/models/errors/honoapierror.ts +0 -82
  160. package/packages/orq-rc/src/models/errors/httpclienterrors.ts +0 -62
  161. package/packages/orq-rc/src/models/errors/index.ts +0 -10
  162. package/packages/orq-rc/src/models/errors/sdkvalidationerror.ts +0 -97
  163. package/packages/orq-rc/src/models/errors/updateprompt.ts +0 -71
  164. package/packages/orq-rc/src/models/operations/bulkcreatedatapoints.ts +0 -1816
  165. package/packages/orq-rc/src/models/operations/cleardataset.ts +0 -75
  166. package/packages/orq-rc/src/models/operations/createcontact.ts +0 -256
  167. package/packages/orq-rc/src/models/operations/createdataset.ts +0 -296
  168. package/packages/orq-rc/src/models/operations/createdatasetitem.ts +0 -1740
  169. package/packages/orq-rc/src/models/operations/createfeedback.ts +0 -286
  170. package/packages/orq-rc/src/models/operations/createprompt.ts +0 -3735
  171. package/packages/orq-rc/src/models/operations/deletedatapoint.ts +0 -81
  172. package/packages/orq-rc/src/models/operations/deletedataset.ts +0 -75
  173. package/packages/orq-rc/src/models/operations/deleteprompt.ts +0 -69
  174. package/packages/orq-rc/src/models/operations/deploymentcreatemetric.ts +0 -4936
  175. package/packages/orq-rc/src/models/operations/deploymentgetconfig.ts +0 -6090
  176. package/packages/orq-rc/src/models/operations/deploymentinvoke.ts +0 -1199
  177. package/packages/orq-rc/src/models/operations/deployments.ts +0 -2194
  178. package/packages/orq-rc/src/models/operations/deploymentstream.ts +0 -5960
  179. package/packages/orq-rc/src/models/operations/filedelete.ts +0 -78
  180. package/packages/orq-rc/src/models/operations/fileget.ts +0 -223
  181. package/packages/orq-rc/src/models/operations/filelist.ts +0 -377
  182. package/packages/orq-rc/src/models/operations/fileupload.ts +0 -324
  183. package/packages/orq-rc/src/models/operations/getallprompts.ts +0 -2165
  184. package/packages/orq-rc/src/models/operations/getoneprompt.ts +0 -1989
  185. package/packages/orq-rc/src/models/operations/getpromptversion.ts +0 -1987
  186. package/packages/orq-rc/src/models/operations/index.ts +0 -35
  187. package/packages/orq-rc/src/models/operations/listdatasetdatapoints.ts +0 -1115
  188. package/packages/orq-rc/src/models/operations/listdatasets.ts +0 -448
  189. package/packages/orq-rc/src/models/operations/listpromptversions.ts +0 -2163
  190. package/packages/orq-rc/src/models/operations/remoteconfigsgetconfig.ts +0 -190
  191. package/packages/orq-rc/src/models/operations/retrievedatapoint.ts +0 -924
  192. package/packages/orq-rc/src/models/operations/retrievedataset.ts +0 -288
  193. package/packages/orq-rc/src/models/operations/updatedatapoint.ts +0 -1729
  194. package/packages/orq-rc/src/models/operations/updatedataset.ts +0 -374
  195. package/packages/orq-rc/src/models/operations/updateprompt.ts +0 -3914
  196. package/packages/orq-rc/src/sdk/contacts.ts +0 -27
  197. package/packages/orq-rc/src/sdk/datasets.ts +0 -222
  198. package/packages/orq-rc/src/sdk/deployments.ts +0 -89
  199. package/packages/orq-rc/src/sdk/feedback.ts +0 -27
  200. package/packages/orq-rc/src/sdk/files.ts +0 -78
  201. package/packages/orq-rc/src/sdk/index.ts +0 -5
  202. package/packages/orq-rc/src/sdk/metrics.ts +0 -27
  203. package/packages/orq-rc/src/sdk/prompts.ts +0 -126
  204. package/packages/orq-rc/src/sdk/remoteconfigs.ts +0 -24
  205. package/packages/orq-rc/src/sdk/sdk.ts +0 -49
  206. package/packages/orq-rc/src/types/async.ts +0 -68
  207. package/packages/orq-rc/src/types/blobs.ts +0 -31
  208. package/packages/orq-rc/src/types/constdatetime.ts +0 -15
  209. package/packages/orq-rc/src/types/enums.ts +0 -16
  210. package/packages/orq-rc/src/types/fp.ts +0 -50
  211. package/packages/orq-rc/src/types/index.ts +0 -11
  212. package/packages/orq-rc/src/types/operations.ts +0 -105
  213. package/packages/orq-rc/src/types/rfcdate.ts +0 -54
  214. package/packages/orq-rc/src/types/streams.ts +0 -21
  215. package/packages/orq-rc/tsconfig.json +0 -41
@@ -1,1115 +0,0 @@
1
- /*
2
- * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
- */
4
-
5
- import * as z from "zod";
6
- import { remap as remap$ } from "../../lib/primitives.js";
7
- import { safeParse } from "../../lib/schemas.js";
8
- import { ClosedEnum } from "../../types/enums.js";
9
- import { Result as SafeParseResult } from "../../types/fp.js";
10
- import { SDKValidationError } from "../errors/sdkvalidationerror.js";
11
-
12
- /**
13
- * List sorting preference.
14
- */
15
- export const ListDatasetDatapointsQueryParamSort = {
16
- Asc: "asc",
17
- Desc: "desc",
18
- } as const;
19
- /**
20
- * List sorting preference.
21
- */
22
- export type ListDatasetDatapointsQueryParamSort = ClosedEnum<
23
- typeof ListDatasetDatapointsQueryParamSort
24
- >;
25
-
26
- export type ListDatasetDatapointsRequest = {
27
- datasetId: string;
28
- /**
29
- * List sorting preference.
30
- */
31
- sort?: ListDatasetDatapointsQueryParamSort | undefined;
32
- /**
33
- * A limit on the number of objects to be returned. Limit can range between 1 and 50, and the default is 10
34
- */
35
- limit?: number | undefined;
36
- /**
37
- * A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 20 objects, ending with `01JJ1HDHN79XAS7A01WB3HYSDB`, your subsequent call can include `after=01JJ1HDHN79XAS7A01WB3HYSDB` in order to fetch the next page of the list.
38
- */
39
- startingAfter?: string | undefined;
40
- /**
41
- * A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 20 objects, starting with `01JJ1HDHN79XAS7A01WB3HYSDB`, your subsequent call can include `before=01JJ1HDHN79XAS7A01WB3HYSDB` in order to fetch the previous page of the list.
42
- */
43
- endingBefore?: string | undefined;
44
- };
45
-
46
- export const ListDatasetDatapointsObject = {
47
- List: "list",
48
- } as const;
49
- export type ListDatasetDatapointsObject = ClosedEnum<
50
- typeof ListDatasetDatapointsObject
51
- >;
52
-
53
- /**
54
- * The role of the prompt message
55
- */
56
- export const ListDatasetDatapointsRole = {
57
- System: "system",
58
- Assistant: "assistant",
59
- User: "user",
60
- Exception: "exception",
61
- Tool: "tool",
62
- Prompt: "prompt",
63
- Correction: "correction",
64
- ExpectedOutput: "expected_output",
65
- } as const;
66
- /**
67
- * The role of the prompt message
68
- */
69
- export type ListDatasetDatapointsRole = ClosedEnum<
70
- typeof ListDatasetDatapointsRole
71
- >;
72
-
73
- export const ListDatasetDatapoints2DatasetsType = {
74
- ImageUrl: "image_url",
75
- } as const;
76
- export type ListDatasetDatapoints2DatasetsType = ClosedEnum<
77
- typeof ListDatasetDatapoints2DatasetsType
78
- >;
79
-
80
- export type ListDatasetDatapoints2ImageUrl = {
81
- /**
82
- * The orq.ai id of the image
83
- */
84
- id?: string | undefined;
85
- /**
86
- * Either a URL of the image or the base64 encoded data URI.
87
- */
88
- url: string;
89
- /**
90
- * Specifies the detail level of the image. Currently only supported with OpenAI models
91
- */
92
- detail?: string | undefined;
93
- };
94
-
95
- /**
96
- * The image part of the prompt message. Only supported with vision models.
97
- */
98
- export type ListDatasetDatapoints22 = {
99
- type: ListDatasetDatapoints2DatasetsType;
100
- imageUrl: ListDatasetDatapoints2ImageUrl;
101
- };
102
-
103
- export const ListDatasetDatapoints2Type = {
104
- Text: "text",
105
- } as const;
106
- export type ListDatasetDatapoints2Type = ClosedEnum<
107
- typeof ListDatasetDatapoints2Type
108
- >;
109
-
110
- /**
111
- * Text content part of a prompt message
112
- */
113
- export type ListDatasetDatapoints21 = {
114
- type: ListDatasetDatapoints2Type;
115
- text: string;
116
- };
117
-
118
- export type ListDatasetDatapointsContent2 =
119
- | ListDatasetDatapoints21
120
- | ListDatasetDatapoints22;
121
-
122
- /**
123
- * The contents of the user message. Either the text content of the message or an array of content parts with a defined type, each can be of type `text` or `image_url` when passing in images. You can pass multiple images by adding multiple `image_url` content parts.
124
- */
125
- export type ListDatasetDatapointsContent =
126
- | string
127
- | Array<ListDatasetDatapoints21 | ListDatasetDatapoints22>;
128
-
129
- export const ListDatasetDatapointsType = {
130
- Function: "function",
131
- } as const;
132
- export type ListDatasetDatapointsType = ClosedEnum<
133
- typeof ListDatasetDatapointsType
134
- >;
135
-
136
- export type ListDatasetDatapointsFunction = {
137
- name: string;
138
- /**
139
- * JSON string arguments for the functions
140
- */
141
- arguments: string;
142
- };
143
-
144
- export type ListDatasetDatapointsToolCalls = {
145
- id?: string | undefined;
146
- index?: number | undefined;
147
- type: ListDatasetDatapointsType;
148
- function: ListDatasetDatapointsFunction;
149
- };
150
-
151
- export type ListDatasetDatapointsMessages = {
152
- /**
153
- * The role of the prompt message
154
- */
155
- role: ListDatasetDatapointsRole;
156
- /**
157
- * The contents of the user message. Either the text content of the message or an array of content parts with a defined type, each can be of type `text` or `image_url` when passing in images. You can pass multiple images by adding multiple `image_url` content parts.
158
- */
159
- content: string | Array<ListDatasetDatapoints21 | ListDatasetDatapoints22>;
160
- toolCalls?: Array<ListDatasetDatapointsToolCalls> | undefined;
161
- };
162
-
163
- export type ListDatasetDatapointsData = {
164
- /**
165
- * The unique identifier of the dataset item
166
- */
167
- id: string;
168
- /**
169
- * The unique identifier of the workspace it belongs to
170
- */
171
- workspaceId: string;
172
- /**
173
- * The inputs of the dataset. Key value pairs where the key is the input name and the value is the input value. Nested objects are not supported.
174
- */
175
- inputs?: { [k: string]: any } | undefined;
176
- /**
177
- * The prompt template messages
178
- */
179
- messages?: Array<ListDatasetDatapointsMessages> | undefined;
180
- expectedOutput?: string | undefined;
181
- /**
182
- * The unique identifier of the dataset
183
- */
184
- datasetId: string;
185
- /**
186
- * The unique identifier of the user who created the dataset
187
- */
188
- createdById?: string | undefined;
189
- /**
190
- * The unique identifier of the user who last updated the dataset
191
- */
192
- updatedById?: string | undefined;
193
- /**
194
- * The date and time the resource was created
195
- */
196
- created?: Date | undefined;
197
- /**
198
- * The date and time the resource was last updated
199
- */
200
- updated?: Date | undefined;
201
- };
202
-
203
- /**
204
- * Datapoints retrieved successfully. Returns a paginated list of datapoints.
205
- */
206
- export type ListDatasetDatapointsResponseBody = {
207
- object: ListDatasetDatapointsObject;
208
- data: Array<ListDatasetDatapointsData>;
209
- hasMore: boolean;
210
- };
211
-
212
- /** @internal */
213
- export const ListDatasetDatapointsQueryParamSort$inboundSchema: z.ZodNativeEnum<
214
- typeof ListDatasetDatapointsQueryParamSort
215
- > = z.nativeEnum(ListDatasetDatapointsQueryParamSort);
216
-
217
- /** @internal */
218
- export const ListDatasetDatapointsQueryParamSort$outboundSchema:
219
- z.ZodNativeEnum<typeof ListDatasetDatapointsQueryParamSort> =
220
- ListDatasetDatapointsQueryParamSort$inboundSchema;
221
-
222
- /**
223
- * @internal
224
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
225
- */
226
- export namespace ListDatasetDatapointsQueryParamSort$ {
227
- /** @deprecated use `ListDatasetDatapointsQueryParamSort$inboundSchema` instead. */
228
- export const inboundSchema =
229
- ListDatasetDatapointsQueryParamSort$inboundSchema;
230
- /** @deprecated use `ListDatasetDatapointsQueryParamSort$outboundSchema` instead. */
231
- export const outboundSchema =
232
- ListDatasetDatapointsQueryParamSort$outboundSchema;
233
- }
234
-
235
- /** @internal */
236
- export const ListDatasetDatapointsRequest$inboundSchema: z.ZodType<
237
- ListDatasetDatapointsRequest,
238
- z.ZodTypeDef,
239
- unknown
240
- > = z.object({
241
- dataset_id: z.string(),
242
- sort: ListDatasetDatapointsQueryParamSort$inboundSchema.default("asc"),
243
- limit: z.number().default(10),
244
- starting_after: z.string().optional(),
245
- ending_before: z.string().optional(),
246
- }).transform((v) => {
247
- return remap$(v, {
248
- "dataset_id": "datasetId",
249
- "starting_after": "startingAfter",
250
- "ending_before": "endingBefore",
251
- });
252
- });
253
-
254
- /** @internal */
255
- export type ListDatasetDatapointsRequest$Outbound = {
256
- dataset_id: string;
257
- sort: string;
258
- limit: number;
259
- starting_after?: string | undefined;
260
- ending_before?: string | undefined;
261
- };
262
-
263
- /** @internal */
264
- export const ListDatasetDatapointsRequest$outboundSchema: z.ZodType<
265
- ListDatasetDatapointsRequest$Outbound,
266
- z.ZodTypeDef,
267
- ListDatasetDatapointsRequest
268
- > = z.object({
269
- datasetId: z.string(),
270
- sort: ListDatasetDatapointsQueryParamSort$outboundSchema.default("asc"),
271
- limit: z.number().default(10),
272
- startingAfter: z.string().optional(),
273
- endingBefore: z.string().optional(),
274
- }).transform((v) => {
275
- return remap$(v, {
276
- datasetId: "dataset_id",
277
- startingAfter: "starting_after",
278
- endingBefore: "ending_before",
279
- });
280
- });
281
-
282
- /**
283
- * @internal
284
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
285
- */
286
- export namespace ListDatasetDatapointsRequest$ {
287
- /** @deprecated use `ListDatasetDatapointsRequest$inboundSchema` instead. */
288
- export const inboundSchema = ListDatasetDatapointsRequest$inboundSchema;
289
- /** @deprecated use `ListDatasetDatapointsRequest$outboundSchema` instead. */
290
- export const outboundSchema = ListDatasetDatapointsRequest$outboundSchema;
291
- /** @deprecated use `ListDatasetDatapointsRequest$Outbound` instead. */
292
- export type Outbound = ListDatasetDatapointsRequest$Outbound;
293
- }
294
-
295
- export function listDatasetDatapointsRequestToJSON(
296
- listDatasetDatapointsRequest: ListDatasetDatapointsRequest,
297
- ): string {
298
- return JSON.stringify(
299
- ListDatasetDatapointsRequest$outboundSchema.parse(
300
- listDatasetDatapointsRequest,
301
- ),
302
- );
303
- }
304
-
305
- export function listDatasetDatapointsRequestFromJSON(
306
- jsonString: string,
307
- ): SafeParseResult<ListDatasetDatapointsRequest, SDKValidationError> {
308
- return safeParse(
309
- jsonString,
310
- (x) => ListDatasetDatapointsRequest$inboundSchema.parse(JSON.parse(x)),
311
- `Failed to parse 'ListDatasetDatapointsRequest' from JSON`,
312
- );
313
- }
314
-
315
- /** @internal */
316
- export const ListDatasetDatapointsObject$inboundSchema: z.ZodNativeEnum<
317
- typeof ListDatasetDatapointsObject
318
- > = z.nativeEnum(ListDatasetDatapointsObject);
319
-
320
- /** @internal */
321
- export const ListDatasetDatapointsObject$outboundSchema: z.ZodNativeEnum<
322
- typeof ListDatasetDatapointsObject
323
- > = ListDatasetDatapointsObject$inboundSchema;
324
-
325
- /**
326
- * @internal
327
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
328
- */
329
- export namespace ListDatasetDatapointsObject$ {
330
- /** @deprecated use `ListDatasetDatapointsObject$inboundSchema` instead. */
331
- export const inboundSchema = ListDatasetDatapointsObject$inboundSchema;
332
- /** @deprecated use `ListDatasetDatapointsObject$outboundSchema` instead. */
333
- export const outboundSchema = ListDatasetDatapointsObject$outboundSchema;
334
- }
335
-
336
- /** @internal */
337
- export const ListDatasetDatapointsRole$inboundSchema: z.ZodNativeEnum<
338
- typeof ListDatasetDatapointsRole
339
- > = z.nativeEnum(ListDatasetDatapointsRole);
340
-
341
- /** @internal */
342
- export const ListDatasetDatapointsRole$outboundSchema: z.ZodNativeEnum<
343
- typeof ListDatasetDatapointsRole
344
- > = ListDatasetDatapointsRole$inboundSchema;
345
-
346
- /**
347
- * @internal
348
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
349
- */
350
- export namespace ListDatasetDatapointsRole$ {
351
- /** @deprecated use `ListDatasetDatapointsRole$inboundSchema` instead. */
352
- export const inboundSchema = ListDatasetDatapointsRole$inboundSchema;
353
- /** @deprecated use `ListDatasetDatapointsRole$outboundSchema` instead. */
354
- export const outboundSchema = ListDatasetDatapointsRole$outboundSchema;
355
- }
356
-
357
- /** @internal */
358
- export const ListDatasetDatapoints2DatasetsType$inboundSchema: z.ZodNativeEnum<
359
- typeof ListDatasetDatapoints2DatasetsType
360
- > = z.nativeEnum(ListDatasetDatapoints2DatasetsType);
361
-
362
- /** @internal */
363
- export const ListDatasetDatapoints2DatasetsType$outboundSchema: z.ZodNativeEnum<
364
- typeof ListDatasetDatapoints2DatasetsType
365
- > = ListDatasetDatapoints2DatasetsType$inboundSchema;
366
-
367
- /**
368
- * @internal
369
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
370
- */
371
- export namespace ListDatasetDatapoints2DatasetsType$ {
372
- /** @deprecated use `ListDatasetDatapoints2DatasetsType$inboundSchema` instead. */
373
- export const inboundSchema = ListDatasetDatapoints2DatasetsType$inboundSchema;
374
- /** @deprecated use `ListDatasetDatapoints2DatasetsType$outboundSchema` instead. */
375
- export const outboundSchema =
376
- ListDatasetDatapoints2DatasetsType$outboundSchema;
377
- }
378
-
379
- /** @internal */
380
- export const ListDatasetDatapoints2ImageUrl$inboundSchema: z.ZodType<
381
- ListDatasetDatapoints2ImageUrl,
382
- z.ZodTypeDef,
383
- unknown
384
- > = z.object({
385
- id: z.string().optional(),
386
- url: z.string(),
387
- detail: z.string().optional(),
388
- });
389
-
390
- /** @internal */
391
- export type ListDatasetDatapoints2ImageUrl$Outbound = {
392
- id?: string | undefined;
393
- url: string;
394
- detail?: string | undefined;
395
- };
396
-
397
- /** @internal */
398
- export const ListDatasetDatapoints2ImageUrl$outboundSchema: z.ZodType<
399
- ListDatasetDatapoints2ImageUrl$Outbound,
400
- z.ZodTypeDef,
401
- ListDatasetDatapoints2ImageUrl
402
- > = z.object({
403
- id: z.string().optional(),
404
- url: z.string(),
405
- detail: z.string().optional(),
406
- });
407
-
408
- /**
409
- * @internal
410
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
411
- */
412
- export namespace ListDatasetDatapoints2ImageUrl$ {
413
- /** @deprecated use `ListDatasetDatapoints2ImageUrl$inboundSchema` instead. */
414
- export const inboundSchema = ListDatasetDatapoints2ImageUrl$inboundSchema;
415
- /** @deprecated use `ListDatasetDatapoints2ImageUrl$outboundSchema` instead. */
416
- export const outboundSchema = ListDatasetDatapoints2ImageUrl$outboundSchema;
417
- /** @deprecated use `ListDatasetDatapoints2ImageUrl$Outbound` instead. */
418
- export type Outbound = ListDatasetDatapoints2ImageUrl$Outbound;
419
- }
420
-
421
- export function listDatasetDatapoints2ImageUrlToJSON(
422
- listDatasetDatapoints2ImageUrl: ListDatasetDatapoints2ImageUrl,
423
- ): string {
424
- return JSON.stringify(
425
- ListDatasetDatapoints2ImageUrl$outboundSchema.parse(
426
- listDatasetDatapoints2ImageUrl,
427
- ),
428
- );
429
- }
430
-
431
- export function listDatasetDatapoints2ImageUrlFromJSON(
432
- jsonString: string,
433
- ): SafeParseResult<ListDatasetDatapoints2ImageUrl, SDKValidationError> {
434
- return safeParse(
435
- jsonString,
436
- (x) => ListDatasetDatapoints2ImageUrl$inboundSchema.parse(JSON.parse(x)),
437
- `Failed to parse 'ListDatasetDatapoints2ImageUrl' from JSON`,
438
- );
439
- }
440
-
441
- /** @internal */
442
- export const ListDatasetDatapoints22$inboundSchema: z.ZodType<
443
- ListDatasetDatapoints22,
444
- z.ZodTypeDef,
445
- unknown
446
- > = z.object({
447
- type: ListDatasetDatapoints2DatasetsType$inboundSchema,
448
- image_url: z.lazy(() => ListDatasetDatapoints2ImageUrl$inboundSchema),
449
- }).transform((v) => {
450
- return remap$(v, {
451
- "image_url": "imageUrl",
452
- });
453
- });
454
-
455
- /** @internal */
456
- export type ListDatasetDatapoints22$Outbound = {
457
- type: string;
458
- image_url: ListDatasetDatapoints2ImageUrl$Outbound;
459
- };
460
-
461
- /** @internal */
462
- export const ListDatasetDatapoints22$outboundSchema: z.ZodType<
463
- ListDatasetDatapoints22$Outbound,
464
- z.ZodTypeDef,
465
- ListDatasetDatapoints22
466
- > = z.object({
467
- type: ListDatasetDatapoints2DatasetsType$outboundSchema,
468
- imageUrl: z.lazy(() => ListDatasetDatapoints2ImageUrl$outboundSchema),
469
- }).transform((v) => {
470
- return remap$(v, {
471
- imageUrl: "image_url",
472
- });
473
- });
474
-
475
- /**
476
- * @internal
477
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
478
- */
479
- export namespace ListDatasetDatapoints22$ {
480
- /** @deprecated use `ListDatasetDatapoints22$inboundSchema` instead. */
481
- export const inboundSchema = ListDatasetDatapoints22$inboundSchema;
482
- /** @deprecated use `ListDatasetDatapoints22$outboundSchema` instead. */
483
- export const outboundSchema = ListDatasetDatapoints22$outboundSchema;
484
- /** @deprecated use `ListDatasetDatapoints22$Outbound` instead. */
485
- export type Outbound = ListDatasetDatapoints22$Outbound;
486
- }
487
-
488
- export function listDatasetDatapoints22ToJSON(
489
- listDatasetDatapoints22: ListDatasetDatapoints22,
490
- ): string {
491
- return JSON.stringify(
492
- ListDatasetDatapoints22$outboundSchema.parse(listDatasetDatapoints22),
493
- );
494
- }
495
-
496
- export function listDatasetDatapoints22FromJSON(
497
- jsonString: string,
498
- ): SafeParseResult<ListDatasetDatapoints22, SDKValidationError> {
499
- return safeParse(
500
- jsonString,
501
- (x) => ListDatasetDatapoints22$inboundSchema.parse(JSON.parse(x)),
502
- `Failed to parse 'ListDatasetDatapoints22' from JSON`,
503
- );
504
- }
505
-
506
- /** @internal */
507
- export const ListDatasetDatapoints2Type$inboundSchema: z.ZodNativeEnum<
508
- typeof ListDatasetDatapoints2Type
509
- > = z.nativeEnum(ListDatasetDatapoints2Type);
510
-
511
- /** @internal */
512
- export const ListDatasetDatapoints2Type$outboundSchema: z.ZodNativeEnum<
513
- typeof ListDatasetDatapoints2Type
514
- > = ListDatasetDatapoints2Type$inboundSchema;
515
-
516
- /**
517
- * @internal
518
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
519
- */
520
- export namespace ListDatasetDatapoints2Type$ {
521
- /** @deprecated use `ListDatasetDatapoints2Type$inboundSchema` instead. */
522
- export const inboundSchema = ListDatasetDatapoints2Type$inboundSchema;
523
- /** @deprecated use `ListDatasetDatapoints2Type$outboundSchema` instead. */
524
- export const outboundSchema = ListDatasetDatapoints2Type$outboundSchema;
525
- }
526
-
527
- /** @internal */
528
- export const ListDatasetDatapoints21$inboundSchema: z.ZodType<
529
- ListDatasetDatapoints21,
530
- z.ZodTypeDef,
531
- unknown
532
- > = z.object({
533
- type: ListDatasetDatapoints2Type$inboundSchema,
534
- text: z.string(),
535
- });
536
-
537
- /** @internal */
538
- export type ListDatasetDatapoints21$Outbound = {
539
- type: string;
540
- text: string;
541
- };
542
-
543
- /** @internal */
544
- export const ListDatasetDatapoints21$outboundSchema: z.ZodType<
545
- ListDatasetDatapoints21$Outbound,
546
- z.ZodTypeDef,
547
- ListDatasetDatapoints21
548
- > = z.object({
549
- type: ListDatasetDatapoints2Type$outboundSchema,
550
- text: z.string(),
551
- });
552
-
553
- /**
554
- * @internal
555
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
556
- */
557
- export namespace ListDatasetDatapoints21$ {
558
- /** @deprecated use `ListDatasetDatapoints21$inboundSchema` instead. */
559
- export const inboundSchema = ListDatasetDatapoints21$inboundSchema;
560
- /** @deprecated use `ListDatasetDatapoints21$outboundSchema` instead. */
561
- export const outboundSchema = ListDatasetDatapoints21$outboundSchema;
562
- /** @deprecated use `ListDatasetDatapoints21$Outbound` instead. */
563
- export type Outbound = ListDatasetDatapoints21$Outbound;
564
- }
565
-
566
- export function listDatasetDatapoints21ToJSON(
567
- listDatasetDatapoints21: ListDatasetDatapoints21,
568
- ): string {
569
- return JSON.stringify(
570
- ListDatasetDatapoints21$outboundSchema.parse(listDatasetDatapoints21),
571
- );
572
- }
573
-
574
- export function listDatasetDatapoints21FromJSON(
575
- jsonString: string,
576
- ): SafeParseResult<ListDatasetDatapoints21, SDKValidationError> {
577
- return safeParse(
578
- jsonString,
579
- (x) => ListDatasetDatapoints21$inboundSchema.parse(JSON.parse(x)),
580
- `Failed to parse 'ListDatasetDatapoints21' from JSON`,
581
- );
582
- }
583
-
584
- /** @internal */
585
- export const ListDatasetDatapointsContent2$inboundSchema: z.ZodType<
586
- ListDatasetDatapointsContent2,
587
- z.ZodTypeDef,
588
- unknown
589
- > = z.union([
590
- z.lazy(() => ListDatasetDatapoints21$inboundSchema),
591
- z.lazy(() => ListDatasetDatapoints22$inboundSchema),
592
- ]);
593
-
594
- /** @internal */
595
- export type ListDatasetDatapointsContent2$Outbound =
596
- | ListDatasetDatapoints21$Outbound
597
- | ListDatasetDatapoints22$Outbound;
598
-
599
- /** @internal */
600
- export const ListDatasetDatapointsContent2$outboundSchema: z.ZodType<
601
- ListDatasetDatapointsContent2$Outbound,
602
- z.ZodTypeDef,
603
- ListDatasetDatapointsContent2
604
- > = z.union([
605
- z.lazy(() => ListDatasetDatapoints21$outboundSchema),
606
- z.lazy(() => ListDatasetDatapoints22$outboundSchema),
607
- ]);
608
-
609
- /**
610
- * @internal
611
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
612
- */
613
- export namespace ListDatasetDatapointsContent2$ {
614
- /** @deprecated use `ListDatasetDatapointsContent2$inboundSchema` instead. */
615
- export const inboundSchema = ListDatasetDatapointsContent2$inboundSchema;
616
- /** @deprecated use `ListDatasetDatapointsContent2$outboundSchema` instead. */
617
- export const outboundSchema = ListDatasetDatapointsContent2$outboundSchema;
618
- /** @deprecated use `ListDatasetDatapointsContent2$Outbound` instead. */
619
- export type Outbound = ListDatasetDatapointsContent2$Outbound;
620
- }
621
-
622
- export function listDatasetDatapointsContent2ToJSON(
623
- listDatasetDatapointsContent2: ListDatasetDatapointsContent2,
624
- ): string {
625
- return JSON.stringify(
626
- ListDatasetDatapointsContent2$outboundSchema.parse(
627
- listDatasetDatapointsContent2,
628
- ),
629
- );
630
- }
631
-
632
- export function listDatasetDatapointsContent2FromJSON(
633
- jsonString: string,
634
- ): SafeParseResult<ListDatasetDatapointsContent2, SDKValidationError> {
635
- return safeParse(
636
- jsonString,
637
- (x) => ListDatasetDatapointsContent2$inboundSchema.parse(JSON.parse(x)),
638
- `Failed to parse 'ListDatasetDatapointsContent2' from JSON`,
639
- );
640
- }
641
-
642
- /** @internal */
643
- export const ListDatasetDatapointsContent$inboundSchema: z.ZodType<
644
- ListDatasetDatapointsContent,
645
- z.ZodTypeDef,
646
- unknown
647
- > = z.union([
648
- z.string(),
649
- z.array(z.union([
650
- z.lazy(() => ListDatasetDatapoints21$inboundSchema),
651
- z.lazy(() => ListDatasetDatapoints22$inboundSchema),
652
- ])),
653
- ]);
654
-
655
- /** @internal */
656
- export type ListDatasetDatapointsContent$Outbound =
657
- | string
658
- | Array<ListDatasetDatapoints21$Outbound | ListDatasetDatapoints22$Outbound>;
659
-
660
- /** @internal */
661
- export const ListDatasetDatapointsContent$outboundSchema: z.ZodType<
662
- ListDatasetDatapointsContent$Outbound,
663
- z.ZodTypeDef,
664
- ListDatasetDatapointsContent
665
- > = z.union([
666
- z.string(),
667
- z.array(z.union([
668
- z.lazy(() => ListDatasetDatapoints21$outboundSchema),
669
- z.lazy(() => ListDatasetDatapoints22$outboundSchema),
670
- ])),
671
- ]);
672
-
673
- /**
674
- * @internal
675
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
676
- */
677
- export namespace ListDatasetDatapointsContent$ {
678
- /** @deprecated use `ListDatasetDatapointsContent$inboundSchema` instead. */
679
- export const inboundSchema = ListDatasetDatapointsContent$inboundSchema;
680
- /** @deprecated use `ListDatasetDatapointsContent$outboundSchema` instead. */
681
- export const outboundSchema = ListDatasetDatapointsContent$outboundSchema;
682
- /** @deprecated use `ListDatasetDatapointsContent$Outbound` instead. */
683
- export type Outbound = ListDatasetDatapointsContent$Outbound;
684
- }
685
-
686
- export function listDatasetDatapointsContentToJSON(
687
- listDatasetDatapointsContent: ListDatasetDatapointsContent,
688
- ): string {
689
- return JSON.stringify(
690
- ListDatasetDatapointsContent$outboundSchema.parse(
691
- listDatasetDatapointsContent,
692
- ),
693
- );
694
- }
695
-
696
- export function listDatasetDatapointsContentFromJSON(
697
- jsonString: string,
698
- ): SafeParseResult<ListDatasetDatapointsContent, SDKValidationError> {
699
- return safeParse(
700
- jsonString,
701
- (x) => ListDatasetDatapointsContent$inboundSchema.parse(JSON.parse(x)),
702
- `Failed to parse 'ListDatasetDatapointsContent' from JSON`,
703
- );
704
- }
705
-
706
- /** @internal */
707
- export const ListDatasetDatapointsType$inboundSchema: z.ZodNativeEnum<
708
- typeof ListDatasetDatapointsType
709
- > = z.nativeEnum(ListDatasetDatapointsType);
710
-
711
- /** @internal */
712
- export const ListDatasetDatapointsType$outboundSchema: z.ZodNativeEnum<
713
- typeof ListDatasetDatapointsType
714
- > = ListDatasetDatapointsType$inboundSchema;
715
-
716
- /**
717
- * @internal
718
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
719
- */
720
- export namespace ListDatasetDatapointsType$ {
721
- /** @deprecated use `ListDatasetDatapointsType$inboundSchema` instead. */
722
- export const inboundSchema = ListDatasetDatapointsType$inboundSchema;
723
- /** @deprecated use `ListDatasetDatapointsType$outboundSchema` instead. */
724
- export const outboundSchema = ListDatasetDatapointsType$outboundSchema;
725
- }
726
-
727
- /** @internal */
728
- export const ListDatasetDatapointsFunction$inboundSchema: z.ZodType<
729
- ListDatasetDatapointsFunction,
730
- z.ZodTypeDef,
731
- unknown
732
- > = z.object({
733
- name: z.string(),
734
- arguments: z.string(),
735
- });
736
-
737
- /** @internal */
738
- export type ListDatasetDatapointsFunction$Outbound = {
739
- name: string;
740
- arguments: string;
741
- };
742
-
743
- /** @internal */
744
- export const ListDatasetDatapointsFunction$outboundSchema: z.ZodType<
745
- ListDatasetDatapointsFunction$Outbound,
746
- z.ZodTypeDef,
747
- ListDatasetDatapointsFunction
748
- > = z.object({
749
- name: z.string(),
750
- arguments: z.string(),
751
- });
752
-
753
- /**
754
- * @internal
755
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
756
- */
757
- export namespace ListDatasetDatapointsFunction$ {
758
- /** @deprecated use `ListDatasetDatapointsFunction$inboundSchema` instead. */
759
- export const inboundSchema = ListDatasetDatapointsFunction$inboundSchema;
760
- /** @deprecated use `ListDatasetDatapointsFunction$outboundSchema` instead. */
761
- export const outboundSchema = ListDatasetDatapointsFunction$outboundSchema;
762
- /** @deprecated use `ListDatasetDatapointsFunction$Outbound` instead. */
763
- export type Outbound = ListDatasetDatapointsFunction$Outbound;
764
- }
765
-
766
- export function listDatasetDatapointsFunctionToJSON(
767
- listDatasetDatapointsFunction: ListDatasetDatapointsFunction,
768
- ): string {
769
- return JSON.stringify(
770
- ListDatasetDatapointsFunction$outboundSchema.parse(
771
- listDatasetDatapointsFunction,
772
- ),
773
- );
774
- }
775
-
776
- export function listDatasetDatapointsFunctionFromJSON(
777
- jsonString: string,
778
- ): SafeParseResult<ListDatasetDatapointsFunction, SDKValidationError> {
779
- return safeParse(
780
- jsonString,
781
- (x) => ListDatasetDatapointsFunction$inboundSchema.parse(JSON.parse(x)),
782
- `Failed to parse 'ListDatasetDatapointsFunction' from JSON`,
783
- );
784
- }
785
-
786
- /** @internal */
787
- export const ListDatasetDatapointsToolCalls$inboundSchema: z.ZodType<
788
- ListDatasetDatapointsToolCalls,
789
- z.ZodTypeDef,
790
- unknown
791
- > = z.object({
792
- id: z.string().optional(),
793
- index: z.number().optional(),
794
- type: ListDatasetDatapointsType$inboundSchema,
795
- function: z.lazy(() => ListDatasetDatapointsFunction$inboundSchema),
796
- });
797
-
798
- /** @internal */
799
- export type ListDatasetDatapointsToolCalls$Outbound = {
800
- id?: string | undefined;
801
- index?: number | undefined;
802
- type: string;
803
- function: ListDatasetDatapointsFunction$Outbound;
804
- };
805
-
806
- /** @internal */
807
- export const ListDatasetDatapointsToolCalls$outboundSchema: z.ZodType<
808
- ListDatasetDatapointsToolCalls$Outbound,
809
- z.ZodTypeDef,
810
- ListDatasetDatapointsToolCalls
811
- > = z.object({
812
- id: z.string().optional(),
813
- index: z.number().optional(),
814
- type: ListDatasetDatapointsType$outboundSchema,
815
- function: z.lazy(() => ListDatasetDatapointsFunction$outboundSchema),
816
- });
817
-
818
- /**
819
- * @internal
820
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
821
- */
822
- export namespace ListDatasetDatapointsToolCalls$ {
823
- /** @deprecated use `ListDatasetDatapointsToolCalls$inboundSchema` instead. */
824
- export const inboundSchema = ListDatasetDatapointsToolCalls$inboundSchema;
825
- /** @deprecated use `ListDatasetDatapointsToolCalls$outboundSchema` instead. */
826
- export const outboundSchema = ListDatasetDatapointsToolCalls$outboundSchema;
827
- /** @deprecated use `ListDatasetDatapointsToolCalls$Outbound` instead. */
828
- export type Outbound = ListDatasetDatapointsToolCalls$Outbound;
829
- }
830
-
831
- export function listDatasetDatapointsToolCallsToJSON(
832
- listDatasetDatapointsToolCalls: ListDatasetDatapointsToolCalls,
833
- ): string {
834
- return JSON.stringify(
835
- ListDatasetDatapointsToolCalls$outboundSchema.parse(
836
- listDatasetDatapointsToolCalls,
837
- ),
838
- );
839
- }
840
-
841
- export function listDatasetDatapointsToolCallsFromJSON(
842
- jsonString: string,
843
- ): SafeParseResult<ListDatasetDatapointsToolCalls, SDKValidationError> {
844
- return safeParse(
845
- jsonString,
846
- (x) => ListDatasetDatapointsToolCalls$inboundSchema.parse(JSON.parse(x)),
847
- `Failed to parse 'ListDatasetDatapointsToolCalls' from JSON`,
848
- );
849
- }
850
-
851
- /** @internal */
852
- export const ListDatasetDatapointsMessages$inboundSchema: z.ZodType<
853
- ListDatasetDatapointsMessages,
854
- z.ZodTypeDef,
855
- unknown
856
- > = z.object({
857
- role: ListDatasetDatapointsRole$inboundSchema,
858
- content: z.union([
859
- z.string(),
860
- z.array(z.union([
861
- z.lazy(() => ListDatasetDatapoints21$inboundSchema),
862
- z.lazy(() => ListDatasetDatapoints22$inboundSchema),
863
- ])),
864
- ]),
865
- tool_calls: z.array(
866
- z.lazy(() => ListDatasetDatapointsToolCalls$inboundSchema),
867
- ).optional(),
868
- }).transform((v) => {
869
- return remap$(v, {
870
- "tool_calls": "toolCalls",
871
- });
872
- });
873
-
874
- /** @internal */
875
- export type ListDatasetDatapointsMessages$Outbound = {
876
- role: string;
877
- content:
878
- | string
879
- | Array<
880
- ListDatasetDatapoints21$Outbound | ListDatasetDatapoints22$Outbound
881
- >;
882
- tool_calls?: Array<ListDatasetDatapointsToolCalls$Outbound> | undefined;
883
- };
884
-
885
- /** @internal */
886
- export const ListDatasetDatapointsMessages$outboundSchema: z.ZodType<
887
- ListDatasetDatapointsMessages$Outbound,
888
- z.ZodTypeDef,
889
- ListDatasetDatapointsMessages
890
- > = z.object({
891
- role: ListDatasetDatapointsRole$outboundSchema,
892
- content: z.union([
893
- z.string(),
894
- z.array(z.union([
895
- z.lazy(() => ListDatasetDatapoints21$outboundSchema),
896
- z.lazy(() => ListDatasetDatapoints22$outboundSchema),
897
- ])),
898
- ]),
899
- toolCalls: z.array(
900
- z.lazy(() => ListDatasetDatapointsToolCalls$outboundSchema),
901
- ).optional(),
902
- }).transform((v) => {
903
- return remap$(v, {
904
- toolCalls: "tool_calls",
905
- });
906
- });
907
-
908
- /**
909
- * @internal
910
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
911
- */
912
- export namespace ListDatasetDatapointsMessages$ {
913
- /** @deprecated use `ListDatasetDatapointsMessages$inboundSchema` instead. */
914
- export const inboundSchema = ListDatasetDatapointsMessages$inboundSchema;
915
- /** @deprecated use `ListDatasetDatapointsMessages$outboundSchema` instead. */
916
- export const outboundSchema = ListDatasetDatapointsMessages$outboundSchema;
917
- /** @deprecated use `ListDatasetDatapointsMessages$Outbound` instead. */
918
- export type Outbound = ListDatasetDatapointsMessages$Outbound;
919
- }
920
-
921
- export function listDatasetDatapointsMessagesToJSON(
922
- listDatasetDatapointsMessages: ListDatasetDatapointsMessages,
923
- ): string {
924
- return JSON.stringify(
925
- ListDatasetDatapointsMessages$outboundSchema.parse(
926
- listDatasetDatapointsMessages,
927
- ),
928
- );
929
- }
930
-
931
- export function listDatasetDatapointsMessagesFromJSON(
932
- jsonString: string,
933
- ): SafeParseResult<ListDatasetDatapointsMessages, SDKValidationError> {
934
- return safeParse(
935
- jsonString,
936
- (x) => ListDatasetDatapointsMessages$inboundSchema.parse(JSON.parse(x)),
937
- `Failed to parse 'ListDatasetDatapointsMessages' from JSON`,
938
- );
939
- }
940
-
941
- /** @internal */
942
- export const ListDatasetDatapointsData$inboundSchema: z.ZodType<
943
- ListDatasetDatapointsData,
944
- z.ZodTypeDef,
945
- unknown
946
- > = z.object({
947
- _id: z.string(),
948
- workspace_id: z.string(),
949
- inputs: z.record(z.any()).optional(),
950
- messages: z.array(z.lazy(() => ListDatasetDatapointsMessages$inboundSchema))
951
- .optional(),
952
- expected_output: z.string().optional(),
953
- dataset_id: z.string(),
954
- created_by_id: z.string().optional(),
955
- updated_by_id: z.string().optional(),
956
- created: z.string().datetime({ offset: true }).transform(v => new Date(v))
957
- .optional(),
958
- updated: z.string().datetime({ offset: true }).default(
959
- "2025-03-21T10:08:06.343Z",
960
- ).transform(v => new Date(v)),
961
- }).transform((v) => {
962
- return remap$(v, {
963
- "_id": "id",
964
- "workspace_id": "workspaceId",
965
- "expected_output": "expectedOutput",
966
- "dataset_id": "datasetId",
967
- "created_by_id": "createdById",
968
- "updated_by_id": "updatedById",
969
- });
970
- });
971
-
972
- /** @internal */
973
- export type ListDatasetDatapointsData$Outbound = {
974
- _id: string;
975
- workspace_id: string;
976
- inputs?: { [k: string]: any } | undefined;
977
- messages?: Array<ListDatasetDatapointsMessages$Outbound> | undefined;
978
- expected_output?: string | undefined;
979
- dataset_id: string;
980
- created_by_id?: string | undefined;
981
- updated_by_id?: string | undefined;
982
- created?: string | undefined;
983
- updated: string;
984
- };
985
-
986
- /** @internal */
987
- export const ListDatasetDatapointsData$outboundSchema: z.ZodType<
988
- ListDatasetDatapointsData$Outbound,
989
- z.ZodTypeDef,
990
- ListDatasetDatapointsData
991
- > = z.object({
992
- id: z.string(),
993
- workspaceId: z.string(),
994
- inputs: z.record(z.any()).optional(),
995
- messages: z.array(z.lazy(() => ListDatasetDatapointsMessages$outboundSchema))
996
- .optional(),
997
- expectedOutput: z.string().optional(),
998
- datasetId: z.string(),
999
- createdById: z.string().optional(),
1000
- updatedById: z.string().optional(),
1001
- created: z.date().transform(v => v.toISOString()).optional(),
1002
- updated: z.date().default(() => new Date("2025-03-21T10:08:06.343Z"))
1003
- .transform(v => v.toISOString()),
1004
- }).transform((v) => {
1005
- return remap$(v, {
1006
- id: "_id",
1007
- workspaceId: "workspace_id",
1008
- expectedOutput: "expected_output",
1009
- datasetId: "dataset_id",
1010
- createdById: "created_by_id",
1011
- updatedById: "updated_by_id",
1012
- });
1013
- });
1014
-
1015
- /**
1016
- * @internal
1017
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
1018
- */
1019
- export namespace ListDatasetDatapointsData$ {
1020
- /** @deprecated use `ListDatasetDatapointsData$inboundSchema` instead. */
1021
- export const inboundSchema = ListDatasetDatapointsData$inboundSchema;
1022
- /** @deprecated use `ListDatasetDatapointsData$outboundSchema` instead. */
1023
- export const outboundSchema = ListDatasetDatapointsData$outboundSchema;
1024
- /** @deprecated use `ListDatasetDatapointsData$Outbound` instead. */
1025
- export type Outbound = ListDatasetDatapointsData$Outbound;
1026
- }
1027
-
1028
- export function listDatasetDatapointsDataToJSON(
1029
- listDatasetDatapointsData: ListDatasetDatapointsData,
1030
- ): string {
1031
- return JSON.stringify(
1032
- ListDatasetDatapointsData$outboundSchema.parse(listDatasetDatapointsData),
1033
- );
1034
- }
1035
-
1036
- export function listDatasetDatapointsDataFromJSON(
1037
- jsonString: string,
1038
- ): SafeParseResult<ListDatasetDatapointsData, SDKValidationError> {
1039
- return safeParse(
1040
- jsonString,
1041
- (x) => ListDatasetDatapointsData$inboundSchema.parse(JSON.parse(x)),
1042
- `Failed to parse 'ListDatasetDatapointsData' from JSON`,
1043
- );
1044
- }
1045
-
1046
- /** @internal */
1047
- export const ListDatasetDatapointsResponseBody$inboundSchema: z.ZodType<
1048
- ListDatasetDatapointsResponseBody,
1049
- z.ZodTypeDef,
1050
- unknown
1051
- > = z.object({
1052
- object: ListDatasetDatapointsObject$inboundSchema,
1053
- data: z.array(z.lazy(() => ListDatasetDatapointsData$inboundSchema)),
1054
- has_more: z.boolean(),
1055
- }).transform((v) => {
1056
- return remap$(v, {
1057
- "has_more": "hasMore",
1058
- });
1059
- });
1060
-
1061
- /** @internal */
1062
- export type ListDatasetDatapointsResponseBody$Outbound = {
1063
- object: string;
1064
- data: Array<ListDatasetDatapointsData$Outbound>;
1065
- has_more: boolean;
1066
- };
1067
-
1068
- /** @internal */
1069
- export const ListDatasetDatapointsResponseBody$outboundSchema: z.ZodType<
1070
- ListDatasetDatapointsResponseBody$Outbound,
1071
- z.ZodTypeDef,
1072
- ListDatasetDatapointsResponseBody
1073
- > = z.object({
1074
- object: ListDatasetDatapointsObject$outboundSchema,
1075
- data: z.array(z.lazy(() => ListDatasetDatapointsData$outboundSchema)),
1076
- hasMore: z.boolean(),
1077
- }).transform((v) => {
1078
- return remap$(v, {
1079
- hasMore: "has_more",
1080
- });
1081
- });
1082
-
1083
- /**
1084
- * @internal
1085
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
1086
- */
1087
- export namespace ListDatasetDatapointsResponseBody$ {
1088
- /** @deprecated use `ListDatasetDatapointsResponseBody$inboundSchema` instead. */
1089
- export const inboundSchema = ListDatasetDatapointsResponseBody$inboundSchema;
1090
- /** @deprecated use `ListDatasetDatapointsResponseBody$outboundSchema` instead. */
1091
- export const outboundSchema =
1092
- ListDatasetDatapointsResponseBody$outboundSchema;
1093
- /** @deprecated use `ListDatasetDatapointsResponseBody$Outbound` instead. */
1094
- export type Outbound = ListDatasetDatapointsResponseBody$Outbound;
1095
- }
1096
-
1097
- export function listDatasetDatapointsResponseBodyToJSON(
1098
- listDatasetDatapointsResponseBody: ListDatasetDatapointsResponseBody,
1099
- ): string {
1100
- return JSON.stringify(
1101
- ListDatasetDatapointsResponseBody$outboundSchema.parse(
1102
- listDatasetDatapointsResponseBody,
1103
- ),
1104
- );
1105
- }
1106
-
1107
- export function listDatasetDatapointsResponseBodyFromJSON(
1108
- jsonString: string,
1109
- ): SafeParseResult<ListDatasetDatapointsResponseBody, SDKValidationError> {
1110
- return safeParse(
1111
- jsonString,
1112
- (x) => ListDatasetDatapointsResponseBody$inboundSchema.parse(JSON.parse(x)),
1113
- `Failed to parse 'ListDatasetDatapointsResponseBody' from JSON`,
1114
- );
1115
- }