@moovio/sdk 0.2.0 → 0.3.0

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 (135) hide show
  1. package/README.md +8 -0
  2. package/docs/sdks/branding/README.md +113 -2
  3. package/funcs/brandingCreate.js +1 -1
  4. package/funcs/brandingCreate.js.map +1 -1
  5. package/funcs/brandingUpsert.d.ts +16 -0
  6. package/funcs/brandingUpsert.d.ts.map +1 -0
  7. package/funcs/brandingUpsert.js +132 -0
  8. package/funcs/brandingUpsert.js.map +1 -0
  9. package/jsr.json +1 -1
  10. package/lib/config.d.ts +3 -3
  11. package/lib/config.js +3 -3
  12. package/models/components/achcreditsamedaypaymentmethod.d.ts +5 -5
  13. package/models/components/achcreditsamedaypaymentmethod.d.ts.map +1 -1
  14. package/models/components/achcreditsamedaypaymentmethod.js +3 -3
  15. package/models/components/achcreditsamedaypaymentmethod.js.map +1 -1
  16. package/models/components/achcreditstandardpaymentmethod.d.ts +5 -5
  17. package/models/components/achcreditstandardpaymentmethod.d.ts.map +1 -1
  18. package/models/components/achcreditstandardpaymentmethod.js +3 -3
  19. package/models/components/achcreditstandardpaymentmethod.js.map +1 -1
  20. package/models/components/achdebitcollectpaymentmethod.d.ts +5 -5
  21. package/models/components/achdebitcollectpaymentmethod.d.ts.map +1 -1
  22. package/models/components/achdebitcollectpaymentmethod.js +3 -3
  23. package/models/components/achdebitcollectpaymentmethod.js.map +1 -1
  24. package/models/components/achdebitfundpaymentmethod.d.ts +5 -5
  25. package/models/components/achdebitfundpaymentmethod.d.ts.map +1 -1
  26. package/models/components/achdebitfundpaymentmethod.js +3 -3
  27. package/models/components/achdebitfundpaymentmethod.js.map +1 -1
  28. package/models/components/applepaypaymentmethod.d.ts +6 -2
  29. package/models/components/applepaypaymentmethod.d.ts.map +1 -1
  30. package/models/components/applepaypaymentmethod.js +3 -2
  31. package/models/components/applepaypaymentmethod.js.map +1 -1
  32. package/models/components/brandcolors.d.ts +35 -0
  33. package/models/components/brandcolors.d.ts.map +1 -0
  34. package/models/components/{colors.js → brandcolors.js} +17 -18
  35. package/models/components/brandcolors.js.map +1 -0
  36. package/models/components/brandproperties.d.ts +33 -0
  37. package/models/components/brandproperties.d.ts.map +1 -0
  38. package/models/components/{brand.js → brandproperties.js} +20 -21
  39. package/models/components/brandproperties.js.map +1 -0
  40. package/models/components/cardpaymentpaymentmethod.d.ts +5 -5
  41. package/models/components/cardpaymentpaymentmethod.d.ts.map +1 -1
  42. package/models/components/cardpaymentpaymentmethod.js +3 -3
  43. package/models/components/cardpaymentpaymentmethod.js.map +1 -1
  44. package/models/components/createrepresentative.d.ts +1 -1
  45. package/models/components/index.d.ts +5 -2
  46. package/models/components/index.d.ts.map +1 -1
  47. package/models/components/index.js +5 -2
  48. package/models/components/index.js.map +1 -1
  49. package/models/components/moovwalletpaymentmethod.d.ts +3 -2
  50. package/models/components/moovwalletpaymentmethod.d.ts.map +1 -1
  51. package/models/components/moovwalletpaymentmethod.js +3 -2
  52. package/models/components/moovwalletpaymentmethod.js.map +1 -1
  53. package/models/components/paymentmethodsbankaccount.d.ts +66 -0
  54. package/models/components/paymentmethodsbankaccount.d.ts.map +1 -0
  55. package/models/components/paymentmethodsbankaccount.js +90 -0
  56. package/models/components/paymentmethodsbankaccount.js.map +1 -0
  57. package/models/components/paymentmethodscard.d.ts +121 -0
  58. package/models/components/paymentmethodscard.d.ts.map +1 -0
  59. package/models/components/paymentmethodscard.js +109 -0
  60. package/models/components/paymentmethodscard.js.map +1 -0
  61. package/models/components/paymentmethodswallet.d.ts +29 -0
  62. package/models/components/paymentmethodswallet.d.ts.map +1 -0
  63. package/models/components/paymentmethodswallet.js +69 -0
  64. package/models/components/paymentmethodswallet.js.map +1 -0
  65. package/models/components/pullfromcardpaymentmethod.d.ts +5 -5
  66. package/models/components/pullfromcardpaymentmethod.d.ts.map +1 -1
  67. package/models/components/pullfromcardpaymentmethod.js +3 -3
  68. package/models/components/pullfromcardpaymentmethod.js.map +1 -1
  69. package/models/components/pushtocardpaymentmethod.d.ts +5 -5
  70. package/models/components/pushtocardpaymentmethod.d.ts.map +1 -1
  71. package/models/components/pushtocardpaymentmethod.js +3 -3
  72. package/models/components/pushtocardpaymentmethod.js.map +1 -1
  73. package/models/components/rtpcreditpaymentmethod.d.ts +5 -5
  74. package/models/components/rtpcreditpaymentmethod.d.ts.map +1 -1
  75. package/models/components/rtpcreditpaymentmethod.js +3 -3
  76. package/models/components/rtpcreditpaymentmethod.js.map +1 -1
  77. package/models/operations/createbrand.d.ts +4 -4
  78. package/models/operations/createbrand.d.ts.map +1 -1
  79. package/models/operations/createbrand.js +6 -6
  80. package/models/operations/createbrand.js.map +1 -1
  81. package/models/operations/getbrand.d.ts +2 -2
  82. package/models/operations/getbrand.d.ts.map +1 -1
  83. package/models/operations/getbrand.js +2 -2
  84. package/models/operations/getbrand.js.map +1 -1
  85. package/models/operations/index.d.ts +1 -0
  86. package/models/operations/index.d.ts.map +1 -1
  87. package/models/operations/index.js +1 -0
  88. package/models/operations/index.js.map +1 -1
  89. package/models/operations/updatebrand.d.ts +2 -2
  90. package/models/operations/updatebrand.d.ts.map +1 -1
  91. package/models/operations/updatebrand.js +2 -2
  92. package/models/operations/updatebrand.js.map +1 -1
  93. package/models/operations/upsertbrand.d.ts +101 -0
  94. package/models/operations/upsertbrand.d.ts.map +1 -0
  95. package/models/operations/upsertbrand.js +155 -0
  96. package/models/operations/upsertbrand.js.map +1 -0
  97. package/package.json +1 -1
  98. package/sdk/branding.d.ts +7 -0
  99. package/sdk/branding.d.ts.map +1 -1
  100. package/sdk/branding.js +10 -0
  101. package/sdk/branding.js.map +1 -1
  102. package/src/funcs/brandingCreate.ts +1 -1
  103. package/src/funcs/brandingUpsert.ts +165 -0
  104. package/src/lib/config.ts +3 -3
  105. package/src/models/components/achcreditsamedaypaymentmethod.ts +11 -11
  106. package/src/models/components/achcreditstandardpaymentmethod.ts +11 -11
  107. package/src/models/components/achdebitcollectpaymentmethod.ts +11 -11
  108. package/src/models/components/achdebitfundpaymentmethod.ts +11 -11
  109. package/src/models/components/applepaypaymentmethod.ts +13 -4
  110. package/src/models/components/brandcolors.ts +75 -0
  111. package/src/models/components/brandproperties.ts +73 -0
  112. package/src/models/components/cardpaymentpaymentmethod.ts +11 -11
  113. package/src/models/components/createrepresentative.ts +1 -1
  114. package/src/models/components/index.ts +5 -2
  115. package/src/models/components/moovwalletpaymentmethod.ts +10 -4
  116. package/src/models/components/paymentmethodsbankaccount.ts +133 -0
  117. package/src/models/components/paymentmethodscard.ts +226 -0
  118. package/src/models/components/paymentmethodswallet.ts +66 -0
  119. package/src/models/components/pullfromcardpaymentmethod.ts +11 -11
  120. package/src/models/components/pushtocardpaymentmethod.ts +11 -11
  121. package/src/models/components/rtpcreditpaymentmethod.ts +11 -11
  122. package/src/models/operations/createbrand.ts +10 -10
  123. package/src/models/operations/getbrand.ts +4 -4
  124. package/src/models/operations/index.ts +1 -0
  125. package/src/models/operations/updatebrand.ts +4 -4
  126. package/src/models/operations/upsertbrand.ts +231 -0
  127. package/src/sdk/branding.ts +18 -0
  128. package/models/components/brand.d.ts +0 -33
  129. package/models/components/brand.d.ts.map +0 -1
  130. package/models/components/brand.js.map +0 -1
  131. package/models/components/colors.d.ts +0 -32
  132. package/models/components/colors.d.ts.map +0 -1
  133. package/models/components/colors.js.map +0 -1
  134. package/src/models/components/brand.ts +0 -68
  135. package/src/models/components/colors.ts +0 -69
