@moovio/sdk 0.14.15 → 0.14.17

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 (149) hide show
  1. package/README.md +32 -2
  2. package/bin/mcp-server.js +399 -392
  3. package/bin/mcp-server.js.map +30 -32
  4. package/docs/sdks/accounts/README.md +19 -10
  5. package/docs/sdks/accountterminalapplications/README.md +4 -0
  6. package/docs/sdks/adjustments/README.md +2 -0
  7. package/docs/sdks/applepay/README.md +5 -0
  8. package/docs/sdks/authentication/README.md +2 -0
  9. package/docs/sdks/avatars/README.md +1 -0
  10. package/docs/sdks/bankaccounts/README.md +9 -0
  11. package/docs/sdks/branding/README.md +4 -0
  12. package/docs/sdks/capabilities/README.md +4 -0
  13. package/docs/sdks/cardissuing/README.md +5 -0
  14. package/docs/sdks/cards/README.md +5 -0
  15. package/docs/sdks/disputes/README.md +11 -0
  16. package/docs/sdks/endtoendencryption/README.md +2 -0
  17. package/docs/sdks/enrichedaddress/README.md +1 -0
  18. package/docs/sdks/enrichedprofile/README.md +1 -0
  19. package/docs/sdks/feeplans/README.md +7 -0
  20. package/docs/sdks/files/README.md +3 -0
  21. package/docs/sdks/industries/README.md +1 -0
  22. package/docs/sdks/institutions/README.md +2 -0
  23. package/docs/sdks/issuingtransactions/README.md +5 -0
  24. package/docs/sdks/onboarding/README.md +4 -0
  25. package/docs/sdks/paymentlinks/README.md +6 -0
  26. package/docs/sdks/paymentmethods/README.md +2 -0
  27. package/docs/sdks/ping/README.md +1 -0
  28. package/docs/sdks/receipts/README.md +2 -0
  29. package/docs/sdks/representatives/README.md +5 -0
  30. package/docs/sdks/scheduling/README.md +6 -0
  31. package/docs/sdks/support/README.md +35 -0
  32. package/docs/sdks/sweeps/README.md +6 -0
  33. package/docs/sdks/terminalapplications/README.md +5 -0
  34. package/docs/sdks/transfers/README.md +11 -0
  35. package/docs/sdks/underwriting/README.md +3 -0
  36. package/docs/sdks/wallets/README.md +2 -0
  37. package/docs/sdks/wallettransactions/README.md +2 -0
  38. package/examples/package-lock.json +1 -1
  39. package/funcs/accountsCreate.d.ts +1 -1
  40. package/funcs/accountsCreate.d.ts.map +1 -1
  41. package/funcs/accountsCreate.js +1 -3
  42. package/funcs/accountsCreate.js.map +1 -1
  43. package/funcs/accountsUpdate.d.ts +1 -1
  44. package/funcs/accountsUpdate.d.ts.map +1 -1
  45. package/funcs/accountsUpdate.js +1 -3
  46. package/funcs/accountsUpdate.js.map +1 -1
  47. package/funcs/supportCreateTicket.d.ts +3 -0
  48. package/funcs/supportCreateTicket.d.ts.map +1 -1
  49. package/funcs/supportCreateTicket.js +3 -0
  50. package/funcs/supportCreateTicket.js.map +1 -1
  51. package/funcs/supportGetTicket.d.ts +3 -0
  52. package/funcs/supportGetTicket.d.ts.map +1 -1
  53. package/funcs/supportGetTicket.js +3 -0
  54. package/funcs/supportGetTicket.js.map +1 -1
  55. package/funcs/supportListTicketMessages.d.ts +3 -0
  56. package/funcs/supportListTicketMessages.d.ts.map +1 -1
  57. package/funcs/supportListTicketMessages.js +3 -0
  58. package/funcs/supportListTicketMessages.js.map +1 -1
  59. package/funcs/supportListTickets.d.ts +3 -0
  60. package/funcs/supportListTickets.d.ts.map +1 -1
  61. package/funcs/supportListTickets.js +3 -0
  62. package/funcs/supportListTickets.js.map +1 -1
  63. package/funcs/supportUpdateTicket.d.ts +3 -0
  64. package/funcs/supportUpdateTicket.d.ts.map +1 -1
  65. package/funcs/supportUpdateTicket.js +3 -0
  66. package/funcs/supportUpdateTicket.js.map +1 -1
  67. package/jsr.json +1 -1
  68. package/lib/config.d.ts +3 -3
  69. package/lib/config.js +3 -3
  70. package/mcp-server/mcp-server.js +1 -1
  71. package/mcp-server/server.js +1 -1
  72. package/mcp-server/tools/supportCreateTicket.d.ts.map +1 -1
  73. package/mcp-server/tools/supportCreateTicket.js +4 -1
  74. package/mcp-server/tools/supportCreateTicket.js.map +1 -1
  75. package/mcp-server/tools/supportGetTicket.d.ts.map +1 -1
  76. package/mcp-server/tools/supportGetTicket.js +4 -1
  77. package/mcp-server/tools/supportGetTicket.js.map +1 -1
  78. package/mcp-server/tools/supportListTicketMessages.d.ts.map +1 -1
  79. package/mcp-server/tools/supportListTicketMessages.js +4 -1
  80. package/mcp-server/tools/supportListTicketMessages.js.map +1 -1
  81. package/mcp-server/tools/supportListTickets.d.ts.map +1 -1
  82. package/mcp-server/tools/supportListTickets.js +4 -1
  83. package/mcp-server/tools/supportListTickets.js.map +1 -1
  84. package/mcp-server/tools/supportUpdateTicket.d.ts.map +1 -1
  85. package/mcp-server/tools/supportUpdateTicket.js +4 -1
  86. package/mcp-server/tools/supportUpdateTicket.js.map +1 -1
  87. package/models/components/index.d.ts +0 -2
  88. package/models/components/index.d.ts.map +1 -1
  89. package/models/components/index.js +0 -2
  90. package/models/components/index.js.map +1 -1
  91. package/models/components/underwritingstatus.d.ts +6 -6
  92. package/models/components/underwritingstatus.js +2 -2
  93. package/models/components/underwritingstatus.js.map +1 -1
  94. package/models/errors/createaccounterror.d.ts +64 -0
  95. package/models/errors/createaccounterror.d.ts.map +1 -0
  96. package/models/{components → errors}/createaccounterror.js +52 -24
  97. package/models/errors/createaccounterror.js.map +1 -0
  98. package/models/errors/index.d.ts +2 -2
  99. package/models/errors/index.d.ts.map +1 -1
  100. package/models/errors/index.js +2 -2
  101. package/models/errors/index.js.map +1 -1
  102. package/models/errors/patchaccounterror.d.ts +52 -0
  103. package/models/errors/patchaccounterror.d.ts.map +1 -0
  104. package/models/{components → errors}/patchaccounterror.js +48 -24
  105. package/models/errors/patchaccounterror.js.map +1 -0
  106. package/package.json +1 -1
  107. package/sdk/support.d.ts +15 -0
  108. package/sdk/support.d.ts.map +1 -1
  109. package/sdk/support.js +15 -0
  110. package/sdk/support.js.map +1 -1
  111. package/src/funcs/accountsCreate.ts +4 -6
  112. package/src/funcs/accountsUpdate.ts +4 -6
  113. package/src/funcs/supportCreateTicket.ts +3 -0
  114. package/src/funcs/supportGetTicket.ts +3 -0
  115. package/src/funcs/supportListTicketMessages.ts +3 -0
  116. package/src/funcs/supportListTickets.ts +3 -0
  117. package/src/funcs/supportUpdateTicket.ts +3 -0
  118. package/src/lib/config.ts +3 -3
  119. package/src/mcp-server/mcp-server.ts +1 -1
  120. package/src/mcp-server/server.ts +1 -1
  121. package/src/mcp-server/tools/supportCreateTicket.ts +4 -1
  122. package/src/mcp-server/tools/supportGetTicket.ts +4 -1
  123. package/src/mcp-server/tools/supportListTicketMessages.ts +4 -1
  124. package/src/mcp-server/tools/supportListTickets.ts +4 -1
  125. package/src/mcp-server/tools/supportUpdateTicket.ts +4 -1
  126. package/src/models/components/index.ts +0 -2
  127. package/src/models/components/underwritingstatus.ts +2 -2
  128. package/src/models/errors/createaccounterror.ts +122 -0
  129. package/src/models/errors/index.ts +2 -2
  130. package/src/models/errors/patchaccounterror.ts +110 -0
  131. package/src/sdk/support.ts +15 -0
  132. package/models/components/createaccounterror.d.ts +0 -51
  133. package/models/components/createaccounterror.d.ts.map +0 -1
  134. package/models/components/createaccounterror.js.map +0 -1
  135. package/models/components/patchaccounterror.d.ts +0 -43
  136. package/models/components/patchaccounterror.d.ts.map +0 -1
  137. package/models/components/patchaccounterror.js.map +0 -1
  138. package/models/errors/createaccount.d.ts +0 -43
  139. package/models/errors/createaccount.d.ts.map +0 -1
  140. package/models/errors/createaccount.js +0 -89
  141. package/models/errors/createaccount.js.map +0 -1
  142. package/models/errors/updateaccount.d.ts +0 -43
  143. package/models/errors/updateaccount.d.ts.map +0 -1
  144. package/models/errors/updateaccount.js +0 -89
  145. package/models/errors/updateaccount.js.map +0 -1
  146. package/src/models/components/createaccounterror.ts +0 -118
  147. package/src/models/components/patchaccounterror.ts +0 -110
  148. package/src/models/errors/createaccount.ts +0 -86
  149. package/src/models/errors/updateaccount.ts +0 -86
