@orq-ai/node 3.1.7 → 3.2.0-rc.3

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 (147) hide show
  1. package/README.md +0 -38
  2. package/docs/sdks/deployments/README.md +0 -81
  3. package/jsr.json +1 -2
  4. package/lib/config.d.ts +3 -3
  5. package/lib/config.js +3 -3
  6. package/lib/config.js.map +1 -1
  7. package/lib/matchers.d.ts.map +1 -1
  8. package/lib/matchers.js +1 -4
  9. package/lib/matchers.js.map +1 -1
  10. package/models/operations/createcontact.js +2 -2
  11. package/models/operations/fileget.js +2 -2
  12. package/models/operations/filelist.js +2 -2
  13. package/models/operations/fileupload.js +2 -2
  14. package/models/operations/index.d.ts +0 -1
  15. package/models/operations/index.d.ts.map +1 -1
  16. package/models/operations/index.js +0 -1
  17. package/models/operations/index.js.map +1 -1
  18. package/package.json +3 -2
  19. package/sdk/deployments.d.ts +0 -8
  20. package/sdk/deployments.d.ts.map +1 -1
  21. package/sdk/deployments.js +0 -10
  22. package/sdk/deployments.js.map +1 -1
  23. package/src/lib/config.ts +3 -3
  24. package/src/lib/matchers.ts +1 -4
  25. package/src/models/operations/createcontact.ts +2 -2
  26. package/src/models/operations/fileget.ts +2 -2
  27. package/src/models/operations/filelist.ts +2 -2
  28. package/src/models/operations/fileupload.ts +2 -2
  29. package/src/models/operations/index.ts +0 -1
  30. package/src/sdk/deployments.ts +0 -19
  31. package/funcs/deploymentsStream.d.ts +0 -16
  32. package/funcs/deploymentsStream.d.ts.map +0 -1
  33. package/funcs/deploymentsStream.js +0 -126
  34. package/funcs/deploymentsStream.js.map +0 -1
  35. package/lib/event-streams.d.ts +0 -17
  36. package/lib/event-streams.d.ts.map +0 -1
  37. package/lib/event-streams.js +0 -220
  38. package/lib/event-streams.js.map +0 -1
  39. package/models/operations/deploymentstream.d.ts +0 -1622
  40. package/models/operations/deploymentstream.d.ts.map +0 -1
  41. package/models/operations/deploymentstream.js +0 -1571
  42. package/models/operations/deploymentstream.js.map +0 -1
  43. package/packages/orq-rc/FUNCTIONS.md +0 -106
  44. package/packages/orq-rc/README.md +0 -506
  45. package/packages/orq-rc/RUNTIMES.md +0 -48
  46. package/packages/orq-rc/docs/sdks/contacts/README.md +0 -84
  47. package/packages/orq-rc/docs/sdks/deployments/README.md +0 -235
  48. package/packages/orq-rc/docs/sdks/feedback/README.md +0 -92
  49. package/packages/orq-rc/docs/sdks/files/README.md +0 -305
  50. package/packages/orq-rc/docs/sdks/metrics/README.md +0 -86
  51. package/packages/orq-rc/docs/sdks/orq/README.md +0 -10
  52. package/packages/orq-rc/docs/sdks/prompts/README.md +0 -608
  53. package/packages/orq-rc/docs/sdks/remoteconfigs/README.md +0 -80
  54. package/packages/orq-rc/jsr.json +0 -27
  55. package/packages/orq-rc/package-lock.json +0 -1861
  56. package/packages/orq-rc/package.json +0 -31
  57. package/packages/orq-rc/src/core.ts +0 -13
  58. package/packages/orq-rc/src/funcs/contactsCreate.ts +0 -127
  59. package/packages/orq-rc/src/funcs/deploymentsGetConfig.ts +0 -135
  60. package/packages/orq-rc/src/funcs/deploymentsInvoke.ts +0 -143
  61. package/packages/orq-rc/src/funcs/deploymentsList.ts +0 -142
  62. package/packages/orq-rc/src/funcs/deploymentsMetricsCreate.ts +0 -135
  63. package/packages/orq-rc/src/funcs/feedbackCreate.ts +0 -127
  64. package/packages/orq-rc/src/funcs/filesCreate.ts +0 -150
  65. package/packages/orq-rc/src/funcs/filesDelete.ts +0 -131
  66. package/packages/orq-rc/src/funcs/filesGet.ts +0 -133
  67. package/packages/orq-rc/src/funcs/filesList.ts +0 -134
  68. package/packages/orq-rc/src/funcs/promptsCreate.ts +0 -127
  69. package/packages/orq-rc/src/funcs/promptsDelete.ts +0 -131
  70. package/packages/orq-rc/src/funcs/promptsGetVersion.ts +0 -147
  71. package/packages/orq-rc/src/funcs/promptsList.ts +0 -134
  72. package/packages/orq-rc/src/funcs/promptsListVersions.ts +0 -140
  73. package/packages/orq-rc/src/funcs/promptsRetrieve.ts +0 -133
  74. package/packages/orq-rc/src/funcs/promptsUpdate.ts +0 -139
  75. package/packages/orq-rc/src/funcs/remoteconfigsRetrieve.ts +0 -128
  76. package/packages/orq-rc/src/hooks/global.ts +0 -44
  77. package/packages/orq-rc/src/hooks/hooks.ts +0 -132
  78. package/packages/orq-rc/src/hooks/index.ts +0 -6
  79. package/packages/orq-rc/src/hooks/registration.ts +0 -15
  80. package/packages/orq-rc/src/hooks/types.ts +0 -110
  81. package/packages/orq-rc/src/index.ts +0 -7
  82. package/packages/orq-rc/src/lib/base64.ts +0 -37
  83. package/packages/orq-rc/src/lib/config.ts +0 -70
  84. package/packages/orq-rc/src/lib/dlv.ts +0 -53
  85. package/packages/orq-rc/src/lib/encodings.ts +0 -483
  86. package/packages/orq-rc/src/lib/env.ts +0 -73
  87. package/packages/orq-rc/src/lib/files.ts +0 -40
  88. package/packages/orq-rc/src/lib/http.ts +0 -323
  89. package/packages/orq-rc/src/lib/is-plain-object.ts +0 -43
  90. package/packages/orq-rc/src/lib/logger.ts +0 -9
  91. package/packages/orq-rc/src/lib/matchers.ts +0 -322
  92. package/packages/orq-rc/src/lib/primitives.ts +0 -136
  93. package/packages/orq-rc/src/lib/retries.ts +0 -218
  94. package/packages/orq-rc/src/lib/schemas.ts +0 -91
  95. package/packages/orq-rc/src/lib/sdks.ts +0 -400
  96. package/packages/orq-rc/src/lib/security.ts +0 -253
  97. package/packages/orq-rc/src/lib/url.ts +0 -33
  98. package/packages/orq-rc/src/models/components/deployments.ts +0 -1666
  99. package/packages/orq-rc/src/models/components/index.ts +0 -6
  100. package/packages/orq-rc/src/models/components/security.ts +0 -71
  101. package/packages/orq-rc/src/models/errors/apierror.ts +0 -27
  102. package/packages/orq-rc/src/models/errors/getpromptversion.ts +0 -71
  103. package/packages/orq-rc/src/models/errors/honoapierror.ts +0 -82
  104. package/packages/orq-rc/src/models/errors/httpclienterrors.ts +0 -62
  105. package/packages/orq-rc/src/models/errors/index.ts +0 -10
  106. package/packages/orq-rc/src/models/errors/sdkvalidationerror.ts +0 -97
  107. package/packages/orq-rc/src/models/errors/updateprompt.ts +0 -71
  108. package/packages/orq-rc/src/models/operations/createcontact.ts +0 -256
  109. package/packages/orq-rc/src/models/operations/createfeedback.ts +0 -286
  110. package/packages/orq-rc/src/models/operations/createprompt.ts +0 -3717
  111. package/packages/orq-rc/src/models/operations/deleteprompt.ts +0 -69
  112. package/packages/orq-rc/src/models/operations/deploymentcreatemetric.ts +0 -1790
  113. package/packages/orq-rc/src/models/operations/deploymentgetconfig.ts +0 -3527
  114. package/packages/orq-rc/src/models/operations/deploymentinvoke.ts +0 -1144
  115. package/packages/orq-rc/src/models/operations/deployments.ts +0 -2148
  116. package/packages/orq-rc/src/models/operations/filedelete.ts +0 -78
  117. package/packages/orq-rc/src/models/operations/fileget.ts +0 -222
  118. package/packages/orq-rc/src/models/operations/filelist.ts +0 -336
  119. package/packages/orq-rc/src/models/operations/fileupload.ts +0 -322
  120. package/packages/orq-rc/src/models/operations/getallprompts.ts +0 -2116
  121. package/packages/orq-rc/src/models/operations/getoneprompt.ts +0 -1982
  122. package/packages/orq-rc/src/models/operations/getpromptversion.ts +0 -2012
  123. package/packages/orq-rc/src/models/operations/index.ts +0 -22
  124. package/packages/orq-rc/src/models/operations/listpromptversions.ts +0 -2146
  125. package/packages/orq-rc/src/models/operations/remoteconfigsgetconfig.ts +0 -190
  126. package/packages/orq-rc/src/models/operations/updateprompt.ts +0 -3900
  127. package/packages/orq-rc/src/sdk/contacts.ts +0 -27
  128. package/packages/orq-rc/src/sdk/deployments.ts +0 -70
  129. package/packages/orq-rc/src/sdk/feedback.ts +0 -27
  130. package/packages/orq-rc/src/sdk/files.ts +0 -78
  131. package/packages/orq-rc/src/sdk/index.ts +0 -5
  132. package/packages/orq-rc/src/sdk/metrics.ts +0 -27
  133. package/packages/orq-rc/src/sdk/prompts.ts +0 -126
  134. package/packages/orq-rc/src/sdk/remoteconfigs.ts +0 -24
  135. package/packages/orq-rc/src/sdk/sdk.ts +0 -43
  136. package/packages/orq-rc/src/types/blobs.ts +0 -31
  137. package/packages/orq-rc/src/types/constdatetime.ts +0 -15
  138. package/packages/orq-rc/src/types/enums.ts +0 -16
  139. package/packages/orq-rc/src/types/fp.ts +0 -50
  140. package/packages/orq-rc/src/types/index.ts +0 -11
  141. package/packages/orq-rc/src/types/operations.ts +0 -105
  142. package/packages/orq-rc/src/types/rfcdate.ts +0 -54
  143. package/packages/orq-rc/src/types/streams.ts +0 -21
  144. package/packages/orq-rc/tsconfig.json +0 -41
  145. package/src/funcs/deploymentsStream.ts +0 -151
  146. package/src/lib/event-streams.ts +0 -264
  147. package/src/models/operations/deploymentstream.ts +0 -3062
