@moovio/sdk 0.3.2 → 0.3.3
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.
- package/README.md +4 -4
- package/docs/sdks/scheduling/README.md +2 -2
- package/docs/sdks/transfers/README.md +2 -2
- package/funcs/schedulingGetOccurrance.d.ts +1 -1
- package/funcs/schedulingGetOccurrance.js +1 -1
- package/funcs/transfersList.d.ts +1 -1
- package/funcs/transfersList.js +1 -1
- package/jsr.json +1 -1
- package/lib/config.d.ts +2 -2
- package/lib/config.js +2 -2
- package/models/components/addresssuggestion.d.ts +42 -0
- package/models/components/addresssuggestion.d.ts.map +1 -0
- package/models/components/addresssuggestion.js +79 -0
- package/models/components/addresssuggestion.js.map +1 -0
- package/models/components/card.d.ts +2 -2
- package/models/components/card.d.ts.map +1 -1
- package/models/components/card.js +2 -2
- package/models/components/card.js.map +1 -1
- package/models/components/enrichedaddressresponse.d.ts +3 -15
- package/models/components/enrichedaddressresponse.d.ts.map +1 -1
- package/models/components/enrichedaddressresponse.js +3 -12
- package/models/components/enrichedaddressresponse.js.map +1 -1
- package/models/components/index.d.ts +1 -0
- package/models/components/index.d.ts.map +1 -1
- package/models/components/index.js +1 -0
- package/models/components/index.js.map +1 -1
- package/models/components/occurrencesresponse.d.ts +18 -18
- package/models/components/occurrencesresponse.d.ts.map +1 -1
- package/models/components/occurrencesresponse.js +15 -15
- package/models/components/occurrencesresponse.js.map +1 -1
- package/models/components/paymentmethodscard.d.ts +2 -2
- package/models/components/paymentmethodscard.d.ts.map +1 -1
- package/models/components/paymentmethodscard.js +2 -2
- package/models/components/paymentmethodscard.js.map +1 -1
- package/models/errors/schedulevalidationerror.d.ts +9 -3
- package/models/errors/schedulevalidationerror.d.ts.map +1 -1
- package/models/errors/schedulevalidationerror.js +2 -2
- package/models/errors/schedulevalidationerror.js.map +1 -1
- package/models/operations/getscheduledoccurrence.d.ts +2 -2
- package/models/operations/getscheduledoccurrence.d.ts.map +1 -1
- package/models/operations/getscheduledoccurrence.js +2 -2
- package/models/operations/getscheduledoccurrence.js.map +1 -1
- package/package.json +1 -1
- package/sdk/scheduling.d.ts +1 -1
- package/sdk/scheduling.js +1 -1
- package/sdk/transfers.d.ts +1 -1
- package/sdk/transfers.js +1 -1
- package/src/funcs/schedulingGetOccurrance.ts +1 -1
- package/src/funcs/transfersList.ts +1 -1
- package/src/lib/config.ts +2 -2
- package/src/models/components/addresssuggestion.ts +89 -0
- package/src/models/components/card.ts +4 -4
- package/src/models/components/enrichedaddressresponse.ts +10 -27
- package/src/models/components/index.ts +1 -0
- package/src/models/components/occurrencesresponse.ts +33 -33
- package/src/models/components/paymentmethodscard.ts +4 -4
- package/src/models/errors/schedulevalidationerror.ts +5 -5
- package/src/models/operations/getscheduledoccurrence.ts +4 -4
- package/src/sdk/scheduling.ts +1 -1
- package/src/sdk/transfers.ts +1 -1
|
@@ -27,11 +27,12 @@ export type ErrorT = {
|
|
|
27
27
|
};
|
|
28
28
|
|
|
29
29
|
export type OccurrencesResponse = {
|
|
30
|
-
|
|
30
|
+
scheduleID?: string | undefined;
|
|
31
|
+
occurrenceID?: string | undefined;
|
|
31
32
|
/**
|
|
32
|
-
*
|
|
33
|
+
* Sandbox or production account mode of this schedule.
|
|
33
34
|
*/
|
|
34
|
-
|
|
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
|
-
|
|
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
|
-
|
|
116
|
-
|
|
117
|
-
|
|
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
|
-
|
|
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
|
-
|
|
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
|
-
|
|
134
|
-
|
|
133
|
+
scheduleID?: string | undefined;
|
|
134
|
+
occurrenceID?: string | undefined;
|
|
135
|
+
mode?: string | undefined;
|
|
135
136
|
generated?: boolean | undefined;
|
|
136
137
|
indefinite?: boolean | undefined;
|
|
137
|
-
|
|
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
|
-
|
|
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
|
-
|
|
154
|
-
|
|
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
|
-
|
|
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
|
-
|
|
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
|
|
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
|
|
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
|
}));
|
|
@@ -43,7 +43,7 @@ export type GetScheduledOccurrenceRequest = {
|
|
|
43
43
|
|
|
44
44
|
export type GetScheduledOccurrenceResponse = {
|
|
45
45
|
headers: { [k: string]: Array<string> };
|
|
46
|
-
result: components.
|
|
46
|
+
result: components.OccurrencesResponse;
|
|
47
47
|
};
|
|
48
48
|
|
|
49
49
|
/** @internal */
|
|
@@ -179,7 +179,7 @@ export const GetScheduledOccurrenceResponse$inboundSchema: z.ZodType<
|
|
|
179
179
|
unknown
|
|
180
180
|
> = z.object({
|
|
181
181
|
Headers: z.record(z.array(z.string())),
|
|
182
|
-
Result: components.
|
|
182
|
+
Result: components.OccurrencesResponse$inboundSchema,
|
|
183
183
|
}).transform((v) => {
|
|
184
184
|
return remap$(v, {
|
|
185
185
|
"Headers": "headers",
|
|
@@ -190,7 +190,7 @@ export const GetScheduledOccurrenceResponse$inboundSchema: z.ZodType<
|
|
|
190
190
|
/** @internal */
|
|
191
191
|
export type GetScheduledOccurrenceResponse$Outbound = {
|
|
192
192
|
Headers: { [k: string]: Array<string> };
|
|
193
|
-
Result: components.
|
|
193
|
+
Result: components.OccurrencesResponse$Outbound;
|
|
194
194
|
};
|
|
195
195
|
|
|
196
196
|
/** @internal */
|
|
@@ -200,7 +200,7 @@ export const GetScheduledOccurrenceResponse$outboundSchema: z.ZodType<
|
|
|
200
200
|
GetScheduledOccurrenceResponse
|
|
201
201
|
> = z.object({
|
|
202
202
|
headers: z.record(z.array(z.string())),
|
|
203
|
-
result: components.
|
|
203
|
+
result: components.OccurrencesResponse$outboundSchema,
|
|
204
204
|
}).transform((v) => {
|
|
205
205
|
return remap$(v, {
|
|
206
206
|
headers: "Headers",
|
package/src/sdk/scheduling.ts
CHANGED
|
@@ -99,7 +99,7 @@ export class Scheduling extends ClientSDK {
|
|
|
99
99
|
}
|
|
100
100
|
|
|
101
101
|
/**
|
|
102
|
-
*
|
|
102
|
+
* Gets a specific occurrence.
|
|
103
103
|
*
|
|
104
104
|
* To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
|
|
105
105
|
* you'll need to specify the `/accounts/{accountID}/transfers.read` scope.
|
package/src/sdk/transfers.ts
CHANGED
|
@@ -41,7 +41,7 @@ export class Transfers extends ClientSDK {
|
|
|
41
41
|
* Read our [transfers overview guide](https://docs.moov.io/guides/money-movement/overview/) to learn more.
|
|
42
42
|
*
|
|
43
43
|
* When you run this request, you retrieve 200 transfers at a time. You can advance past a results set of 200 transfers by using the `skip` parameter (for example,
|
|
44
|
-
* if you set `skip`= 10, you will see a results set of 200 transfers after the first
|
|
44
|
+
* if you set `skip`= 10, you will see a results set of 200 transfers after the first 10). If you are searching a high volume of transfers, the request will likely
|
|
45
45
|
* process very slowly. To achieve faster performance, restrict the data as much as you can by using the `StartDateTime` and `EndDateTime` parameters for a limited
|
|
46
46
|
* period of time. You can run multiple requests in smaller time window increments until you've retrieved all the transfers you need.
|
|
47
47
|
*
|