@moovio/sdk 0.12.4 → 0.12.6

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 (99) hide show
  1. package/README.md +54 -36
  2. package/bin/mcp-server.js +403 -163
  3. package/bin/mcp-server.js.map +26 -23
  4. package/docs/sdks/transfers/README.md +117 -2
  5. package/funcs/disputesUploadEvidenceFile.d.ts.map +1 -1
  6. package/funcs/disputesUploadEvidenceFile.js +5 -3
  7. package/funcs/disputesUploadEvidenceFile.js.map +1 -1
  8. package/funcs/filesUpload.d.ts.map +1 -1
  9. package/funcs/filesUpload.js +5 -3
  10. package/funcs/filesUpload.js.map +1 -1
  11. package/funcs/transfersGenerateOptions.d.ts +1 -1
  12. package/funcs/transfersGenerateOptions.js +1 -1
  13. package/funcs/transfersGenerateOptionsForAccount.d.ts +23 -0
  14. package/funcs/transfersGenerateOptionsForAccount.d.ts.map +1 -0
  15. package/funcs/transfersGenerateOptionsForAccount.js +133 -0
  16. package/funcs/transfersGenerateOptionsForAccount.js.map +1 -0
  17. package/jsr.json +1 -1
  18. package/lib/config.d.ts +3 -3
  19. package/lib/config.js +3 -3
  20. package/lib/files.d.ts +5 -0
  21. package/lib/files.d.ts.map +1 -1
  22. package/lib/files.js +41 -0
  23. package/lib/files.js.map +1 -1
  24. package/lib/security.d.ts +2 -2
  25. package/lib/security.d.ts.map +1 -1
  26. package/mcp-server/mcp-server.js +1 -1
  27. package/mcp-server/server.d.ts.map +1 -1
  28. package/mcp-server/server.js +3 -1
  29. package/mcp-server/server.js.map +1 -1
  30. package/mcp-server/tools/transfersGenerateOptions.js +1 -1
  31. package/mcp-server/tools/transfersGenerateOptions.js.map +1 -1
  32. package/mcp-server/tools/transfersGenerateOptionsForAccount.d.ts +8 -0
  33. package/mcp-server/tools/transfersGenerateOptionsForAccount.d.ts.map +1 -0
  34. package/mcp-server/tools/transfersGenerateOptionsForAccount.js +70 -0
  35. package/mcp-server/tools/transfersGenerateOptionsForAccount.js.map +1 -0
  36. package/models/components/capability.d.ts +1 -1
  37. package/models/components/capabilityid.d.ts +32 -2
  38. package/models/components/capabilityid.d.ts.map +1 -1
  39. package/models/components/capabilityid.js +11 -1
  40. package/models/components/capabilityid.js.map +1 -1
  41. package/models/components/createaccount.d.ts +4 -4
  42. package/models/components/createaccount.d.ts.map +1 -1
  43. package/models/components/createaccount.js +4 -4
  44. package/models/components/createaccount.js.map +1 -1
  45. package/models/components/createrefundresponse.d.ts +2 -2
  46. package/models/components/createrefundresponse.d.ts.map +1 -1
  47. package/models/components/createrefundresponse.js +2 -2
  48. package/models/components/createrefundresponse.js.map +1 -1
  49. package/models/components/webhookdata.d.ts +2 -2
  50. package/models/components/webhookdata.d.ts.map +1 -1
  51. package/models/components/webhookdata.js +38 -38
  52. package/models/components/webhookdata.js.map +1 -1
  53. package/models/components/webhookdatacapabilityrequested.d.ts +1 -1
  54. package/models/components/webhookdatacapabilityupdated.d.ts +1 -1
  55. package/models/operations/createtransfer.d.ts +4 -4
  56. package/models/operations/createtransfer.d.ts.map +1 -1
  57. package/models/operations/createtransfer.js +8 -8
  58. package/models/operations/createtransfer.js.map +1 -1
  59. package/models/operations/createtransferoptionsforaccount.d.ts +104 -0
  60. package/models/operations/createtransferoptionsforaccount.d.ts.map +1 -0
  61. package/models/operations/createtransferoptionsforaccount.js +155 -0
  62. package/models/operations/createtransferoptionsforaccount.js.map +1 -0
  63. package/models/operations/disablecapability.d.ts +1 -1
  64. package/models/operations/getcapability.d.ts +1 -1
  65. package/models/operations/index.d.ts +1 -0
  66. package/models/operations/index.d.ts.map +1 -1
  67. package/models/operations/index.js +1 -0
  68. package/models/operations/index.js.map +1 -1
  69. package/package.json +1 -1
  70. package/sdk/transfers.d.ts +13 -1
  71. package/sdk/transfers.d.ts.map +1 -1
  72. package/sdk/transfers.js +16 -1
  73. package/sdk/transfers.js.map +1 -1
  74. package/src/funcs/disputesUploadEvidenceFile.ts +20 -4
  75. package/src/funcs/filesUpload.ts +20 -4
  76. package/src/funcs/transfersGenerateOptions.ts +1 -1
  77. package/src/funcs/transfersGenerateOptionsForAccount.ts +202 -0
  78. package/src/lib/config.ts +3 -3
  79. package/src/lib/files.ts +42 -0
  80. package/src/lib/security.ts +2 -2
  81. package/src/mcp-server/mcp-server.ts +1 -1
  82. package/src/mcp-server/server.ts +3 -1
  83. package/src/mcp-server/tools/transfersGenerateOptions.ts +1 -1
  84. package/src/mcp-server/tools/transfersGenerateOptionsForAccount.ts +46 -0
  85. package/src/models/components/capability.ts +1 -1
  86. package/src/models/components/capabilityid.ts +12 -2
  87. package/src/models/components/createaccount.ts +10 -10
  88. package/src/models/components/createrefundresponse.ts +5 -5
  89. package/src/models/components/webhookdata.ts +76 -76
  90. package/src/models/components/webhookdatacapabilityrequested.ts +1 -1
  91. package/src/models/components/webhookdatacapabilityupdated.ts +1 -1
  92. package/src/models/operations/createtransfer.ts +16 -16
  93. package/src/models/operations/createtransferoptionsforaccount.ts +257 -0
  94. package/src/models/operations/disablecapability.ts +1 -1
  95. package/src/models/operations/getcapability.ts +1 -1
  96. package/src/models/operations/index.ts +1 -0
  97. package/src/sdk/transfers.ts +24 -1
  98. package/src/types/constdatetime.ts +1 -1
  99. package/types/constdatetime.js +1 -1
