syllable-sdk 1.0.13 → 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 (100) hide show
  1. package/README.md +7 -0
  2. package/bin/mcp-server.js +1319 -989
  3. package/bin/mcp-server.js.map +19 -11
  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 +2 -2
  19. package/lib/config.js +2 -2
  20. package/lib/config.js.map +1 -1
  21. package/mcp-server/mcp-server.js +1 -1
  22. package/mcp-server/mcp-server.js.map +1 -1
  23. package/mcp-server/server.d.ts.map +1 -1
  24. package/mcp-server/server.js +5 -1
  25. package/mcp-server/server.js.map +1 -1
  26. package/mcp-server/tools/conversationConfigGetBridgePhrasesConfig.d.ts +8 -0
  27. package/mcp-server/tools/conversationConfigGetBridgePhrasesConfig.d.ts.map +1 -0
  28. package/mcp-server/tools/conversationConfigGetBridgePhrasesConfig.js +64 -0
  29. package/mcp-server/tools/conversationConfigGetBridgePhrasesConfig.js.map +1 -0
  30. package/mcp-server/tools/conversationConfigUpdateBridgePhrasesConfig.d.ts +8 -0
  31. package/mcp-server/tools/conversationConfigUpdateBridgePhrasesConfig.d.ts.map +1 -0
  32. package/mcp-server/tools/conversationConfigUpdateBridgePhrasesConfig.js +64 -0
  33. package/mcp-server/tools/conversationConfigUpdateBridgePhrasesConfig.js.map +1 -0
  34. package/models/components/bridgephrasesconfig.d.ts +39 -0
  35. package/models/components/bridgephrasesconfig.d.ts.map +1 -0
  36. package/models/components/bridgephrasesconfig.js +80 -0
  37. package/models/components/bridgephrasesconfig.js.map +1 -0
  38. package/models/components/index.d.ts +3 -1
  39. package/models/components/index.d.ts.map +1 -1
  40. package/models/components/index.js +3 -1
  41. package/models/components/index.js.map +1 -1
  42. package/models/components/pronunciationoverridesdictionary.d.ts +3 -3
  43. package/models/components/pronunciationoverridesdictionary.d.ts.map +1 -1
  44. package/models/components/pronunciationoverridesdictionary.js +3 -3
  45. package/models/components/pronunciationoverridesdictionary.js.map +1 -1
  46. package/models/components/schemascortexv1bridgephrasesdictionarymetadata.d.ts +33 -0
  47. package/models/components/schemascortexv1bridgephrasesdictionarymetadata.d.ts.map +1 -0
  48. package/models/components/schemascortexv1bridgephrasesdictionarymetadata.js +62 -0
  49. package/models/components/schemascortexv1bridgephrasesdictionarymetadata.js.map +1 -0
  50. package/models/components/schemasttsv1pronunciationsdictionarymetadata.d.ts +24 -0
  51. package/models/components/schemasttsv1pronunciationsdictionarymetadata.d.ts.map +1 -0
  52. package/models/components/{dictionarymetadata.js → schemasttsv1pronunciationsdictionarymetadata.js} +10 -10
  53. package/models/components/schemasttsv1pronunciationsdictionarymetadata.js.map +1 -0
  54. package/models/operations/getbridgephrasesconfig.d.ts +25 -0
  55. package/models/operations/getbridgephrasesconfig.d.ts.map +1 -0
  56. package/models/operations/getbridgephrasesconfig.js +71 -0
  57. package/models/operations/getbridgephrasesconfig.js.map +1 -0
  58. package/models/operations/index.d.ts +2 -0
  59. package/models/operations/index.d.ts.map +1 -1
  60. package/models/operations/index.js +2 -0
  61. package/models/operations/index.js.map +1 -1
  62. package/models/operations/updatebridgephrasesconfig.d.ts +28 -0
  63. package/models/operations/updatebridgephrasesconfig.d.ts.map +1 -0
  64. package/models/operations/updatebridgephrasesconfig.js +76 -0
  65. package/models/operations/updatebridgephrasesconfig.js.map +1 -0
  66. package/openapi.json +290 -60
  67. package/package.json +1 -1
  68. package/sdk/conversationconfig.d.ts +20 -0
  69. package/sdk/conversationconfig.d.ts.map +1 -0
  70. package/sdk/conversationconfig.js +32 -0
  71. package/sdk/conversationconfig.js.map +1 -0
  72. package/sdk/pronunciations.d.ts +1 -1
  73. package/sdk/pronunciations.d.ts.map +1 -1
  74. package/sdk/sdk.d.ts +3 -0
  75. package/sdk/sdk.d.ts.map +1 -1
  76. package/sdk/sdk.js +4 -0
  77. package/sdk/sdk.js.map +1 -1
  78. package/src/funcs/conversationConfigGetBridgePhrasesConfig.ts +176 -0
  79. package/src/funcs/conversationConfigUpdateBridgePhrasesConfig.ts +179 -0
  80. package/src/funcs/pronunciationsPronunciationsGetMetadata.ts +7 -4
  81. package/src/lib/config.ts +2 -2
  82. package/src/mcp-server/mcp-server.ts +1 -1
  83. package/src/mcp-server/server.ts +5 -1
  84. package/src/mcp-server/tools/conversationConfigGetBridgePhrasesConfig.ts +39 -0
  85. package/src/mcp-server/tools/conversationConfigUpdateBridgePhrasesConfig.ts +39 -0
  86. package/src/models/components/bridgephrasesconfig.ts +101 -0
  87. package/src/models/components/index.ts +3 -1
  88. package/src/models/components/pronunciationoverridesdictionary.ts +10 -10
  89. package/src/models/components/schemascortexv1bridgephrasesdictionarymetadata.ts +82 -0
  90. package/src/models/components/schemasttsv1pronunciationsdictionarymetadata.ts +73 -0
  91. package/src/models/operations/getbridgephrasesconfig.ts +74 -0
  92. package/src/models/operations/index.ts +2 -0
  93. package/src/models/operations/updatebridgephrasesconfig.ts +81 -0
  94. package/src/sdk/conversationconfig.ts +46 -0
  95. package/src/sdk/pronunciations.ts +1 -1
  96. package/src/sdk/sdk.ts +6 -0
  97. package/models/components/dictionarymetadata.d.ts +0 -24
  98. package/models/components/dictionarymetadata.d.ts.map +0 -1
  99. package/models/components/dictionarymetadata.js.map +0 -1
  100. package/src/models/components/dictionarymetadata.ts +0 -62