@@ -51,7 +51,7 @@ export function accountsCreate(
51
51
  Result<
52
52
  operations.CreateAccountResponse,
53
53
  | errors.GenericError
54
- | errors.CreateAccountResponseBody
54
+ | errors.CreateAccountError
55
55
  | MoovError
56
56
  | ResponseValidationError
57
57
  | ConnectionError
@@ -78,7 +78,7 @@ async function $do(
78
78
  Result<
79
79
  operations.CreateAccountResponse,
80
80
  | errors.GenericError
81
- | errors.CreateAccountResponseBody
81
+ | errors.CreateAccountError
82
82
  | MoovError
83
83
  | ResponseValidationError
84
84
  | ConnectionError
@@ -177,7 +177,7 @@ async function $do(
177
177
  const [result] = await M.match<
178
178
  operations.CreateAccountResponse,
179
179
  | errors.GenericError
180
- | errors.CreateAccountResponseBody
180
+ | errors.CreateAccountError
181
181
  | MoovError
182
182
  | ResponseValidationError
183
183
  | ConnectionError
@@ -192,9 +192,7 @@ async function $do(
192
192
  key: "Result",
193
193
  }),
194
194
  M.jsonErr([400, 409], errors.GenericError$inboundSchema, { hdrs: true }),
195
- M.jsonErr(422, errors.CreateAccountResponseBody$inboundSchema, {
196
- hdrs: true,
197
- }),
195
+ M.jsonErr(422, errors.CreateAccountError$inboundSchema, { hdrs: true }),
198
196
  M.fail([401, 403, 404, 429]),
199
197
  M.fail([500, 504]),
200
198
  M.fail("4XX"),
@@ -47,7 +47,7 @@ export function accountsUpdate(
47
47
  Result<
48
48
  operations.UpdateAccountResponse,
49
49
  | errors.GenericError
50
- | errors.UpdateAccountResponseBody
50
+ | errors.PatchAccountError
51
51
  | MoovError
52
52
  | ResponseValidationError
53
53
  | ConnectionError
@@ -74,7 +74,7 @@ async function $do(
74
74
  Result<
75
75
  operations.UpdateAccountResponse,
76
76
  | errors.GenericError
77
- | errors.UpdateAccountResponseBody
77
+ | errors.PatchAccountError
78
78
  | MoovError
79
79
  | ResponseValidationError
80
80
  | ConnectionError
@@ -180,7 +180,7 @@ async function $do(
180
180
  const [result] = await M.match<
181
181
  operations.UpdateAccountResponse,
182
182
  | errors.GenericError
183
- | errors.UpdateAccountResponseBody
183
+ | errors.PatchAccountError
184
184
  | MoovError
185
185
  | ResponseValidationError
186
186
  | ConnectionError
@@ -195,9 +195,7 @@ async function $do(
195
195
  key: "Result",
196
196
  }),
197
197
  M.jsonErr([400, 409], errors.GenericError$inboundSchema, { hdrs: true }),
198
- M.jsonErr(422, errors.UpdateAccountResponseBody$inboundSchema, {
199
- hdrs: true,
200
- }),
198
+ M.jsonErr(422, errors.PatchAccountError$inboundSchema, { hdrs: true }),
201
199
  M.fail([401, 403, 404, 429]),
202
200
  M.fail([500, 504]),
203
201
  M.fail("4XX"),
@@ -30,6 +30,9 @@ import { Result } from "../types/fp.js";
30
30
  *
31
31
  * To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
32
32
  * you'll need to specify the `/accounts/{accountID}/tickets.write` scope.
33
+ *
34
+ * If you're creating the ticket on behalf of another account, then you'll need to
35
+ * specify the `/accounts/{partnerAccountID}/tickets.write` and `/accounts/{accountID}/profile.read` scopes.
33
36
  */
34
37
  export function supportCreateTicket(
35
38
  client: MoovCore,
@@ -29,6 +29,9 @@ import { Result } from "../types/fp.js";
29
29
  *
30
30
  * To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
31
31
  * you'll need to specify the `/accounts/{accountID}/tickets.read` scope.
32
+ *
33
+ * If you're retrieving another account's ticket, then you'll need to
34
+ * specify the `/accounts/{partnerAccountID}/tickets.read` and `/accounts/{accountID}/profile.read` scopes.
32
35
  */
33
36
  export function supportGetTicket(
34
37
  client: MoovCore,
@@ -29,6 +29,9 @@ import { Result } from "../types/fp.js";
29
29
  *
30
30
  * To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
31
31
  * you'll need to specify the `/accounts/{accountID}/tickets.read` scope.
32
+ *
33
+ * If you're listing another account's messages, then you'll need to
34
+ * specify the `/accounts/{partnerAccountID}/tickets.read` and `/accounts/{accountID}/profile.read` scopes.
32
35
  */
33
36
  export function supportListTicketMessages(
34
37
  client: MoovCore,
@@ -29,6 +29,9 @@ import { Result } from "../types/fp.js";
29
29
  *
30
30
  * To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
31
31
  * you'll need to specify the `/accounts/{accountID}/tickets.read` scope.
32
+ *
33
+ * If you're listing another account's tickets, then you'll need to
34
+ * specify the `/accounts/{partnerAccountID}/tickets.read` and `/accounts/{accountID}/profile.read` scopes.
32
35
  */
33
36
  export function supportListTickets(
34
37
  client: MoovCore,
@@ -30,6 +30,9 @@ import { Result } from "../types/fp.js";
30
30
  *
31
31
  * To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
32
32
  * you'll need to specify the `/accounts/{accountID}/tickets.write` scope.
33
+ *
34
+ * If you're updating the ticket on behalf of another account, then you'll need to
35
+ * specify the `/accounts/{partnerAccountID}/tickets.write` and `/accounts/{accountID}/profile.read` scopes.
33
36
  */
34
37
  export function supportUpdateTicket(
35
38
  client: MoovCore,
package/src/lib/config.ts CHANGED
@@ -73,7 +73,7 @@ export function serverURLFromOptions(options: SDKOptions): URL | null {
73
73
  export const SDK_METADATA = {
74
74
  language: "typescript",
75
75
  openapiDocVersion: "latest",
76
- sdkVersion: "0.14.15",
77
- genVersion: "2.666.0",
78
- userAgent: "speakeasy-sdk/typescript 0.14.15 2.666.0 latest @moovio/sdk",
76
+ sdkVersion: "0.14.17",
77
+ genVersion: "2.667.0",
78
+ userAgent: "speakeasy-sdk/typescript 0.14.17 2.667.0 latest @moovio/sdk",
79
79
  } as const;
@@ -19,7 +19,7 @@ const routes = buildRouteMap({
19
19
  export const app = buildApplication(routes, {
20
20
  name: "mcp",
21
21
  versionInfo: {
22
- currentVersion: "0.14.15",
22
+ currentVersion: "0.14.17",
23
23
  },
24
24
  });
25
25
 
@@ -168,7 +168,7 @@ export function createMCPServer(deps: {
168
168
  }) {
169
169
  const server = new McpServer({
170
170
  name: "Moov",
171
- version: "0.14.15",
171
+ version: "0.14.17",
172
172
  });
173
173
 
174
174
  const client = new MoovCore({
@@ -15,7 +15,10 @@ export const tool$supportCreateTicket: ToolDefinition<typeof args> = {
15
15
  description: `Create a support ticket for a Moov account.
16
16
 
17
17
  To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
18
- you'll need to specify the \`/accounts/{accountID}/tickets.write\` scope.`,
18
+ you'll need to specify the \`/accounts/{accountID}/tickets.write\` scope.
19
+
20
+ If you're creating the ticket on behalf of another account, then you'll need to
21
+ specify the \`/accounts/{partnerAccountID}/tickets.write\` and \`/accounts/{accountID}/profile.read\` scopes.`,
19
22
  args,
20
23
  tool: async (client, args, ctx) => {
21
24
  const [result, apiCall] = await supportCreateTicket(
@@ -15,7 +15,10 @@ export const tool$supportGetTicket: ToolDefinition<typeof args> = {
15
15
  description: `Retrieve a support ticket by ID.
16
16
 
17
17
  To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
18
- you'll need to specify the \`/accounts/{accountID}/tickets.read\` scope.`,
18
+ you'll need to specify the \`/accounts/{accountID}/tickets.read\` scope.
19
+
20
+ If you're retrieving another account's ticket, then you'll need to
21
+ specify the \`/accounts/{partnerAccountID}/tickets.read\` and \`/accounts/{accountID}/profile.read\` scopes.`,
19
22
  args,
20
23
  tool: async (client, args, ctx) => {
21
24
  const [result, apiCall] = await supportGetTicket(
@@ -15,7 +15,10 @@ export const tool$supportListTicketMessages: ToolDefinition<typeof args> = {
15
15
  description: `List all the messages for a support ticket.
16
16
 
17
17
  To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
18
- you'll need to specify the \`/accounts/{accountID}/tickets.read\` scope.`,
18
+ you'll need to specify the \`/accounts/{accountID}/tickets.read\` scope.
19
+
20
+ If you're listing another account's messages, then you'll need to
21
+ specify the \`/accounts/{partnerAccountID}/tickets.read\` and \`/accounts/{accountID}/profile.read\` scopes.`,
19
22
  args,
20
23
  tool: async (client, args, ctx) => {
21
24
  const [result, apiCall] = await supportListTicketMessages(
@@ -15,7 +15,10 @@ export const tool$supportListTickets: ToolDefinition<typeof args> = {
15
15
  description: `List all the support tickets created under a Moov account.
16
16
 
17
17
  To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
18
- you'll need to specify the \`/accounts/{accountID}/tickets.read\` scope.`,
18
+ you'll need to specify the \`/accounts/{accountID}/tickets.read\` scope.
19
+
20
+ If you're listing another account's tickets, then you'll need to
21
+ specify the \`/accounts/{partnerAccountID}/tickets.read\` and \`/accounts/{accountID}/profile.read\` scopes.`,
19
22
  args,
20
23
  tool: async (client, args, ctx) => {
21
24
  const [result, apiCall] = await supportListTickets(
@@ -15,7 +15,10 @@ export const tool$supportUpdateTicket: ToolDefinition<typeof args> = {
15
15
  description: `Updates a support ticket.
16
16
 
17
17
  To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
18
- you'll need to specify the \`/accounts/{accountID}/tickets.write\` scope.`,
18
+ you'll need to specify the \`/accounts/{accountID}/tickets.write\` scope.
19
+
20
+ If you're updating the ticket on behalf of another account, then you'll need to
21
+ specify the \`/accounts/{partnerAccountID}/tickets.write\` and \`/accounts/{accountID}/profile.read\` scopes.`,
19
22
  args,
20
23
  tool: async (client, args, ctx) => {
21
24
  const [result, apiCall] = await supportUpdateTicket(
@@ -118,7 +118,6 @@ export * from "./completemicrodeposits.js";
118
118
  export * from "./contact.js";
119
119
  export * from "./countrieserrors.js";
120
120
  export * from "./createaccount.js";
121
- export * from "./createaccounterror.js";
122
121
  export * from "./createaccountsettings.js";
123
122
  export * from "./createaccounttype.js";
124
123
  export * from "./createapplepaysession.js";
@@ -273,7 +272,6 @@ export * from "./partialscheduleaccount.js";
273
272
  export * from "./partnerpricing.js";
274
273
  export * from "./partnerpricingagreement.js";
275
274
  export * from "./patchaccount.js";
276
- export * from "./patchaccounterror.js";
277
275
  export * from "./patchbusiness.js";
278
276
  export * from "./patchindividual.js";
279
277
  export * from "./patchprofile.js";
@@ -11,9 +11,9 @@ import { ClosedEnum } from "../../types/enums.js";
11
11
  export const UnderwritingStatus = {
12
12
  Approved: "approved",
13
13
  Rejected: "rejected",
14
- PendingReview: "pendingReview",
14
+ PendingReview: "pending_review",
15
15
  Pending: "pending",
16
- NotRequested: "notRequested",
16
+ NotRequested: "not_requested",
17
17
  } as const;
18
18
  /**
19
19
  * @deprecated enum: This will be removed in a future release, please migrate away from it as soon as possible.
@@ -0,0 +1,122 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod";
6
+ import * as components from "../components/index.js";
7
+ import { MoovError } from "./mooverror.js";
8
+
9
+ export type CreateAccountErrorData = {
10
+ accountType?: string | undefined;
11
+ profile?: components.CreateProfileError | undefined;
12
+ metadata?: string | undefined;
13
+ termsOfService?: components.TermsOfServiceError | undefined;
14
+ foreignID?: string | undefined;
15
+ customerSupport?: components.CustomerSupportError | undefined;
16
+ settings?: components.CreateAccountSettings | undefined;
17
+ capabilities?: { [k: string]: string } | undefined;
18
+ };
19
+
20
+ export class CreateAccountError extends MoovError {
21
+ accountType?: string | undefined;
22
+ profile?: components.CreateProfileError | undefined;
23
+ metadata?: string | undefined;
24
+ termsOfService?: components.TermsOfServiceError | undefined;
25
+ foreignID?: string | undefined;
26
+ customerSupport?: components.CustomerSupportError | undefined;
27
+ settings?: components.CreateAccountSettings | undefined;
28
+ capabilities?: { [k: string]: string } | undefined;
29
+
30
+ /** The original data that was passed to this error instance. */
31
+ data$: CreateAccountErrorData;
32
+
33
+ constructor(
34
+ err: CreateAccountErrorData,
35
+ httpMeta: { response: Response; request: Request; body: string },
36
+ ) {
37
+ const message = "message" in err && typeof err.message === "string"
38
+ ? err.message
39
+ : `API error occurred: ${JSON.stringify(err)}`;
40
+ super(message, httpMeta);
41
+ this.data$ = err;
42
+ if (err.accountType != null) this.accountType = err.accountType;
43
+ if (err.profile != null) this.profile = err.profile;
44
+ if (err.metadata != null) this.metadata = err.metadata;
45
+ if (err.termsOfService != null) this.termsOfService = err.termsOfService;
46
+ if (err.foreignID != null) this.foreignID = err.foreignID;
47
+ if (err.customerSupport != null) this.customerSupport = err.customerSupport;
48
+ if (err.settings != null) this.settings = err.settings;
49
+ if (err.capabilities != null) this.capabilities = err.capabilities;
50
+
51
+ this.name = "CreateAccountError";
52
+ }
53
+ }
54
+
55
+ /** @internal */
56
+ export const CreateAccountError$inboundSchema: z.ZodType<
57
+ CreateAccountError,
58
+ z.ZodTypeDef,
59
+ unknown
60
+ > = z.object({
61
+ accountType: z.string().optional(),
62
+ profile: components.CreateProfileError$inboundSchema.optional(),
63
+ metadata: z.string().optional(),
64
+ termsOfService: components.TermsOfServiceError$inboundSchema.optional(),
65
+ foreignID: z.string().optional(),
66
+ customerSupport: components.CustomerSupportError$inboundSchema.optional(),
67
+ settings: components.CreateAccountSettings$inboundSchema.optional(),
68
+ capabilities: z.record(z.string()).optional(),
69
+ request$: z.instanceof(Request),
70
+ response$: z.instanceof(Response),
71
+ body$: z.string(),
72
+ })
73
+ .transform((v) => {
74
+ return new CreateAccountError(v, {
75
+ request: v.request$,
76
+ response: v.response$,
77
+ body: v.body$,
78
+ });
79
+ });
80
+
81
+ /** @internal */
82
+ export type CreateAccountError$Outbound = {
83
+ accountType?: string | undefined;
84
+ profile?: components.CreateProfileError$Outbound | undefined;
85
+ metadata?: string | undefined;
86
+ termsOfService?: components.TermsOfServiceError$Outbound | undefined;
87
+ foreignID?: string | undefined;
88
+ customerSupport?: components.CustomerSupportError$Outbound | undefined;
89
+ settings?: components.CreateAccountSettings$Outbound | undefined;
90
+ capabilities?: { [k: string]: string } | undefined;
91
+ };
92
+
93
+ /** @internal */
94
+ export const CreateAccountError$outboundSchema: z.ZodType<
95
+ CreateAccountError$Outbound,
96
+ z.ZodTypeDef,
97
+ CreateAccountError
98
+ > = z.instanceof(CreateAccountError)
99
+ .transform(v => v.data$)
100
+ .pipe(z.object({
101
+ accountType: z.string().optional(),
102
+ profile: components.CreateProfileError$outboundSchema.optional(),
103
+ metadata: z.string().optional(),
104
+ termsOfService: components.TermsOfServiceError$outboundSchema.optional(),
105
+ foreignID: z.string().optional(),
106
+ customerSupport: components.CustomerSupportError$outboundSchema.optional(),
107
+ settings: components.CreateAccountSettings$outboundSchema.optional(),
108
+ capabilities: z.record(z.string()).optional(),
109
+ }));
110
+
111
+ /**
112
+ * @internal
113
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
114
+ */
115
+ export namespace CreateAccountError$ {
116
+ /** @deprecated use `CreateAccountError$inboundSchema` instead. */
117
+ export const inboundSchema = CreateAccountError$inboundSchema;
118
+ /** @deprecated use `CreateAccountError$outboundSchema` instead. */
119
+ export const outboundSchema = CreateAccountError$outboundSchema;
120
+ /** @deprecated use `CreateAccountError$Outbound` instead. */
121
+ export type Outbound = CreateAccountError$Outbound;
122
+ }
@@ -10,7 +10,7 @@ export * from "./authtokenrequesterror.js";
10
10
  export * from "./bankaccountvalidationerror.js";
11
11
  export * from "./brandvalidationerror.js";
12
12
  export * from "./cardacquiringrefund.js";
13
- export * from "./createaccount.js";
13
+ export * from "./createaccounterror.js";
14
14
  export * from "./createpaymentlinkerror.js";
15
15
  export * from "./createsweepconfigerror.js";
16
16
  export * from "./createticketerror.js";
@@ -23,6 +23,7 @@ export * from "./linkapplepayerror.js";
23
23
  export * from "./linkcarderror.js";
24
24
  export * from "./microdepositvalidationerror.js";
25
25
  export * from "./onboardinginviteerror.js";
26
+ export * from "./patchaccounterror.js";
26
27
  export * from "./patchsweepconfigerror.js";
27
28
  export * from "./refundvalidationerror.js";
28
29
  export * from "./representativevalidationerror.js";
@@ -36,7 +37,6 @@ export * from "./terminalapplicationerror.js";
36
37
  export * from "./transfer.js";
37
38
  export * from "./transferoptionsvalidationerror.js";
38
39
  export * from "./transfervalidationerror.js";
39
- export * from "./updateaccount.js";
40
40
  export * from "./updatecarderror.js";
41
41
  export * from "./updateissuedcarderror.js";
42
42
  export * from "./updatepaymentlinkerror.js";
@@ -0,0 +1,110 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod";
6
+ import * as components from "../components/index.js";
7
+ import { MoovError } from "./mooverror.js";
8
+
9
+ export type PatchAccountErrorData = {
10
+ profile?: components.CreateProfileError | undefined;
11
+ metadata?: string | undefined;
12
+ termsOfService?: components.TermsOfServiceError | undefined;
13
+ foreignID?: string | undefined;
14
+ customerSupport?: components.CustomerSupportError | undefined;
15
+ settings?: components.CreateAccountSettings | undefined;
16
+ };
17
+
18
+ export class PatchAccountError extends MoovError {
19
+ profile?: components.CreateProfileError | undefined;
20
+ metadata?: string | undefined;
21
+ termsOfService?: components.TermsOfServiceError | undefined;
22
+ foreignID?: string | undefined;
23
+ customerSupport?: components.CustomerSupportError | undefined;
24
+ settings?: components.CreateAccountSettings | undefined;
25
+
26
+ /** The original data that was passed to this error instance. */
27
+ data$: PatchAccountErrorData;
28
+
29
+ constructor(
30
+ err: PatchAccountErrorData,
31
+ httpMeta: { response: Response; request: Request; body: string },
32
+ ) {
33
+ const message = "message" in err && typeof err.message === "string"
34
+ ? err.message
35
+ : `API error occurred: ${JSON.stringify(err)}`;
36
+ super(message, httpMeta);
37
+ this.data$ = err;
38
+ if (err.profile != null) this.profile = err.profile;
39
+ if (err.metadata != null) this.metadata = err.metadata;
40
+ if (err.termsOfService != null) this.termsOfService = err.termsOfService;
41
+ if (err.foreignID != null) this.foreignID = err.foreignID;
42
+ if (err.customerSupport != null) this.customerSupport = err.customerSupport;
43
+ if (err.settings != null) this.settings = err.settings;
44
+
45
+ this.name = "PatchAccountError";
46
+ }
47
+ }
48
+
49
+ /** @internal */
50
+ export const PatchAccountError$inboundSchema: z.ZodType<
51
+ PatchAccountError,
52
+ z.ZodTypeDef,
53
+ unknown
54
+ > = z.object({
55
+ profile: components.CreateProfileError$inboundSchema.optional(),
56
+ metadata: z.string().optional(),
57
+ termsOfService: components.TermsOfServiceError$inboundSchema.optional(),
58
+ foreignID: z.string().optional(),
59
+ customerSupport: components.CustomerSupportError$inboundSchema.optional(),
60
+ settings: components.CreateAccountSettings$inboundSchema.optional(),
61
+ request$: z.instanceof(Request),
62
+ response$: z.instanceof(Response),
63
+ body$: z.string(),
64
+ })
65
+ .transform((v) => {
66
+ return new PatchAccountError(v, {
67
+ request: v.request$,
68
+ response: v.response$,
69
+ body: v.body$,
70
+ });
71
+ });
72
+
73
+ /** @internal */
74
+ export type PatchAccountError$Outbound = {
75
+ profile?: components.CreateProfileError$Outbound | undefined;
76
+ metadata?: string | undefined;
77
+ termsOfService?: components.TermsOfServiceError$Outbound | undefined;
78
+ foreignID?: string | undefined;
79
+ customerSupport?: components.CustomerSupportError$Outbound | undefined;
80
+ settings?: components.CreateAccountSettings$Outbound | undefined;
81
+ };
82
+
83
+ /** @internal */
84
+ export const PatchAccountError$outboundSchema: z.ZodType<
85
+ PatchAccountError$Outbound,
86
+ z.ZodTypeDef,
87
+ PatchAccountError
88
+ > = z.instanceof(PatchAccountError)
89
+ .transform(v => v.data$)
90
+ .pipe(z.object({
91
+ profile: components.CreateProfileError$outboundSchema.optional(),
92
+ metadata: z.string().optional(),
93
+ termsOfService: components.TermsOfServiceError$outboundSchema.optional(),
94
+ foreignID: z.string().optional(),
95
+ customerSupport: components.CustomerSupportError$outboundSchema.optional(),
96
+ settings: components.CreateAccountSettings$outboundSchema.optional(),
97
+ }));
98
+
99
+ /**
100
+ * @internal
101
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
102
+ */
103
+ export namespace PatchAccountError$ {
104
+ /** @deprecated use `PatchAccountError$inboundSchema` instead. */
105
+ export const inboundSchema = PatchAccountError$inboundSchema;
106
+ /** @deprecated use `PatchAccountError$outboundSchema` instead. */
107
+ export const outboundSchema = PatchAccountError$outboundSchema;
108
+ /** @deprecated use `PatchAccountError$Outbound` instead. */
109
+ export type Outbound = PatchAccountError$Outbound;
110
+ }
@@ -17,6 +17,9 @@ export class Support extends ClientSDK {
17
17
  *
18
18
  * To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
19
19
  * you'll need to specify the `/accounts/{accountID}/tickets.write` scope.
20
+ *
21
+ * If you're creating the ticket on behalf of another account, then you'll need to
22
+ * specify the `/accounts/{partnerAccountID}/tickets.write` and `/accounts/{accountID}/profile.read` scopes.
20
23
  */
21
24
  async createTicket(
22
25
  request: operations.CreateTicketRequest,
@@ -34,6 +37,9 @@ export class Support extends ClientSDK {
34
37
  *
35
38
  * To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
36
39
  * you'll need to specify the `/accounts/{accountID}/tickets.read` scope.
40
+ *
41
+ * If you're listing another account's tickets, then you'll need to
42
+ * specify the `/accounts/{partnerAccountID}/tickets.read` and `/accounts/{accountID}/profile.read` scopes.
37
43
  */
38
44
  async listTickets(
39
45
  request: operations.ListTicketsRequest,
@@ -51,6 +57,9 @@ export class Support extends ClientSDK {
51
57
  *
52
58
  * To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
53
59
  * you'll need to specify the `/accounts/{accountID}/tickets.read` scope.
60
+ *
61
+ * If you're retrieving another account's ticket, then you'll need to
62
+ * specify the `/accounts/{partnerAccountID}/tickets.read` and `/accounts/{accountID}/profile.read` scopes.
54
63
  */
55
64
  async getTicket(
56
65
  request: operations.GetTicketRequest,
@@ -68,6 +77,9 @@ export class Support extends ClientSDK {
68
77
  *
69
78
  * To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
70
79
  * you'll need to specify the `/accounts/{accountID}/tickets.write` scope.
80
+ *
81
+ * If you're updating the ticket on behalf of another account, then you'll need to
82
+ * specify the `/accounts/{partnerAccountID}/tickets.write` and `/accounts/{accountID}/profile.read` scopes.
71
83
  */
72
84
  async updateTicket(
73
85
  request: operations.UpdateTicketRequest,
@@ -85,6 +97,9 @@ export class Support extends ClientSDK {
85
97
  *
86
98
  * To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
87
99
  * you'll need to specify the `/accounts/{accountID}/tickets.read` scope.
100
+ *
101
+ * If you're listing another account's messages, then you'll need to
102
+ * specify the `/accounts/{partnerAccountID}/tickets.read` and `/accounts/{accountID}/profile.read` scopes.
88
103
  */
89
104
  async listTicketMessages(
90
105
  request: operations.ListTicketMessagesRequest,
@@ -1,51 +0,0 @@
1
- import * as z from "zod";
2
- import { Result as SafeParseResult } from "../../types/fp.js";
3
- import { SDKValidationError } from "../errors/sdkvalidationerror.js";
4
- import { CreateAccountSettings, CreateAccountSettings$Outbound } from "./createaccountsettings.js";
5
- import { CreateProfileError, CreateProfileError$Outbound } from "./createprofileerror.js";
6
- import { CustomerSupportError, CustomerSupportError$Outbound } from "./customersupporterror.js";
7
- import { TermsOfServiceError, TermsOfServiceError$Outbound } from "./termsofserviceerror.js";
8
- export type CreateAccountError = {
9
- accountType?: string | undefined;
10
- profile?: CreateProfileError | undefined;
11
- metadata?: string | undefined;
12
- termsOfService?: TermsOfServiceError | undefined;
13
- foreignID?: string | undefined;
14
- customerSupport?: CustomerSupportError | undefined;
15
- settings?: CreateAccountSettings | undefined;
16
- capabilities?: {
17
- [k: string]: string;
18
- } | undefined;
19
- };
20
- /** @internal */
21
- export declare const CreateAccountError$inboundSchema: z.ZodType<CreateAccountError, z.ZodTypeDef, unknown>;
22
- /** @internal */
23
- export type CreateAccountError$Outbound = {
24
- accountType?: string | undefined;
25
- profile?: CreateProfileError$Outbound | undefined;
26
- metadata?: string | undefined;
27
- termsOfService?: TermsOfServiceError$Outbound | undefined;
28
- foreignID?: string | undefined;
29
- customerSupport?: CustomerSupportError$Outbound | undefined;
30
- settings?: CreateAccountSettings$Outbound | undefined;
31
- capabilities?: {
32
- [k: string]: string;
33
- } | undefined;
34
- };
35
- /** @internal */
36
- export declare const CreateAccountError$outboundSchema: z.ZodType<CreateAccountError$Outbound, z.ZodTypeDef, CreateAccountError>;
37
- /**
38
- * @internal
39
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
40
- */
41
- export declare namespace CreateAccountError$ {
42
- /** @deprecated use `CreateAccountError$inboundSchema` instead. */
43
- const inboundSchema: z.ZodType<CreateAccountError, z.ZodTypeDef, unknown>;
44
- /** @deprecated use `CreateAccountError$outboundSchema` instead. */
45
- const outboundSchema: z.ZodType<CreateAccountError$Outbound, z.ZodTypeDef, CreateAccountError>;
46
- /** @deprecated use `CreateAccountError$Outbound` instead. */
47
- type Outbound = CreateAccountError$Outbound;
48
- }
49
- export declare function createAccountErrorToJSON(createAccountError: CreateAccountError): string;
50
- export declare function createAccountErrorFromJSON(jsonString: string): SafeParseResult<CreateAccountError, SDKValidationError>;
51
- //# sourceMappingURL=createaccounterror.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"createaccounterror.d.ts","sourceRoot":"","sources":["../../src/models/components/createaccounterror.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AAEzB,OAAO,EAAE,MAAM,IAAI,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAC9D,OAAO,EAAE,kBAAkB,EAAE,MAAM,iCAAiC,CAAC;AACrE,OAAO,EACL,qBAAqB,EAErB,8BAA8B,EAE/B,MAAM,4BAA4B,CAAC;AACpC,OAAO,EACL,kBAAkB,EAElB,2BAA2B,EAE5B,MAAM,yBAAyB,CAAC;AACjC,OAAO,EACL,oBAAoB,EAEpB,6BAA6B,EAE9B,MAAM,2BAA2B,CAAC;AACnC,OAAO,EACL,mBAAmB,EAEnB,4BAA4B,EAE7B,MAAM,0BAA0B,CAAC;AAElC,MAAM,MAAM,kBAAkB,GAAG;IAC/B,WAAW,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IACjC,OAAO,CAAC,EAAE,kBAAkB,GAAG,SAAS,CAAC;IACzC,QAAQ,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IAC9B,cAAc,CAAC,EAAE,mBAAmB,GAAG,SAAS,CAAC;IACjD,SAAS,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IAC/B,eAAe,CAAC,EAAE,oBAAoB,GAAG,SAAS,CAAC;IACnD,QAAQ,CAAC,EAAE,qBAAqB,GAAG,SAAS,CAAC;IAC7C,YAAY,CAAC,EAAE;QAAE,CAAC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