@@ -8,11 +8,11 @@ import { ClosedEnum } from "../../types/enums.js";
8
8
  import { Result as SafeParseResult } from "../../types/fp.js";
9
9
  import { SDKValidationError } from "../errors/sdkvalidationerror.js";
10
10
  import {
11
- BankAccount,
12
- BankAccount$inboundSchema,
13
- BankAccount$Outbound,
14
- BankAccount$outboundSchema,
15
- } from "./bankaccount.js";
11
+ PaymentMethodsBankAccount,
12
+ PaymentMethodsBankAccount$inboundSchema,
13
+ PaymentMethodsBankAccount$Outbound,
14
+ PaymentMethodsBankAccount$outboundSchema,
15
+ } from "./paymentmethodsbankaccount.js";
16
16
 
17
17
  export const AchDebitCollectPaymentMethodPaymentMethodType = {
18
18
  AchDebitCollect: "ach-debit-collect",
@@ -26,11 +26,11 @@ export type AchDebitCollectPaymentMethod = {
26
26
  * ID of the payment method.
27
27
  */
28
28
  paymentMethodID: string;
29
+ paymentMethodType: AchDebitCollectPaymentMethodPaymentMethodType;
29
30
  /**
30
- * Describes a bank account linked to a Moov account.
31
+ * A bank account as contained within a payment method.
31
32
  */
32
- bankAccount: BankAccount;
33
- paymentMethodType: AchDebitCollectPaymentMethodPaymentMethodType;
33
+ bankAccount: PaymentMethodsBankAccount;
34
34
  };
35
35
 
36
36
  /** @internal */
@@ -63,16 +63,16 @@ export const AchDebitCollectPaymentMethod$inboundSchema: z.ZodType<
63
63
  unknown
64
64
  > = z.object({
65
65
  paymentMethodID: z.string(),
66
- bankAccount: BankAccount$inboundSchema,
67
66
  paymentMethodType:
68
67
  AchDebitCollectPaymentMethodPaymentMethodType$inboundSchema,
68
+ bankAccount: PaymentMethodsBankAccount$inboundSchema,
69
69
  });
70
70
 
71
71
  /** @internal */
72
72
  export type AchDebitCollectPaymentMethod$Outbound = {
73
73
  paymentMethodID: string;
74
- bankAccount: BankAccount$Outbound;
75
74
  paymentMethodType: string;
75
+ bankAccount: PaymentMethodsBankAccount$Outbound;
76
76
  };
77
77
 
78
78
  /** @internal */
@@ -82,9 +82,9 @@ export const AchDebitCollectPaymentMethod$outboundSchema: z.ZodType<
82
82
  AchDebitCollectPaymentMethod
83
83
  > = z.object({
84
84
  paymentMethodID: z.string(),
85
- bankAccount: BankAccount$outboundSchema,
86
85
  paymentMethodType:
87
86
  AchDebitCollectPaymentMethodPaymentMethodType$outboundSchema,
87
+ bankAccount: PaymentMethodsBankAccount$outboundSchema,
88
88
  });
89
89
 
90
90
  /**
@@ -8,11 +8,11 @@ import { ClosedEnum } from "../../types/enums.js";
8
8
  import { Result as SafeParseResult } from "../../types/fp.js";
9
9
  import { SDKValidationError } from "../errors/sdkvalidationerror.js";
10
10
  import {
11
- BankAccount,
12
- BankAccount$inboundSchema,
13
- BankAccount$Outbound,
14
- BankAccount$outboundSchema,
15
- } from "./bankaccount.js";
11
+ PaymentMethodsBankAccount,
12
+ PaymentMethodsBankAccount$inboundSchema,
13
+ PaymentMethodsBankAccount$Outbound,
14
+ PaymentMethodsBankAccount$outboundSchema,
15
+ } from "./paymentmethodsbankaccount.js";
16
16
 
17
17
  export const AchDebitFundPaymentMethodPaymentMethodType = {
18
18
  AchDebitFund: "ach-debit-fund",
@@ -26,11 +26,11 @@ export type AchDebitFundPaymentMethod = {
26
26
  * ID of the payment method.
27
27
  */
28
28
  paymentMethodID: string;
29
+ paymentMethodType: AchDebitFundPaymentMethodPaymentMethodType;
29
30
  /**
30
- * Describes a bank account linked to a Moov account.
31
+ * A bank account as contained within a payment method.
31
32
  */
32
- bankAccount: BankAccount;
33
- paymentMethodType: AchDebitFundPaymentMethodPaymentMethodType;
33
+ bankAccount: PaymentMethodsBankAccount;
34
34
  };