@@ -0,0 +1,101 @@
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 { SDKValidationError } from "../errors/sdkvalidationerror.js";
10
+ import {
11
+ SchemasCortexV1BridgePhrasesDictionaryMetadata,
12
+ SchemasCortexV1BridgePhrasesDictionaryMetadata$inboundSchema,
13
+ SchemasCortexV1BridgePhrasesDictionaryMetadata$Outbound,
14
+ SchemasCortexV1BridgePhrasesDictionaryMetadata$outboundSchema,
15
+ } from "./schemascortexv1bridgephrasesdictionarymetadata.js";
16
+
17
+ /**
18
+ * Configuration for conversational bridge phrases.
19
+ */
20
+ export type BridgePhrasesConfig = {
21
+ /**
22
+ * Messages to say when the agent is first delayed.
23
+ */
24
+ firstSlowMessages?: Array<string> | undefined;
25
+ /**
26
+ * Messages to say when the agent is significantly delayed.
27
+ */
28
+ verySlowMessages?: Array<string> | undefined;
29
+ /**
30
+ * Messages to say when a tool call is in progress.
31
+ */
32
+ toolResponses?: Array<string> | undefined;
33
+ /**
34
+ * Metadata for the bridge phrases dictionary.
35
+ */
36
+ metadata?: SchemasCortexV1BridgePhrasesDictionaryMetadata | undefined;
37
+ };
38
+
39
+ /** @internal */
40
+ export const BridgePhrasesConfig$inboundSchema: z.ZodType<
41
+ BridgePhrasesConfig,
42
+ z.ZodTypeDef,
43
+ unknown
44
+ > = z.object({
45
+ first_slow_messages: z.array(z.string()).optional(),
46
+ very_slow_messages: z.array(z.string()).optional(),
47
+ tool_responses: z.array(z.string()).optional(),
48
+ metadata: SchemasCortexV1BridgePhrasesDictionaryMetadata$inboundSchema
49
+ .optional(),
50
+ }).transform((v) => {
51
+ return remap$(v, {
52
+ "first_slow_messages": "firstSlowMessages",
53
+ "very_slow_messages": "verySlowMessages",
54
+ "tool_responses": "toolResponses",
55
+ });
56
+ });
57
+ /** @internal */
58
+ export type BridgePhrasesConfig$Outbound = {
59
+ first_slow_messages?: Array<string> | undefined;
60
+ very_slow_messages?: Array<string> | undefined;
61
+ tool_responses?: Array<string> | undefined;
62
+ metadata?:
63
+ | SchemasCortexV1BridgePhrasesDictionaryMetadata$Outbound
64
+ | undefined;
65
+ };
66
+
67
+ /** @internal */
68
+ export const BridgePhrasesConfig$outboundSchema: z.ZodType<
69
+ BridgePhrasesConfig$Outbound,
70
+ z.ZodTypeDef,
71
+ BridgePhrasesConfig
72
+ > = z.object({
73
+ firstSlowMessages: z.array(z.string()).optional(),
74
+ verySlowMessages: z.array(z.string()).optional(),
75
+ toolResponses: z.array(z.string()).optional(),
76
+ metadata: SchemasCortexV1BridgePhrasesDictionaryMetadata$outboundSchema
77
+ .optional(),
78
+ }).transform((v) => {
79
+ return remap$(v, {
80
+ firstSlowMessages: "first_slow_messages",
81
+ verySlowMessages: "very_slow_messages",
82
+ toolResponses: "tool_responses",
83
+ });
84
+ });
85
+
86
+ export function bridgePhrasesConfigToJSON(
87
+ bridgePhrasesConfig: BridgePhrasesConfig,
88
+ ): string {
89
+ return JSON.stringify(
90
+ BridgePhrasesConfig$outboundSchema.parse(bridgePhrasesConfig),
91
+ );
92
+ }
93
+ export function bridgePhrasesConfigFromJSON(
94
+ jsonString: string,
95
+ ): SafeParseResult<BridgePhrasesConfig, SDKValidationError> {
96
+ return safeParse(
97
+ jsonString,
98
+ (x) => BridgePhrasesConfig$inboundSchema.parse(JSON.parse(x)),
99
+ `Failed to parse 'BridgePhrasesConfig' from JSON`,
100
+ );
101
+ }
@@ -29,6 +29,7 @@ export * from "./bodyorganizationsupdate.js";
29
29
  export * from "./bodyoutboundbatchdelete.js";
