@moovio/sdk 0.3.2 → 0.3.4

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 (105) hide show
  1. package/README.md +4 -4
  2. package/docs/sdks/scheduling/README.md +2 -2
  3. package/docs/sdks/transfers/README.md +2 -2
  4. package/funcs/avatarsGet.d.ts +1 -7
  5. package/funcs/avatarsGet.d.ts.map +1 -1
  6. package/funcs/avatarsGet.js +2 -12
  7. package/funcs/avatarsGet.js.map +1 -1
  8. package/funcs/schedulingGetOccurrance.d.ts +1 -1
  9. package/funcs/schedulingGetOccurrance.js +1 -1
  10. package/funcs/transfersList.d.ts +1 -1
  11. package/funcs/transfersList.js +1 -1
  12. package/jsr.json +1 -1
  13. package/lib/config.d.ts +2 -2
  14. package/lib/config.js +2 -2
  15. package/models/components/addresssuggestion.d.ts +42 -0
  16. package/models/components/addresssuggestion.d.ts.map +1 -0
  17. package/models/components/addresssuggestion.js +79 -0
  18. package/models/components/addresssuggestion.js.map +1 -0
  19. package/models/components/capabilityrequirement.d.ts +2 -2
  20. package/models/components/capabilityrequirement.d.ts.map +1 -1
  21. package/models/components/capabilityrequirement.js +2 -2
  22. package/models/components/capabilityrequirement.js.map +1 -1
  23. package/models/components/card.d.ts +2 -2
  24. package/models/components/card.d.ts.map +1 -1
  25. package/models/components/card.js +2 -2
  26. package/models/components/card.js.map +1 -1
  27. package/models/components/enrichedaddressresponse.d.ts +3 -15
  28. package/models/components/enrichedaddressresponse.d.ts.map +1 -1
  29. package/models/components/enrichedaddressresponse.js +3 -12
  30. package/models/components/enrichedaddressresponse.js.map +1 -1
  31. package/models/components/enrichedbusinessresponse.d.ts +30 -0
  32. package/models/components/enrichedbusinessresponse.d.ts.map +1 -0
  33. package/models/components/enrichedbusinessresponse.js +70 -0
  34. package/models/components/enrichedbusinessresponse.js.map +1 -0
  35. package/models/components/enrichedindustries.d.ts +30 -0
  36. package/models/components/enrichedindustries.d.ts.map +1 -0
  37. package/models/components/enrichedindustries.js +70 -0
  38. package/models/components/enrichedindustries.js.map +1 -0
  39. package/models/components/index.d.ts +3 -0
  40. package/models/components/index.d.ts.map +1 -1
  41. package/models/components/index.js +3 -0
  42. package/models/components/index.js.map +1 -1
  43. package/models/components/occurrencesresponse.d.ts +18 -18
  44. package/models/components/occurrencesresponse.d.ts.map +1 -1
  45. package/models/components/occurrencesresponse.js +15 -15
  46. package/models/components/occurrencesresponse.js.map +1 -1
  47. package/models/components/paymentmethodscard.d.ts +2 -2
  48. package/models/components/paymentmethodscard.d.ts.map +1 -1
  49. package/models/components/paymentmethodscard.js +2 -2
  50. package/models/components/paymentmethodscard.js.map +1 -1
  51. package/models/errors/schedulevalidationerror.d.ts +9 -3
  52. package/models/errors/schedulevalidationerror.d.ts.map +1 -1
  53. package/models/errors/schedulevalidationerror.js +2 -2
  54. package/models/errors/schedulevalidationerror.js.map +1 -1
  55. package/models/operations/getavatar.d.ts +2 -23
  56. package/models/operations/getavatar.d.ts.map +1 -1
  57. package/models/operations/getavatar.js +3 -38
  58. package/models/operations/getavatar.js.map +1 -1
  59. package/models/operations/getenrichmentprofile.d.ts +2 -2
  60. package/models/operations/getenrichmentprofile.d.ts.map +1 -1
  61. package/models/operations/getenrichmentprofile.js +2 -2
  62. package/models/operations/getenrichmentprofile.js.map +1 -1
  63. package/models/operations/getscheduledoccurrence.d.ts +2 -2
  64. package/models/operations/getscheduledoccurrence.d.ts.map +1 -1
  65. package/models/operations/getscheduledoccurrence.js +2 -2
  66. package/models/operations/getscheduledoccurrence.js.map +1 -1
  67. package/models/operations/listindustries.d.ts +2 -2
  68. package/models/operations/listindustries.d.ts.map +1 -1
  69. package/models/operations/listindustries.js +2 -2
  70. package/models/operations/listindustries.js.map +1 -1
  71. package/models/operations/listinstitutions.d.ts +2 -2
  72. package/models/operations/listinstitutions.d.ts.map +1 -1
  73. package/models/operations/listinstitutions.js +2 -2
  74. package/models/operations/listinstitutions.js.map +1 -1
  75. package/package.json +1 -1
  76. package/sdk/avatars.d.ts +1 -5
  77. package/sdk/avatars.d.ts.map +1 -1
  78. package/sdk/avatars.js +1 -3
  79. package/sdk/avatars.js.map +1 -1
  80. package/sdk/scheduling.d.ts +1 -1
  81. package/sdk/scheduling.js +1 -1
  82. package/sdk/transfers.d.ts +1 -1
  83. package/sdk/transfers.js +1 -1
  84. package/src/funcs/avatarsGet.ts +3 -13
  85. package/src/funcs/schedulingGetOccurrance.ts +1 -1
  86. package/src/funcs/transfersList.ts +1 -1
  87. package/src/lib/config.ts +2 -2
  88. package/src/models/components/addresssuggestion.ts +89 -0
  89. package/src/models/components/capabilityrequirement.ts +4 -4
  90. package/src/models/components/card.ts +4 -4
  91. package/src/models/components/enrichedaddressresponse.ts +10 -27
  92. package/src/models/components/enrichedbusinessresponse.ts +72 -0
  93. package/src/models/components/enrichedindustries.ts +72 -0
  94. package/src/models/components/index.ts +3 -0
  95. package/src/models/components/occurrencesresponse.ts +33 -33
  96. package/src/models/components/paymentmethodscard.ts +4 -4
  97. package/src/models/errors/schedulevalidationerror.ts +5 -5
  98. package/src/models/operations/getavatar.ts +4 -70
  99. package/src/models/operations/getenrichmentprofile.ts +4 -4
  100. package/src/models/operations/getscheduledoccurrence.ts +4 -4
  101. package/src/models/operations/listindustries.ts +4 -4
  102. package/src/models/operations/listinstitutions.ts +4 -4
  103. package/src/sdk/avatars.ts +2 -4
  104. package/src/sdk/scheduling.ts +1 -1
  105. package/src/sdk/transfers.ts +1 -1
