@orq-ai/node 1.32.0-rc.5 → 1.32.0-rc.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.
- package/README.md +30 -0
- package/docs/sdks/prompt/README.md +6 -0
- package/docs/sdks/prompts/README.md +533 -0
- package/docs/sdks/snippets/README.md +84 -0
- package/docs/sdks/templates/README.md +80 -0
- package/funcs/promptSnippetsFindOne.d.ts +12 -0
- package/funcs/promptSnippetsFindOne.d.ts.map +1 -0
- package/funcs/promptSnippetsFindOne.js +108 -0
- package/funcs/promptSnippetsFindOne.js.map +1 -0
- package/funcs/promptTemplatesGetAll.d.ts +12 -0
- package/funcs/promptTemplatesGetAll.d.ts.map +1 -0
- package/funcs/promptTemplatesGetAll.js +108 -0
- package/funcs/promptTemplatesGetAll.js.map +1 -0
- package/funcs/promptsCreate.d.ts +12 -0
- package/funcs/promptsCreate.d.ts.map +1 -0
- package/funcs/promptsCreate.js +105 -0
- package/funcs/promptsCreate.js.map +1 -0
- package/funcs/promptsCreateVersion.d.ts +12 -0
- package/funcs/promptsCreateVersion.d.ts.map +1 -0
- package/funcs/promptsCreateVersion.js +109 -0
- package/funcs/promptsCreateVersion.js.map +1 -0
- package/funcs/promptsDelete.d.ts +12 -0
- package/funcs/promptsDelete.d.ts.map +1 -0
- package/funcs/promptsDelete.js +109 -0
- package/funcs/promptsDelete.js.map +1 -0
- package/funcs/promptsDuplicate.d.ts +12 -0
- package/funcs/promptsDuplicate.d.ts.map +1 -0
- package/funcs/promptsDuplicate.js +109 -0
- package/funcs/promptsDuplicate.js.map +1 -0
- package/funcs/promptsGetAll.d.ts +12 -0
- package/funcs/promptsGetAll.d.ts.map +1 -0
- package/funcs/promptsGetAll.js +108 -0
- package/funcs/promptsGetAll.js.map +1 -0
- package/funcs/promptsGetOne.d.ts +12 -0
- package/funcs/promptsGetOne.d.ts.map +1 -0
- package/funcs/promptsGetOne.js +109 -0
- package/funcs/promptsGetOne.js.map +1 -0
- package/funcs/promptsUpdate.d.ts +13 -0
- package/funcs/promptsUpdate.d.ts.map +1 -0
- package/funcs/promptsUpdate.js +113 -0
- package/funcs/promptsUpdate.js.map +1 -0
- package/lib/config.d.ts +2 -2
- package/lib/config.js +2 -2
- package/models/errors/index.d.ts +1 -0
- package/models/errors/index.d.ts.map +1 -1
- package/models/errors/index.js +1 -0
- package/models/errors/index.js.map +1 -1
- package/models/errors/updateprompt.d.ts +36 -0
- package/models/errors/updateprompt.d.ts.map +1 -0
- package/models/errors/updateprompt.js +79 -0
- package/models/errors/updateprompt.js.map +1 -0
- package/models/operations/bulkfileupload.js +2 -2
- package/models/operations/createcontact.js +2 -2
- package/models/operations/createprompt.d.ts +2035 -0
- package/models/operations/createprompt.d.ts.map +1 -0
- package/models/operations/createprompt.js +1853 -0
- package/models/operations/createprompt.js.map +1 -0
- package/models/operations/createpromptversion.d.ts +2001 -0
- package/models/operations/createpromptversion.d.ts.map +1 -0
- package/models/operations/createpromptversion.js +1848 -0
- package/models/operations/createpromptversion.js.map +1 -0
- package/models/operations/deleteprompt.d.ts +32 -0
- package/models/operations/deleteprompt.d.ts.map +1 -0
- package/models/operations/deleteprompt.js +69 -0
- package/models/operations/deleteprompt.js.map +1 -0
- package/models/operations/deploymentgetconfig.d.ts +96 -96
- package/models/operations/deploymentgetconfig.d.ts.map +1 -1
- package/models/operations/deploymentgetconfig.js +136 -135
- package/models/operations/deploymentgetconfig.js.map +1 -1
- package/models/operations/deploymentinvoke.d.ts +46 -49
- package/models/operations/deploymentinvoke.d.ts.map +1 -1
- package/models/operations/deploymentinvoke.js +61 -63
- package/models/operations/deploymentinvoke.js.map +1 -1
- package/models/operations/deployments.d.ts +53 -53
- package/models/operations/deployments.d.ts.map +1 -1
- package/models/operations/deployments.js +66 -67
- package/models/operations/deployments.js.map +1 -1
- package/models/operations/duplicateprompt.d.ts +32 -0
- package/models/operations/duplicateprompt.d.ts.map +1 -0
- package/models/operations/duplicateprompt.js +69 -0
- package/models/operations/duplicateprompt.js.map +1 -0
- package/models/operations/fileupload.js +2 -2
- package/models/operations/findonepromptsnippet.d.ts +6278 -0
- package/models/operations/findonepromptsnippet.d.ts.map +1 -0
- package/models/operations/findonepromptsnippet.js +5891 -0
- package/models/operations/findonepromptsnippet.js.map +1 -0
- package/models/operations/getallprompts.d.ts +6613 -0
- package/models/operations/getallprompts.d.ts.map +1 -0
- package/models/operations/getallprompts.js +6161 -0
- package/models/operations/getallprompts.js.map +1 -0
- package/models/operations/getallprompttemplates.d.ts +6607 -0
- package/models/operations/getallprompttemplates.d.ts.map +1 -0
- package/models/operations/getallprompttemplates.js +6225 -0
- package/models/operations/getallprompttemplates.js.map +1 -0
- package/models/operations/getoneprompt.d.ts +32 -0
- package/models/operations/getoneprompt.d.ts.map +1 -0
- package/models/operations/getoneprompt.js +69 -0
- package/models/operations/getoneprompt.js.map +1 -0
- package/models/operations/index.d.ts +9 -0
- package/models/operations/index.d.ts.map +1 -1
- package/models/operations/index.js +9 -0
- package/models/operations/index.js.map +1 -1
- package/models/operations/updateprompt.d.ts +7251 -0
- package/models/operations/updateprompt.d.ts.map +1 -0
- package/models/operations/updateprompt.js +6678 -0
- package/models/operations/updateprompt.js.map +1 -0
- package/package.json +1 -1
- package/sdk/prompt.d.ts +10 -0
- package/sdk/prompt.d.ts.map +1 -0
- package/sdk/prompt.js +21 -0
- package/sdk/prompt.js.map +1 -0
- package/sdk/prompts.d.ts +33 -0
- package/sdk/prompts.d.ts.map +1 -0
- package/sdk/prompts.js +61 -0
- package/sdk/prompts.js.map +1 -0
- package/sdk/sdk.d.ts +6 -0
- package/sdk/sdk.d.ts.map +1 -1
- package/sdk/sdk.js +10 -0
- package/sdk/sdk.js.map +1 -1
- package/sdk/snippets.d.ts +9 -0
- package/sdk/snippets.d.ts.map +1 -0
- package/sdk/snippets.js +19 -0
- package/sdk/snippets.js.map +1 -0
- package/sdk/templates.d.ts +9 -0
- package/sdk/templates.d.ts.map +1 -0
- package/sdk/templates.js +19 -0
- package/sdk/templates.js.map +1 -0
- package/src/funcs/promptSnippetsFindOne.ts +128 -0
- package/src/funcs/promptTemplatesGetAll.ts +130 -0
- package/src/funcs/promptsCreate.ts +124 -0
- package/src/funcs/promptsCreateVersion.ts +129 -0
- package/src/funcs/promptsDelete.ts +128 -0
- package/src/funcs/promptsDuplicate.ts +128 -0
- package/src/funcs/promptsGetAll.ts +128 -0
- package/src/funcs/promptsGetOne.ts +128 -0
- package/src/funcs/promptsUpdate.ts +136 -0
- package/src/lib/config.ts +2 -2
- package/src/models/errors/index.ts +1 -0
- package/src/models/errors/updateprompt.ts +71 -0
- package/src/models/operations/bulkfileupload.ts +2 -2
- package/src/models/operations/createcontact.ts +2 -2
- package/src/models/operations/createprompt.ts +3455 -0
- package/src/models/operations/createpromptversion.ts +3697 -0
- package/src/models/operations/deleteprompt.ts +69 -0
- package/src/models/operations/deploymentgetconfig.ts +255 -188
- package/src/models/operations/deploymentinvoke.ts +95 -81
- package/src/models/operations/deployments.ts +101 -88
- package/src/models/operations/duplicateprompt.ts +69 -0
- package/src/models/operations/fileupload.ts +2 -2
- package/src/models/operations/findonepromptsnippet.ts +13629 -0
- package/src/models/operations/getallprompts.ts +13390 -0
- package/src/models/operations/getallprompttemplates.ts +13690 -0
- package/src/models/operations/getoneprompt.ts +69 -0
- package/src/models/operations/index.ts +9 -0
- package/src/models/operations/updateprompt.ts +14407 -0
- package/src/sdk/prompt.ts +19 -0
- package/src/sdk/prompts.ts +114 -0
- package/src/sdk/sdk.ts +12 -0
- package/src/sdk/snippets.ts +24 -0
- package/src/sdk/templates.ts +24 -0
|
@@ -89,7 +89,7 @@ export type DeploymentsTools = {
|
|
|
89
89
|
/**
|
|
90
90
|
* The type of the model
|
|
91
91
|
*/
|
|
92
|
-
export const
|
|
92
|
+
export const DeploymentsModelType = {
|
|
93
93
|
Chat: "chat",
|
|
94
94
|
Completion: "completion",
|
|
95
95
|
Embedding: "embedding",
|
|
@@ -103,7 +103,7 @@ export const ModelType = {
|
|
|
103
103
|
/**
|
|
104
104
|
* The type of the model
|
|
105
105
|
*/
|
|
106
|
-
export type
|
|
106
|
+
export type DeploymentsModelType = ClosedEnum<typeof DeploymentsModelType>;
|
|
107
107
|
|
|
108
108
|
/**
|
|
109
109
|
* Only supported on `image` models.
|
|
@@ -149,7 +149,7 @@ export type DeploymentsResponseFormatDeploymentsType = ClosedEnum<
|
|
|
149
149
|
typeof DeploymentsResponseFormatDeploymentsType
|
|
150
150
|
>;
|
|
151
151
|
|
|
152
|
-
export type
|
|
152
|
+
export type DeploymentsResponseFormatJsonSchema = {
|
|
153
153
|
name: string;
|
|
154
154
|
strict: boolean;
|
|
155
155
|
schema: { [k: string]: any };
|
|
@@ -157,7 +157,7 @@ export type ResponseFormatJsonSchema = {
|
|
|
157
157
|
|
|
158
158
|
export type DeploymentsResponseFormat1 = {
|
|
159
159
|
type: DeploymentsResponseFormatDeploymentsType;
|
|
160
|
-
jsonSchema:
|
|
160
|
+
jsonSchema: DeploymentsResponseFormatJsonSchema;
|
|
161
161
|
};
|
|
162
162
|
|
|
163
163
|
/**
|
|
@@ -206,7 +206,7 @@ export type DeploymentsEncodingFormat = ClosedEnum<
|
|
|
206
206
|
/**
|
|
207
207
|
* Model Parameters: Not all parameters apply to every model
|
|
208
208
|
*/
|
|
209
|
-
export type
|
|
209
|
+
export type DeploymentsModelParameters = {
|
|
210
210
|
/**
|
|
211
211
|
* Only supported on `chat` and `completion` models.
|
|
212
212
|
*/
|
|
@@ -403,17 +403,17 @@ export type DeploymentsMessages = {
|
|
|
403
403
|
toolCalls?: Array<DeploymentsToolCalls> | undefined;
|
|
404
404
|
};
|
|
405
405
|
|
|
406
|
-
export type
|
|
406
|
+
export type DeploymentsPromptConfig = {
|
|
407
407
|
tools: Array<DeploymentsTools>;
|
|
408
408
|
model: string;
|
|
409
409
|
/**
|
|
410
410
|
* The type of the model
|
|
411
411
|
*/
|
|
412
|
-
modelType:
|
|
412
|
+
modelType: DeploymentsModelType;
|
|
413
413
|
/**
|
|
414
414
|
* Model Parameters: Not all parameters apply to every model
|
|
415
415
|
*/
|
|
416
|
-
modelParameters:
|
|
416
|
+
modelParameters: DeploymentsModelParameters;
|
|
417
417
|
provider: DeploymentsProvider;
|
|
418
418
|
messages: Array<DeploymentsMessages>;
|
|
419
419
|
};
|
|
@@ -439,7 +439,7 @@ export type Data = {
|
|
|
439
439
|
* An arbitrary string attached to the object. Often useful for displaying to users.
|
|
440
440
|
*/
|
|
441
441
|
description: string;
|
|
442
|
-
promptConfig:
|
|
442
|
+
promptConfig: DeploymentsPromptConfig;
|
|
443
443
|
/**
|
|
444
444
|
* THe version of the deployment
|
|
445
445
|
*/
|
|
@@ -761,22 +761,24 @@ export function deploymentsToolsFromJSON(
|
|
|
761
761
|
}
|
|
762
762
|
|
|
763
763
|
/** @internal */
|
|
764
|
-
export const
|
|
765
|
-
|
|
764
|
+
export const DeploymentsModelType$inboundSchema: z.ZodNativeEnum<
|
|
765
|
+
typeof DeploymentsModelType
|
|
766
|
+
> = z.nativeEnum(DeploymentsModelType);
|
|
766
767
|
|
|
767
768
|
/** @internal */
|
|
768
|
-
export const
|
|
769
|
-
|
|
769
|
+
export const DeploymentsModelType$outboundSchema: z.ZodNativeEnum<
|
|
770
|
+
typeof DeploymentsModelType
|
|
771
|
+
> = DeploymentsModelType$inboundSchema;
|
|
770
772
|
|
|
771
773
|
/**
|
|
772
774
|
* @internal
|
|
773
775
|
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
774
776
|
*/
|
|
775
|
-
export namespace
|
|
776
|
-
/** @deprecated use `
|
|
777
|
-
export const inboundSchema =
|
|
778
|
-
/** @deprecated use `
|
|
779
|
-
export const outboundSchema =
|
|
777
|
+
export namespace DeploymentsModelType$ {
|
|
778
|
+
/** @deprecated use `DeploymentsModelType$inboundSchema` instead. */
|
|
779
|
+
export const inboundSchema = DeploymentsModelType$inboundSchema;
|
|
780
|
+
/** @deprecated use `DeploymentsModelType$outboundSchema` instead. */
|
|
781
|
+
export const outboundSchema = DeploymentsModelType$outboundSchema;
|
|
780
782
|
}
|
|
781
783
|
|
|
782
784
|
/** @internal */
|
|
@@ -920,8 +922,8 @@ export namespace DeploymentsResponseFormatDeploymentsType$ {
|
|
|
920
922
|
}
|
|
921
923
|
|
|
922
924
|
/** @internal */
|
|
923
|
-
export const
|
|
924
|
-
|
|
925
|
+
export const DeploymentsResponseFormatJsonSchema$inboundSchema: z.ZodType<
|
|
926
|
+
DeploymentsResponseFormatJsonSchema,
|
|
925
927
|
z.ZodTypeDef,
|
|
926
928
|
unknown
|
|
927
929
|
> = z.object({
|
|
@@ -931,17 +933,17 @@ export const ResponseFormatJsonSchema$inboundSchema: z.ZodType<
|
|
|
931
933
|
});
|
|
932
934
|
|
|
933
935
|
/** @internal */
|
|
934
|
-
export type
|
|
936
|
+
export type DeploymentsResponseFormatJsonSchema$Outbound = {
|
|
935
937
|
name: string;
|
|
936
938
|
strict: boolean;
|
|
937
939
|
schema: { [k: string]: any };
|
|
938
940
|
};
|
|
939
941
|
|
|
940
942
|
/** @internal */
|
|
941
|
-
export const
|
|
942
|
-
|
|
943
|
+
export const DeploymentsResponseFormatJsonSchema$outboundSchema: z.ZodType<
|
|
944
|
+
DeploymentsResponseFormatJsonSchema$Outbound,
|
|
943
945
|
z.ZodTypeDef,
|
|
944
|
-
|
|
946
|
+
DeploymentsResponseFormatJsonSchema
|
|
945
947
|
> = z.object({
|
|
946
948
|
name: z.string(),
|
|
947
949
|
strict: z.boolean(),
|
|
@@ -952,30 +954,35 @@ export const ResponseFormatJsonSchema$outboundSchema: z.ZodType<
|
|
|
952
954
|
* @internal
|
|
953
955
|
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
954
956
|
*/
|
|
955
|
-
export namespace
|
|
956
|
-
/** @deprecated use `
|
|
957
|
-
export const inboundSchema =
|
|
958
|
-
|
|
959
|
-
|
|
960
|
-
|
|
961
|
-
|
|
957
|
+
export namespace DeploymentsResponseFormatJsonSchema$ {
|
|
958
|
+
/** @deprecated use `DeploymentsResponseFormatJsonSchema$inboundSchema` instead. */
|
|
959
|
+
export const inboundSchema =
|
|
960
|
+
DeploymentsResponseFormatJsonSchema$inboundSchema;
|
|
961
|
+
/** @deprecated use `DeploymentsResponseFormatJsonSchema$outboundSchema` instead. */
|
|
962
|
+
export const outboundSchema =
|
|
963
|
+
DeploymentsResponseFormatJsonSchema$outboundSchema;
|
|
964
|
+
/** @deprecated use `DeploymentsResponseFormatJsonSchema$Outbound` instead. */
|
|
965
|
+
export type Outbound = DeploymentsResponseFormatJsonSchema$Outbound;
|
|
962
966
|
}
|
|
963
967
|
|
|
964
|
-
export function
|
|
965
|
-
|
|
968
|
+
export function deploymentsResponseFormatJsonSchemaToJSON(
|
|
969
|
+
deploymentsResponseFormatJsonSchema: DeploymentsResponseFormatJsonSchema,
|
|
966
970
|
): string {
|
|
967
971
|
return JSON.stringify(
|
|
968
|
-
|
|
972
|
+
DeploymentsResponseFormatJsonSchema$outboundSchema.parse(
|
|
973
|
+
deploymentsResponseFormatJsonSchema,
|
|
974
|
+
),
|
|
969
975
|
);
|
|
970
976
|
}
|
|
971
977
|
|
|
972
|
-
export function
|
|
978
|
+
export function deploymentsResponseFormatJsonSchemaFromJSON(
|
|
973
979
|
jsonString: string,
|
|
974
|
-
): SafeParseResult<
|
|
980
|
+
): SafeParseResult<DeploymentsResponseFormatJsonSchema, SDKValidationError> {
|
|
975
981
|
return safeParse(
|
|
976
982
|
jsonString,
|
|
977
|
-
(x) =>
|
|
978
|
-
|
|
983
|
+
(x) =>
|
|
984
|
+
DeploymentsResponseFormatJsonSchema$inboundSchema.parse(JSON.parse(x)),
|
|
985
|
+
`Failed to parse 'DeploymentsResponseFormatJsonSchema' from JSON`,
|
|
979
986
|
);
|
|
980
987
|
}
|
|
981
988
|
|
|
@@ -986,7 +993,7 @@ export const DeploymentsResponseFormat1$inboundSchema: z.ZodType<
|
|
|
986
993
|
unknown
|
|
987
994
|
> = z.object({
|
|
988
995
|
type: DeploymentsResponseFormatDeploymentsType$inboundSchema,
|
|
989
|
-
json_schema: z.lazy(() =>
|
|
996
|
+
json_schema: z.lazy(() => DeploymentsResponseFormatJsonSchema$inboundSchema),
|
|
990
997
|
}).transform((v) => {
|
|
991
998
|
return remap$(v, {
|
|
992
999
|
"json_schema": "jsonSchema",
|
|
@@ -996,7 +1003,7 @@ export const DeploymentsResponseFormat1$inboundSchema: z.ZodType<
|
|
|
996
1003
|
/** @internal */
|
|
997
1004
|
export type DeploymentsResponseFormat1$Outbound = {
|
|
998
1005
|
type: string;
|
|
999
|
-
json_schema:
|
|
1006
|
+
json_schema: DeploymentsResponseFormatJsonSchema$Outbound;
|
|
1000
1007
|
};
|
|
1001
1008
|
|
|
1002
1009
|
/** @internal */
|
|
@@ -1006,7 +1013,7 @@ export const DeploymentsResponseFormat1$outboundSchema: z.ZodType<
|
|
|
1006
1013
|
DeploymentsResponseFormat1
|
|
1007
1014
|
> = z.object({
|
|
1008
1015
|
type: DeploymentsResponseFormatDeploymentsType$outboundSchema,
|
|
1009
|
-
jsonSchema: z.lazy(() =>
|
|
1016
|
+
jsonSchema: z.lazy(() => DeploymentsResponseFormatJsonSchema$outboundSchema),
|
|
1010
1017
|
}).transform((v) => {
|
|
1011
1018
|
return remap$(v, {
|
|
1012
1019
|
jsonSchema: "json_schema",
|
|
@@ -1143,8 +1150,8 @@ export namespace DeploymentsEncodingFormat$ {
|
|
|
1143
1150
|
}
|
|
1144
1151
|
|
|
1145
1152
|
/** @internal */
|
|
1146
|
-
export const
|
|
1147
|
-
|
|
1153
|
+
export const DeploymentsModelParameters$inboundSchema: z.ZodType<
|
|
1154
|
+
DeploymentsModelParameters,
|
|
1148
1155
|
z.ZodTypeDef,
|
|
1149
1156
|
unknown
|
|
1150
1157
|
> = z.object({
|
|
@@ -1175,7 +1182,7 @@ export const ModelParameters$inboundSchema: z.ZodType<
|
|
|
1175
1182
|
});
|
|
1176
1183
|
|
|
1177
1184
|
/** @internal */
|
|
1178
|
-
export type
|
|
1185
|
+
export type DeploymentsModelParameters$Outbound = {
|
|
1179
1186
|
temperature?: number | undefined;
|
|
1180
1187
|
maxTokens?: number | undefined;
|
|
1181
1188
|
topK?: number | undefined;
|
|
@@ -1198,10 +1205,10 @@ export type ModelParameters$Outbound = {
|
|
|
1198
1205
|
};
|
|
1199
1206
|
|
|
1200
1207
|
/** @internal */
|
|
1201
|
-
export const
|
|
1202
|
-
|
|
1208
|
+
export const DeploymentsModelParameters$outboundSchema: z.ZodType<
|
|
1209
|
+
DeploymentsModelParameters$Outbound,
|
|
1203
1210
|
z.ZodTypeDef,
|
|
1204
|
-
|
|
1211
|
+
DeploymentsModelParameters
|
|
1205
1212
|
> = z.object({
|
|
1206
1213
|
temperature: z.number().optional(),
|
|
1207
1214
|
maxTokens: z.number().optional(),
|
|
@@ -1233,28 +1240,30 @@ export const ModelParameters$outboundSchema: z.ZodType<
|
|
|
1233
1240
|
* @internal
|
|
1234
1241
|
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
1235
1242
|
*/
|
|
1236
|
-
export namespace
|
|
1237
|
-
/** @deprecated use `
|
|
1238
|
-
export const inboundSchema =
|
|
1239
|
-
/** @deprecated use `
|
|
1240
|
-
export const outboundSchema =
|
|
1241
|
-
/** @deprecated use `
|
|
1242
|
-
export type Outbound =
|
|
1243
|
+
export namespace DeploymentsModelParameters$ {
|
|
1244
|
+
/** @deprecated use `DeploymentsModelParameters$inboundSchema` instead. */
|
|
1245
|
+
export const inboundSchema = DeploymentsModelParameters$inboundSchema;
|
|
1246
|
+
/** @deprecated use `DeploymentsModelParameters$outboundSchema` instead. */
|
|
1247
|
+
export const outboundSchema = DeploymentsModelParameters$outboundSchema;
|
|
1248
|
+
/** @deprecated use `DeploymentsModelParameters$Outbound` instead. */
|
|
1249
|
+
export type Outbound = DeploymentsModelParameters$Outbound;
|
|
1243
1250
|
}
|
|
1244
1251
|
|
|
1245
|
-
export function
|
|
1246
|
-
|
|
1252
|
+
export function deploymentsModelParametersToJSON(
|
|
1253
|
+
deploymentsModelParameters: DeploymentsModelParameters,
|
|
1247
1254
|
): string {
|
|
1248
|
-
return JSON.stringify(
|
|
1255
|
+
return JSON.stringify(
|
|
1256
|
+
DeploymentsModelParameters$outboundSchema.parse(deploymentsModelParameters),
|
|
1257
|
+
);
|
|
1249
1258
|
}
|
|
1250
1259
|
|
|
1251
|
-
export function
|
|
1260
|
+
export function deploymentsModelParametersFromJSON(
|
|
1252
1261
|
jsonString: string,
|
|
1253
|
-
): SafeParseResult<
|
|
1262
|
+
): SafeParseResult<DeploymentsModelParameters, SDKValidationError> {
|
|
1254
1263
|
return safeParse(
|
|
1255
1264
|
jsonString,
|
|
1256
|
-
(x) =>
|
|
1257
|
-
`Failed to parse '
|
|
1265
|
+
(x) => DeploymentsModelParameters$inboundSchema.parse(JSON.parse(x)),
|
|
1266
|
+
`Failed to parse 'DeploymentsModelParameters' from JSON`,
|
|
1258
1267
|
);
|
|
1259
1268
|
}
|
|
1260
1269
|
|
|
@@ -1860,15 +1869,15 @@ export function deploymentsMessagesFromJSON(
|
|
|
1860
1869
|
}
|
|
1861
1870
|
|
|
1862
1871
|
/** @internal */
|
|
1863
|
-
export const
|
|
1864
|
-
|
|
1872
|
+
export const DeploymentsPromptConfig$inboundSchema: z.ZodType<
|
|
1873
|
+
DeploymentsPromptConfig,
|
|
1865
1874
|
z.ZodTypeDef,
|
|
1866
1875
|
unknown
|
|
1867
1876
|
> = z.object({
|
|
1868
1877
|
tools: z.array(z.lazy(() => DeploymentsTools$inboundSchema)),
|
|
1869
1878
|
model: z.string(),
|
|
1870
|
-
model_type:
|
|
1871
|
-
model_parameters: z.lazy(() =>
|
|
1879
|
+
model_type: DeploymentsModelType$inboundSchema,
|
|
1880
|
+
model_parameters: z.lazy(() => DeploymentsModelParameters$inboundSchema),
|
|
1872
1881
|
provider: DeploymentsProvider$inboundSchema,
|
|
1873
1882
|
messages: z.array(z.lazy(() => DeploymentsMessages$inboundSchema)),
|
|
1874
1883
|
}).transform((v) => {
|
|
@@ -1879,25 +1888,25 @@ export const PromptConfig$inboundSchema: z.ZodType<
|
|
|
1879
1888
|
});
|
|
1880
1889
|
|
|
1881
1890
|
/** @internal */
|
|
1882
|
-
export type
|
|
1891
|
+
export type DeploymentsPromptConfig$Outbound = {
|
|
1883
1892
|
tools: Array<DeploymentsTools$Outbound>;
|
|
1884
1893
|
model: string;
|
|
1885
1894
|
model_type: string;
|
|
1886
|
-
model_parameters:
|
|
1895
|
+
model_parameters: DeploymentsModelParameters$Outbound;
|
|
1887
1896
|
provider: string;
|
|
1888
1897
|
messages: Array<DeploymentsMessages$Outbound>;
|
|
1889
1898
|
};
|
|
1890
1899
|
|
|
1891
1900
|
/** @internal */
|
|
1892
|
-
export const
|
|
1893
|
-
|
|
1901
|
+
export const DeploymentsPromptConfig$outboundSchema: z.ZodType<
|
|
1902
|
+
DeploymentsPromptConfig$Outbound,
|
|
1894
1903
|
z.ZodTypeDef,
|
|
1895
|
-
|
|
1904
|
+
DeploymentsPromptConfig
|
|
1896
1905
|
> = z.object({
|
|
1897
1906
|
tools: z.array(z.lazy(() => DeploymentsTools$outboundSchema)),
|
|
1898
1907
|
model: z.string(),
|
|
1899
|
-
modelType:
|
|
1900
|
-
modelParameters: z.lazy(() =>
|
|
1908
|
+
modelType: DeploymentsModelType$outboundSchema,
|
|
1909
|
+
modelParameters: z.lazy(() => DeploymentsModelParameters$outboundSchema),
|
|
1901
1910
|
provider: DeploymentsProvider$outboundSchema,
|
|
1902
1911
|
messages: z.array(z.lazy(() => DeploymentsMessages$outboundSchema)),
|
|
1903
1912
|
}).transform((v) => {
|
|
@@ -1911,26 +1920,30 @@ export const PromptConfig$outboundSchema: z.ZodType<
|
|
|
1911
1920
|
* @internal
|
|
1912
1921
|
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
1913
1922
|
*/
|
|
1914
|
-
export namespace
|
|
1915
|
-
/** @deprecated use `
|
|
1916
|
-
export const inboundSchema =
|
|
1917
|
-
/** @deprecated use `
|
|
1918
|
-
export const outboundSchema =
|
|
1919
|
-
/** @deprecated use `
|
|
1920
|
-
export type Outbound =
|
|
1923
|
+
export namespace DeploymentsPromptConfig$ {
|
|
1924
|
+
/** @deprecated use `DeploymentsPromptConfig$inboundSchema` instead. */
|
|
1925
|
+
export const inboundSchema = DeploymentsPromptConfig$inboundSchema;
|
|
1926
|
+
/** @deprecated use `DeploymentsPromptConfig$outboundSchema` instead. */
|
|
1927
|
+
export const outboundSchema = DeploymentsPromptConfig$outboundSchema;
|
|
1928
|
+
/** @deprecated use `DeploymentsPromptConfig$Outbound` instead. */
|
|
1929
|
+
export type Outbound = DeploymentsPromptConfig$Outbound;
|
|
1921
1930
|
}
|
|
1922
1931
|
|
|
1923
|
-
export function
|
|
1924
|
-
|
|
1932
|
+
export function deploymentsPromptConfigToJSON(
|
|
1933
|
+
deploymentsPromptConfig: DeploymentsPromptConfig,
|
|
1934
|
+
): string {
|
|
1935
|
+
return JSON.stringify(
|
|
1936
|
+
DeploymentsPromptConfig$outboundSchema.parse(deploymentsPromptConfig),
|
|
1937
|
+
);
|
|
1925
1938
|
}
|
|
1926
1939
|
|
|
1927
|
-
export function
|
|
1940
|
+
export function deploymentsPromptConfigFromJSON(
|
|
1928
1941
|
jsonString: string,
|
|
1929
|
-
): SafeParseResult<
|
|
1942
|
+
): SafeParseResult<DeploymentsPromptConfig, SDKValidationError> {
|
|
1930
1943
|
return safeParse(
|
|
1931
1944
|
jsonString,
|
|
1932
|
-
(x) =>
|
|
1933
|
-
`Failed to parse '
|
|
1945
|
+
(x) => DeploymentsPromptConfig$inboundSchema.parse(JSON.parse(x)),
|
|
1946
|
+
`Failed to parse 'DeploymentsPromptConfig' from JSON`,
|
|
1934
1947
|
);
|
|
1935
1948
|
}
|
|
1936
1949
|
|
|
@@ -1942,7 +1955,7 @@ export const Data$inboundSchema: z.ZodType<Data, z.ZodTypeDef, unknown> = z
|
|
|
1942
1955
|
updated: z.string(),
|
|
1943
1956
|
key: z.string(),
|
|
1944
1957
|
description: z.string(),
|
|
1945
|
-
prompt_config: z.lazy(() =>
|
|
1958
|
+
prompt_config: z.lazy(() => DeploymentsPromptConfig$inboundSchema),
|
|
1946
1959
|
version: z.string(),
|
|
1947
1960
|
}).transform((v) => {
|
|
1948
1961
|
return remap$(v, {
|
|
@@ -1957,7 +1970,7 @@ export type Data$Outbound = {
|
|
|
1957
1970
|
updated: string;
|
|
1958
1971
|
key: string;
|
|
1959
1972
|
description: string;
|
|
1960
|
-
prompt_config:
|
|
1973
|
+
prompt_config: DeploymentsPromptConfig$Outbound;
|
|
1961
1974
|
version: string;
|
|
1962
1975
|
};
|
|
1963
1976
|
|
|
@@ -1969,7 +1982,7 @@ export const Data$outboundSchema: z.ZodType<Data$Outbound, z.ZodTypeDef, Data> =
|
|
|
1969
1982
|
updated: z.string(),
|
|
1970
1983
|
key: z.string(),
|
|
1971
1984
|
description: z.string(),
|
|
1972
|
-
promptConfig: z.lazy(() =>
|
|
1985
|
+
promptConfig: z.lazy(() => DeploymentsPromptConfig$outboundSchema),
|
|
1973
1986
|
version: z.string(),
|
|
1974
1987
|
}).transform((v) => {
|
|
1975
1988
|
return remap$(v, {
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod";
|
|
6
|
+
import { safeParse } from "../../lib/schemas.js";
|
|
7
|
+
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
8
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
9
|
+
|
|
10
|
+
export type DuplicatePromptRequest = {
|
|
11
|
+
/**
|
|
12
|
+
* Prompt ID
|
|
13
|
+
*/
|
|
14
|
+
id: string;
|
|
15
|
+
};
|
|
16
|
+
|
|
17
|
+
/** @internal */
|
|
18
|
+
export const DuplicatePromptRequest$inboundSchema: z.ZodType<
|
|
19
|
+
DuplicatePromptRequest,
|
|
20
|
+
z.ZodTypeDef,
|
|
21
|
+
unknown
|
|
22
|
+
> = z.object({
|
|
23
|
+
id: z.string(),
|
|
24
|
+
});
|
|
25
|
+
|
|
26
|
+
/** @internal */
|
|
27
|
+
export type DuplicatePromptRequest$Outbound = {
|
|
28
|
+
id: string;
|
|
29
|
+
};
|
|
30
|
+
|
|
31
|
+
/** @internal */
|
|
32
|
+
export const DuplicatePromptRequest$outboundSchema: z.ZodType<
|
|
33
|
+
DuplicatePromptRequest$Outbound,
|
|
34
|
+
z.ZodTypeDef,
|
|
35
|
+
DuplicatePromptRequest
|
|
36
|
+
> = z.object({
|
|
37
|
+
id: z.string(),
|
|
38
|
+
});
|
|
39
|
+
|
|
40
|
+
/**
|
|
41
|
+
* @internal
|
|
42
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
43
|
+
*/
|
|
44
|
+
export namespace DuplicatePromptRequest$ {
|
|
45
|
+
/** @deprecated use `DuplicatePromptRequest$inboundSchema` instead. */
|
|
46
|
+
export const inboundSchema = DuplicatePromptRequest$inboundSchema;
|
|
47
|
+
/** @deprecated use `DuplicatePromptRequest$outboundSchema` instead. */
|
|
48
|
+
export const outboundSchema = DuplicatePromptRequest$outboundSchema;
|
|
49
|
+
/** @deprecated use `DuplicatePromptRequest$Outbound` instead. */
|
|
50
|
+
export type Outbound = DuplicatePromptRequest$Outbound;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
export function duplicatePromptRequestToJSON(
|
|
54
|
+
duplicatePromptRequest: DuplicatePromptRequest,
|
|
55
|
+
): string {
|
|
56
|
+
return JSON.stringify(
|
|
57
|
+
DuplicatePromptRequest$outboundSchema.parse(duplicatePromptRequest),
|
|
58
|
+
);
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
export function duplicatePromptRequestFromJSON(
|
|
62
|
+
jsonString: string,
|
|
63
|
+
): SafeParseResult<DuplicatePromptRequest, SDKValidationError> {
|
|
64
|
+
return safeParse(
|
|
65
|
+
jsonString,
|
|
66
|
+
(x) => DuplicatePromptRequest$inboundSchema.parse(JSON.parse(x)),
|
|
67
|
+
`Failed to parse 'DuplicatePromptRequest' from JSON`,
|
|
68
|
+
);
|
|
69
|
+
}
|
|
@@ -238,7 +238,7 @@ export const FileUploadResponseBody$inboundSchema: z.ZodType<
|
|
|
238
238
|
bytes: z.number(),
|
|
239
239
|
file_name: z.string(),
|
|
240
240
|
created: z.string().datetime({ offset: true }).default(
|
|
241
|
-
"2024-12-
|
|
241
|
+
"2024-12-01T21:30:45.101Z",
|
|
242
242
|
).transform(v => new Date(v)),
|
|
243
243
|
}).transform((v) => {
|
|
244
244
|
return remap$(v, {
|
|
@@ -269,7 +269,7 @@ export const FileUploadResponseBody$outboundSchema: z.ZodType<
|
|
|
269
269
|
purpose: FileUploadPurpose$outboundSchema,
|
|
270
270
|
bytes: z.number(),
|
|
271
271
|
fileName: z.string(),
|
|
272
|
-
created: z.date().default(() => new Date("2024-12-
|
|
272
|
+
created: z.date().default(() => new Date("2024-12-01T21:30:45.101Z"))
|
|
273
273
|
.transform(v => v.toISOString()),
|
|
274
274
|
}).transform((v) => {
|
|
275
275
|
return remap$(v, {
|