30
30
  export * from "./bodyoutboundbatchupload.js";
31
31
  export * from "./bodypronunciationsuploadcsv.js";
32
+ export * from "./bridgephrasesconfig.js";
32
33
  export * from "./callaction.js";
33
34
  export * from "./campaignproperties.js";
34
35
  export * from "./caseexpression.js";
@@ -74,7 +75,6 @@ export * from "./daysofweek.js";
74
75
  export * from "./dialogmessage.js";
75
76
  export * from "./dialogrole.js";
76
77
  export * from "./dialogtoolcall.js";
77
- export * from "./dictionarymetadata.js";
78
78
  export * from "./directoryextension.js";
79
79
  export * from "./directoryextensionnumber.js";
80
80
  export * from "./directorymember.js";
@@ -188,6 +188,8 @@ export * from "./roleresponse.js";
188
188
  export * from "./roleupdaterequest.js";
189
189
  export * from "./saveaction.js";
190
190
  export * from "./sayaction.js";
191
+ export * from "./schemascortexv1bridgephrasesdictionarymetadata.js";
192
+ export * from "./schemasttsv1pronunciationsdictionarymetadata.js";
191
193
  export * from "./security.js";
192
194
  export * from "./servicecreaterequest.js";
193
195
  export * from "./serviceproperties.js";
@@ -6,18 +6,18 @@ import * as z from "zod/v3";
6
6
  import { safeParse } from "../../lib/schemas.js";
7
7
  import { Result as SafeParseResult } from "../../types/fp.js";
8
8
  import { SDKValidationError } from "../errors/sdkvalidationerror.js";