35
35
 
36
36
  /** @internal */
@@ -63,15 +63,15 @@ export const AchDebitFundPaymentMethod$inboundSchema: z.ZodType<
63
63
  unknown
64
64
  > = z.object({
65
65
  paymentMethodID: z.string(),
66
- bankAccount: BankAccount$inboundSchema,
67
66
  paymentMethodType: AchDebitFundPaymentMethodPaymentMethodType$inboundSchema,
67
+ bankAccount: PaymentMethodsBankAccount$inboundSchema,
68
68
  });
69
69
 
70
70
  /** @internal */
71
71
  export type AchDebitFundPaymentMethod$Outbound = {
72
72
  paymentMethodID: string;
73
- bankAccount: BankAccount$Outbound;
74
73
  paymentMethodType: string;
74
+ bankAccount: PaymentMethodsBankAccount$Outbound;
75
75
  };
76
76
 
77
77
  /** @internal */
@@ -81,8 +81,8 @@ export const AchDebitFundPaymentMethod$outboundSchema: z.ZodType<
81
81
  AchDebitFundPaymentMethod
82
82
  > = z.object({
83
83
  paymentMethodID: z.string(),
84
- bankAccount: BankAccount$outboundSchema,
85
84
  paymentMethodType: AchDebitFundPaymentMethodPaymentMethodType$outboundSchema,
85
+ bankAccount: PaymentMethodsBankAccount$outboundSchema,
86
86
  });
