@moovio/sdk 0.13.0 → 0.14.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 (179) hide show
  1. package/README.md +81 -36
  2. package/bin/mcp-server.js +1530 -341
  3. package/bin/mcp-server.js.map +37 -13
  4. package/docs/sdks/support/README.md +476 -0
  5. package/funcs/supportCreateTicket.d.ts +18 -0
  6. package/funcs/supportCreateTicket.d.ts.map +1 -0
  7. package/funcs/supportCreateTicket.js +139 -0
  8. package/funcs/supportCreateTicket.js.map +1 -0
  9. package/funcs/supportGetTicket.d.ts +17 -0
  10. package/funcs/supportGetTicket.d.ts.map +1 -0
  11. package/funcs/supportGetTicket.js +129 -0
  12. package/funcs/supportGetTicket.js.map +1 -0
  13. package/funcs/supportListTicketMessages.d.ts +17 -0
  14. package/funcs/supportListTicketMessages.d.ts.map +1 -0
  15. package/funcs/supportListTicketMessages.js +134 -0
  16. package/funcs/supportListTicketMessages.js.map +1 -0
  17. package/funcs/supportListTickets.d.ts +17 -0
  18. package/funcs/supportListTickets.d.ts.map +1 -0
  19. package/funcs/supportListTickets.js +130 -0
  20. package/funcs/supportListTickets.js.map +1 -0
  21. package/funcs/supportUpdateTicket.d.ts +18 -0
  22. package/funcs/supportUpdateTicket.d.ts.map +1 -0
  23. package/funcs/supportUpdateTicket.js +143 -0
  24. package/funcs/supportUpdateTicket.js.map +1 -0
  25. package/jsr.json +1 -1
  26. package/lib/config.d.ts +3 -3
  27. package/lib/config.js +3 -3
  28. package/mcp-server/cli/start/command.d.ts.map +1 -1
  29. package/mcp-server/cli/start/command.js +0 -12
  30. package/mcp-server/cli/start/command.js.map +1 -1
  31. package/mcp-server/cli/start/impl.d.ts +0 -2
  32. package/mcp-server/cli/start/impl.d.ts.map +1 -1
  33. package/mcp-server/cli/start/impl.js +0 -2
  34. package/mcp-server/cli/start/impl.js.map +1 -1
  35. package/mcp-server/mcp-server.js +1 -1
  36. package/mcp-server/server.d.ts.map +1 -1
  37. package/mcp-server/server.js +11 -1
  38. package/mcp-server/server.js.map +1 -1
  39. package/mcp-server/tools/supportCreateTicket.d.ts +8 -0
  40. package/mcp-server/tools/supportCreateTicket.d.ts.map +1 -0
  41. package/mcp-server/tools/supportCreateTicket.js +65 -0
  42. package/mcp-server/tools/supportCreateTicket.js.map +1 -0
  43. package/mcp-server/tools/supportGetTicket.d.ts +8 -0
  44. package/mcp-server/tools/supportGetTicket.d.ts.map +1 -0
  45. package/mcp-server/tools/supportGetTicket.js +65 -0
  46. package/mcp-server/tools/supportGetTicket.js.map +1 -0
  47. package/mcp-server/tools/supportListTicketMessages.d.ts +8 -0
  48. package/mcp-server/tools/supportListTicketMessages.d.ts.map +1 -0
  49. package/mcp-server/tools/supportListTicketMessages.js +65 -0
  50. package/mcp-server/tools/supportListTicketMessages.js.map +1 -0
  51. package/mcp-server/tools/supportListTickets.d.ts +8 -0
  52. package/mcp-server/tools/supportListTickets.d.ts.map +1 -0
  53. package/mcp-server/tools/supportListTickets.js +65 -0
  54. package/mcp-server/tools/supportListTickets.js.map +1 -0
  55. package/mcp-server/tools/supportUpdateTicket.d.ts +8 -0
  56. package/mcp-server/tools/supportUpdateTicket.d.ts.map +1 -0
  57. package/mcp-server/tools/supportUpdateTicket.js +65 -0
  58. package/mcp-server/tools/supportUpdateTicket.js.map +1 -0
  59. package/models/components/createticket.d.ts +37 -0
  60. package/models/components/createticket.d.ts.map +1 -0
  61. package/models/components/createticket.js +74 -0
  62. package/models/components/createticket.js.map +1 -0
  63. package/models/components/createticketcontacterror.d.ts +31 -0
  64. package/models/components/createticketcontacterror.d.ts.map +1 -0
  65. package/models/components/createticketcontacterror.js +71 -0
  66. package/models/components/createticketcontacterror.js.map +1 -0
  67. package/models/components/index.d.ts +8 -0
  68. package/models/components/index.d.ts.map +1 -1
  69. package/models/components/index.js +8 -0
  70. package/models/components/index.js.map +1 -1
  71. package/models/components/ticket.d.ts +47 -0
  72. package/models/components/ticket.d.ts.map +1 -0
  73. package/models/components/ticket.js +89 -0
  74. package/models/components/ticket.js.map +1 -0
  75. package/models/components/ticketcontact.d.ts +31 -0
  76. package/models/components/ticketcontact.d.ts.map +1 -0
  77. package/models/components/ticketcontact.js +71 -0
  78. package/models/components/ticketcontact.js.map +1 -0
  79. package/models/components/ticketmessage.d.ts +33 -0
  80. package/models/components/ticketmessage.d.ts.map +1 -0
  81. package/models/components/ticketmessage.js +73 -0
  82. package/models/components/ticketmessage.js.map +1 -0
  83. package/models/components/ticketstatus.d.ts +34 -0
  84. package/models/components/ticketstatus.d.ts.map +1 -0
  85. package/models/components/ticketstatus.js +62 -0
  86. package/models/components/ticketstatus.js.map +1 -0
  87. package/models/components/updateticket.d.ts +33 -0
  88. package/models/components/updateticket.d.ts.map +1 -0
  89. package/models/components/updateticket.js +70 -0
  90. package/models/components/updateticket.js.map +1 -0
  91. package/models/components/updateticketstatus.d.ts +25 -0
  92. package/models/components/updateticketstatus.d.ts.map +1 -0
  93. package/models/components/updateticketstatus.js +59 -0
  94. package/models/components/updateticketstatus.js.map +1 -0
  95. package/models/errors/apierror.d.ts.map +1 -1
  96. package/models/errors/apierror.js +8 -2
  97. package/models/errors/apierror.js.map +1 -1
  98. package/models/errors/createticketerror.d.ts +42 -0
  99. package/models/errors/createticketerror.d.ts.map +1 -0
  100. package/models/errors/createticketerror.js +93 -0
  101. package/models/errors/createticketerror.js.map +1 -0
  102. package/models/errors/index.d.ts +2 -0
  103. package/models/errors/index.d.ts.map +1 -1
  104. package/models/errors/index.js +2 -0
  105. package/models/errors/index.js.map +1 -1
  106. package/models/errors/updateticketerror.d.ts +36 -0
  107. package/models/errors/updateticketerror.d.ts.map +1 -0
  108. package/models/errors/updateticketerror.js +86 -0
  109. package/models/errors/updateticketerror.js.map +1 -0
  110. package/models/operations/createticket.d.ts +101 -0
  111. package/models/operations/createticket.d.ts.map +1 -0
  112. package/models/operations/createticket.js +155 -0
  113. package/models/operations/createticket.js.map +1 -0
  114. package/models/operations/getticket.d.ts +101 -0
  115. package/models/operations/getticket.d.ts.map +1 -0
  116. package/models/operations/getticket.js +147 -0
  117. package/models/operations/getticket.js.map +1 -0
  118. package/models/operations/index.d.ts +5 -0
  119. package/models/operations/index.d.ts.map +1 -1
  120. package/models/operations/index.js +5 -0
  121. package/models/operations/index.js.map +1 -1
  122. package/models/operations/listticketmessages.d.ts +105 -0
  123. package/models/operations/listticketmessages.d.ts.map +1 -0
  124. package/models/operations/listticketmessages.js +151 -0
  125. package/models/operations/listticketmessages.js.map +1 -0
  126. package/models/operations/listtickets.d.ts +103 -0
  127. package/models/operations/listtickets.d.ts.map +1 -0
  128. package/models/operations/listtickets.js +149 -0
  129. package/models/operations/listtickets.js.map +1 -0
  130. package/models/operations/updateticket.d.ts +103 -0
  131. package/models/operations/updateticket.d.ts.map +1 -0
  132. package/models/operations/updateticket.js +157 -0
  133. package/models/operations/updateticket.js.map +1 -0
  134. package/package.json +1 -1
  135. package/sdk/sdk.d.ts +3 -0
  136. package/sdk/sdk.d.ts.map +1 -1
  137. package/sdk/sdk.js +4 -0
  138. package/sdk/sdk.js.map +1 -1
  139. package/sdk/support.d.ts +40 -0
  140. package/sdk/support.d.ts.map +1 -0
  141. package/sdk/support.js +62 -0
  142. package/sdk/support.js.map +1 -0
  143. package/src/funcs/supportCreateTicket.ts +201 -0
  144. package/src/funcs/supportGetTicket.ts +185 -0
  145. package/src/funcs/supportListTicketMessages.ts +191 -0
  146. package/src/funcs/supportListTickets.ts +185 -0
  147. package/src/funcs/supportUpdateTicket.ts +207 -0
  148. package/src/lib/config.ts +3 -3
  149. package/src/mcp-server/cli/start/command.ts +0 -13
  150. package/src/mcp-server/cli/start/impl.ts +0 -4
  151. package/src/mcp-server/mcp-server.ts +1 -1
  152. package/src/mcp-server/server.ts +11 -1
  153. package/src/mcp-server/tools/supportCreateTicket.ts +38 -0
  154. package/src/mcp-server/tools/supportGetTicket.ts +38 -0
  155. package/src/mcp-server/tools/supportListTicketMessages.ts +38 -0
  156. package/src/mcp-server/tools/supportListTickets.ts +38 -0
  157. package/src/mcp-server/tools/supportUpdateTicket.ts +38 -0
  158. package/src/models/components/createticket.ts +79 -0
  159. package/src/models/components/createticketcontacterror.ts +70 -0
  160. package/src/models/components/index.ts +8 -0
  161. package/src/models/components/ticket.ts +109 -0
  162. package/src/models/components/ticketcontact.ts +66 -0
  163. package/src/models/components/ticketmessage.ts +70 -0
  164. package/src/models/components/ticketstatus.ts +33 -0
  165. package/src/models/components/updateticket.ts +70 -0
  166. package/src/models/components/updateticketstatus.ts +32 -0
  167. package/src/models/errors/apierror.ts +8 -2
  168. package/src/models/errors/createticketerror.ts +90 -0
  169. package/src/models/errors/index.ts +2 -0
  170. package/src/models/errors/updateticketerror.ts +79 -0
  171. package/src/models/operations/createticket.ts +231 -0
  172. package/src/models/operations/getticket.ts +223 -0
  173. package/src/models/operations/index.ts +5 -0
  174. package/src/models/operations/listticketmessages.ts +231 -0
  175. package/src/models/operations/listtickets.ts +227 -0
  176. package/src/models/operations/updateticket.ts +235 -0
  177. package/src/sdk/sdk.ts +6 -0
  178. package/src/sdk/support.ts +99 -0
  179. package/src/__tests__/mockserver/README.md +0 -52