9
- import {
10
- DictionaryMetadata,
11
- DictionaryMetadata$inboundSchema,
12
- DictionaryMetadata$Outbound,
13
- DictionaryMetadata$outboundSchema,
14
- } from "./dictionarymetadata.js";
15
9
  import {
16
10
  PronunciationOverride,
17
11
  PronunciationOverride$inboundSchema,
18
12
  PronunciationOverride$Outbound,
19
13
  PronunciationOverride$outboundSchema,
20
14
  } from "./pronunciationoverride.js";
15
+ import {
16
+ SchemasTtsV1PronunciationsDictionaryMetadata,
17
+ SchemasTtsV1PronunciationsDictionaryMetadata$inboundSchema,
18
+ SchemasTtsV1PronunciationsDictionaryMetadata$Outbound,
19
+ SchemasTtsV1PronunciationsDictionaryMetadata$outboundSchema,
20
+ } from "./schemasttsv1pronunciationsdictionarymetadata.js";
21
21
  import {
22
22
  VoiceDisplayInfo,
23
23
  VoiceDisplayInfo$inboundSchema,
@@ -55,7 +55,7 @@ export type PronunciationOverridesDictionary = {
55
55
  /**
56
56
  * Audit metadata associated with a dictionary.
57
57
  */
58
- metadata: DictionaryMetadata;
58
+ metadata: SchemasTtsV1PronunciationsDictionaryMetadata;
59
59
  };
60
60
 
61
61
  /** @internal */
@@ -67,14 +67,14 @@ export const PronunciationOverridesDictionary$inboundSchema: z.ZodType<
67
67
  type: z.string().default("pronunciations_v1"),
68
68
  pronunciations: z.array(PronunciationOverride$inboundSchema),
69
69
  voices: z.record(VoiceDisplayInfo$inboundSchema).optional(),
70
- metadata: DictionaryMetadata$inboundSchema,
70
+ metadata: SchemasTtsV1PronunciationsDictionaryMetadata$inboundSchema,
71
71
  });
72
72
  /** @internal */
73
73
  export type PronunciationOverridesDictionary$Outbound = {
74
74
  type: string;
75
75
  pronunciations: Array<PronunciationOverride$Outbound>;
76
76
  voices?: { [k: string]: VoiceDisplayInfo$Outbound } | undefined;
77
- metadata: DictionaryMetadata$Outbound;
77
+ metadata: SchemasTtsV1PronunciationsDictionaryMetadata$Outbound;
78
78
  };
79
79
 
80
80
  /** @internal */
@@ -86,7 +86,7 @@ export const PronunciationOverridesDictionary$outboundSchema: z.ZodType<
86
86
  type: z.string().default("pronunciations_v1"),
87
87
  pronunciations: z.array(PronunciationOverride$outboundSchema),
88
88
  voices: z.record(VoiceDisplayInfo$outboundSchema).optional(),
89
- metadata: DictionaryMetadata$outboundSchema,
89
+ metadata: SchemasTtsV1PronunciationsDictionaryMetadata$outboundSchema,
90
90
  });
91
91
 
