syllable-sdk 1.0.13-rc.6 → 1.0.14-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 (158) hide show
  1. package/README.md +7 -0
  2. package/bin/mcp-server.js +1704 -1950
  3. package/bin/mcp-server.js.map +34 -26
  4. package/examples/package-lock.json +1 -1
  5. package/funcs/conversationConfigGetBridgePhrasesConfig.d.ts +19 -0
  6. package/funcs/conversationConfigGetBridgePhrasesConfig.d.ts.map +1 -0
  7. package/funcs/conversationConfigGetBridgePhrasesConfig.js +123 -0
  8. package/funcs/conversationConfigGetBridgePhrasesConfig.js.map +1 -0
  9. package/funcs/conversationConfigUpdateBridgePhrasesConfig.d.ts +19 -0
  10. package/funcs/conversationConfigUpdateBridgePhrasesConfig.d.ts.map +1 -0
  11. package/funcs/conversationConfigUpdateBridgePhrasesConfig.js +126 -0
  12. package/funcs/conversationConfigUpdateBridgePhrasesConfig.js.map +1 -0
  13. package/funcs/pronunciationsPronunciationsGetMetadata.d.ts +1 -1
  14. package/funcs/pronunciationsPronunciationsGetMetadata.d.ts.map +1 -1
  15. package/funcs/pronunciationsPronunciationsGetMetadata.js +1 -1
  16. package/funcs/pronunciationsPronunciationsGetMetadata.js.map +1 -1
  17. package/jsr.json +1 -1
  18. package/lib/config.d.ts +3 -3
  19. package/lib/config.js +3 -3
  20. package/lib/encodings.d.ts.map +1 -1
  21. package/lib/encodings.js +3 -1
  22. package/lib/encodings.js.map +1 -1
  23. package/mcp-server/mcp-server.js +1 -1
  24. package/mcp-server/server.d.ts.map +1 -1
  25. package/mcp-server/server.js +5 -1
  26. package/mcp-server/server.js.map +1 -1
  27. package/mcp-server/tools/conversationConfigGetBridgePhrasesConfig.d.ts +8 -0
  28. package/mcp-server/tools/conversationConfigGetBridgePhrasesConfig.d.ts.map +1 -0
  29. package/mcp-server/tools/conversationConfigGetBridgePhrasesConfig.js +64 -0
  30. package/mcp-server/tools/conversationConfigGetBridgePhrasesConfig.js.map +1 -0
  31. package/mcp-server/tools/conversationConfigUpdateBridgePhrasesConfig.d.ts +8 -0
  32. package/mcp-server/tools/conversationConfigUpdateBridgePhrasesConfig.d.ts.map +1 -0
  33. package/mcp-server/tools/conversationConfigUpdateBridgePhrasesConfig.js +64 -0
  34. package/mcp-server/tools/conversationConfigUpdateBridgePhrasesConfig.js.map +1 -0
  35. package/models/components/bridgephrasesconfig.d.ts +39 -0
  36. package/models/components/bridgephrasesconfig.d.ts.map +1 -0
  37. package/models/components/bridgephrasesconfig.js +80 -0
  38. package/models/components/bridgephrasesconfig.js.map +1 -0
  39. package/models/components/callaction.d.ts.map +1 -1
  40. package/models/components/callaction.js +18 -38
  41. package/models/components/callaction.js.map +1 -1
  42. package/models/components/conditionaltext.d.ts.map +1 -1
  43. package/models/components/conditionaltext.js +18 -38
  44. package/models/components/conditionaltext.js.map +1 -1
  45. package/models/components/conditionalvalue.d.ts.map +1 -1
  46. package/models/components/conditionalvalue.js +36 -80
  47. package/models/components/conditionalvalue.js.map +1 -1
  48. package/models/components/context.d.ts.map +1 -1
  49. package/models/components/context.js +48 -140
  50. package/models/components/context.js.map +1 -1
  51. package/models/components/eventtaskevents.d.ts.map +1 -1
  52. package/models/components/eventtaskevents.js +20 -60
  53. package/models/components/eventtaskevents.js.map +1 -1
  54. package/models/components/expressiontask.d.ts.map +1 -1
  55. package/models/components/expressiontask.js +18 -38
  56. package/models/components/expressiontask.js.map +1 -1
  57. package/models/components/expressiontaskevents.d.ts.map +1 -1
  58. package/models/components/expressiontaskevents.js +40 -120
  59. package/models/components/expressiontaskevents.js.map +1 -1
  60. package/models/components/incrementaction.d.ts.map +1 -1
  61. package/models/components/incrementaction.js +18 -38
  62. package/models/components/incrementaction.js.map +1 -1
  63. package/models/components/index.d.ts +3 -1
  64. package/models/components/index.d.ts.map +1 -1
  65. package/models/components/index.js +3 -1
  66. package/models/components/index.js.map +1 -1
  67. package/models/components/nextstep.d.ts.map +1 -1
  68. package/models/components/nextstep.js +18 -38
  69. package/models/components/nextstep.js.map +1 -1
  70. package/models/components/pronunciationoverridesdictionary.d.ts +3 -3
  71. package/models/components/pronunciationoverridesdictionary.d.ts.map +1 -1
  72. package/models/components/pronunciationoverridesdictionary.js +3 -3
  73. package/models/components/pronunciationoverridesdictionary.js.map +1 -1
  74. package/models/components/saveaction.d.ts.map +1 -1
  75. package/models/components/saveaction.js +18 -38
  76. package/models/components/saveaction.js.map +1 -1
  77. package/models/components/sayaction.d.ts.map +1 -1
  78. package/models/components/sayaction.js +18 -38
  79. package/models/components/sayaction.js.map +1 -1
  80. package/models/components/schemascortexv1bridgephrasesdictionarymetadata.d.ts +33 -0
  81. package/models/components/schemascortexv1bridgephrasesdictionarymetadata.d.ts.map +1 -0
  82. package/models/components/schemascortexv1bridgephrasesdictionarymetadata.js +62 -0
  83. package/models/components/schemascortexv1bridgephrasesdictionarymetadata.js.map +1 -0
  84. package/models/components/schemasttsv1pronunciationsdictionarymetadata.d.ts +24 -0
  85. package/models/components/schemasttsv1pronunciationsdictionarymetadata.d.ts.map +1 -0
  86. package/models/components/{dictionarymetadata.js → schemasttsv1pronunciationsdictionarymetadata.js} +10 -10
  87. package/models/components/schemasttsv1pronunciationsdictionarymetadata.js.map +1 -0
  88. package/models/components/setvalueaction.d.ts.map +1 -1
  89. package/models/components/setvalueaction.js +36 -76
  90. package/models/components/setvalueaction.js.map +1 -1
  91. package/models/components/stepeventactions.d.ts.map +1 -1
  92. package/models/components/stepeventactions.js +60 -180
  93. package/models/components/stepeventactions.js.map +1 -1
  94. package/models/components/variable.d.ts.map +1 -1
  95. package/models/components/variable.js +18 -38
  96. package/models/components/variable.js.map +1 -1
  97. package/models/operations/getbridgephrasesconfig.d.ts +25 -0
  98. package/models/operations/getbridgephrasesconfig.d.ts.map +1 -0
  99. package/models/operations/getbridgephrasesconfig.js +71 -0
  100. package/models/operations/getbridgephrasesconfig.js.map +1 -0
  101. package/models/operations/index.d.ts +2 -0
  102. package/models/operations/index.d.ts.map +1 -1
  103. package/models/operations/index.js +2 -0
  104. package/models/operations/index.js.map +1 -1
  105. package/models/operations/updatebridgephrasesconfig.d.ts +28 -0
  106. package/models/operations/updatebridgephrasesconfig.d.ts.map +1 -0
  107. package/models/operations/updatebridgephrasesconfig.js +76 -0
  108. package/models/operations/updatebridgephrasesconfig.js.map +1 -0
  109. package/openapi.json +290 -60
  110. package/package.json +1 -1
  111. package/sdk/conversationconfig.d.ts +20 -0
  112. package/sdk/conversationconfig.d.ts.map +1 -0
  113. package/sdk/conversationconfig.js +32 -0
  114. package/sdk/conversationconfig.js.map +1 -0
  115. package/sdk/pronunciations.d.ts +1 -1
  116. package/sdk/pronunciations.d.ts.map +1 -1
  117. package/sdk/sdk.d.ts +3 -0
  118. package/sdk/sdk.d.ts.map +1 -1
  119. package/sdk/sdk.js +4 -0
  120. package/sdk/sdk.js.map +1 -1
  121. package/src/funcs/conversationConfigGetBridgePhrasesConfig.ts +176 -0
  122. package/src/funcs/conversationConfigUpdateBridgePhrasesConfig.ts +179 -0
  123. package/src/funcs/pronunciationsPronunciationsGetMetadata.ts +7 -4
  124. package/src/lib/config.ts +3 -3
  125. package/src/lib/encodings.ts +4 -3
  126. package/src/mcp-server/mcp-server.ts +1 -1
  127. package/src/mcp-server/server.ts +5 -1
  128. package/src/mcp-server/tools/conversationConfigGetBridgePhrasesConfig.ts +39 -0
  129. package/src/mcp-server/tools/conversationConfigUpdateBridgePhrasesConfig.ts +39 -0
  130. package/src/models/components/bridgephrasesconfig.ts +101 -0
  131. package/src/models/components/callaction.ts +18 -58
  132. package/src/models/components/conditionaltext.ts +18 -58
  133. package/src/models/components/conditionalvalue.ts +36 -118
  134. package/src/models/components/context.ts +48 -188
  135. package/src/models/components/eventtaskevents.ts +20 -92
  136. package/src/models/components/expressiontask.ts +18 -58
  137. package/src/models/components/expressiontaskevents.ts +40 -184
  138. package/src/models/components/incrementaction.ts +18 -58
  139. package/src/models/components/index.ts +3 -1
  140. package/src/models/components/nextstep.ts +18 -58
  141. package/src/models/components/pronunciationoverridesdictionary.ts +10 -10
  142. package/src/models/components/saveaction.ts +18 -58
  143. package/src/models/components/sayaction.ts +18 -58
  144. package/src/models/components/schemascortexv1bridgephrasesdictionarymetadata.ts +82 -0
  145. package/src/models/components/schemasttsv1pronunciationsdictionarymetadata.ts +73 -0
  146. package/src/models/components/setvalueaction.ts +36 -116
  147. package/src/models/components/stepeventactions.ts +60 -276
  148. package/src/models/components/variable.ts +18 -58
  149. package/src/models/operations/getbridgephrasesconfig.ts +74 -0
  150. package/src/models/operations/index.ts +2 -0
  151. package/src/models/operations/updatebridgephrasesconfig.ts +81 -0
  152. package/src/sdk/conversationconfig.ts +46 -0
  153. package/src/sdk/pronunciations.ts +1 -1
  154. package/src/sdk/sdk.ts +6 -0
  155. package/models/components/dictionarymetadata.d.ts +0 -24
  156. package/models/components/dictionarymetadata.d.ts.map +0 -1
  157. package/models/components/dictionarymetadata.js.map +0 -1
  158. package/src/models/components/dictionarymetadata.ts +0 -62