@@ -0,0 +1,231 @@
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 * as components from "../components/index.js";
10
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
11
+
12
+ export type ListTicketMessagesGlobals = {
13
+ /**
14
+ * Specify an API version.
15
+ *
16
+ * @remarks
17
+ *
18
+ * API versioning follows the format `vYYYY.QQ.BB`, where
19
+ * - `YYYY` is the year
20
+ * - `QQ` is the two-digit month for the first month of the quarter (e.g., 01, 04, 07, 10)
21
+ * - `BB` is the build number, starting at `.01`, for subsequent builds in the same quarter.
22
+ * - For example, `v2024.01.00` is the initial release of the first quarter of 2024.
23
+ *
24
+ * The `latest` version represents the most recent development state. It may include breaking changes and should be treated as a beta release.
25
+ */
26
+ xMoovVersion?: string | undefined;
27
+ };
28
+
29
+ export type ListTicketMessagesRequest = {
30
+ skip?: number | undefined;
31
+ count?: number | undefined;
32
+ accountID: string;
33
+ ticketID: string;
34
+ };
35
+
36
+ export type ListTicketMessagesResponse = {
37
+ headers: { [k: string]: Array<string> };
38
+ result: Array<components.TicketMessage>;
39
+ };
40
+
41
+ /** @internal */
42
+ export const ListTicketMessagesGlobals$inboundSchema: z.ZodType<
43
+ ListTicketMessagesGlobals,
44
+ z.ZodTypeDef,
45
+ unknown
46
+ > = z.object({
47
+ "x-moov-version": z.string().default("v2024.01.00"),
48
+ }).transform((v) => {
49
+ return remap$(v, {
50
+ "x-moov-version": "xMoovVersion",
51
+ });
52
+ });
53
+
54
+ /** @internal */
55
+ export type ListTicketMessagesGlobals$Outbound = {
56
+ "x-moov-version": string;
57
+ };
58
+
59
+ /** @internal */
60
+ export const ListTicketMessagesGlobals$outboundSchema: z.ZodType<
61
+ ListTicketMessagesGlobals$Outbound,
62
+ z.ZodTypeDef,
63
+ ListTicketMessagesGlobals
64
+ > = z.object({
65
+ xMoovVersion: z.string().default("v2024.01.00"),
66
+ }).transform((v) => {
67
+ return remap$(v, {
68
+ xMoovVersion: "x-moov-version",
69
+ });
70
+ });
71
+
72
+ /**
73
+ * @internal
74
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
75
+ */
76
+ export namespace ListTicketMessagesGlobals$ {
77
+ /** @deprecated use `ListTicketMessagesGlobals$inboundSchema` instead. */
78
+ export const inboundSchema = ListTicketMessagesGlobals$inboundSchema;
79
+ /** @deprecated use `ListTicketMessagesGlobals$outboundSchema` instead. */
80
+ export const outboundSchema = ListTicketMessagesGlobals$outboundSchema;
81
+ /** @deprecated use `ListTicketMessagesGlobals$Outbound` instead. */
82
+ export type Outbound = ListTicketMessagesGlobals$Outbound;
83
+ }
84
+
85
+ export function listTicketMessagesGlobalsToJSON(
86
+ listTicketMessagesGlobals: ListTicketMessagesGlobals,
87
+ ): string {
88
+ return JSON.stringify(
89
+ ListTicketMessagesGlobals$outboundSchema.parse(listTicketMessagesGlobals),
90
+ );
91
+ }
92
+
93
+ export function listTicketMessagesGlobalsFromJSON(
94
+ jsonString: string,
95
+ ): SafeParseResult<ListTicketMessagesGlobals, SDKValidationError> {
96
+ return safeParse(
97
+ jsonString,
98
+ (x) => ListTicketMessagesGlobals$inboundSchema.parse(JSON.parse(x)),
99
+ `Failed to parse 'ListTicketMessagesGlobals' from JSON`,
100
+ );
101
+ }
102
+
103
+ /** @internal */
104
+ export const ListTicketMessagesRequest$inboundSchema: z.ZodType<
105
+ ListTicketMessagesRequest,
106
+ z.ZodTypeDef,
107
+ unknown
108
+ > = z.object({
109
+ skip: z.number().int().optional(),
110
+ count: z.number().int().optional(),
111
+ accountID: z.string(),
112
+ ticketID: z.string(),
113
+ });
114
+
115
+ /** @internal */
116
+ export type ListTicketMessagesRequest$Outbound = {
117
+ skip?: number | undefined;
118
+ count?: number | undefined;
119
+ accountID: string;
120
+ ticketID: string;
121
+ };
122
+
123
+ /** @internal */
124
+ export const ListTicketMessagesRequest$outboundSchema: z.ZodType<
125
+ ListTicketMessagesRequest$Outbound,
126
+ z.ZodTypeDef,
127
+ ListTicketMessagesRequest
128
+ > = z.object({
129
+ skip: z.number().int().optional(),
130
+ count: z.number().int().optional(),
131
+ accountID: z.string(),
132
+ ticketID: z.string(),
133
+ });
134
+
135
+ /**
136
+ * @internal
137
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
138
+ */
139
+ export namespace ListTicketMessagesRequest$ {
140
+ /** @deprecated use `ListTicketMessagesRequest$inboundSchema` instead. */
141
+ export const inboundSchema = ListTicketMessagesRequest$inboundSchema;
142
+ /** @deprecated use `ListTicketMessagesRequest$outboundSchema` instead. */
143
+ export const outboundSchema = ListTicketMessagesRequest$outboundSchema;
144
+ /** @deprecated use `ListTicketMessagesRequest$Outbound` instead. */
145
+ export type Outbound = ListTicketMessagesRequest$Outbound;
146
+ }
147
+
148
+ export function listTicketMessagesRequestToJSON(
149
+ listTicketMessagesRequest: ListTicketMessagesRequest,
150
+ ): string {
151
+ return JSON.stringify(
152
+ ListTicketMessagesRequest$outboundSchema.parse(listTicketMessagesRequest),
153
+ );
154
+ }
155
+
156
+ export function listTicketMessagesRequestFromJSON(
157
+ jsonString: string,
158
+ ): SafeParseResult<ListTicketMessagesRequest, SDKValidationError> {
159
+ return safeParse(
160
+ jsonString,
161
+ (x) => ListTicketMessagesRequest$inboundSchema.parse(JSON.parse(x)),
162
+ `Failed to parse 'ListTicketMessagesRequest' from JSON`,
163
+ );
164
+ }
165
+
166
+ /** @internal */
167
+ export const ListTicketMessagesResponse$inboundSchema: z.ZodType<
168
+ ListTicketMessagesResponse,
169
+ z.ZodTypeDef,
170
+ unknown
171
+ > = z.object({
172
+ Headers: z.record(z.array(z.string())),
173
+ Result: z.array(components.TicketMessage$inboundSchema),
174
+ }).transform((v) => {
175
+ return remap$(v, {
176
+ "Headers": "headers",
177
+ "Result": "result",
178
+ });
179
+ });
180
+
181
+ /** @internal */
182
+ export type ListTicketMessagesResponse$Outbound = {
183
+ Headers: { [k: string]: Array<string> };
184
+ Result: Array<components.TicketMessage$Outbound>;
185
+ };
186
+
187
+ /** @internal */
188
+ export const ListTicketMessagesResponse$outboundSchema: z.ZodType<
189
+ ListTicketMessagesResponse$Outbound,
190
+ z.ZodTypeDef,
191
+ ListTicketMessagesResponse
192
+ > = z.object({
193
+ headers: z.record(z.array(z.string())),
194
+ result: z.array(components.TicketMessage$outboundSchema),
195
+ }).transform((v) => {
196
+ return remap$(v, {
197
+ headers: "Headers",
198
+ result: "Result",
199
+ });
200
+ });
201
+
202
+ /**
203
+ * @internal
204
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
205
+ */
206
+ export namespace ListTicketMessagesResponse$ {
207
+ /** @deprecated use `ListTicketMessagesResponse$inboundSchema` instead. */
208
+ export const inboundSchema = ListTicketMessagesResponse$inboundSchema;
209
+ /** @deprecated use `ListTicketMessagesResponse$outboundSchema` instead. */
210
+ export const outboundSchema = ListTicketMessagesResponse$outboundSchema;
211
+ /** @deprecated use `ListTicketMessagesResponse$Outbound` instead. */
212
+ export type Outbound = ListTicketMessagesResponse$Outbound;
213
+ }
214
+
215
+ export function listTicketMessagesResponseToJSON(
216
+ listTicketMessagesResponse: ListTicketMessagesResponse,
217
+ ): string {
218
+ return JSON.stringify(
219
+ ListTicketMessagesResponse$outboundSchema.parse(listTicketMessagesResponse),
220
+ );
221
+ }
222
+
223
+ export function listTicketMessagesResponseFromJSON(
224
+ jsonString: string,
225
+ ): SafeParseResult<ListTicketMessagesResponse, SDKValidationError> {
226
+ return safeParse(
227
+ jsonString,
228
+ (x) => ListTicketMessagesResponse$inboundSchema.parse(JSON.parse(x)),
229
+ `Failed to parse 'ListTicketMessagesResponse' from JSON`,
230
+ );
231
+ }
@@ -0,0 +1,227 @@
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 * as components from "../components/index.js";
10
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
11
+
12
+ export type ListTicketsGlobals = {
13
+ /**
14
+ * Specify an API version.
15
+ *
16
+ * @remarks
17
+ *
18
+ * API versioning follows the format `vYYYY.QQ.BB`, where
19
+ * - `YYYY` is the year
20
+ * - `QQ` is the two-digit month for the first month of the quarter (e.g., 01, 04, 07, 10)
21
+ * - `BB` is the build number, starting at `.01`, for subsequent builds in the same quarter.
22
+ * - For example, `v2024.01.00` is the initial release of the first quarter of 2024.
23
+ *
24
+ * The `latest` version represents the most recent development state. It may include breaking changes and should be treated as a beta release.
25
+ */
26
+ xMoovVersion?: string | undefined;
27
+ };
28
+
29
+ export type ListTicketsRequest = {
30
+ skip?: number | undefined;
31
+ count?: number | undefined;
32
+ accountID: string;
33
+ };
34
+
35
+ export type ListTicketsResponse = {
36
+ headers: { [k: string]: Array<string> };
37
+ result: Array<components.Ticket>;
38
+ };
39
+
40
+ /** @internal */
41
+ export const ListTicketsGlobals$inboundSchema: z.ZodType<
42
+ ListTicketsGlobals,
43
+ z.ZodTypeDef,
44
+ unknown
45
+ > = z.object({
46
+ "x-moov-version": z.string().default("v2024.01.00"),
47
+ }).transform((v) => {
48
+ return remap$(v, {
49
+ "x-moov-version": "xMoovVersion",
50
+ });
51
+ });
52
+
53
+ /** @internal */
54
+ export type ListTicketsGlobals$Outbound = {
55
+ "x-moov-version": string;
56
+ };
57
+
58
+ /** @internal */
59
+ export const ListTicketsGlobals$outboundSchema: z.ZodType<
60
+ ListTicketsGlobals$Outbound,
61
+ z.ZodTypeDef,
62
+ ListTicketsGlobals
63
+ > = z.object({
64
+ xMoovVersion: z.string().default("v2024.01.00"),
65
+ }).transform((v) => {
66
+ return remap$(v, {
67
+ xMoovVersion: "x-moov-version",
68
+ });
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 ListTicketsGlobals$ {
76
+ /** @deprecated use `ListTicketsGlobals$inboundSchema` instead. */
77
+ export const inboundSchema = ListTicketsGlobals$inboundSchema;
78
+ /** @deprecated use `ListTicketsGlobals$outboundSchema` instead. */
79
+ export const outboundSchema = ListTicketsGlobals$outboundSchema;
80
+ /** @deprecated use `ListTicketsGlobals$Outbound` instead. */
81
+ export type Outbound = ListTicketsGlobals$Outbound;
82
+ }
83
+
84
+ export function listTicketsGlobalsToJSON(
85
+ listTicketsGlobals: ListTicketsGlobals,
86
+ ): string {
87
+ return JSON.stringify(
88
+ ListTicketsGlobals$outboundSchema.parse(listTicketsGlobals),
89
+ );
90
+ }
91
+
92
+ export function listTicketsGlobalsFromJSON(
93
+ jsonString: string,
94
+ ): SafeParseResult<ListTicketsGlobals, SDKValidationError> {
95
+ return safeParse(
96
+ jsonString,
97
+ (x) => ListTicketsGlobals$inboundSchema.parse(JSON.parse(x)),
98
+ `Failed to parse 'ListTicketsGlobals' from JSON`,
99
+ );
100
+ }
101
+
102
+ /** @internal */
103
+ export const ListTicketsRequest$inboundSchema: z.ZodType<
104
+ ListTicketsRequest,
105
+ z.ZodTypeDef,
106
+ unknown
107
+ > = z.object({
108
+ skip: z.number().int().optional(),
109
+ count: z.number().int().optional(),
110
+ accountID: z.string(),
111
+ });
112
+
113
+ /** @internal */
114
+ export type ListTicketsRequest$Outbound = {
115
+ skip?: number | undefined;
116
+ count?: number | undefined;
117
+ accountID: string;
118
+ };
119
+
120
+ /** @internal */
121
+ export const ListTicketsRequest$outboundSchema: z.ZodType<
122
+ ListTicketsRequest$Outbound,
123
+ z.ZodTypeDef,
124
+ ListTicketsRequest
125
+ > = z.object({
126
+ skip: z.number().int().optional(),
127
+ count: z.number().int().optional(),
128
+ accountID: z.string(),
129
+ });
130
+
131
+ /**
132
+ * @internal
133
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
134
+ */
135
+ export namespace ListTicketsRequest$ {
136
+ /** @deprecated use `ListTicketsRequest$inboundSchema` instead. */
137
+ export const inboundSchema = ListTicketsRequest$inboundSchema;
138
+ /** @deprecated use `ListTicketsRequest$outboundSchema` instead. */
139
+ export const outboundSchema = ListTicketsRequest$outboundSchema;
140
+ /** @deprecated use `ListTicketsRequest$Outbound` instead. */
141
+ export type Outbound = ListTicketsRequest$Outbound;
142
+ }
143
+
144
+ export function listTicketsRequestToJSON(
145
+ listTicketsRequest: ListTicketsRequest,
146
+ ): string {
147
+ return JSON.stringify(
148
+ ListTicketsRequest$outboundSchema.parse(listTicketsRequest),
149
+ );
150
+ }
151
+
152
+ export function listTicketsRequestFromJSON(
153
+ jsonString: string,
154
+ ): SafeParseResult<ListTicketsRequest, SDKValidationError> {
155
+ return safeParse(
156
+ jsonString,
157
+ (x) => ListTicketsRequest$inboundSchema.parse(JSON.parse(x)),
158
+ `Failed to parse 'ListTicketsRequest' from JSON`,
159
+ );
160
+ }
161
+
162
+ /** @internal */
163
+ export const ListTicketsResponse$inboundSchema: z.ZodType<
164
+ ListTicketsResponse,
165
+ z.ZodTypeDef,
166
+ unknown
167
+ > = z.object({
168
+ Headers: z.record(z.array(z.string())),
169
+ Result: z.array(components.Ticket$inboundSchema),
170
+ }).transform((v) => {
171
+ return remap$(v, {
172
+ "Headers": "headers",
173
+ "Result": "result",
174
+ });
175
+ });
176
+
177
+ /** @internal */
178
+ export type ListTicketsResponse$Outbound = {
179
+ Headers: { [k: string]: Array<string> };
180
+ Result: Array<components.Ticket$Outbound>;
181
+ };
182
+
183
+ /** @internal */
184
+ export const ListTicketsResponse$outboundSchema: z.ZodType<
185
+ ListTicketsResponse$Outbound,
186
+ z.ZodTypeDef,
187
+ ListTicketsResponse
188
+ > = z.object({
189
+ headers: z.record(z.array(z.string())),
190
+ result: z.array(components.Ticket$outboundSchema),
191
+ }).transform((v) => {
192
+ return remap$(v, {
193
+ headers: "Headers",
194
+ result: "Result",
195
+ });
196
+ });
197
+
198
+ /**
199
+ * @internal
200
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
201
+ */
202
+ export namespace ListTicketsResponse$ {
203
+ /** @deprecated use `ListTicketsResponse$inboundSchema` instead. */
204
+ export const inboundSchema = ListTicketsResponse$inboundSchema;
205
+ /** @deprecated use `ListTicketsResponse$outboundSchema` instead. */
206
+ export const outboundSchema = ListTicketsResponse$outboundSchema;
207
+ /** @deprecated use `ListTicketsResponse$Outbound` instead. */
208
+ export type Outbound = ListTicketsResponse$Outbound;
209
+ }
210
+
211
+ export function listTicketsResponseToJSON(
212
+ listTicketsResponse: ListTicketsResponse,
213
+ ): string {
214
+ return JSON.stringify(
215
+ ListTicketsResponse$outboundSchema.parse(listTicketsResponse),
216
+ );
217
+ }
218
+
219
+ export function listTicketsResponseFromJSON(
220
+ jsonString: string,
221
+ ): SafeParseResult<ListTicketsResponse, SDKValidationError> {
222
+ return safeParse(
223
+ jsonString,
224
+ (x) => ListTicketsResponse$inboundSchema.parse(JSON.parse(x)),
225
+ `Failed to parse 'ListTicketsResponse' from JSON`,
226
+ );
227
+ }
@@ -0,0 +1,235 @@
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 * as components from "../components/index.js";
10
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
11
+
12
+ export type UpdateTicketGlobals = {
13
+ /**
14
+ * Specify an API version.
15
+ *
16
+ * @remarks
17
+ *
18
+ * API versioning follows the format `vYYYY.QQ.BB`, where
19
+ * - `YYYY` is the year
20
+ * - `QQ` is the two-digit month for the first month of the quarter (e.g., 01, 04, 07, 10)
21
+ * - `BB` is the build number, starting at `.01`, for subsequent builds in the same quarter.
22
+ * - For example, `v2024.01.00` is the initial release of the first quarter of 2024.
23
+ *
24
+ * The `latest` version represents the most recent development state. It may include breaking changes and should be treated as a beta release.
25
+ */
26
+ xMoovVersion?: string | undefined;
27
+ };
28
+
29
+ export type UpdateTicketRequest = {
30
+ accountID: string;
31
+ ticketID: string;
32
+ updateTicket: components.UpdateTicket;
33
+ };
34
+
35
+ export type UpdateTicketResponse = {
36
+ headers: { [k: string]: Array<string> };
37
+ result: components.Ticket;
38
+ };
39
+
40
+ /** @internal */
41
+ export const UpdateTicketGlobals$inboundSchema: z.ZodType<
42
+ UpdateTicketGlobals,
43
+ z.ZodTypeDef,
44
+ unknown
45
+ > = z.object({
46
+ "x-moov-version": z.string().default("v2024.01.00"),
47
+ }).transform((v) => {
48
+ return remap$(v, {
49
+ "x-moov-version": "xMoovVersion",
50
+ });
51
+ });
52
+
53
+ /** @internal */
54
+ export type UpdateTicketGlobals$Outbound = {
55
+ "x-moov-version": string;
56
+ };
57
+
58
+ /** @internal */
59
+ export const UpdateTicketGlobals$outboundSchema: z.ZodType<
60
+ UpdateTicketGlobals$Outbound,
61
+ z.ZodTypeDef,
62
+ UpdateTicketGlobals
63
+ > = z.object({
64
+ xMoovVersion: z.string().default("v2024.01.00"),
65
+ }).transform((v) => {
66
+ return remap$(v, {
67
+ xMoovVersion: "x-moov-version",
68
+ });
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 UpdateTicketGlobals$ {
76
+ /** @deprecated use `UpdateTicketGlobals$inboundSchema` instead. */
77
+ export const inboundSchema = UpdateTicketGlobals$inboundSchema;
78
+ /** @deprecated use `UpdateTicketGlobals$outboundSchema` instead. */
79
+ export const outboundSchema = UpdateTicketGlobals$outboundSchema;
80
+ /** @deprecated use `UpdateTicketGlobals$Outbound` instead. */
81
+ export type Outbound = UpdateTicketGlobals$Outbound;
82
+ }
83
+
84
+ export function updateTicketGlobalsToJSON(
85
+ updateTicketGlobals: UpdateTicketGlobals,
86
+ ): string {
87
+ return JSON.stringify(
88
+ UpdateTicketGlobals$outboundSchema.parse(updateTicketGlobals),
89
+ );
90
+ }
91
+
92
+ export function updateTicketGlobalsFromJSON(
93
+ jsonString: string,
94
+ ): SafeParseResult<UpdateTicketGlobals, SDKValidationError> {
95
+ return safeParse(
96
+ jsonString,
97
+ (x) => UpdateTicketGlobals$inboundSchema.parse(JSON.parse(x)),
98
+ `Failed to parse 'UpdateTicketGlobals' from JSON`,
99
+ );
100
+ }
101
+
102
+ /** @internal */
103
+ export const UpdateTicketRequest$inboundSchema: z.ZodType<
104
+ UpdateTicketRequest,
105
+ z.ZodTypeDef,
106
+ unknown
107
+ > = z.object({
108
+ accountID: z.string(),
109
+ ticketID: z.string(),
110
+ UpdateTicket: components.UpdateTicket$inboundSchema,
111
+ }).transform((v) => {
112
+ return remap$(v, {
113
+ "UpdateTicket": "updateTicket",
114
+ });
115
+ });
116
+
117
+ /** @internal */
118
+ export type UpdateTicketRequest$Outbound = {
119
+ accountID: string;
120
+ ticketID: string;
121
+ UpdateTicket: components.UpdateTicket$Outbound;
122
+ };
123
+
124
+ /** @internal */
125
+ export const UpdateTicketRequest$outboundSchema: z.ZodType<
126
+ UpdateTicketRequest$Outbound,
127
+ z.ZodTypeDef,
128
+ UpdateTicketRequest
129
+ > = z.object({
130
+ accountID: z.string(),
131
+ ticketID: z.string(),
132
+ updateTicket: components.UpdateTicket$outboundSchema,
133
+ }).transform((v) => {
134
+ return remap$(v, {
135
+ updateTicket: "UpdateTicket",
136
+ });
137
+ });
138
+
139
+ /**
140
+ * @internal
141
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
142
+ */
143
+ export namespace UpdateTicketRequest$ {
144
+ /** @deprecated use `UpdateTicketRequest$inboundSchema` instead. */
145
+ export const inboundSchema = UpdateTicketRequest$inboundSchema;
146
+ /** @deprecated use `UpdateTicketRequest$outboundSchema` instead. */
147
+ export const outboundSchema = UpdateTicketRequest$outboundSchema;
148
+ /** @deprecated use `UpdateTicketRequest$Outbound` instead. */
149
+ export type Outbound = UpdateTicketRequest$Outbound;
150
+ }
151
+
152
+ export function updateTicketRequestToJSON(
153
+ updateTicketRequest: UpdateTicketRequest,
154
+ ): string {
155
+ return JSON.stringify(
156
+ UpdateTicketRequest$outboundSchema.parse(updateTicketRequest),
157
+ );
158
+ }
159
+
160
+ export function updateTicketRequestFromJSON(
161
+ jsonString: string,
162
+ ): SafeParseResult<UpdateTicketRequest, SDKValidationError> {
163
+ return safeParse(
164
+ jsonString,
165
+ (x) => UpdateTicketRequest$inboundSchema.parse(JSON.parse(x)),
166
+ `Failed to parse 'UpdateTicketRequest' from JSON`,
167
+ );
168
+ }
169
+
170
+ /** @internal */
171
+ export const UpdateTicketResponse$inboundSchema: z.ZodType<
172
+ UpdateTicketResponse,
173
+ z.ZodTypeDef,
174
+ unknown
175
+ > = z.object({
176
+ Headers: z.record(z.array(z.string())),
177
+ Result: components.Ticket$inboundSchema,
178
+ }).transform((v) => {
179
+ return remap$(v, {
180
+ "Headers": "headers",
181
+ "Result": "result",
182
+ });
183
+ });
184
+
185
+ /** @internal */
186
+ export type UpdateTicketResponse$Outbound = {
187
+ Headers: { [k: string]: Array<string> };
188
+ Result: components.Ticket$Outbound;
189
+ };
190
+
191
+ /** @internal */
192
+ export const UpdateTicketResponse$outboundSchema: z.ZodType<
193
+ UpdateTicketResponse$Outbound,
194
+ z.ZodTypeDef,
195
+ UpdateTicketResponse
196
+ > = z.object({
197
+ headers: z.record(z.array(z.string())),
198
+ result: components.Ticket$outboundSchema,
199
+ }).transform((v) => {
200
+ return remap$(v, {
201
+ headers: "Headers",
202
+ result: "Result",
203
+ });
204
+ });
205
+
206
+ /**
207
+ * @internal
208
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
209
+ */
210
+ export namespace UpdateTicketResponse$ {
211
+ /** @deprecated use `UpdateTicketResponse$inboundSchema` instead. */
212
+ export const inboundSchema = UpdateTicketResponse$inboundSchema;
213
+ /** @deprecated use `UpdateTicketResponse$outboundSchema` instead. */
214
+ export const outboundSchema = UpdateTicketResponse$outboundSchema;
215
+ /** @deprecated use `UpdateTicketResponse$Outbound` instead. */
216
+ export type Outbound = UpdateTicketResponse$Outbound;
217
+ }
218
+
219
+ export function updateTicketResponseToJSON(
220
+ updateTicketResponse: UpdateTicketResponse,
221
+ ): string {
222
+ return JSON.stringify(
223
+ UpdateTicketResponse$outboundSchema.parse(updateTicketResponse),
224
+ );
225
+ }
226
+
227
+ export function updateTicketResponseFromJSON(
228
+ jsonString: string,
229
+ ): SafeParseResult<UpdateTicketResponse, SDKValidationError> {
230
+ return safeParse(
231
+ jsonString,
232
+ (x) => UpdateTicketResponse$inboundSchema.parse(JSON.parse(x)),
233
+ `Failed to parse 'UpdateTicketResponse' from JSON`,
234
+ );
235
+ }
package/src/sdk/sdk.ts CHANGED
@@ -30,6 +30,7 @@ import { Ping } from "./ping.js";
30
30
  import { Receipts } from "./receipts.js";
31
31
  import { Representatives } from "./representatives.js";
32
32
  import { Scheduling } from "./scheduling.js";
33
+ import { Support } from "./support.js";
33
34
  import { Sweeps } from "./sweeps.js";
34
35
  import { TerminalApplications } from "./terminalapplications.js";
35
36
  import { Transfers } from "./transfers.js";
@@ -119,6 +120,11 @@ export class Moov extends ClientSDK {
119
120
  new AccountTerminalApplications(this._options));
120
121
  }
121
122
 
123
+ private _support?: Support;
124
+ get support(): Support {
125
+ return (this._support ??= new Support(this._options));
126
+ }
127
+
122
128
  private _transfers?: Transfers;
123
129
  get transfers(): Transfers {
124
130
  return (this._transfers ??= new Transfers(this._options));