92
92
  export function pronunciationOverridesDictionaryToJSON(
@@ -0,0 +1,82 @@
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
+ * Metadata for the bridge phrases dictionary.
12
+ */
13
+ export type SchemasCortexV1BridgePhrasesDictionaryMetadata = {
14
+ /**
15
+ * Hash of the dictionary content.
16
+ */
17
+ hash?: string | null | undefined;
18
+ /**
19
+ * Source of the dictionary (e.g. filename).
20
+ */
21
+ source?: string | null | undefined;
22
+ /**
23
+ * Number of entries in the dictionary.
24
+ */
25
+ entries?: number | undefined;
26
+ };
27
+
28
+ /** @internal */
29
+ export const SchemasCortexV1BridgePhrasesDictionaryMetadata$inboundSchema:
30
+ z.ZodType<
31
+ SchemasCortexV1BridgePhrasesDictionaryMetadata,
32
+ z.ZodTypeDef,
33
+ unknown
34
+ > = z.object({
35
+ hash: z.nullable(z.string()).optional(),
36
+ source: z.nullable(z.string()).optional(),
37
+ entries: z.number().int().default(0),
38
+ });
39
+ /** @internal */
40
+ export type SchemasCortexV1BridgePhrasesDictionaryMetadata$Outbound = {
41
+ hash?: string | null | undefined;
42
+ source?: string | null | undefined;
43
+ entries: number;
44
+ };
45
+
46
+ /** @internal */
47
+ export const SchemasCortexV1BridgePhrasesDictionaryMetadata$outboundSchema:
48
+ z.ZodType<
49
+ SchemasCortexV1BridgePhrasesDictionaryMetadata$Outbound,
50
+ z.ZodTypeDef,
51
+ SchemasCortexV1BridgePhrasesDictionaryMetadata
52
+ > = z.object({
53
+ hash: z.nullable(z.string()).optional(),
54
+ source: z.nullable(z.string()).optional(),
55
+ entries: z.number().int().default(0),
56
+ });
57
+
58
+ export function schemasCortexV1BridgePhrasesDictionaryMetadataToJSON(
59
+ schemasCortexV1BridgePhrasesDictionaryMetadata:
60
+ SchemasCortexV1BridgePhrasesDictionaryMetadata,
61
+ ): string {
62
+ return JSON.stringify(
63
+ SchemasCortexV1BridgePhrasesDictionaryMetadata$outboundSchema.parse(
64
+ schemasCortexV1BridgePhrasesDictionaryMetadata,
65
+ ),
66
+ );
67
+ }
68
+ export function schemasCortexV1BridgePhrasesDictionaryMetadataFromJSON(
69
+ jsonString: string,
70
+ ): SafeParseResult<
71
+ SchemasCortexV1BridgePhrasesDictionaryMetadata,
72
+ SDKValidationError
73
+ > {
74
+ return safeParse(
75
+ jsonString,
76
+ (x) =>
77
+ SchemasCortexV1BridgePhrasesDictionaryMetadata$inboundSchema.parse(
78
+ JSON.parse(x),
79
+ ),
80
+ `Failed to parse 'SchemasCortexV1BridgePhrasesDictionaryMetadata' from JSON`,
81
+ );
82
+ }
@@ -0,0 +1,73 @@
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 SchemasTtsV1PronunciationsDictionaryMetadata = {
14
+ entries: number;
15
+ hash: string;
16
+ source?: string | undefined;
17
+ };
18
+
19
+ /** @internal */
20
+ export const SchemasTtsV1PronunciationsDictionaryMetadata$inboundSchema:
21
+ z.ZodType<
22
+ SchemasTtsV1PronunciationsDictionaryMetadata,
23
+ z.ZodTypeDef,
24
+ unknown
25
+ > = z.object({
26
+ entries: z.number().int(),
27
+ hash: z.string(),
28
+ source: z.string().default(""),
29
+ });
30
+ /** @internal */
31
+ export type SchemasTtsV1PronunciationsDictionaryMetadata$Outbound = {
32
+ entries: number;
33
+ hash: string;
34
+ source: string;
35
+ };
36
+
37
+ /** @internal */
38
+ export const SchemasTtsV1PronunciationsDictionaryMetadata$outboundSchema:
39
+ z.ZodType<
40
+ SchemasTtsV1PronunciationsDictionaryMetadata$Outbound,
41
+ z.ZodTypeDef,
42
+ SchemasTtsV1PronunciationsDictionaryMetadata
43
+ > = z.object({
44
+ entries: z.number().int(),
45
+ hash: z.string(),
46
+ source: z.string().default(""),
47
+ });
48
+
49
+ export function schemasTtsV1PronunciationsDictionaryMetadataToJSON(
50
+ schemasTtsV1PronunciationsDictionaryMetadata:
51
+ SchemasTtsV1PronunciationsDictionaryMetadata,
52
+ ): string {
53
+ return JSON.stringify(
54
+ SchemasTtsV1PronunciationsDictionaryMetadata$outboundSchema.parse(
55
+ schemasTtsV1PronunciationsDictionaryMetadata,
56
+ ),
57
+ );
58
+ }
59
+ export function schemasTtsV1PronunciationsDictionaryMetadataFromJSON(
60
+ jsonString: string,
61
+ ): SafeParseResult<
62
+ SchemasTtsV1PronunciationsDictionaryMetadata,
63
+ SDKValidationError
64
+ > {
65
+ return safeParse(
66
+ jsonString,
67
+ (x) =>
68
+ SchemasTtsV1PronunciationsDictionaryMetadata$inboundSchema.parse(
69
+ JSON.parse(x),
70
+ ),
71
+ `Failed to parse 'SchemasTtsV1PronunciationsDictionaryMetadata' from JSON`,
72
+ );
73
+ }
@@ -0,0 +1,74 @@
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 { SDKValidationError } from "../errors/sdkvalidationerror.js";
10
+
11
+ export type GetBridgePhrasesConfigRequest = {
12
+ /**
13
+ * Agent ID to fetch config for
14
+ */
15
+ agentId?: number | null | undefined;
16
+ /**
17
+ * Tool name to fetch config for
18
+ */
19
+ toolName?: string | null | undefined;
20
+ };
21
+
22
+ /** @internal */
23
+ export const GetBridgePhrasesConfigRequest$inboundSchema: z.ZodType<
24
+ GetBridgePhrasesConfigRequest,
25
+ z.ZodTypeDef,
26
+ unknown
27
+ > = z.object({
28
+ agent_id: z.nullable(z.number().int()).optional(),
29
+ tool_name: z.nullable(z.string()).optional(),
30
+ }).transform((v) => {
31
+ return remap$(v, {
32
+ "agent_id": "agentId",
33
+ "tool_name": "toolName",
34
+ });
35
+ });
36
+ /** @internal */
37
+ export type GetBridgePhrasesConfigRequest$Outbound = {
38
+ agent_id?: number | null | undefined;
39
+ tool_name?: string | null | undefined;
40
+ };
41
+
42
+ /** @internal */
43
+ export const GetBridgePhrasesConfigRequest$outboundSchema: z.ZodType<
44
+ GetBridgePhrasesConfigRequest$Outbound,
45
+ z.ZodTypeDef,
46
+ GetBridgePhrasesConfigRequest
47
+ > = z.object({
48
+ agentId: z.nullable(z.number().int()).optional(),
49
+ toolName: z.nullable(z.string()).optional(),
50
+ }).transform((v) => {
51
+ return remap$(v, {
52
+ agentId: "agent_id",
53
+ toolName: "tool_name",
54
+ });
55
+ });
56
+
57
+ export function getBridgePhrasesConfigRequestToJSON(
58
+ getBridgePhrasesConfigRequest: GetBridgePhrasesConfigRequest,
59
+ ): string {
60
+ return JSON.stringify(
61
+ GetBridgePhrasesConfigRequest$outboundSchema.parse(
62
+ getBridgePhrasesConfigRequest,
63
+ ),
64
+ );
65
+ }
66
+ export function getBridgePhrasesConfigRequestFromJSON(
67
+ jsonString: string,
68
+ ): SafeParseResult<GetBridgePhrasesConfigRequest, SDKValidationError> {
69
+ return safeParse(
70
+ jsonString,
71
+ (x) => GetBridgePhrasesConfigRequest$inboundSchema.parse(JSON.parse(x)),
72
+ `Failed to parse 'GetBridgePhrasesConfigRequest' from JSON`,
73
+ );
74
+ }
@@ -30,6 +30,7 @@ export * from "./directorymembertestextension.js";
30
30
  export * from "./directorymemberupdate.js";
31
31
  export * from "./eventslist.js";
32
32
  export * from "./generatesessionrecordingurls.js";
33
+ export * from "./getbridgephrasesconfig.js";
33
34
  export * from "./getsessiondatabysessionid.js";
34
35
  export * from "./getsessiondatabysid.js";
35
36
  export * from "./getsessiontoolcallresultbyid.js";
@@ -94,6 +95,7 @@ export * from "./takeoutsgetfile.js";
94
95
  export * from "./tooldelete.js";
95
96
  export * from "./toolgetbyname.js";
96
97
  export * from "./toollist.js";
98
+ export * from "./updatebridgephrasesconfig.js";
97
99
  export * from "./usersgetbyemail.js";
98
100
  export * from "./userslist.js";
99
101
  export * from "./userssendemail.js";
@@ -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"}