87
87
 
88
88
  /**
@@ -7,6 +7,12 @@ import { safeParse } from "../../lib/schemas.js";
7
7
  import { ClosedEnum } from "../../types/enums.js";
8
8
  import { Result as SafeParseResult } from "../../types/fp.js";
9
9
  import { SDKValidationError } from "../errors/sdkvalidationerror.js";
10
+ import {
11
+ ApplePayResponse,
12
+ ApplePayResponse$inboundSchema,
13
+ ApplePayResponse$Outbound,
14
+ ApplePayResponse$outboundSchema,
15
+ } from "./applepayresponse.js";
10
16
 
11
17
  export const ApplePayPaymentMethodPaymentMethodType = {
12
18
  ApplePay: "apple-pay",
@@ -21,7 +27,10 @@ export type ApplePayPaymentMethod = {
21
27
  */
22
28
  paymentMethodID: string;
23
29
  paymentMethodType: ApplePayPaymentMethodPaymentMethodType;
24
- applePay?: any | undefined;
30
+ /**
31
+ * Describes an Apple Pay token on a Moov account.
32
+ */
33
+ applePay: ApplePayResponse;
25
34
  };
26
35
 
27
36
  /** @internal */
@@ -56,14 +65,14 @@ export const ApplePayPaymentMethod$inboundSchema: z.ZodType<
56
65
  > = z.object({
57
66
  paymentMethodID: z.string(),
58
67
  paymentMethodType: ApplePayPaymentMethodPaymentMethodType$inboundSchema,
59
- applePay: z.any().optional(),
68
+ applePay: ApplePayResponse$inboundSchema,
60
69
  });
61
70
 
62
71
  /** @internal */
63
72
  export type ApplePayPaymentMethod$Outbound = {
64
73
  paymentMethodID: string;
65
74
  paymentMethodType: string;
66
- applePay?: any | undefined;
75
+ applePay: ApplePayResponse$Outbound;
67
76
  };
68
77
 
69
78
  /** @internal */
@@ -74,7 +83,7 @@ export const ApplePayPaymentMethod$outboundSchema: z.ZodType<
74
83
  > = z.object({
75
84
  paymentMethodID: z.string(),
76
85
  paymentMethodType: ApplePayPaymentMethodPaymentMethodType$outboundSchema,
77
- applePay: z.any().optional(),
86
+ applePay: ApplePayResponse$outboundSchema,
78
87
  });