@@ -0,0 +1,81 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod/v3";
6
+ import { remap as remap$ } from "../../lib/primitives.js";
7
+ import { safeParse } from "../../lib/schemas.js";
8
+ import { Result as SafeParseResult } from "../../types/fp.js";
9
+ import * as components from "../components/index.js";
10
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
11
+
12
+ export type UpdateBridgePhrasesConfigRequest = {
13
+ /**
14
+ * Agent ID to update config for
15
+ */
16
+ agentId?: number | null | undefined;
17
+ /**
18
+ * Tool name to update config for
19
+ */
20
+ toolName?: string | null | undefined;
21
+ bridgePhrasesConfig: components.BridgePhrasesConfig;
22
+ };
23
+
24
+ /** @internal */
25
+ export const UpdateBridgePhrasesConfigRequest$inboundSchema: z.ZodType<
26
+ UpdateBridgePhrasesConfigRequest,
27
+ z.ZodTypeDef,
28
+ unknown
29
+ > = z.object({
30
+ agent_id: z.nullable(z.number().int()).optional(),
31
+ tool_name: z.nullable(z.string()).optional(),
32
+ BridgePhrasesConfig: components.BridgePhrasesConfig$inboundSchema,
33
+ }).transform((v) => {
34
+ return remap$(v, {
35
+ "agent_id": "agentId",
36
+ "tool_name": "toolName",
37
+ "BridgePhrasesConfig": "bridgePhrasesConfig",
38
+ });
39
+ });
40
+ /** @internal */
41
+ export type UpdateBridgePhrasesConfigRequest$Outbound = {
42
+ agent_id?: number | null | undefined;
43
+ tool_name?: string | null | undefined;
44
+ BridgePhrasesConfig: components.BridgePhrasesConfig$Outbound;
45
+ };
46
+
47
+ /** @internal */
48
+ export const UpdateBridgePhrasesConfigRequest$outboundSchema: z.ZodType<
49
+ UpdateBridgePhrasesConfigRequest$Outbound,
50
+ z.ZodTypeDef,
51
+ UpdateBridgePhrasesConfigRequest
52
+ > = z.object({
53
+ agentId: z.nullable(z.number().int()).optional(),
54
+ toolName: z.nullable(z.string()).optional(),
55
+ bridgePhrasesConfig: components.BridgePhrasesConfig$outboundSchema,
56
+ }).transform((v) => {
57
+ return remap$(v, {
58
+ agentId: "agent_id",
59
+ toolName: "tool_name",
60
+ bridgePhrasesConfig: "BridgePhrasesConfig",
61
+ });
62
+ });
63
+
64
+ export function updateBridgePhrasesConfigRequestToJSON(
65
+ updateBridgePhrasesConfigRequest: UpdateBridgePhrasesConfigRequest,
66
+ ): string {
67
+ return JSON.stringify(
68
+ UpdateBridgePhrasesConfigRequest$outboundSchema.parse(
69
+ updateBridgePhrasesConfigRequest,
70
+ ),
71
+ );
72
+ }
73
+ export function updateBridgePhrasesConfigRequestFromJSON(
74
+ jsonString: string,
75
+ ): SafeParseResult<UpdateBridgePhrasesConfigRequest, SDKValidationError> {
76
+ return safeParse(
77
+ jsonString,
78
+ (x) => UpdateBridgePhrasesConfigRequest$inboundSchema.parse(JSON.parse(x)),
79
+ `Failed to parse 'UpdateBridgePhrasesConfigRequest' from JSON`,
80
+ );
81
+ }
@@ -0,0 +1,46 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import { conversationConfigGetBridgePhrasesConfig } from "../funcs/conversationConfigGetBridgePhrasesConfig.js";
6
+ import { conversationConfigUpdateBridgePhrasesConfig } from "../funcs/conversationConfigUpdateBridgePhrasesConfig.js";
7
+ import { ClientSDK, RequestOptions } from "../lib/sdks.js";
8
+ import * as components from "../models/components/index.js";
9
+ import * as operations from "../models/operations/index.js";
10
+ import { unwrapAsync } from "../types/fp.js";
11
+
12
+ export class ConversationConfig extends ClientSDK {
13
+ /**
14
+ * Get Bridge Phrases Config
15
+ *
16
+ * @remarks
17
+ * Get the bridge phrases configuration.
18
+ */
19
+ async getBridgePhrasesConfig(
20
+ request: operations.GetBridgePhrasesConfigRequest,
21
+ options?: RequestOptions,
22
+ ): Promise<components.BridgePhrasesConfig> {
23
+ return unwrapAsync(conversationConfigGetBridgePhrasesConfig(
24
+ this,
25
+ request,
26
+ options,
27
+ ));
28
+ }
29
+
30
+ /**
31
+ * Update Bridge Phrases Config
32
+ *
33
+ * @remarks
34
+ * Update the bridge phrases configuration.
35
+ */
36
+ async updateBridgePhrasesConfig(
37
+ request: operations.UpdateBridgePhrasesConfigRequest,
38
+ options?: RequestOptions,
39
+ ): Promise<components.BridgePhrasesConfig> {
40
+ return unwrapAsync(conversationConfigUpdateBridgePhrasesConfig(
41
+ this,
42
+ request,
43
+ options,
44
+ ));
45
+ }
46
+ }
@@ -29,7 +29,7 @@ export class Pronunciations extends ClientSDK {
29
29
  */
30
30
  async pronunciationsGetMetadata(
31
31
  options?: RequestOptions,
32
- ): Promise<components.DictionaryMetadata> {
32
+ ): Promise<components.SchemasTtsV1PronunciationsDictionaryMetadata> {
33
33
  return unwrapAsync(pronunciationsPronunciationsGetMetadata(
34
34
  this,
35
35
  options,
package/src/sdk/sdk.ts CHANGED
@@ -5,6 +5,7 @@
5
5
  import { ClientSDK } from "../lib/sdks.js";
6
6
  import { Agents } from "./agents.js";
7
7
  import { Channels } from "./channels.js";
8
+ import { ConversationConfig } from "./conversationconfig.js";
8
9
  import { Conversations } from "./conversations.js";
9
10
  import { CustomMessages } from "./custommessages.js";
10
11
  import { Dashboards } from "./dashboards.js";
@@ -46,6 +47,11 @@ export class SyllableSDK extends ClientSDK {
46
47
  return (this._conversations ??= new Conversations(this._options));
47
48
  }
48
49
 
50
+ private _conversationConfig?: ConversationConfig;
51
+ get conversationConfig(): ConversationConfig {
52
+ return (this._conversationConfig ??= new ConversationConfig(this._options));
53
+ }
54
+
49
55
  private _dataSources?: DataSources;
50
56
  get dataSources(): DataSources {
51
57
  return (this._dataSources ??= new DataSources(this._options));
@@ -1,24 +0,0 @@
1
- import * as z from "zod/v3";
2
- import { Result as SafeParseResult } from "../../types/fp.js";
3
- import { SDKValidationError } from "../errors/sdkvalidationerror.js";
4
- /**
5
- * Audit metadata associated with a dictionary.
6
- */
7
- export type DictionaryMetadata = {
8
- entries: number;
9
- hash: string;
10
- source?: string | undefined;
11
- };
12
- /** @internal */
13
- export declare const DictionaryMetadata$inboundSchema: z.ZodType<DictionaryMetadata, z.ZodTypeDef, unknown>;
14
- /** @internal */
15
- export type DictionaryMetadata$Outbound = {
16
- entries: number;
17
- hash: string;
18
- source: string;
19
- };
20
- /** @internal */
21
- export declare const DictionaryMetadata$outboundSchema: z.ZodType<DictionaryMetadata$Outbound, z.ZodTypeDef, DictionaryMetadata>;
22
- export declare function dictionaryMetadataToJSON(dictionaryMetadata: DictionaryMetadata): string;
23
- export declare function dictionaryMetadataFromJSON(jsonString: string): SafeParseResult<DictionaryMetadata, SDKValidationError>;
24
- //# sourceMappingURL=dictionarymetadata.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"dictionarymetadata.d.ts","sourceRoot":"","sources":["../../src/models/components/dictionarymetadata.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,CAAC,MAAM,QAAQ,CAAC;AAE5B,OAAO,EAAE,MAAM,IAAI,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAC9D,OAAO,EAAE,kBAAkB,EAAE,MAAM,iCAAiC,CAAC;AAErE;;GAEG;AACH,MAAM,MAAM,kBAAkB,GAAG;IAC/B,OAAO,EAAE,MAAM,CAAC;IAChB,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;CAC7B,CAAC;AAEF,gBAAgB;AAChB,eAAO,MAAM,gCAAgC,EAAE,CAAC,CAAC,OAAO,CACtD,kBAAkB,EAClB,CAAC,CAAC,UAAU,EACZ,OAAO,CAKP,CAAC;AACH,gBAAgB;AAChB,MAAM,MAAM,2BAA2B,GAAG;IACxC,OAAO,EAAE,MAAM,CAAC;IAChB,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,MAAM,CAAC;CAChB,CAAC;AAEF,gBAAgB;AAChB,eAAO,MAAM,iCAAiC,EAAE,CAAC,CAAC,OAAO,CACvD,2BAA2B,EAC3B,CAAC,CAAC,UAAU,EACZ,kBAAkB,CAKlB,CAAC;AAEH,wBAAgB,wBAAwB,CACtC,kBAAkB,EAAE,kBAAkB,GACrC,MAAM,CAIR;AACD,wBAAgB,0BAA0B,CACxC,UAAU,EAAE,MAAM,GACjB,eAAe,CAAC,kBAAkB,EAAE,kBAAkB,CAAC,CAMzD"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"dictionarymetadata.js","sourceRoot":"","sources":["../../src/models/components/dictionarymetadata.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA4CH,4DAMC;AACD,gEAQC;AAzDD,0CAA4B;AAC5B,qDAAiD;AAajD,gBAAgB;AACH,QAAA,gCAAgC,GAIzC,CAAC,CAAC,MAAM,CAAC;IACX,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE;IACzB,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE;IAChB,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,OAAO,CAAC,EAAE,CAAC;CAC/B,CAAC,CAAC;AAQH,gBAAgB;AACH,QAAA,iCAAiC,GAI1C,CAAC,CAAC,MAAM,CAAC;IACX,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE;IACzB,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE;IAChB,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,OAAO,CAAC,EAAE,CAAC;CAC/B,CAAC,CAAC;AAEH,SAAgB,wBAAwB,CACtC,kBAAsC;IAEtC,OAAO,IAAI,CAAC,SAAS,CACnB,yCAAiC,CAAC,KAAK,CAAC,kBAAkB,CAAC,CAC5D,CAAC;AACJ,CAAC;AACD,SAAgB,0BAA0B,CACxC,UAAkB;IAElB,OAAO,IAAA,sBAAS,EACd,UAAU,EACV,CAAC,CAAC,EAAE,EAAE,CAAC,wCAAgC,CAAC,KAAK,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,EAC5D,gDAAgD,CACjD,CAAC;AACJ,CAAC"}
@@ -1,62 +0,0 @@
1
- /*
2
- * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
- */
4
-
5
- import * as z from "zod/v3";
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
- /**
11
- * Audit metadata associated with a dictionary.
12
- */
13
- export type DictionaryMetadata = {
14
- entries: number;
15
- hash: string;
16
- source?: string | undefined;
17
- };
18
-
19
- /** @internal */
20
- export const DictionaryMetadata$inboundSchema: z.ZodType<
21
- DictionaryMetadata,
22
- z.ZodTypeDef,
23
- unknown
24
- > = z.object({
25
- entries: z.number().int(),
26
- hash: z.string(),
27
- source: z.string().default(""),
28
- });
29
- /** @internal */
30
- export type DictionaryMetadata$Outbound = {
31
- entries: number;
32
- hash: string;
33
- source: string;
34
- };
35
-
36
- /** @internal */
37
- export const DictionaryMetadata$outboundSchema: z.ZodType<
38
- DictionaryMetadata$Outbound,
39
- z.ZodTypeDef,
40
- DictionaryMetadata
41
- > = z.object({
42
- entries: z.number().int(),
43
- hash: z.string(),
44
- source: z.string().default(""),
45
- });
46
-
47
- export function dictionaryMetadataToJSON(
48
- dictionaryMetadata: DictionaryMetadata,
49
- ): string {
50
- return JSON.stringify(
51
- DictionaryMetadata$outboundSchema.parse(dictionaryMetadata),
52
- );
53
- }
54
- export function dictionaryMetadataFromJSON(
55
- jsonString: string,
56
- ): SafeParseResult<DictionaryMetadata, SDKValidationError> {
57
- return safeParse(
58
- jsonString,
59
- (x) => DictionaryMetadata$inboundSchema.parse(JSON.parse(x)),
60
- `Failed to parse 'DictionaryMetadata' from JSON`,
61
- );
62
- }