@@ -185,34 +185,34 @@ import {
185
185
  * The data for the webhook event. The contents are based on the event type.
186
186
  */
187
187
  export type WebhookData =
188
- | WebhookDataAccountCreated
189
- | WebhookDataAccountUpdated
190
- | WebhookDataAccountDeleted
188
+ | WebhookDataDisputeCreated
189
+ | WebhookDataDisputeUpdated
190
+ | WebhookDataTransferUpdated
191
+ | WebhookDataBankAccountUpdated
192
+ | WebhookDataRefundUpdated
193
+ | WebhookDataWalletTransactionUpdated
194
+ | WebhookDataCancellationCreated
195
+ | WebhookDataCancellationUpdated
196
+ | WebhookDataCardAutoUpdated
197
+ | WebhookDataCapabilityUpdated
198
+ | WebhookDataPaymentMethodEnabled
199
+ | WebhookDataPaymentMethodDisabled
200
+ | WebhookDataRefundCreated
201
+ | WebhookDataSweepUpdated
202
+ | WebhookDataTransferCreated
191
203
  | WebhookDataBalanceUpdated
192
204
  | WebhookDataBankAccountCreated
193
205
  | WebhookDataBankAccountDeleted
206
+ | WebhookDataCapabilityRequested
194
207
  | WebhookDataRepresentativeCreated
195
208
  | WebhookDataRepresentativeUpdated
196
209
  | WebhookDataRepresentativeDisabled
197
210
  | WebhookDataSweepCreated
198
211
  | WebhookDataTerminalApplicationCreated
199
212
  | WebhookDataTerminalApplicationUpdated
200
- | WebhookDataCancellationCreated
201
- | WebhookDataCancellationUpdated
202
- | WebhookDataCardAutoUpdated
203
- | WebhookDataCapabilityRequested
204
- | WebhookDataPaymentMethodEnabled
205
- | WebhookDataPaymentMethodDisabled
206
- | WebhookDataRefundCreated
207
- | WebhookDataTransferCreated
208
- | WebhookDataCapabilityUpdated
209
- | WebhookDataRefundUpdated
210
- | WebhookDataSweepUpdated
211
- | WebhookDataBankAccountUpdated
212
- | WebhookDataTransferUpdated
213
- | WebhookDataWalletTransactionUpdated
214
- | WebhookDataDisputeCreated
215
- | WebhookDataDisputeUpdated
213
+ | WebhookDataAccountCreated
214
+ | WebhookDataAccountUpdated
215
+ | WebhookDataAccountDeleted
216
216
  | WebhookDataNetworkIDUpdated;
217
217
 
218
218
  /** @internal */
@@ -221,67 +221,67 @@ export const WebhookData$inboundSchema: z.ZodType<
221
221
  z.ZodTypeDef,
222
222
  unknown
223
223
  > = z.union([
224
- WebhookDataAccountCreated$inboundSchema,
225
- WebhookDataAccountUpdated$inboundSchema,
226
- WebhookDataAccountDeleted$inboundSchema,
224
+ WebhookDataDisputeCreated$inboundSchema,
225
+ WebhookDataDisputeUpdated$inboundSchema,
226
+ WebhookDataTransferUpdated$inboundSchema,
227
+ WebhookDataBankAccountUpdated$inboundSchema,
228
+ WebhookDataRefundUpdated$inboundSchema,
229
+ WebhookDataWalletTransactionUpdated$inboundSchema,
230
+ WebhookDataCancellationCreated$inboundSchema,
231
+ WebhookDataCancellationUpdated$inboundSchema,
232
+ WebhookDataCardAutoUpdated$inboundSchema,
233
+ WebhookDataCapabilityUpdated$inboundSchema,
234
+ WebhookDataPaymentMethodEnabled$inboundSchema,
235
+ WebhookDataPaymentMethodDisabled$inboundSchema,
236
+ WebhookDataRefundCreated$inboundSchema,
237
+ WebhookDataSweepUpdated$inboundSchema,
238
+ WebhookDataTransferCreated$inboundSchema,
227
239
  WebhookDataBalanceUpdated$inboundSchema,
228
240
  WebhookDataBankAccountCreated$inboundSchema,
229
241
  WebhookDataBankAccountDeleted$inboundSchema,
242
+ WebhookDataCapabilityRequested$inboundSchema,
230
243
  WebhookDataRepresentativeCreated$inboundSchema,
231
244
  WebhookDataRepresentativeUpdated$inboundSchema,
232
245
  WebhookDataRepresentativeDisabled$inboundSchema,
233
246
  WebhookDataSweepCreated$inboundSchema,
234
247
  WebhookDataTerminalApplicationCreated$inboundSchema,
235
248
  WebhookDataTerminalApplicationUpdated$inboundSchema,
236
- WebhookDataCancellationCreated$inboundSchema,
237
- WebhookDataCancellationUpdated$inboundSchema,
238
- WebhookDataCardAutoUpdated$inboundSchema,
239
- WebhookDataCapabilityRequested$inboundSchema,
240
- WebhookDataPaymentMethodEnabled$inboundSchema,
241
- WebhookDataPaymentMethodDisabled$inboundSchema,
242
- WebhookDataRefundCreated$inboundSchema,
243
- WebhookDataTransferCreated$inboundSchema,
244
- WebhookDataCapabilityUpdated$inboundSchema,
245
- WebhookDataRefundUpdated$inboundSchema,
246
- WebhookDataSweepUpdated$inboundSchema,
247
- WebhookDataBankAccountUpdated$inboundSchema,
248
- WebhookDataTransferUpdated$inboundSchema,
249
- WebhookDataWalletTransactionUpdated$inboundSchema,
250
- WebhookDataDisputeCreated$inboundSchema,
251
- WebhookDataDisputeUpdated$inboundSchema,
249
+ WebhookDataAccountCreated$inboundSchema,
250
+ WebhookDataAccountUpdated$inboundSchema,
251
+ WebhookDataAccountDeleted$inboundSchema,
252
252
  WebhookDataNetworkIDUpdated$inboundSchema,
253
253
  ]);
254
254
 
255
255
  /** @internal */
256
256
  export type WebhookData$Outbound =
257
- | WebhookDataAccountCreated$Outbound
258
- | WebhookDataAccountUpdated$Outbound
259
- | WebhookDataAccountDeleted$Outbound
257
+ | WebhookDataDisputeCreated$Outbound
258
+ | WebhookDataDisputeUpdated$Outbound
259
+ | WebhookDataTransferUpdated$Outbound
260
+ | WebhookDataBankAccountUpdated$Outbound
261
+ | WebhookDataRefundUpdated$Outbound
262
+ | WebhookDataWalletTransactionUpdated$Outbound
263
+ | WebhookDataCancellationCreated$Outbound
264
+ | WebhookDataCancellationUpdated$Outbound
265
+ | WebhookDataCardAutoUpdated$Outbound
266
+ | WebhookDataCapabilityUpdated$Outbound
267
+ | WebhookDataPaymentMethodEnabled$Outbound
268
+ | WebhookDataPaymentMethodDisabled$Outbound
269
+ | WebhookDataRefundCreated$Outbound
270
+ | WebhookDataSweepUpdated$Outbound
271
+ | WebhookDataTransferCreated$Outbound
260
272
  | WebhookDataBalanceUpdated$Outbound
261
273
  | WebhookDataBankAccountCreated$Outbound
262
274
  | WebhookDataBankAccountDeleted$Outbound
275
+ | WebhookDataCapabilityRequested$Outbound
263
276
  | WebhookDataRepresentativeCreated$Outbound
264
277
  | WebhookDataRepresentativeUpdated$Outbound
265
278
  | WebhookDataRepresentativeDisabled$Outbound
266
279
  | WebhookDataSweepCreated$Outbound
267
280
  | WebhookDataTerminalApplicationCreated$Outbound
268
281
  | WebhookDataTerminalApplicationUpdated$Outbound
269
- | WebhookDataCancellationCreated$Outbound
270
- | WebhookDataCancellationUpdated$Outbound
271
- | WebhookDataCardAutoUpdated$Outbound
272
- | WebhookDataCapabilityRequested$Outbound
273
- | WebhookDataPaymentMethodEnabled$Outbound
274
- | WebhookDataPaymentMethodDisabled$Outbound
275
- | WebhookDataRefundCreated$Outbound
276
- | WebhookDataTransferCreated$Outbound
277
- | WebhookDataCapabilityUpdated$Outbound
278
- | WebhookDataRefundUpdated$Outbound
279
- | WebhookDataSweepUpdated$Outbound
280
- | WebhookDataBankAccountUpdated$Outbound
281
- | WebhookDataTransferUpdated$Outbound
282
- | WebhookDataWalletTransactionUpdated$Outbound
283
- | WebhookDataDisputeCreated$Outbound
284
- | WebhookDataDisputeUpdated$Outbound
282
+ | WebhookDataAccountCreated$Outbound
283
+ | WebhookDataAccountUpdated$Outbound
284
+ | WebhookDataAccountDeleted$Outbound
285
285
  | WebhookDataNetworkIDUpdated$Outbound;
286
286
 
287
287
  /** @internal */
@@ -290,34 +290,34 @@ export const WebhookData$outboundSchema: z.ZodType<
290
290
  z.ZodTypeDef,
291
291
  WebhookData
292
292
  > = z.union([
293
- WebhookDataAccountCreated$outboundSchema,
294
- WebhookDataAccountUpdated$outboundSchema,
295
- WebhookDataAccountDeleted$outboundSchema,
293
+ WebhookDataDisputeCreated$outboundSchema,
294
+ WebhookDataDisputeUpdated$outboundSchema,
295
+ WebhookDataTransferUpdated$outboundSchema,
296
+ WebhookDataBankAccountUpdated$outboundSchema,
297
+ WebhookDataRefundUpdated$outboundSchema,
298
+ WebhookDataWalletTransactionUpdated$outboundSchema,
299
+ WebhookDataCancellationCreated$outboundSchema,
300
+ WebhookDataCancellationUpdated$outboundSchema,
301
+ WebhookDataCardAutoUpdated$outboundSchema,
302
+ WebhookDataCapabilityUpdated$outboundSchema,
303
+ WebhookDataPaymentMethodEnabled$outboundSchema,
304
+ WebhookDataPaymentMethodDisabled$outboundSchema,
305
+ WebhookDataRefundCreated$outboundSchema,
306
+ WebhookDataSweepUpdated$outboundSchema,
307
+ WebhookDataTransferCreated$outboundSchema,
296
308
  WebhookDataBalanceUpdated$outboundSchema,
297
309
  WebhookDataBankAccountCreated$outboundSchema,
298
310
  WebhookDataBankAccountDeleted$outboundSchema,
311
+ WebhookDataCapabilityRequested$outboundSchema,
299
312
  WebhookDataRepresentativeCreated$outboundSchema,
300
313
  WebhookDataRepresentativeUpdated$outboundSchema,
301
314
  WebhookDataRepresentativeDisabled$outboundSchema,
302
315
  WebhookDataSweepCreated$outboundSchema,
303
316
  WebhookDataTerminalApplicationCreated$outboundSchema,
304
317
  WebhookDataTerminalApplicationUpdated$outboundSchema,
305
- WebhookDataCancellationCreated$outboundSchema,
306
- WebhookDataCancellationUpdated$outboundSchema,
307
- WebhookDataCardAutoUpdated$outboundSchema,
308
- WebhookDataCapabilityRequested$outboundSchema,
309
- WebhookDataPaymentMethodEnabled$outboundSchema,
310
- WebhookDataPaymentMethodDisabled$outboundSchema,
311
- WebhookDataRefundCreated$outboundSchema,
312
- WebhookDataTransferCreated$outboundSchema,
313
- WebhookDataCapabilityUpdated$outboundSchema,
314
- WebhookDataRefundUpdated$outboundSchema,
315
- WebhookDataSweepUpdated$outboundSchema,
316
- WebhookDataBankAccountUpdated$outboundSchema,
317
- WebhookDataTransferUpdated$outboundSchema,
318
- WebhookDataWalletTransactionUpdated$outboundSchema,
319
- WebhookDataDisputeCreated$outboundSchema,
320
- WebhookDataDisputeUpdated$outboundSchema,
318
+ WebhookDataAccountCreated$outboundSchema,
319
+ WebhookDataAccountUpdated$outboundSchema,
320
+ WebhookDataAccountDeleted$outboundSchema,
321
321
  WebhookDataNetworkIDUpdated$outboundSchema,
322
322
  ]);
323
323
 
@@ -20,7 +20,7 @@ export type WebhookDataCapabilityRequested = {
20
20
  *
21
21
  * @remarks
22
22
  *
23
- * The `production-app` capability might appear in your list. This is a read-only capability that Moov requests and uses for account verification purposes. The capability remains active with your account and requires no additional action.
23
+ * The `production-app`, `platform.production-app`, and / or `platform.wallet-transfers` capabilities might appear in your list. These are read-only capabilities that Moov requests and uses for account verification purposes. These capabilities remains active with your account and require no additional action.
24
24
  */
25
25
  capabilityID: CapabilityID;
26
26
  };
@@ -25,7 +25,7 @@ export type WebhookDataCapabilityUpdated = {
25
25
  *
26
26
  * @remarks
27
27
  *
28
- * The `production-app` capability might appear in your list. This is a read-only capability that Moov requests and uses for account verification purposes. The capability remains active with your account and requires no additional action.
28
+ * The `production-app`, `platform.production-app`, and / or `platform.wallet-transfers` capabilities might appear in your list. These are read-only capabilities that Moov requests and uses for account verification purposes. These capabilities remains active with your account and require no additional action.
29
29
  */
30
30
  capabilityID: CapabilityID;
31
31
  /**
@@ -46,16 +46,16 @@ export type CreateTransferRequest = {
46
46
  };
47
47
 
48
48
  export type CreateTransferResponseResult =
49
- | components.AsyncTransfer
49
+ | components.Transfer
50
50
  | components.CreatedTransfer
51
- | components.Transfer;
51
+ | components.AsyncTransfer;
52
52
 
53
53
  export type CreateTransferResponse = {
54
54
  headers: { [k: string]: Array<string> };
55
55
  result:
56
- | components.AsyncTransfer
56
+ | components.Transfer
57
57
  | components.CreatedTransfer
58
- | components.Transfer;
58
+ | components.AsyncTransfer;
59
59
  };
60
60
 
61
61
  /** @internal */
@@ -201,16 +201,16 @@ export const CreateTransferResponseResult$inboundSchema: z.ZodType<
201
201
  z.ZodTypeDef,
202
202
  unknown
203
203
  > = z.union([
204
- components.AsyncTransfer$inboundSchema,
205
- components.CreatedTransfer$inboundSchema,
206
204
  components.Transfer$inboundSchema,
205
+ components.CreatedTransfer$inboundSchema,
206
+ components.AsyncTransfer$inboundSchema,
207
207
  ]);
208
208
 
209
209
  /** @internal */
210
210
  export type CreateTransferResponseResult$Outbound =
211
- | components.AsyncTransfer$Outbound
211
+ | components.Transfer$Outbound
212
212
  | components.CreatedTransfer$Outbound
213
- | components.Transfer$Outbound;
213
+ | components.AsyncTransfer$Outbound;
214
214
 
215
215
  /** @internal */
216
216
  export const CreateTransferResponseResult$outboundSchema: z.ZodType<
@@ -218,9 +218,9 @@ export const CreateTransferResponseResult$outboundSchema: z.ZodType<
218
218
  z.ZodTypeDef,
219
219
  CreateTransferResponseResult
220
220
  > = z.union([
221
- components.AsyncTransfer$outboundSchema,
222
- components.CreatedTransfer$outboundSchema,
223
221
  components.Transfer$outboundSchema,
222
+ components.CreatedTransfer$outboundSchema,
223
+ components.AsyncTransfer$outboundSchema,
224
224
  ]);
225
225
 
226
226
  /**
@@ -264,9 +264,9 @@ export const CreateTransferResponse$inboundSchema: z.ZodType<
264
264
  > = z.object({
265
265
  Headers: z.record(z.array(z.string())),
266
266
  Result: z.union([
267
- components.AsyncTransfer$inboundSchema,
268
- components.CreatedTransfer$inboundSchema,
269
267
  components.Transfer$inboundSchema,
268
+ components.CreatedTransfer$inboundSchema,
269
+ components.AsyncTransfer$inboundSchema,
270
270
  ]),
271
271
  }).transform((v) => {
272
272
  return remap$(v, {
@@ -279,9 +279,9 @@ export const CreateTransferResponse$inboundSchema: z.ZodType<
279
279
  export type CreateTransferResponse$Outbound = {
280
280
  Headers: { [k: string]: Array<string> };
281
281
  Result:
282
- | components.AsyncTransfer$Outbound
282
+ | components.Transfer$Outbound
283
283
  | components.CreatedTransfer$Outbound
284
- | components.Transfer$Outbound;
284
+ | components.AsyncTransfer$Outbound;
285
285
  };
286
286
 
287
287
  /** @internal */
@@ -292,9 +292,9 @@ export const CreateTransferResponse$outboundSchema: z.ZodType<
292
292
  > = z.object({
293
293
  headers: z.record(z.array(z.string())),
294
294
  result: z.union([
295
- components.AsyncTransfer$outboundSchema,
296
- components.CreatedTransfer$outboundSchema,
297
295
  components.Transfer$outboundSchema,
296
+ components.CreatedTransfer$outboundSchema,
297
+ components.AsyncTransfer$outboundSchema,
298
298
  ]),
299
299
  }).transform((v) => {
300
300
  return remap$(v, {
@@ -0,0 +1,257 @@
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 CreateTransferOptionsForAccountGlobals = {
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 CreateTransferOptionsForAccountRequest = {
30
+ /**
31
+ * The partner's Moov account ID.
32
+ */
33
+ accountID: string;
34
+ createTransferOptions: components.CreateTransferOptions;
35
+ };
36
+
37
+ export type CreateTransferOptionsForAccountResponse = {
38
+ headers: { [k: string]: Array<string> };
39
+ result: components.TransferOptions;
40
+ };
41
+
42
+ /** @internal */
43
+ export const CreateTransferOptionsForAccountGlobals$inboundSchema: z.ZodType<
44
+ CreateTransferOptionsForAccountGlobals,
45
+ z.ZodTypeDef,
46
+ unknown
47
+ > = z.object({
48
+ "x-moov-version": z.string().default("v2024.01.00"),
49
+ }).transform((v) => {
50
+ return remap$(v, {
51
+ "x-moov-version": "xMoovVersion",
52
+ });
53
+ });
54
+
55
+ /** @internal */
56
+ export type CreateTransferOptionsForAccountGlobals$Outbound = {
57
+ "x-moov-version": string;
58
+ };
59
+
60
+ /** @internal */
61
+ export const CreateTransferOptionsForAccountGlobals$outboundSchema: z.ZodType<
62
+ CreateTransferOptionsForAccountGlobals$Outbound,
63
+ z.ZodTypeDef,
64
+ CreateTransferOptionsForAccountGlobals
65
+ > = z.object({
66
+ xMoovVersion: z.string().default("v2024.01.00"),
67
+ }).transform((v) => {
68
+ return remap$(v, {
69
+ xMoovVersion: "x-moov-version",
70
+ });
71
+ });
72
+
73
+ /**
74
+ * @internal
75
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
76
+ */
77
+ export namespace CreateTransferOptionsForAccountGlobals$ {
78
+ /** @deprecated use `CreateTransferOptionsForAccountGlobals$inboundSchema` instead. */
79
+ export const inboundSchema =
80
+ CreateTransferOptionsForAccountGlobals$inboundSchema;
81
+ /** @deprecated use `CreateTransferOptionsForAccountGlobals$outboundSchema` instead. */
82
+ export const outboundSchema =
83
+ CreateTransferOptionsForAccountGlobals$outboundSchema;
84
+ /** @deprecated use `CreateTransferOptionsForAccountGlobals$Outbound` instead. */
85
+ export type Outbound = CreateTransferOptionsForAccountGlobals$Outbound;
86
+ }
87
+
88
+ export function createTransferOptionsForAccountGlobalsToJSON(
89
+ createTransferOptionsForAccountGlobals:
90
+ CreateTransferOptionsForAccountGlobals,
91
+ ): string {
92
+ return JSON.stringify(
93
+ CreateTransferOptionsForAccountGlobals$outboundSchema.parse(
94
+ createTransferOptionsForAccountGlobals,
95
+ ),
96
+ );
97
+ }
98
+
99
+ export function createTransferOptionsForAccountGlobalsFromJSON(
100
+ jsonString: string,
101
+ ): SafeParseResult<CreateTransferOptionsForAccountGlobals, SDKValidationError> {
102
+ return safeParse(
103
+ jsonString,
104
+ (x) =>
105
+ CreateTransferOptionsForAccountGlobals$inboundSchema.parse(JSON.parse(x)),
106
+ `Failed to parse 'CreateTransferOptionsForAccountGlobals' from JSON`,
107
+ );
108
+ }
109
+
110
+ /** @internal */
111
+ export const CreateTransferOptionsForAccountRequest$inboundSchema: z.ZodType<
112
+ CreateTransferOptionsForAccountRequest,
113
+ z.ZodTypeDef,
114
+ unknown
115
+ > = z.object({
116
+ accountID: z.string(),
117
+ CreateTransferOptions: components.CreateTransferOptions$inboundSchema,
118
+ }).transform((v) => {
119
+ return remap$(v, {
120
+ "CreateTransferOptions": "createTransferOptions",
121
+ });
122
+ });
123
+
124
+ /** @internal */
125
+ export type CreateTransferOptionsForAccountRequest$Outbound = {
126
+ accountID: string;
127
+ CreateTransferOptions: components.CreateTransferOptions$Outbound;
128
+ };
129
+
130
+ /** @internal */
131
+ export const CreateTransferOptionsForAccountRequest$outboundSchema: z.ZodType<
132
+ CreateTransferOptionsForAccountRequest$Outbound,
133
+ z.ZodTypeDef,
134
+ CreateTransferOptionsForAccountRequest
135
+ > = z.object({
136
+ accountID: z.string(),
137
+ createTransferOptions: components.CreateTransferOptions$outboundSchema,
138
+ }).transform((v) => {
139
+ return remap$(v, {
140
+ createTransferOptions: "CreateTransferOptions",
141
+ });
142
+ });
143
+
144
+ /**
145
+ * @internal
146
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
147
+ */
148
+ export namespace CreateTransferOptionsForAccountRequest$ {
149
+ /** @deprecated use `CreateTransferOptionsForAccountRequest$inboundSchema` instead. */
150
+ export const inboundSchema =
151
+ CreateTransferOptionsForAccountRequest$inboundSchema;
152
+ /** @deprecated use `CreateTransferOptionsForAccountRequest$outboundSchema` instead. */
153
+ export const outboundSchema =
154
+ CreateTransferOptionsForAccountRequest$outboundSchema;
155
+ /** @deprecated use `CreateTransferOptionsForAccountRequest$Outbound` instead. */
156
+ export type Outbound = CreateTransferOptionsForAccountRequest$Outbound;
157
+ }
158
+
159
+ export function createTransferOptionsForAccountRequestToJSON(
160
+ createTransferOptionsForAccountRequest:
161
+ CreateTransferOptionsForAccountRequest,
162
+ ): string {
163
+ return JSON.stringify(
164
+ CreateTransferOptionsForAccountRequest$outboundSchema.parse(
165
+ createTransferOptionsForAccountRequest,
166
+ ),
167
+ );
168
+ }
169
+
170
+ export function createTransferOptionsForAccountRequestFromJSON(
171
+ jsonString: string,
172
+ ): SafeParseResult<CreateTransferOptionsForAccountRequest, SDKValidationError> {
173
+ return safeParse(
174
+ jsonString,
175
+ (x) =>
176
+ CreateTransferOptionsForAccountRequest$inboundSchema.parse(JSON.parse(x)),
177
+ `Failed to parse 'CreateTransferOptionsForAccountRequest' from JSON`,
178
+ );
179
+ }
180
+
181
+ /** @internal */
182
+ export const CreateTransferOptionsForAccountResponse$inboundSchema: z.ZodType<
183
+ CreateTransferOptionsForAccountResponse,
184
+ z.ZodTypeDef,
185
+ unknown
186
+ > = z.object({
187
+ Headers: z.record(z.array(z.string())),
188
+ Result: components.TransferOptions$inboundSchema,
189
+ }).transform((v) => {
190
+ return remap$(v, {
191
+ "Headers": "headers",
192
+ "Result": "result",
193
+ });
194
+ });
195
+
196
+ /** @internal */
197
+ export type CreateTransferOptionsForAccountResponse$Outbound = {
198
+ Headers: { [k: string]: Array<string> };
199
+ Result: components.TransferOptions$Outbound;
200
+ };
201
+
202
+ /** @internal */
203
+ export const CreateTransferOptionsForAccountResponse$outboundSchema: z.ZodType<
204
+ CreateTransferOptionsForAccountResponse$Outbound,
205
+ z.ZodTypeDef,
206
+ CreateTransferOptionsForAccountResponse
207
+ > = z.object({
208
+ headers: z.record(z.array(z.string())),
209
+ result: components.TransferOptions$outboundSchema,
210
+ }).transform((v) => {
211
+ return remap$(v, {
212
+ headers: "Headers",
213
+ result: "Result",
214
+ });
215
+ });
216
+
217
+ /**
218
+ * @internal
219
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
220
+ */
221
+ export namespace CreateTransferOptionsForAccountResponse$ {
222
+ /** @deprecated use `CreateTransferOptionsForAccountResponse$inboundSchema` instead. */
223
+ export const inboundSchema =
224
+ CreateTransferOptionsForAccountResponse$inboundSchema;
225
+ /** @deprecated use `CreateTransferOptionsForAccountResponse$outboundSchema` instead. */
226
+ export const outboundSchema =
227
+ CreateTransferOptionsForAccountResponse$outboundSchema;
228
+ /** @deprecated use `CreateTransferOptionsForAccountResponse$Outbound` instead. */
229
+ export type Outbound = CreateTransferOptionsForAccountResponse$Outbound;
230
+ }
231
+
232
+ export function createTransferOptionsForAccountResponseToJSON(
233
+ createTransferOptionsForAccountResponse:
234
+ CreateTransferOptionsForAccountResponse,
235
+ ): string {
236
+ return JSON.stringify(
237
+ CreateTransferOptionsForAccountResponse$outboundSchema.parse(
238
+ createTransferOptionsForAccountResponse,
239
+ ),
240
+ );
241
+ }
242
+
243
+ export function createTransferOptionsForAccountResponseFromJSON(
244
+ jsonString: string,
245
+ ): SafeParseResult<
246
+ CreateTransferOptionsForAccountResponse,
247
+ SDKValidationError
248
+ > {
249
+ return safeParse(
250
+ jsonString,
251
+ (x) =>
252
+ CreateTransferOptionsForAccountResponse$inboundSchema.parse(
253
+ JSON.parse(x),
254
+ ),
255
+ `Failed to parse 'CreateTransferOptionsForAccountResponse' from JSON`,
256
+ );
257
+ }
@@ -33,7 +33,7 @@ export type DisableCapabilityRequest = {
33
33
  *
34
34
  * @remarks
35
35
  *
36
- * The `production-app` capability might appear in your list. This is a read-only capability that Moov requests and uses for account verification purposes. The capability remains active with your account and requires no additional action.
36
+ * The `production-app`, `platform.production-app`, and / or `platform.wallet-transfers` capabilities might appear in your list. These are read-only capabilities that Moov requests and uses for account verification purposes. These capabilities remains active with your account and require no additional action.
37
37
  */
38
38
  capabilityID: components.CapabilityID;
39
39
  };
@@ -33,7 +33,7 @@ export type GetCapabilityRequest = {
33
33
  *
34
34
  * @remarks
35
35
  *
36
- * The `production-app` capability might appear in your list. This is a read-only capability that Moov requests and uses for account verification purposes. The capability remains active with your account and requires no additional action.
36
+ * The `production-app`, `platform.production-app`, and / or `platform.wallet-transfers` capabilities might appear in your list. These are read-only capabilities that Moov requests and uses for account verification purposes. These capabilities remains active with your account and require no additional action.
37
37
  */
38
38
  capabilityID: components.CapabilityID;
39
39
  };
@@ -23,6 +23,7 @@ export * from "./createsweepconfig.js";
23
23
  export * from "./createterminalapplication.js";
24
24
  export * from "./createtransfer.js";
25
25
  export * from "./createtransferoptions.js";
26
+ export * from "./createtransferoptionsforaccount.js";
26
27
  export * from "./deletedisputeevidencefile.js";
27
28
  export * from "./deleterepresentative.js";
28
29
  export * from "./deleteterminalapplication.js";
@@ -6,6 +6,7 @@ import { transfersCreate } from "../funcs/transfersCreate.js";
6
6
  import { transfersCreateCancellation } from "../funcs/transfersCreateCancellation.js";
7
7
  import { transfersCreateReversal } from "../funcs/transfersCreateReversal.js";
8
8
  import { transfersGenerateOptions } from "../funcs/transfersGenerateOptions.js";
9
+ import { transfersGenerateOptionsForAccount } from "../funcs/transfersGenerateOptionsForAccount.js";
9
10
  import { transfersGet } from "../funcs/transfersGet.js";
10
11
  import { transfersGetCancellation } from "../funcs/transfersGetCancellation.js";
11
12
  import { transfersGetRefund } from "../funcs/transfersGetRefund.js";
@@ -19,6 +20,28 @@ import * as operations from "../models/operations/index.js";
19
20
  import { unwrapAsync } from "../types/fp.js";
20
21
 
21
22
  export class Transfers extends ClientSDK {
23
+ /**
24
+ * Generate available payment method options for one or multiple transfer participants depending on the accountID or paymentMethodID you
25
+ * supply in the request body.
26
+ *
27
+ * The accountID in the route should the partner's accountID.
28
+ *
29
+ * Read our [transfers overview guide](https://docs.moov.io/guides/money-movement/overview/) to learn more.
30
+ *
31
+ * To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
32
+ * you'll need to specify the `/accounts/{accountID}/transfers.write` scope.
33
+ */
34
+ async generateOptionsForAccount(
35
+ request: operations.CreateTransferOptionsForAccountRequest,
36
+ options?: RequestOptions,
37
+ ): Promise<operations.CreateTransferOptionsForAccountResponse> {
38
+ return unwrapAsync(transfersGenerateOptionsForAccount(
39
+ this,
40
+ request,
41
+ options,
42
+ ));
43
+ }
44
+
22
45
  /**
23
46
  * Move money by providing the source, destination, and amount in the request body.
24
47
  *
@@ -215,7 +238,7 @@ export class Transfers extends ClientSDK {
215
238
  * Read our [transfers overview guide](https://docs.moov.io/guides/money-movement/overview/) to learn more.
216
239
  *
217
240
  * To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
218
- * you'll need to specify the `/accounts/{accountID}/transfers.read` scope.
241
+ * you'll need to specify the `/accounts/{accountID}/transfers.write` scope.
219
242
  */
220
243
  async generateOptions(
221
244
  request: components.CreateTransferOptions,
@@ -11,5 +11,5 @@ export function constDateTime(
11
11
  return (
12
12
  typeof v === "string" && new Date(v).getTime() === new Date(val).getTime()
13
13
  );
14
- }, `Value must be equivelant to ${val}`);
14
+ }, `Value must be equivalent to ${val}`);
15
15
  }
@@ -41,6 +41,6 @@ const z = __importStar(require("zod"));
41
41
  function constDateTime(val) {
42
42
  return z.custom((v) => {
43
43
  return (typeof v === "string" && new Date(v).getTime() === new Date(val).getTime());
44
- }, `Value must be equivelant to ${val}`);
44
+ }, `Value must be equivalent to ${val}`);
45
45
  }
46
46
  //# sourceMappingURL=constdatetime.js.map