79
88
 
80
89
  /**
@@ -0,0 +1,75 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod";
6
+ import { safeParse } from "../../lib/schemas.js";
7
+ import { Result as SafeParseResult } from "../../types/fp.js";
8
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
9
+ import {
10
+ BrandColor,
11
+ BrandColor$inboundSchema,
12
+ BrandColor$Outbound,
13
+ BrandColor$outboundSchema,
14
+ } from "./brandcolor.js";
15
+
16
+ /**
17
+ * Brand colors for light and dark modes.
18
+ */
19
+ export type BrandColors = {
20
+ dark: BrandColor;
21
+ light: BrandColor;
22
+ };
23
+
24
+ /** @internal */
25
+ export const BrandColors$inboundSchema: z.ZodType<
26
+ BrandColors,
27
+ z.ZodTypeDef,
28
+ unknown
29
+ > = z.object({
30
+ dark: BrandColor$inboundSchema,
31
+ light: BrandColor$inboundSchema,
32
+ });
33
+
34
+ /** @internal */
35
+ export type BrandColors$Outbound = {
36
+ dark: BrandColor$Outbound;
37
+ light: BrandColor$Outbound;
38
+ };
39
+
40
+ /** @internal */
41
+ export const BrandColors$outboundSchema: z.ZodType<
42
+ BrandColors$Outbound,
43
+ z.ZodTypeDef,
44
+ BrandColors
45
+ > = z.object({
46
+ dark: BrandColor$outboundSchema,
47
+ light: BrandColor$outboundSchema,
48
+ });
49
+
50
+ /**
51
+ * @internal
52
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
53
+ */
54
+ export namespace BrandColors$ {
55
+ /** @deprecated use `BrandColors$inboundSchema` instead. */
56
+ export const inboundSchema = BrandColors$inboundSchema;
57
+ /** @deprecated use `BrandColors$outboundSchema` instead. */
58
+ export const outboundSchema = BrandColors$outboundSchema;
59
+ /** @deprecated use `BrandColors$Outbound` instead. */
60
+ export type Outbound = BrandColors$Outbound;
61
+ }
62
+
63
+ export function brandColorsToJSON(brandColors: BrandColors): string {
64
+ return JSON.stringify(BrandColors$outboundSchema.parse(brandColors));
65
+ }
66
+
67
+ export function brandColorsFromJSON(
68
+ jsonString: string,
69
+ ): SafeParseResult<BrandColors, SDKValidationError> {
70
+ return safeParse(
71
+ jsonString,
72
+ (x) => BrandColors$inboundSchema.parse(JSON.parse(x)),
73
+ `Failed to parse 'BrandColors' from JSON`,
74
+ );
75
+ }
@@ -0,0 +1,73 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod";
6
+ import { safeParse } from "../../lib/schemas.js";
7
+ import { Result as SafeParseResult } from "../../types/fp.js";
8
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
9
+ import {
10
+ BrandColors,
11
+ BrandColors$inboundSchema,
12
+ BrandColors$Outbound,
13
+ BrandColors$outboundSchema,
14
+ } from "./brandcolors.js";
15
+
16
+ export type BrandProperties = {
17
+ /**
18
+ * Brand colors for light and dark modes.
19
+ */
20
+ colors: BrandColors;
21
+ };
22
+
23
+ /** @internal */
24
+ export const BrandProperties$inboundSchema: z.ZodType<
25
+ BrandProperties,
26
+ z.ZodTypeDef,
27
+ unknown
28
+ > = z.object({
29
+ colors: BrandColors$inboundSchema,
30
+ });
31
+
32
+ /** @internal */
33
+ export type BrandProperties$Outbound = {
34
+ colors: BrandColors$Outbound;
35
+ };
36
+
37
+ /** @internal */
38
+ export const BrandProperties$outboundSchema: z.ZodType<
39
+ BrandProperties$Outbound,
40
+ z.ZodTypeDef,
41
+ BrandProperties
42
+ > = z.object({
43
+ colors: BrandColors$outboundSchema,
44
+ });
45
+
46
+ /**
47
+ * @internal
48
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
49
+ */
50
+ export namespace BrandProperties$ {
51
+ /** @deprecated use `BrandProperties$inboundSchema` instead. */
52
+ export const inboundSchema = BrandProperties$inboundSchema;
53
+ /** @deprecated use `BrandProperties$outboundSchema` instead. */
54
+ export const outboundSchema = BrandProperties$outboundSchema;
55
+ /** @deprecated use `BrandProperties$Outbound` instead. */
56
+ export type Outbound = BrandProperties$Outbound;
57
+ }
58
+
59
+ export function brandPropertiesToJSON(
60
+ brandProperties: BrandProperties,
61
+ ): string {
62
+ return JSON.stringify(BrandProperties$outboundSchema.parse(brandProperties));
63
+ }
64
+
65
+ export function brandPropertiesFromJSON(
66
+ jsonString: string,
67
+ ): SafeParseResult<BrandProperties, SDKValidationError> {
68
+ return safeParse(
69
+ jsonString,
70
+ (x) => BrandProperties$inboundSchema.parse(JSON.parse(x)),
71
+ `Failed to parse 'BrandProperties' from JSON`,
72
+ );
73
+ }
@@ -8,11 +8,11 @@ import { ClosedEnum } from "../../types/enums.js";
8
8
  import { Result as SafeParseResult } from "../../types/fp.js";