package/src/lib/config.ts CHANGED
@@ -66,7 +66,7 @@ export function serverURLFromOptions(options: SDKOptions): URL | null {
66
66
  export const SDK_METADATA = {
67
67
  language: "typescript",
68
68
  openapiDocVersion: "latest",
69
- sdkVersion: "0.3.2",
69
+ sdkVersion: "0.3.4",
70
70
  genVersion: "2.512.4",
71
- userAgent: "speakeasy-sdk/typescript 0.3.2 2.512.4 latest @moovio/sdk",
71
+ userAgent: "speakeasy-sdk/typescript 0.3.4 2.512.4 latest @moovio/sdk",
72
72
  } as const;
@@ -0,0 +1,89 @@
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
+
10
+ export type AddressSuggestion = {
11
+ addressLine1?: string | undefined;
12
+ addressLine2?: string | undefined;
13
+ city?: string | undefined;
14
+ /**
15
+ * The number of units at an address. For example the number of apartments or businesses in a building.
16
+ */
17
+ entries?: number | undefined;
18
+ postalCode?: string | undefined;
19
+ stateOrProvince?: string | undefined;
20
+ };
21
+
22
+ /** @internal */
23
+ export const AddressSuggestion$inboundSchema: z.ZodType<
24
+ AddressSuggestion,
25
+ z.ZodTypeDef,
26
+ unknown
27
+ > = z.object({
28
+ addressLine1: z.string().optional(),
29
+ addressLine2: z.string().optional(),
30
+ city: z.string().optional(),
31
+ entries: z.number().int().optional(),
32
+ postalCode: z.string().optional(),
33
+ stateOrProvince: z.string().optional(),
34
+ });
35
+
36
+ /** @internal */
37
+ export type AddressSuggestion$Outbound = {
38
+ addressLine1?: string | undefined;
39
+ addressLine2?: string | undefined;
40
+ city?: string | undefined;
41
+ entries?: number | undefined;
42
+ postalCode?: string | undefined;
43
+ stateOrProvince?: string | undefined;
44
+ };
45
+
46
+ /** @internal */
47
+ export const AddressSuggestion$outboundSchema: z.ZodType<
48
+ AddressSuggestion$Outbound,
49
+ z.ZodTypeDef,
50
+ AddressSuggestion
51
+ > = z.object({
52
+ addressLine1: z.string().optional(),
53
+ addressLine2: z.string().optional(),
54
+ city: z.string().optional(),
55
+ entries: z.number().int().optional(),
56
+ postalCode: z.string().optional(),
57
+ stateOrProvince: z.string().optional(),
58
+ });
59
+
60
+ /**
61
+ * @internal
62
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
63
+ */
64
+ export namespace AddressSuggestion$ {
65
+ /** @deprecated use `AddressSuggestion$inboundSchema` instead. */
66
+ export const inboundSchema = AddressSuggestion$inboundSchema;
67
+ /** @deprecated use `AddressSuggestion$outboundSchema` instead. */
68
+ export const outboundSchema = AddressSuggestion$outboundSchema;
69
+ /** @deprecated use `AddressSuggestion$Outbound` instead. */
70
+ export type Outbound = AddressSuggestion$Outbound;
71
+ }
72
+
73
+ export function addressSuggestionToJSON(
74
+ addressSuggestion: AddressSuggestion,
75
+ ): string {
76
+ return JSON.stringify(
77
+ AddressSuggestion$outboundSchema.parse(addressSuggestion),
78
+ );
79
+ }
80
+
81
+ export function addressSuggestionFromJSON(
82
+ jsonString: string,
83
+ ): SafeParseResult<AddressSuggestion, SDKValidationError> {
84
+ return safeParse(
85
+ jsonString,
86
+ (x) => AddressSuggestion$inboundSchema.parse(JSON.parse(x)),
87
+ `Failed to parse 'AddressSuggestion' from JSON`,
88
+ );
89
+ }
@@ -22,7 +22,7 @@ import {
22
22
  * Represents individual and business data necessary to facilitate the enabling of a capability for an account.
23
23
  */
24
24
  export type CapabilityRequirement = {
25
- currentlyDue: Array<RequirementID>;
25
+ currentlyDue?: Array<RequirementID> | undefined;
26
26
  errors?: Array<RequirementError> | undefined;
27
27
  };
28
28
 
@@ -32,13 +32,13 @@ export const CapabilityRequirement$inboundSchema: z.ZodType<
32
32
  z.ZodTypeDef,
33
33
  unknown
34
34
  > = z.object({
35
- currentlyDue: z.array(RequirementID$inboundSchema),
35
+ currentlyDue: z.array(RequirementID$inboundSchema).optional(),
36
36
  errors: z.array(RequirementError$inboundSchema).optional(),
37
37
  });
38
38
 
39
39
  /** @internal */
40
40
  export type CapabilityRequirement$Outbound = {
41
- currentlyDue: Array<string>;
41
+ currentlyDue?: Array<string> | undefined;
42
42
  errors?: Array<RequirementError$Outbound> | undefined;
43
43
  };
44
44
 
@@ -48,7 +48,7 @@ export const CapabilityRequirement$outboundSchema: z.ZodType<
48
48
  z.ZodTypeDef,
49
49
  CapabilityRequirement
50
50
  > = z.object({
51
- currentlyDue: z.array(RequirementID$outboundSchema),
51
+ currentlyDue: z.array(RequirementID$outboundSchema).optional(),
52
52
  errors: z.array(RequirementError$outboundSchema).optional(),
53
53
  });
54
54
 
@@ -103,7 +103,7 @@ export type Card = {
103
103
  /**
104
104
  * The name of the cardholder as it appears on the card.
105
105
  */
106
- holderName: string;
106
+ holderName?: string | undefined;
107
107
  billingAddress: CardAddress;
108
108
  /**
109
109
  * The results of submitting cardholder data to a card network for verification.
@@ -170,7 +170,7 @@ export const Card$inboundSchema: z.ZodType<Card, z.ZodTypeDef, unknown> = z
170
170
  lastFourCardNumber: z.string(),
171
171
  bin: z.string(),
172
172
  expiration: CardExpiration$inboundSchema,
173
- holderName: z.string(),
173
+ holderName: z.string().optional(),
174
174
  billingAddress: CardAddress$inboundSchema,
175
175
  cardVerification: CardVerification$inboundSchema,
176
176
  issuer: z.string(),
@@ -197,7 +197,7 @@ export type Card$Outbound = {
197
197
  lastFourCardNumber: string;
198
198
  bin: string;
199
199
  expiration: CardExpiration$Outbound;
200
- holderName: string;
200
+ holderName?: string | undefined;
201
201
  billingAddress: CardAddress$Outbound;
202
202
  cardVerification: CardVerification$Outbound;
203
203
  issuer: string;
@@ -225,7 +225,7 @@ export const Card$outboundSchema: z.ZodType<Card$Outbound, z.ZodTypeDef, Card> =
225
225
  lastFourCardNumber: z.string(),
226
226
  bin: z.string(),
227
227
  expiration: CardExpiration$outboundSchema,
228
- holderName: z.string(),
228
+ holderName: z.string().optional(),
229
229
  billingAddress: CardAddress$outboundSchema,
230
230
  cardVerification: CardVerification$outboundSchema,
231
231
  issuer: z.string(),
@@ -6,17 +6,15 @@ import * as z from "zod";
6
6
  import { safeParse } from "../../lib/schemas.js";
7
7
  import { Result as SafeParseResult } from "../../types/fp.js";
8
8
  import { SDKValidationError } from "../errors/sdkvalidationerror.js";
9
+ import {
10
+ AddressSuggestion,
11
+ AddressSuggestion$inboundSchema,
12
+ AddressSuggestion$Outbound,
13
+ AddressSuggestion$outboundSchema,
14
+ } from "./addresssuggestion.js";
9
15
 
10
16
  export type EnrichedAddressResponse = {
11
- addressLine1?: string | undefined;
12
- addressLine2?: string | undefined;
13
- city?: string | undefined;
14
- /**
15
- * The number of units at an address. For example the number of apartments or businesses in a building.
16
- */
17
- entries?: number | undefined;
18
- postalCode?: string | undefined;
19
- stateOrProvince?: string | undefined;
17
+ suggestions: Array<AddressSuggestion>;
20
18
  };
21
19
 
22
20
  /** @internal */
@@ -25,22 +23,12 @@ export const EnrichedAddressResponse$inboundSchema: z.ZodType<
25
23
  z.ZodTypeDef,
26
24
  unknown
27
25
  > = z.object({
28
- addressLine1: z.string().optional(),
29
- addressLine2: z.string().optional(),
30
- city: z.string().optional(),
31
- entries: z.number().int().optional(),
32
- postalCode: z.string().optional(),
33
- stateOrProvince: z.string().optional(),
26
+ suggestions: z.array(AddressSuggestion$inboundSchema),
34
27
  });
35
28
 
36
29
  /** @internal */
37
30
  export type EnrichedAddressResponse$Outbound = {
38
- addressLine1?: string | undefined;
39
- addressLine2?: string | undefined;
40
- city?: string | undefined;
41
- entries?: number | undefined;
42
- postalCode?: string | undefined;
43
- stateOrProvince?: string | undefined;
31
+ suggestions: Array<AddressSuggestion$Outbound>;
44
32
  };
45
33
 
46
34
  /** @internal */
@@ -49,12 +37,7 @@ export const EnrichedAddressResponse$outboundSchema: z.ZodType<
49
37
  z.ZodTypeDef,
50
38
  EnrichedAddressResponse
51
39
  > = z.object({
52
- addressLine1: z.string().optional(),
53
- addressLine2: z.string().optional(),
54
- city: z.string().optional(),
55
- entries: z.number().int().optional(),
56
- postalCode: z.string().optional(),
57
- stateOrProvince: z.string().optional(),
40
+ suggestions: z.array(AddressSuggestion$outboundSchema),
58
41
  });
59
42
 
60
43
  /**
@@ -0,0 +1,72 @@
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
+ EnrichedBusinessProfile,
11
+ EnrichedBusinessProfile$inboundSchema,
12
+ EnrichedBusinessProfile$Outbound,
13
+ EnrichedBusinessProfile$outboundSchema,
14
+ } from "./enrichedbusinessprofile.js";
15
+
16
+ export type EnrichedBusinessResponse = {
17
+ business?: EnrichedBusinessProfile | undefined;
18
+ };
19
+
20
+ /** @internal */
21
+ export const EnrichedBusinessResponse$inboundSchema: z.ZodType<
22
+ EnrichedBusinessResponse,
23
+ z.ZodTypeDef,
24
+ unknown
25
+ > = z.object({
26
+ business: EnrichedBusinessProfile$inboundSchema.optional(),
27
+ });
28
+
29
+ /** @internal */
30
+ export type EnrichedBusinessResponse$Outbound = {
31
+ business?: EnrichedBusinessProfile$Outbound | undefined;
32
+ };
33
+
34
+ /** @internal */
35
+ export const EnrichedBusinessResponse$outboundSchema: z.ZodType<
36
+ EnrichedBusinessResponse$Outbound,
37
+ z.ZodTypeDef,
38
+ EnrichedBusinessResponse
39
+ > = z.object({
40
+ business: EnrichedBusinessProfile$outboundSchema.optional(),
41
+ });
42
+
43
+ /**
44
+ * @internal
45
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
46
+ */
47
+ export namespace EnrichedBusinessResponse$ {
48
+ /** @deprecated use `EnrichedBusinessResponse$inboundSchema` instead. */
49
+ export const inboundSchema = EnrichedBusinessResponse$inboundSchema;
50
+ /** @deprecated use `EnrichedBusinessResponse$outboundSchema` instead. */
51
+ export const outboundSchema = EnrichedBusinessResponse$outboundSchema;
52
+ /** @deprecated use `EnrichedBusinessResponse$Outbound` instead. */
53
+ export type Outbound = EnrichedBusinessResponse$Outbound;
54
+ }
55
+
56
+ export function enrichedBusinessResponseToJSON(
57
+ enrichedBusinessResponse: EnrichedBusinessResponse,
58
+ ): string {
59
+ return JSON.stringify(
60
+ EnrichedBusinessResponse$outboundSchema.parse(enrichedBusinessResponse),
61
+ );
62
+ }
63
+
64
+ export function enrichedBusinessResponseFromJSON(
65
+ jsonString: string,
66
+ ): SafeParseResult<EnrichedBusinessResponse, SDKValidationError> {
67
+ return safeParse(
68
+ jsonString,
69
+ (x) => EnrichedBusinessResponse$inboundSchema.parse(JSON.parse(x)),
70
+ `Failed to parse 'EnrichedBusinessResponse' from JSON`,
71
+ );
72
+ }
@@ -0,0 +1,72 @@
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
+ EnrichedIndustry,
11
+ EnrichedIndustry$inboundSchema,
12
+ EnrichedIndustry$Outbound,
13
+ EnrichedIndustry$outboundSchema,
14
+ } from "./enrichedindustry.js";
15
+
16
+ export type EnrichedIndustries = {
17
+ industries: Array<EnrichedIndustry>;
18
+ };
19
+
20
+ /** @internal */
21
+ export const EnrichedIndustries$inboundSchema: z.ZodType<
22
+ EnrichedIndustries,
23
+ z.ZodTypeDef,
24
+ unknown
25
+ > = z.object({
26
+ industries: z.array(EnrichedIndustry$inboundSchema),
27
+ });
28
+
29
+ /** @internal */
30
+ export type EnrichedIndustries$Outbound = {
31
+ industries: Array<EnrichedIndustry$Outbound>;
32
+ };
33
+
34
+ /** @internal */
35
+ export const EnrichedIndustries$outboundSchema: z.ZodType<
36
+ EnrichedIndustries$Outbound,
37
+ z.ZodTypeDef,
38
+ EnrichedIndustries
39
+ > = z.object({
40
+ industries: z.array(EnrichedIndustry$outboundSchema),
41
+ });
42
+
43
+ /**
44
+ * @internal
45
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
46
+ */
47
+ export namespace EnrichedIndustries$ {
48
+ /** @deprecated use `EnrichedIndustries$inboundSchema` instead. */
49
+ export const inboundSchema = EnrichedIndustries$inboundSchema;
50
+ /** @deprecated use `EnrichedIndustries$outboundSchema` instead. */
51
+ export const outboundSchema = EnrichedIndustries$outboundSchema;
52
+ /** @deprecated use `EnrichedIndustries$Outbound` instead. */
53
+ export type Outbound = EnrichedIndustries$Outbound;
54
+ }
55
+
56
+ export function enrichedIndustriesToJSON(
57
+ enrichedIndustries: EnrichedIndustries,
58
+ ): string {
59
+ return JSON.stringify(
60
+ EnrichedIndustries$outboundSchema.parse(enrichedIndustries),
61
+ );
62
+ }
63
+
64
+ export function enrichedIndustriesFromJSON(
65
+ jsonString: string,
66
+ ): SafeParseResult<EnrichedIndustries, SDKValidationError> {
67
+ return safeParse(
68
+ jsonString,
69
+ (x) => EnrichedIndustries$inboundSchema.parse(JSON.parse(x)),
70
+ `Failed to parse 'EnrichedIndustries' from JSON`,
71
+ );
72
+ }
@@ -25,6 +25,7 @@ export * from "./achtransactionstatus.js";
25
25
  export * from "./addcapabilities.js";
26
26
  export * from "./address.js";
27
27
  export * from "./addresserror.js";
28
+ export * from "./addresssuggestion.js";
28
29
  export * from "./addressupdate.js";
29
30
  export * from "./adjustment.js";
30
31
  export * from "./amount.js";
@@ -157,6 +158,8 @@ export * from "./e2eetokenupdate.js";
157
158
  export * from "./end2endencryptionerror.js";
158
159
  export * from "./enrichedaddressresponse.js";
159
160
  export * from "./enrichedbusinessprofile.js";
161
+ export * from "./enrichedbusinessresponse.js";
162
+ export * from "./enrichedindustries.js";
160
163
  export * from "./enrichedindustry.js";
161
164
  export * from "./enrichedindustrycodes.js";
162
165
  export * from "./evidencetextresponse.js";
@@ -27,11 +27,12 @@ export type ErrorT = {
27
27
  };
28
28
 
29
29
  export type OccurrencesResponse = {
30
- canceledOn?: Date | undefined;
30
+ scheduleID?: string | undefined;
31
+ occurrenceID?: string | undefined;
31
32
  /**
32
- * Contains details on why the occurrence errored.
33
+ * Sandbox or production account mode of this schedule.
33
34
  */
34
- error?: ErrorT | undefined;
35
+ mode?: Mode | undefined;
35
36
  /**
36
37
  * True if this was generated by a RRule.
37
38
  */
@@ -40,23 +41,22 @@ export type OccurrencesResponse = {
40
41
  * True if the RRule set runs indefinitely.
41
42
  */
42
43
  indefinite?: boolean | undefined;
43
- /**
44
- * Sandbox or production status of this schedule.
45
- */
46
- mode?: Mode | undefined;
47
- occurrenceID?: string | undefined;
48
- ranOn?: Date | undefined;
49
- ranTransferID?: string | undefined;
44
+ canceledOn?: Date | undefined;
50
45
  runOn: Date;
51
46
  /**
52
47
  * Defines the attributes of a transfer.
53
48
  */
54
49
  runTransfer: RunTransfer;
55
- scheduleID?: string | undefined;
50
+ ranOn?: Date | undefined;
51
+ ranTransferID?: string | undefined;
56
52
  /**
57
53
  * Status of the completed occurrence.
58
54
  */
59
55
  status?: OccurrenceStatus | undefined;
56
+ /**
57
+ * Contains details on why the occurrence errored.
58
+ */
59
+ error?: ErrorT | undefined;
60
60
  };
61
61
 
62
62
  /** @internal */
@@ -112,36 +112,36 @@ export const OccurrencesResponse$inboundSchema: z.ZodType<
112
112
  z.ZodTypeDef,
113
113
  unknown
114
114
  > = z.object({
115
- canceledOn: z.string().datetime({ offset: true }).transform(v => new Date(v))
116
- .optional(),
117
- error: z.lazy(() => ErrorT$inboundSchema).optional(),
115
+ scheduleID: z.string().optional(),
116
+ occurrenceID: z.string().optional(),
117
+ mode: Mode$inboundSchema.optional(),
118
118
  generated: z.boolean().optional(),
119
119
  indefinite: z.boolean().optional(),
120
- mode: Mode$inboundSchema.optional(),
121
- occurrenceID: z.string().optional(),
122
- ranOn: z.string().datetime({ offset: true }).transform(v => new Date(v))
120
+ canceledOn: z.string().datetime({ offset: true }).transform(v => new Date(v))
123
121
  .optional(),
124
- ranTransferID: z.string().optional(),
125
122
  runOn: z.string().datetime({ offset: true }).transform(v => new Date(v)),
126
123
  runTransfer: RunTransfer$inboundSchema,
127
- scheduleID: z.string().optional(),
124
+ ranOn: z.string().datetime({ offset: true }).transform(v => new Date(v))
125
+ .optional(),
126
+ ranTransferID: z.string().optional(),
128
127
  status: OccurrenceStatus$inboundSchema.optional(),
128
+ error: z.lazy(() => ErrorT$inboundSchema).optional(),
129
129
  });
130
130
 
131
131
  /** @internal */
132
132
  export type OccurrencesResponse$Outbound = {
133
- canceledOn?: string | undefined;
134
- error?: ErrorT$Outbound | undefined;
133
+ scheduleID?: string | undefined;
134
+ occurrenceID?: string | undefined;
135
+ mode?: string | undefined;
135
136
  generated?: boolean | undefined;
136
137
  indefinite?: boolean | undefined;
137
- mode?: string | undefined;
138
- occurrenceID?: string | undefined;
139
- ranOn?: string | undefined;
140
- ranTransferID?: string | undefined;
138
+ canceledOn?: string | undefined;
141
139
  runOn: string;
142
140
  runTransfer: RunTransfer$Outbound;
143
- scheduleID?: string | undefined;
141
+ ranOn?: string | undefined;
142
+ ranTransferID?: string | undefined;
144
143
  status?: string | undefined;
144
+ error?: ErrorT$Outbound | undefined;
145
145
  };
146
146
 
147
147
  /** @internal */
@@ -150,18 +150,18 @@ export const OccurrencesResponse$outboundSchema: z.ZodType<
150
150
  z.ZodTypeDef,
151
151
  OccurrencesResponse
152
152
  > = z.object({
153
- canceledOn: z.date().transform(v => v.toISOString()).optional(),
154
- error: z.lazy(() => ErrorT$outboundSchema).optional(),
153
+ scheduleID: z.string().optional(),
154
+ occurrenceID: z.string().optional(),
155
+ mode: Mode$outboundSchema.optional(),
155
156
  generated: z.boolean().optional(),
156
157
  indefinite: z.boolean().optional(),
157
- mode: Mode$outboundSchema.optional(),
158
- occurrenceID: z.string().optional(),
159
- ranOn: z.date().transform(v => v.toISOString()).optional(),
160
- ranTransferID: z.string().optional(),
158
+ canceledOn: z.date().transform(v => v.toISOString()).optional(),
161
159
  runOn: z.date().transform(v => v.toISOString()),
162
160
  runTransfer: RunTransfer$outboundSchema,
163
- scheduleID: z.string().optional(),
161
+ ranOn: z.date().transform(v => v.toISOString()).optional(),
162
+ ranTransferID: z.string().optional(),
164
163
  status: OccurrenceStatus$outboundSchema.optional(),
164
+ error: z.lazy(() => ErrorT$outboundSchema).optional(),
165
165
  });
166
166
 
167
167
  /**
@@ -90,7 +90,7 @@ export type PaymentMethodsCard = {
90
90
  /**
91
91
  * The name of the cardholder as it appears on the card.
92
92
  */
93
- holderName: string;
93
+ holderName?: string | undefined;
94
94
  billingAddress: CardAddress;
95
95
  /**
96
96
  * The results of submitting cardholder data to a card network for verification.
@@ -136,7 +136,7 @@ export const PaymentMethodsCard$inboundSchema: z.ZodType<
136
136
  lastFourCardNumber: z.string(),
137
137
  bin: z.string(),
138
138
  expiration: CardExpiration$inboundSchema,
139
- holderName: z.string(),
139
+ holderName: z.string().optional(),
140
140
  billingAddress: CardAddress$inboundSchema,
141
141
  cardVerification: CardVerification$inboundSchema,
142
142
  issuer: z.string(),
@@ -157,7 +157,7 @@ export type PaymentMethodsCard$Outbound = {
157
157
  lastFourCardNumber: string;
158
158
  bin: string;
159
159
  expiration: CardExpiration$Outbound;
160
- holderName: string;
160
+ holderName?: string | undefined;
161
161
  billingAddress: CardAddress$Outbound;
162
162
  cardVerification: CardVerification$Outbound;
163
163
  issuer: string;
@@ -182,7 +182,7 @@ export const PaymentMethodsCard$outboundSchema: z.ZodType<
182
182
  lastFourCardNumber: z.string(),
183
183
  bin: z.string(),
184
184
  expiration: CardExpiration$outboundSchema,
185
- holderName: z.string(),
185
+ holderName: z.string().optional(),
186
186
  billingAddress: CardAddress$outboundSchema,
187
187
  cardVerification: CardVerification$outboundSchema,
188
188
  issuer: z.string(),
@@ -5,13 +5,13 @@
5
5
  import * as z from "zod";
6
6
 
7
7
  export type ScheduleValidationErrorData = {
8
- occurrences?: string | undefined;
8
+ occurrences?: { [k: string]: string } | undefined;
9
9
  recur?: string | undefined;
10
10
  description?: string | undefined;
11
11
  };
12
12
 
13
13
  export class ScheduleValidationError extends Error {
14
- occurrences?: string | undefined;
14
+ occurrences?: { [k: string]: string } | undefined;
15
15
  recur?: string | undefined;
16
16
  description?: string | undefined;
17
17
 
@@ -39,7 +39,7 @@ export const ScheduleValidationError$inboundSchema: z.ZodType<
39
39
  z.ZodTypeDef,
40
40
  unknown
41
41
  > = z.object({
42
- occurrences: z.string().optional(),
42
+ occurrences: z.record(z.string()).optional(),
43
43
  recur: z.string().optional(),
44
44
  description: z.string().optional(),
45
45
  })
@@ -49,7 +49,7 @@ export const ScheduleValidationError$inboundSchema: z.ZodType<
49
49
 
50
50
  /** @internal */
51
51
  export type ScheduleValidationError$Outbound = {
52
- occurrences?: string | undefined;
52
+ occurrences?: { [k: string]: string } | undefined;
53
53
  recur?: string | undefined;
54
54
  description?: string | undefined;
55
55
  };
@@ -62,7 +62,7 @@ export const ScheduleValidationError$outboundSchema: z.ZodType<
62
62
  > = z.instanceof(ScheduleValidationError)
63
63
  .transform(v => v.data$)
64
64
  .pipe(z.object({
65
- occurrences: z.string().optional(),
65
+ occurrences: z.record(z.string()).optional(),
66
66
  recur: z.string().optional(),
67
67
  description: z.string().optional(),
68
68
  }));