@@ -1,6 +0,0 @@
1
- /*
2
- * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
- */
4
-
5
- export * from "./deployments.js";
6
- export * from "./security.js";
@@ -1,71 +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 { Result as SafeParseResult } from "../../types/fp.js";
9
- import { SDKValidationError } from "../errors/sdkvalidationerror.js";
10
-
11
- export type Security = {
12
- apiKey?: string | undefined;
13
- };
14
-
15
- /** @internal */
16
- export const Security$inboundSchema: z.ZodType<
17
- Security,
18
- z.ZodTypeDef,
19
- unknown
20
- > = z.object({
21
- ApiKey: z.string().optional(),
22
- }).transform((v) => {
23
- return remap$(v, {
24
- "ApiKey": "apiKey",
25
- });
26
- });
27
-
28
- /** @internal */
29
- export type Security$Outbound = {
30
- ApiKey?: string | undefined;
31
- };
32
-
33
- /** @internal */
34
- export const Security$outboundSchema: z.ZodType<
35
- Security$Outbound,
36
- z.ZodTypeDef,
37
- Security
38
- > = z.object({
39
- apiKey: z.string().optional(),
40
- }).transform((v) => {
41
- return remap$(v, {
42
- apiKey: "ApiKey",
43
- });
44
- });
45
-
46
- /**
47
- * @internal
48
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
49
- */
50
- export namespace Security$ {
51
- /** @deprecated use `Security$inboundSchema` instead. */
52
- export const inboundSchema = Security$inboundSchema;
53
- /** @deprecated use `Security$outboundSchema` instead. */
54
- export const outboundSchema = Security$outboundSchema;
55
- /** @deprecated use `Security$Outbound` instead. */
56
- export type Outbound = Security$Outbound;
57
- }
58
-
59
- export function securityToJSON(security: Security): string {
60
- return JSON.stringify(Security$outboundSchema.parse(security));
61
- }
62
-
63
- export function securityFromJSON(
64
- jsonString: string,
65
- ): SafeParseResult<Security, SDKValidationError> {
66
- return safeParse(
67
- jsonString,
68
- (x) => Security$inboundSchema.parse(JSON.parse(x)),
69
- `Failed to parse 'Security' from JSON`,
70
- );
71
- }
@@ -1,27 +0,0 @@
1
- /*
2
- * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
- */
4
-
5
- export class APIError extends Error {
6
- public readonly statusCode: number;
7
- public readonly contentType: string;
8
-
9
- constructor(
10
- message: string,
11
- public readonly rawResponse: Response,
12
- public readonly body: string = "",
13
- ) {
14
- const statusCode = rawResponse.status;
15
- const contentType = rawResponse.headers.get("content-type") || "";
16
- const bodyString = body.length > 0 ? `\n${body}` : "";
17
-
18
- super(
19
- `${message}: Status ${statusCode} Content-Type ${contentType} Body ${bodyString}`,
20
- );
21
-
22
- this.statusCode = statusCode;
23
- this.contentType = contentType;
24
-
25
- this.name = "APIError";
26
- }
27
- }
@@ -1,71 +0,0 @@
1
- /*
2
- * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
- */
4
-
5
- import * as z from "zod";
6
-
7
- /**
8
- * Not Found - The prompt or prompt version does not exist.
9
- */
10
- export type GetPromptVersionResponseBodyData = {
11
- message: string;
12
- };
13
-
14
- /**
15
- * Not Found - The prompt or prompt version does not exist.
16
- */
17
- export class GetPromptVersionResponseBody extends Error {
18
- /** The original data that was passed to this error instance. */
19
- data$: GetPromptVersionResponseBodyData;
20
-
21
- constructor(err: GetPromptVersionResponseBodyData) {
22
- const message = "message" in err && typeof err.message === "string"
23
- ? err.message
24
- : `API error occurred: ${JSON.stringify(err)}`;
25
- super(message);
26
- this.data$ = err;
27
-
28
- this.name = "GetPromptVersionResponseBody";
29
- }
30
- }
31
-
32
- /** @internal */
33
- export const GetPromptVersionResponseBody$inboundSchema: z.ZodType<
34
- GetPromptVersionResponseBody,
35
- z.ZodTypeDef,
36
- unknown
37
- > = z.object({
38
- message: z.string(),
39
- })
40
- .transform((v) => {
41
- return new GetPromptVersionResponseBody(v);
42
- });
43
-
44
- /** @internal */
45
- export type GetPromptVersionResponseBody$Outbound = {
46
- message: string;
47
- };
48
-
49
- /** @internal */
50
- export const GetPromptVersionResponseBody$outboundSchema: z.ZodType<
51
- GetPromptVersionResponseBody$Outbound,
52
- z.ZodTypeDef,
53
- GetPromptVersionResponseBody
54
- > = z.instanceof(GetPromptVersionResponseBody)
55
- .transform(v => v.data$)
56
- .pipe(z.object({
57
- message: z.string(),
58
- }));
59
-
60
- /**
61
- * @internal
62
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
63
- */
64
- export namespace GetPromptVersionResponseBody$ {
65
- /** @deprecated use `GetPromptVersionResponseBody$inboundSchema` instead. */
66
- export const inboundSchema = GetPromptVersionResponseBody$inboundSchema;
67
- /** @deprecated use `GetPromptVersionResponseBody$outboundSchema` instead. */
68
- export const outboundSchema = GetPromptVersionResponseBody$outboundSchema;
69
- /** @deprecated use `GetPromptVersionResponseBody$Outbound` instead. */
70
- export type Outbound = GetPromptVersionResponseBody$Outbound;
71
- }
@@ -1,82 +0,0 @@
1
- /*
2
- * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
- */
4
-
5
- import * as z from "zod";
6
-
7
- export type HonoApiErrorData = {
8
- /**
9
- * HTTP status code
10
- */
11
- code?: string | undefined;
12
- /**
13
- * Error message
14
- */
15
- message: string;
16
- };
17
-
18
- export class HonoApiError extends Error {
19
- /**
20
- * HTTP status code
21
- */
22
- code?: string | undefined;
23
-
24
- /** The original data that was passed to this error instance. */
25
- data$: HonoApiErrorData;
26
-
27
- constructor(err: HonoApiErrorData) {
28
- const message = "message" in err && typeof err.message === "string"
29
- ? err.message
30
- : `API error occurred: ${JSON.stringify(err)}`;
31
- super(message);
32
- this.data$ = err;
33
-
34
- if (err.code != null) this.code = err.code;
35
-
36
- this.name = "HonoApiError";
37
- }
38
- }
39
-
40
- /** @internal */
41
- export const HonoApiError$inboundSchema: z.ZodType<
42
- HonoApiError,
43
- z.ZodTypeDef,
44
- unknown
45
- > = z.object({
46
- code: z.string().optional(),
47
- message: z.string(),
48
- })
49
- .transform((v) => {
50
- return new HonoApiError(v);
51
- });
52
-
53
- /** @internal */
54
- export type HonoApiError$Outbound = {
55
- code?: string | undefined;
56
- message: string;
57
- };
58
-
59
- /** @internal */
60
- export const HonoApiError$outboundSchema: z.ZodType<
61
- HonoApiError$Outbound,
62
- z.ZodTypeDef,
63
- HonoApiError
64
- > = z.instanceof(HonoApiError)
65
- .transform(v => v.data$)
66
- .pipe(z.object({
67
- code: z.string().optional(),
68
- message: z.string(),
69
- }));
70
-
71
- /**
72
- * @internal
73
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
74
- */
75
- export namespace HonoApiError$ {
76
- /** @deprecated use `HonoApiError$inboundSchema` instead. */
77
- export const inboundSchema = HonoApiError$inboundSchema;
78
- /** @deprecated use `HonoApiError$outboundSchema` instead. */
79
- export const outboundSchema = HonoApiError$outboundSchema;
80
- /** @deprecated use `HonoApiError$Outbound` instead. */
81
- export type Outbound = HonoApiError$Outbound;
82
- }
@@ -1,62 +0,0 @@
1
- /*
2
- * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
- */
4
-
5
- /**
6
- * Base class for all HTTP errors.
7
- */
8
- export class HTTPClientError extends Error {
9
- /** The underlying cause of the error. */
10
- override readonly cause: unknown;
11
- override name = "HTTPClientError";
12
- constructor(message: string, opts?: { cause?: unknown }) {
13
- let msg = message;
14
- if (opts?.cause) {
15
- msg += `: ${opts.cause}`;
16
- }
17
-
18
- super(msg, opts);
19
- // In older runtimes, the cause field would not have been assigned through
20
- // the super() call.
21
- if (typeof this.cause === "undefined") {
22
- this.cause = opts?.cause;
23
- }
24
- }
25
- }
26
-
27
- /**
28
- * An error to capture unrecognised or unexpected errors when making HTTP calls.
29
- */
30
- export class UnexpectedClientError extends HTTPClientError {
31
- override name = "UnexpectedClientError";
32
- }
33
-
34
- /**
35
- * An error that is raised when any inputs used to create a request are invalid.
36
- */
37
- export class InvalidRequestError extends HTTPClientError {
38
- override name = "InvalidRequestError";
39
- }
40
-
41
- /**
42
- * An error that is raised when a HTTP request was aborted by the client error.
43
- */
44
- export class RequestAbortedError extends HTTPClientError {
45
- override readonly name = "RequestAbortedError";
46
- }
47
-
48
- /**
49
- * An error that is raised when a HTTP request timed out due to an AbortSignal
50
- * signal timeout.
51
- */
52
- export class RequestTimeoutError extends HTTPClientError {
53
- override readonly name = "RequestTimeoutError";
54
- }
55
-
56
- /**
57
- * An error that is raised when a HTTP client is unable to make a request to
58
- * a server.
59
- */
60
- export class ConnectionError extends HTTPClientError {
61
- override readonly name = "ConnectionError";
62
- }
@@ -1,10 +0,0 @@
1
- /*
2
- * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
- */
4
-
5
- export * from "./apierror.js";
6
- export * from "./getpromptversion.js";
7
- export * from "./honoapierror.js";
8
- export * from "./httpclienterrors.js";
9
- export * from "./sdkvalidationerror.js";
10
- export * from "./updateprompt.js";
@@ -1,97 +0,0 @@
1
- /*
2
- * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
- */
4
-
5
- import * as z from "zod";
6
-
7
- export class SDKValidationError extends Error {
8
- /**
9
- * The raw value that failed validation.
10
- */
11
- public readonly rawValue: unknown;
12
-
13
- /**
14
- * The raw message that failed validation.
15
- */
16
- public readonly rawMessage: unknown;
17
-
18
- constructor(message: string, cause: unknown, rawValue: unknown) {
19
- super(`${message}: ${cause}`);
20
- this.name = "SDKValidationError";
21
- this.cause = cause;
22
- this.rawValue = rawValue;
23
- this.rawMessage = message;
24
- }
25
-
26
- /**
27
- * Return a pretty-formatted error message if the underlying validation error
28
- * is a ZodError or some other recognized error type, otherwise return the
29
- * default error message.
30
- */
31
- public pretty(): string {
32
- if (this.cause instanceof z.ZodError) {
33
- return `${this.rawMessage}\n${formatZodError(this.cause)}`;
34
- } else {
35
- return this.toString();
36
- }
37
- }
38
- }
39
-
40
- export function formatZodError(err: z.ZodError, level = 0): string {
41
- let pre = " ".repeat(level);
42
- pre = level > 0 ? `│${pre}` : pre;
43
- pre += " ".repeat(level);
44
-
45
- let message = "";
46
- const append = (str: string) => (message += `\n${pre}${str}`);
47
-
48
- const len = err.issues.length;
49
- const headline = len === 1 ? `${len} issue found` : `${len} issues found`;
50
-
51
- if (len) {
52
- append(`┌ ${headline}:`);
53
- }
54
-
55
- for (const issue of err.issues) {
56
- let path = issue.path.join(".");
57
- path = path ? `<root>.${path}` : "<root>";
58
- append(`│ • [${path}]: ${issue.message} (${issue.code})`);
59
- switch (issue.code) {
60
- case "invalid_literal":
61
- case "invalid_type": {
62
- append(`│ Want: ${issue.expected}`);
63
- append(`│ Got: ${issue.received}`);
64
- break;
65
- }
66
- case "unrecognized_keys": {
67
- append(`│ Keys: ${issue.keys.join(", ")}`);
68
- break;
69
- }
70
- case "invalid_enum_value": {
71
- append(`│ Allowed: ${issue.options.join(", ")}`);
72
- append(`│ Got: ${issue.received}`);
73
- break;
74
- }
75
- case "invalid_union_discriminator": {
76
- append(`│ Allowed: ${issue.options.join(", ")}`);
77
- break;
78
- }
79
- case "invalid_union": {
80
- const len = issue.unionErrors.length;
81
- append(
82
- `│ ✖︎ Attemped to deserialize into one of ${len} union members:`,
83
- );
84
- issue.unionErrors.forEach((err, i) => {
85
- append(`│ ✖︎ Member ${i + 1} of ${len}`);
86
- append(`${formatZodError(err, level + 1)}`);
87
- });
88
- }
89
- }
90
- }
91
-
92
- if (err.issues.length) {
93
- append(`└─*`);
94
- }
95
-
96
- return message.slice(1);
97
- }
@@ -1,71 +0,0 @@
1
- /*
2
- * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
- */
4
-
5
- import * as z from "zod";
6
-
7
- /**
8
- * Prompt not found.
9
- */
10
- export type UpdatePromptResponseBodyData = {
11
- message: string;
12
- };
13
-
14
- /**
15
- * Prompt not found.
16
- */
17
- export class UpdatePromptResponseBody extends Error {
18
- /** The original data that was passed to this error instance. */
19
- data$: UpdatePromptResponseBodyData;
20
-
21
- constructor(err: UpdatePromptResponseBodyData) {
22
- const message = "message" in err && typeof err.message === "string"
23
- ? err.message
24
- : `API error occurred: ${JSON.stringify(err)}`;
25
- super(message);
26
- this.data$ = err;
27
-
28
- this.name = "UpdatePromptResponseBody";
29
- }
30
- }
31
-
32
- /** @internal */
33
- export const UpdatePromptResponseBody$inboundSchema: z.ZodType<
34
- UpdatePromptResponseBody,
35
- z.ZodTypeDef,
36
- unknown
37
- > = z.object({
38
- message: z.string(),
39
- })
40
- .transform((v) => {
41
- return new UpdatePromptResponseBody(v);
42
- });
43
-
44
- /** @internal */
45
- export type UpdatePromptResponseBody$Outbound = {
46
- message: string;
47
- };
48
-
49
- /** @internal */
50
- export const UpdatePromptResponseBody$outboundSchema: z.ZodType<
51
- UpdatePromptResponseBody$Outbound,
52
- z.ZodTypeDef,
53
- UpdatePromptResponseBody
54
- > = z.instanceof(UpdatePromptResponseBody)
55
- .transform(v => v.data$)
56
- .pipe(z.object({
57
- message: z.string(),
58
- }));
59
-
60
- /**
61
- * @internal
62
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
63
- */
64
- export namespace UpdatePromptResponseBody$ {
65
- /** @deprecated use `UpdatePromptResponseBody$inboundSchema` instead. */
66
- export const inboundSchema = UpdatePromptResponseBody$inboundSchema;
67
- /** @deprecated use `UpdatePromptResponseBody$outboundSchema` instead. */
68
- export const outboundSchema = UpdatePromptResponseBody$outboundSchema;
69
- /** @deprecated use `UpdatePromptResponseBody$Outbound` instead. */
70
- export type Outbound = UpdatePromptResponseBody$Outbound;
71
- }