9
9
  import { SDKValidationError } from "../errors/sdkvalidationerror.js";
10
10
  import {
11
- Card,
12
- Card$inboundSchema,
13
- Card$Outbound,
14
- Card$outboundSchema,
15
- } from "./card.js";
11
+ PaymentMethodsCard,
12
+ PaymentMethodsCard$inboundSchema,
13
+ PaymentMethodsCard$Outbound,
14
+ PaymentMethodsCard$outboundSchema,
15
+ } from "./paymentmethodscard.js";
16
16
 
17
17
  export const CardPaymentPaymentMethodPaymentMethodType = {
18
18
  CardPayment: "card-payment",
@@ -26,11 +26,11 @@ export type CardPaymentPaymentMethod = {
26
26
  * ID of the payment method.
27
27
  */
28
28
  paymentMethodID: string;
29
+ paymentMethodType: CardPaymentPaymentMethodPaymentMethodType;
29
30
  /**
30
- * Describes a card on a Moov account.
31
+ * A card as contained within a payment method.
31
32
  */
32
- card: Card;
33
- paymentMethodType: CardPaymentPaymentMethodPaymentMethodType;
33
+ card: PaymentMethodsCard;
34
34
  };
35
35
 
36
36
  /** @internal */
@@ -63,15 +63,15 @@ export const CardPaymentPaymentMethod$inboundSchema: z.ZodType<
63
63
  unknown
64
64
  > = z.object({
65
65
  paymentMethodID: z.string(),
66
- card: Card$inboundSchema,
67
66
  paymentMethodType: CardPaymentPaymentMethodPaymentMethodType$inboundSchema,
67
+ card: PaymentMethodsCard$inboundSchema,
68
68
  });
69
69
 
70
70
  /** @internal */
71
71
  export type CardPaymentPaymentMethod$Outbound = {
72
72
  paymentMethodID: string;
73
- card: Card$Outbound;
74
73
  paymentMethodType: string;
74
+ card: PaymentMethodsCard$Outbound;
75
75
  };
76
76
 
77
77
  /** @internal */
@@ -81,8 +81,8 @@ export const CardPaymentPaymentMethod$outboundSchema: z.ZodType<
81
81
  CardPaymentPaymentMethod
82
82
  > = z.object({
83
83
  paymentMethodID: z.string(),
84
- card: Card$outboundSchema,
85
84
  paymentMethodType: CardPaymentPaymentMethodPaymentMethodType$outboundSchema,
85
+ card: PaymentMethodsCard$outboundSchema,
86
86
  });
87
87
 
88
88
  /**
@@ -44,7 +44,7 @@ import {
44
44
  } from "./representativeresponsibilities.js";
45
45
 
46
46
  /**
47
- * The template for omitting properties.
47
+ * Describes a business representative to create.
48
48
  */
49
49
  export type CreateRepresentative = {
50
50
  name: IndividualName;
@@ -61,9 +61,10 @@ export * from "./birthdate.js";
61
61
  export * from "./birthdateerror.js";
62
62
  export * from "./birthdateupdate.js";
63
63
  export * from "./birthdatevalidationerror.js";
64
- export * from "./brand.js";
65
64
  export * from "./brandcolor.js";
65
+ export * from "./brandcolors.js";
66
66
  export * from "./brandcolorvalidationerror.js";
67
+ export * from "./brandproperties.js";
67
68
  export * from "./businessprofile.js";
68
69
  export * from "./businesstype.js";
69
70
  export * from "./calltoaction.js";
@@ -99,7 +100,6 @@ export * from "./cardverificationresult.js";
99
100
  export * from "./cardvolumedistribution.js";
100
101
  export * from "./cardvolumedistributionerror.js";
101
102
  export * from "./collectionpaymentmethodtype.js";
102
- export * from "./colors.js";
103
103
  export * from "./colorsvalidationerror.js";
104
104
  export * from "./completebankaccountverification.js";
105
105
  export * from "./completedmicrodeposits.js";
@@ -239,6 +239,9 @@ export * from "./paymentlinkpayoutdetails.js";
239
239
  export * from "./paymentlinkpayoutdetailsupdate.js";
240
240
  export * from "./paymentlinkstatus.js";
241
241
  export * from "./paymentmethod.js";
242
+ export * from "./paymentmethodsbankaccount.js";
243
+ export * from "./paymentmethodscard.js";
244
+ export * from "./paymentmethodswallet.js";
242
245
  export * from "./paymentmethodtype.js";
243
246
  export * from "./payoutdetailserror.js";
244
247
  export * from "./payoutrecipient.js";
@@ -7,6 +7,12 @@ import { safeParse } from "../../lib/schemas.js";
7
7
  import { ClosedEnum } from "../../types/enums.js";
8
8
  import { Result as SafeParseResult } from "../../types/fp.js";
9
9
  import { SDKValidationError } from "../errors/sdkvalidationerror.js";
10
+ import {
11
+ PaymentMethodsWallet,
12
+ PaymentMethodsWallet$inboundSchema,
13
+ PaymentMethodsWallet$Outbound,
14
+ PaymentMethodsWallet$outboundSchema,
15
+ } from "./paymentmethodswallet.js";
10
16
 
11
17
  export const MoovWalletPaymentMethodPaymentMethodType = {
12
18
  MoovWallet: "moov-wallet",
@@ -21,7 +27,7 @@ export type MoovWalletPaymentMethod = {
21
27
  */
22
28
  paymentMethodID: string;
23
29
  paymentMethodType: MoovWalletPaymentMethodPaymentMethodType;
24
- wallet?: any | undefined;
30
+ wallet: PaymentMethodsWallet;
25
31
  };
26
32
 
27
33
  /** @internal */
@@ -55,14 +61,14 @@ export const MoovWalletPaymentMethod$inboundSchema: z.ZodType<
55
61
  > = z.object({
56
62
  paymentMethodID: z.string(),
57
63
  paymentMethodType: MoovWalletPaymentMethodPaymentMethodType$inboundSchema,
58
- wallet: z.any().optional(),
64
+ wallet: PaymentMethodsWallet$inboundSchema,
59
65
  });
60
66
 
61
67
  /** @internal */
62
68
  export type MoovWalletPaymentMethod$Outbound = {
63
69
  paymentMethodID: string;
64
70
  paymentMethodType: string;
65
- wallet?: any | undefined;
71
+ wallet: PaymentMethodsWallet$Outbound;
66
72
  };
67
73
 
68
74
  /** @internal */
@@ -73,7 +79,7 @@ export const MoovWalletPaymentMethod$outboundSchema: z.ZodType<
73
79
  > = z.object({
74
80
  paymentMethodID: z.string(),
75
81
  paymentMethodType: MoovWalletPaymentMethodPaymentMethodType$outboundSchema,
76
- wallet: z.any().optional(),
82
+ wallet: PaymentMethodsWallet$outboundSchema,
77
83
  });
78
84
 
79
85
  /**
@@ -0,0 +1,133 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod";
6
+ import { safeParse } from "../../lib/schemas.js";
7
+ import { Result as SafeParseResult } from "../../types/fp.js";
8
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
9
+ import {
10
+ BankAccountHolderType,
11
+ BankAccountHolderType$inboundSchema,
12
+ BankAccountHolderType$outboundSchema,
13
+ } from "./bankaccountholdertype.js";
14
+ import {
15
+ BankAccountStatus,
16
+ BankAccountStatus$inboundSchema,
17
+ BankAccountStatus$outboundSchema,
18
+ } from "./bankaccountstatus.js";
19
+ import {
20
+ BankAccountType,
21
+ BankAccountType$inboundSchema,
22
+ BankAccountType$outboundSchema,
23
+ } from "./bankaccounttype.js";
24
+
25
+ /**
26
+ * A bank account as contained within a payment method.
27
+ */
28
+ export type PaymentMethodsBankAccount = {
29
+ bankAccountID: string;
30
+ /**
31
+ * Once the bank account is linked, we don't reveal the full bank account number.
32
+ *
33
+ * @remarks
34
+ *
35
+ * The fingerprint acts as a way to identify whether two linked bank accounts are the same.
36
+ */
37
+ fingerprint: string;
38
+ status: BankAccountStatus;
39
+ holderName: string;
40
+ /**
41
+ * The type of holder on a funding source.
42
+ */
43
+ holderType: BankAccountHolderType;
44
+ bankName: string;
45
+ /**
46
+ * The bank account type.
47
+ */
48
+ bankAccountType: BankAccountType;
49
+ routingNumber: string;
50
+ lastFourAccountNumber: string;
51
+ updatedOn: Date;
52
+ };
53
+
54
+ /** @internal */
55
+ export const PaymentMethodsBankAccount$inboundSchema: z.ZodType<
56
+ PaymentMethodsBankAccount,
57
+ z.ZodTypeDef,
58
+ unknown
59
+ > = z.object({
60
+ bankAccountID: z.string(),
61
+ fingerprint: z.string(),
62
+ status: BankAccountStatus$inboundSchema,
63
+ holderName: z.string(),
64
+ holderType: BankAccountHolderType$inboundSchema,
65
+ bankName: z.string(),
66
+ bankAccountType: BankAccountType$inboundSchema,
67
+ routingNumber: z.string(),
68
+ lastFourAccountNumber: z.string(),
69
+ updatedOn: z.string().datetime({ offset: true }).transform(v => new Date(v)),
70
+ });
71
+
72
+ /** @internal */
73
+ export type PaymentMethodsBankAccount$Outbound = {
74
+ bankAccountID: string;
75
+ fingerprint: string;
76
+ status: string;
77
+ holderName: string;
78
+ holderType: string;
79
+ bankName: string;
80
+ bankAccountType: string;
81
+ routingNumber: string;
82
+ lastFourAccountNumber: string;
83
+ updatedOn: string;
84
+ };
85
+
86
+ /** @internal */
87
+ export const PaymentMethodsBankAccount$outboundSchema: z.ZodType<
88
+ PaymentMethodsBankAccount$Outbound,
89
+ z.ZodTypeDef,
90
+ PaymentMethodsBankAccount
91
+ > = z.object({
92
+ bankAccountID: z.string(),
93
+ fingerprint: z.string(),
94
+ status: BankAccountStatus$outboundSchema,
95
+ holderName: z.string(),
96
+ holderType: BankAccountHolderType$outboundSchema,
97
+ bankName: z.string(),
98
+ bankAccountType: BankAccountType$outboundSchema,
99
+ routingNumber: z.string(),
100
+ lastFourAccountNumber: z.string(),
101
+ updatedOn: z.date().transform(v => v.toISOString()),
102
+ });
103
+
104
+ /**
105
+ * @internal
106
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
107
+ */
108
+ export namespace PaymentMethodsBankAccount$ {
109
+ /** @deprecated use `PaymentMethodsBankAccount$inboundSchema` instead. */
110
+ export const inboundSchema = PaymentMethodsBankAccount$inboundSchema;
111
+ /** @deprecated use `PaymentMethodsBankAccount$outboundSchema` instead. */
112
+ export const outboundSchema = PaymentMethodsBankAccount$outboundSchema;
113
+ /** @deprecated use `PaymentMethodsBankAccount$Outbound` instead. */
114
+ export type Outbound = PaymentMethodsBankAccount$Outbound;
115
+ }
116
+
117
+ export function paymentMethodsBankAccountToJSON(
118
+ paymentMethodsBankAccount: PaymentMethodsBankAccount,
119
+ ): string {
120
+ return JSON.stringify(
121
+ PaymentMethodsBankAccount$outboundSchema.parse(paymentMethodsBankAccount),
122
+ );
123
+ }
124
+
125
+ export function paymentMethodsBankAccountFromJSON(
126
+ jsonString: string,
127
+ ): SafeParseResult<PaymentMethodsBankAccount, SDKValidationError> {
128
+ return safeParse(
129
+ jsonString,
130
+ (x) => PaymentMethodsBankAccount$inboundSchema.parse(JSON.parse(x)),
131
+ `Failed to parse 'PaymentMethodsBankAccount' from JSON`,
132
+ );
133
+ }