@moovio/sdk 0.21.0 → 0.21.2
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/bin/mcp-server.js +79 -61
- package/bin/mcp-server.js.map +11 -10
- package/examples/package-lock.json +1 -1
- package/hooks/hooks.d.ts +3 -2
- package/hooks/hooks.d.ts.map +1 -1
- package/hooks/hooks.js.map +1 -1
- package/hooks/moov-version-hook.d.ts +6 -0
- package/hooks/moov-version-hook.d.ts.map +1 -0
- package/hooks/moov-version-hook.js +12 -0
- package/hooks/moov-version-hook.js.map +1 -0
- package/hooks/registration.d.ts.map +1 -1
- package/hooks/registration.js +3 -1
- package/hooks/registration.js.map +1 -1
- package/hooks/types.d.ts +2 -6
- package/hooks/types.d.ts.map +1 -1
- package/jsr.json +1 -1
- package/lib/config.d.ts +3 -3
- package/lib/config.js +3 -3
- package/lib/sdks.d.ts.map +1 -1
- package/lib/sdks.js +5 -6
- package/lib/sdks.js.map +1 -1
- package/mcp-server/mcp-server.js +1 -1
- package/mcp-server/server.js +1 -1
- package/package.json +1 -1
- package/src/hooks/hooks.ts +2 -2
- package/src/hooks/moov-version-hook.ts +9 -0
- package/src/hooks/registration.ts +4 -1
- package/src/hooks/types.ts +2 -7
- package/src/lib/config.ts +3 -3
- package/src/lib/sdks.ts +6 -7
- package/src/mcp-server/mcp-server.ts +1 -1
- package/src/mcp-server/server.ts +1 -1
- package/docs/sdks/accounts/README.md +0 -1038
- package/docs/sdks/accountterminalapplications/README.md +0 -371
- package/docs/sdks/adjustments/README.md +0 -185
- package/docs/sdks/applepay/README.md +0 -572
- package/docs/sdks/authentication/README.md +0 -191
- package/docs/sdks/avatars/README.md +0 -95
- package/docs/sdks/bankaccounts/README.md +0 -951
- package/docs/sdks/branding/README.md +0 -407
- package/docs/sdks/capabilities/README.md +0 -380
- package/docs/sdks/cardissuing/README.md +0 -533
- package/docs/sdks/cards/README.md +0 -544
- package/docs/sdks/disputes/README.md +0 -1085
- package/docs/sdks/endtoendencryption/README.md +0 -174
- package/docs/sdks/enrichedaddress/README.md +0 -95
- package/docs/sdks/enrichedprofile/README.md +0 -95
- package/docs/sdks/feeplans/README.md +0 -921
- package/docs/sdks/files/README.md +0 -293
- package/docs/sdks/images/README.md +0 -616
- package/docs/sdks/industries/README.md +0 -91
- package/docs/sdks/institutions/README.md +0 -184
- package/docs/sdks/issuingtransactions/README.md +0 -465
- package/docs/sdks/onboarding/README.md +0 -389
- package/docs/sdks/paymentlinks/README.md +0 -615
- package/docs/sdks/paymentmethods/README.md +0 -187
- package/docs/sdks/ping/README.md +0 -91
- package/docs/sdks/products/README.md +0 -616
- package/docs/sdks/receipts/README.md +0 -180
- package/docs/sdks/representatives/README.md +0 -603
- package/docs/sdks/scheduling/README.md +0 -1018
- package/docs/sdks/statements/README.md +0 -194
- package/docs/sdks/support/README.md +0 -505
- package/docs/sdks/sweeps/README.md +0 -571
- package/docs/sdks/terminalapplications/README.md +0 -460
- package/docs/sdks/transfers/README.md +0 -1136
- package/docs/sdks/underwriting/README.md +0 -331
- package/docs/sdks/wallets/README.md +0 -416
- package/docs/sdks/wallettransactions/README.md +0 -202
- package/examples/README.md +0 -31
- package/test/README.md +0 -14
|
@@ -1,571 +0,0 @@
|
|
|
1
|
-
# Sweeps
|
|
2
|
-
(*sweeps*)
|
|
3
|
-
|
|
4
|
-
## Overview
|
|
5
|
-
|
|
6
|
-
### Available Operations
|
|
7
|
-
|
|
8
|
-
* [createConfig](#createconfig) - Create a sweep config for a wallet.
|
|
9
|
-
|
|
10
|
-
To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
|
|
11
|
-
you'll need to specify the `/accounts/{accountID}/wallets.write` scope.
|
|
12
|
-
* [listConfigs](#listconfigs) - List sweep configs associated with an account.
|
|
13
|
-
|
|
14
|
-
To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
|
|
15
|
-
you'll need to specify the `/accounts/{accountID}/wallets.read` scope.
|
|
16
|
-
* [getConfig](#getconfig) - Get a sweep config associated with a wallet.
|
|
17
|
-
|
|
18
|
-
To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
|
|
19
|
-
you'll need to specify the `/accounts/{accountID}/wallets.read` scope.
|
|
20
|
-
* [updateConfig](#updateconfig) - Update settings on a sweep config.
|
|
21
|
-
|
|
22
|
-
To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
|
|
23
|
-
you'll need to specify the `/accounts/{accountID}/wallets.write` scope.
|
|
24
|
-
* [list](#list) - List sweeps associated with a wallet.
|
|
25
|
-
|
|
26
|
-
To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
|
|
27
|
-
you'll need to specify the `/accounts/{accountID}/wallets.read` scope.
|
|
28
|
-
* [get](#get) - Get details on a specific sweep.
|
|
29
|
-
|
|
30
|
-
To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
|
|
31
|
-
you'll need to specify the `/accounts/{accountID}/wallets.read` scope.
|
|
32
|
-
|
|
33
|
-
## createConfig
|
|
34
|
-
|
|
35
|
-
Create a sweep config for a wallet.
|
|
36
|
-
|
|
37
|
-
To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
|
|
38
|
-
you'll need to specify the `/accounts/{accountID}/wallets.write` scope.
|
|
39
|
-
|
|
40
|
-
### Example Usage
|
|
41
|
-
|
|
42
|
-
<!-- UsageSnippet language="typescript" operationID="createSweepConfig" method="post" path="/accounts/{accountID}/sweep-configs" -->
|
|
43
|
-
```typescript
|
|
44
|
-
import { Moov } from "@moovio/sdk";
|
|
45
|
-
|
|
46
|
-
const moov = new Moov({
|
|
47
|
-
xMoovVersion: "v2024.01.00",
|
|
48
|
-
security: {
|
|
49
|
-
username: "",
|
|
50
|
-
password: "",
|
|
51
|
-
},
|
|
52
|
-
});
|
|
53
|
-
|
|
54
|
-
async function run() {
|
|
55
|
-
const result = await moov.sweeps.createConfig({
|
|
56
|
-
accountID: "cd0ec32e-bd84-418c-90d3-fffbc5465f8b",
|
|
57
|
-
createSweepConfig: {
|
|
58
|
-
walletID: "01234567-89ab-cdef-0123-456789abcdef",
|
|
59
|
-
status: "enabled",
|
|
60
|
-
pushPaymentMethodID: "01234567-89ab-cdef-0123-456789abcdef",
|
|
61
|
-
pullPaymentMethodID: "01234567-89ab-cdef-0123-456789abcdef",
|
|
62
|
-
},
|
|
63
|
-
});
|
|
64
|
-
|
|
65
|
-
console.log(result);
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
run();
|
|
69
|
-
```
|
|
70
|
-
|
|
71
|
-
### Standalone function
|
|
72
|
-
|
|
73
|
-
The standalone function version of this method:
|
|
74
|
-
|
|
75
|
-
```typescript
|
|
76
|
-
import { MoovCore } from "@moovio/sdk/core.js";
|
|
77
|
-
import { sweepsCreateConfig } from "@moovio/sdk/funcs/sweepsCreateConfig.js";
|
|
78
|
-
|
|
79
|
-
// Use `MoovCore` for best tree-shaking performance.
|
|
80
|
-
// You can create one instance of it to use across an application.
|
|
81
|
-
const moov = new MoovCore({
|
|
82
|
-
xMoovVersion: "v2024.01.00",
|
|
83
|
-
security: {
|
|
84
|
-
username: "",
|
|
85
|
-
password: "",
|
|
86
|
-
},
|
|
87
|
-
});
|
|
88
|
-
|
|
89
|
-
async function run() {
|
|
90
|
-
const res = await sweepsCreateConfig(moov, {
|
|
91
|
-
accountID: "cd0ec32e-bd84-418c-90d3-fffbc5465f8b",
|
|
92
|
-
createSweepConfig: {
|
|
93
|
-
walletID: "01234567-89ab-cdef-0123-456789abcdef",
|
|
94
|
-
status: "enabled",
|
|
95
|
-
pushPaymentMethodID: "01234567-89ab-cdef-0123-456789abcdef",
|
|
96
|
-
pullPaymentMethodID: "01234567-89ab-cdef-0123-456789abcdef",
|
|
97
|
-
},
|
|
98
|
-
});
|
|
99
|
-
if (res.ok) {
|
|
100
|
-
const { value: result } = res;
|
|
101
|
-
console.log(result);
|
|
102
|
-
} else {
|
|
103
|
-
console.log("sweepsCreateConfig failed:", res.error);
|
|
104
|
-
}
|
|
105
|
-
}
|
|
106
|
-
|
|
107
|
-
run();
|
|
108
|
-
```
|
|
109
|
-
|
|
110
|
-
### Parameters
|
|
111
|
-
|
|
112
|
-
| Parameter | Type | Required | Description |
|
|
113
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
114
|
-
| `request` | [operations.CreateSweepConfigRequest](../../models/operations/createsweepconfigrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
115
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
116
|
-
| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
|
|
117
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
118
|
-
|
|
119
|
-
### Response
|
|
120
|
-
|
|
121
|
-
**Promise\<[operations.CreateSweepConfigResponse](../../models/operations/createsweepconfigresponse.md)\>**
|
|
122
|
-
|
|
123
|
-
### Errors
|
|
124
|
-
|
|
125
|
-
| Error Type | Status Code | Content Type |
|
|
126
|
-
| ----------------------------- | ----------------------------- | ----------------------------- |
|
|
127
|
-
| errors.GenericError | 400, 409 | application/json |
|
|
128
|
-
| errors.CreateSweepConfigError | 422 | application/json |
|
|
129
|
-
| errors.APIError | 4XX, 5XX | \*/\* |
|
|
130
|
-
|
|
131
|
-
## listConfigs
|
|
132
|
-
|
|
133
|
-
List sweep configs associated with an account.
|
|
134
|
-
|
|
135
|
-
To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
|
|
136
|
-
you'll need to specify the `/accounts/{accountID}/wallets.read` scope.
|
|
137
|
-
|
|
138
|
-
### Example Usage
|
|
139
|
-
|
|
140
|
-
<!-- UsageSnippet language="typescript" operationID="listSweepConfigs" method="get" path="/accounts/{accountID}/sweep-configs" -->
|
|
141
|
-
```typescript
|
|
142
|
-
import { Moov } from "@moovio/sdk";
|
|
143
|
-
|
|
144
|
-
const moov = new Moov({
|
|
145
|
-
xMoovVersion: "v2024.01.00",
|
|
146
|
-
security: {
|
|
147
|
-
username: "",
|
|
148
|
-
password: "",
|
|
149
|
-
},
|
|
150
|
-
});
|
|
151
|
-
|
|
152
|
-
async function run() {
|
|
153
|
-
const result = await moov.sweeps.listConfigs({
|
|
154
|
-
accountID: "ed67e4c8-03d3-4d88-ba38-fcd87de45a92",
|
|
155
|
-
});
|
|
156
|
-
|
|
157
|
-
console.log(result);
|
|
158
|
-
}
|
|
159
|
-
|
|
160
|
-
run();
|
|
161
|
-
```
|
|
162
|
-
|
|
163
|
-
### Standalone function
|
|
164
|
-
|
|
165
|
-
The standalone function version of this method:
|
|
166
|
-
|
|
167
|
-
```typescript
|
|
168
|
-
import { MoovCore } from "@moovio/sdk/core.js";
|
|
169
|
-
import { sweepsListConfigs } from "@moovio/sdk/funcs/sweepsListConfigs.js";
|
|
170
|
-
|
|
171
|
-
// Use `MoovCore` for best tree-shaking performance.
|
|
172
|
-
// You can create one instance of it to use across an application.
|
|
173
|
-
const moov = new MoovCore({
|
|
174
|
-
xMoovVersion: "v2024.01.00",
|
|
175
|
-
security: {
|
|
176
|
-
username: "",
|
|
177
|
-
password: "",
|
|
178
|
-
},
|
|
179
|
-
});
|
|
180
|
-
|
|
181
|
-
async function run() {
|
|
182
|
-
const res = await sweepsListConfigs(moov, {
|
|
183
|
-
accountID: "ed67e4c8-03d3-4d88-ba38-fcd87de45a92",
|
|
184
|
-
});
|
|
185
|
-
if (res.ok) {
|
|
186
|
-
const { value: result } = res;
|
|
187
|
-
console.log(result);
|
|
188
|
-
} else {
|
|
189
|
-
console.log("sweepsListConfigs failed:", res.error);
|
|
190
|
-
}
|
|
191
|
-
}
|
|
192
|
-
|
|
193
|
-
run();
|
|
194
|
-
```
|
|
195
|
-
|
|
196
|
-
### Parameters
|
|
197
|
-
|
|
198
|
-
| Parameter | Type | Required | Description |
|
|
199
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
200
|
-
| `request` | [operations.ListSweepConfigsRequest](../../models/operations/listsweepconfigsrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
201
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
202
|
-
| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
|
|
203
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
204
|
-
|
|
205
|
-
### Response
|
|
206
|
-
|
|
207
|
-
**Promise\<[operations.ListSweepConfigsResponse](../../models/operations/listsweepconfigsresponse.md)\>**
|
|
208
|
-
|
|
209
|
-
### Errors
|
|
210
|
-
|
|
211
|
-
| Error Type | Status Code | Content Type |
|
|
212
|
-
| --------------- | --------------- | --------------- |
|
|
213
|
-
| errors.APIError | 4XX, 5XX | \*/\* |
|
|
214
|
-
|
|
215
|
-
## getConfig
|
|
216
|
-
|
|
217
|
-
Get a sweep config associated with a wallet.
|
|
218
|
-
|
|
219
|
-
To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
|
|
220
|
-
you'll need to specify the `/accounts/{accountID}/wallets.read` scope.
|
|
221
|
-
|
|
222
|
-
### Example Usage
|
|
223
|
-
|
|
224
|
-
<!-- UsageSnippet language="typescript" operationID="getSweepConfig" method="get" path="/accounts/{accountID}/sweep-configs/{sweepConfigID}" -->
|
|
225
|
-
```typescript
|
|
226
|
-
import { Moov } from "@moovio/sdk";
|
|
227
|
-
|
|
228
|
-
const moov = new Moov({
|
|
229
|
-
xMoovVersion: "v2024.01.00",
|
|
230
|
-
security: {
|
|
231
|
-
username: "",
|
|
232
|
-
password: "",
|
|
233
|
-
},
|
|
234
|
-
});
|
|
235
|
-
|
|
236
|
-
async function run() {
|
|
237
|
-
const result = await moov.sweeps.getConfig({
|
|
238
|
-
accountID: "ae1c2e76-3195-4fc8-b922-b7af6dcf1aad",
|
|
239
|
-
sweepConfigID: "bfddff28-5291-4d9b-a0f8-22a0895e8486",
|
|
240
|
-
});
|
|
241
|
-
|
|
242
|
-
console.log(result);
|
|
243
|
-
}
|
|
244
|
-
|
|
245
|
-
run();
|
|
246
|
-
```
|
|
247
|
-
|
|
248
|
-
### Standalone function
|
|
249
|
-
|
|
250
|
-
The standalone function version of this method:
|
|
251
|
-
|
|
252
|
-
```typescript
|
|
253
|
-
import { MoovCore } from "@moovio/sdk/core.js";
|
|
254
|
-
import { sweepsGetConfig } from "@moovio/sdk/funcs/sweepsGetConfig.js";
|
|
255
|
-
|
|
256
|
-
// Use `MoovCore` for best tree-shaking performance.
|
|
257
|
-
// You can create one instance of it to use across an application.
|
|
258
|
-
const moov = new MoovCore({
|
|
259
|
-
xMoovVersion: "v2024.01.00",
|
|
260
|
-
security: {
|
|
261
|
-
username: "",
|
|
262
|
-
password: "",
|
|
263
|
-
},
|
|
264
|
-
});
|
|
265
|
-
|
|
266
|
-
async function run() {
|
|
267
|
-
const res = await sweepsGetConfig(moov, {
|
|
268
|
-
accountID: "ae1c2e76-3195-4fc8-b922-b7af6dcf1aad",
|
|
269
|
-
sweepConfigID: "bfddff28-5291-4d9b-a0f8-22a0895e8486",
|
|
270
|
-
});
|
|
271
|
-
if (res.ok) {
|
|
272
|
-
const { value: result } = res;
|
|
273
|
-
console.log(result);
|
|
274
|
-
} else {
|
|
275
|
-
console.log("sweepsGetConfig failed:", res.error);
|
|
276
|
-
}
|
|
277
|
-
}
|
|
278
|
-
|
|
279
|
-
run();
|
|
280
|
-
```
|
|
281
|
-
|
|
282
|
-
### Parameters
|
|
283
|
-
|
|
284
|
-
| Parameter | Type | Required | Description |
|
|
285
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
286
|
-
| `request` | [operations.GetSweepConfigRequest](../../models/operations/getsweepconfigrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
287
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
288
|
-
| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
|
|
289
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
290
|
-
|
|
291
|
-
### Response
|
|
292
|
-
|
|
293
|
-
**Promise\<[operations.GetSweepConfigResponse](../../models/operations/getsweepconfigresponse.md)\>**
|
|
294
|
-
|
|
295
|
-
### Errors
|
|
296
|
-
|
|
297
|
-
| Error Type | Status Code | Content Type |
|
|
298
|
-
| --------------- | --------------- | --------------- |
|
|
299
|
-
| errors.APIError | 4XX, 5XX | \*/\* |
|
|
300
|
-
|
|
301
|
-
## updateConfig
|
|
302
|
-
|
|
303
|
-
Update settings on a sweep config.
|
|
304
|
-
|
|
305
|
-
To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
|
|
306
|
-
you'll need to specify the `/accounts/{accountID}/wallets.write` scope.
|
|
307
|
-
|
|
308
|
-
### Example Usage
|
|
309
|
-
|
|
310
|
-
<!-- UsageSnippet language="typescript" operationID="updateSweepConfig" method="patch" path="/accounts/{accountID}/sweep-configs/{sweepConfigID}" -->
|
|
311
|
-
```typescript
|
|
312
|
-
import { Moov } from "@moovio/sdk";
|
|
313
|
-
|
|
314
|
-
const moov = new Moov({
|
|
315
|
-
xMoovVersion: "v2024.01.00",
|
|
316
|
-
security: {
|
|
317
|
-
username: "",
|
|
318
|
-
password: "",
|
|
319
|
-
},
|
|
320
|
-
});
|
|
321
|
-
|
|
322
|
-
async function run() {
|
|
323
|
-
const result = await moov.sweeps.updateConfig({
|
|
324
|
-
accountID: "c16d0264-3e93-4d13-b8d8-6e8e98122631",
|
|
325
|
-
sweepConfigID: "f7943244-882b-4a3a-837a-a58418358399",
|
|
326
|
-
patchSweepConfig: {
|
|
327
|
-
status: "disabled",
|
|
328
|
-
},
|
|
329
|
-
});
|
|
330
|
-
|
|
331
|
-
console.log(result);
|
|
332
|
-
}
|
|
333
|
-
|
|
334
|
-
run();
|
|
335
|
-
```
|
|
336
|
-
|
|
337
|
-
### Standalone function
|
|
338
|
-
|
|
339
|
-
The standalone function version of this method:
|
|
340
|
-
|
|
341
|
-
```typescript
|
|
342
|
-
import { MoovCore } from "@moovio/sdk/core.js";
|
|
343
|
-
import { sweepsUpdateConfig } from "@moovio/sdk/funcs/sweepsUpdateConfig.js";
|
|
344
|
-
|
|
345
|
-
// Use `MoovCore` for best tree-shaking performance.
|
|
346
|
-
// You can create one instance of it to use across an application.
|
|
347
|
-
const moov = new MoovCore({
|
|
348
|
-
xMoovVersion: "v2024.01.00",
|
|
349
|
-
security: {
|
|
350
|
-
username: "",
|
|
351
|
-
password: "",
|
|
352
|
-
},
|
|
353
|
-
});
|
|
354
|
-
|
|
355
|
-
async function run() {
|
|
356
|
-
const res = await sweepsUpdateConfig(moov, {
|
|
357
|
-
accountID: "c16d0264-3e93-4d13-b8d8-6e8e98122631",
|
|
358
|
-
sweepConfigID: "f7943244-882b-4a3a-837a-a58418358399",
|
|
359
|
-
patchSweepConfig: {
|
|
360
|
-
status: "disabled",
|
|
361
|
-
},
|
|
362
|
-
});
|
|
363
|
-
if (res.ok) {
|
|
364
|
-
const { value: result } = res;
|
|
365
|
-
console.log(result);
|
|
366
|
-
} else {
|
|
367
|
-
console.log("sweepsUpdateConfig failed:", res.error);
|
|
368
|
-
}
|
|
369
|
-
}
|
|
370
|
-
|
|
371
|
-
run();
|
|
372
|
-
```
|
|
373
|
-
|
|
374
|
-
### Parameters
|
|
375
|
-
|
|
376
|
-
| Parameter | Type | Required | Description |
|
|
377
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
378
|
-
| `request` | [operations.UpdateSweepConfigRequest](../../models/operations/updatesweepconfigrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
379
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
380
|
-
| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
|
|
381
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
382
|
-
|
|
383
|
-
### Response
|
|
384
|
-
|
|
385
|
-
**Promise\<[operations.UpdateSweepConfigResponse](../../models/operations/updatesweepconfigresponse.md)\>**
|
|
386
|
-
|
|
387
|
-
### Errors
|
|
388
|
-
|
|
389
|
-
| Error Type | Status Code | Content Type |
|
|
390
|
-
| ---------------------------- | ---------------------------- | ---------------------------- |
|
|
391
|
-
| errors.GenericError | 400, 409 | application/json |
|
|
392
|
-
| errors.PatchSweepConfigError | 422 | application/json |
|
|
393
|
-
| errors.APIError | 4XX, 5XX | \*/\* |
|
|
394
|
-
|
|
395
|
-
## list
|
|
396
|
-
|
|
397
|
-
List sweeps associated with a wallet.
|
|
398
|
-
|
|
399
|
-
To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
|
|
400
|
-
you'll need to specify the `/accounts/{accountID}/wallets.read` scope.
|
|
401
|
-
|
|
402
|
-
### Example Usage
|
|
403
|
-
|
|
404
|
-
<!-- UsageSnippet language="typescript" operationID="listSweeps" method="get" path="/accounts/{accountID}/wallets/{walletID}/sweeps" -->
|
|
405
|
-
```typescript
|
|
406
|
-
import { Moov } from "@moovio/sdk";
|
|
407
|
-
|
|
408
|
-
const moov = new Moov({
|
|
409
|
-
xMoovVersion: "v2024.01.00",
|
|
410
|
-
security: {
|
|
411
|
-
username: "",
|
|
412
|
-
password: "",
|
|
413
|
-
},
|
|
414
|
-
});
|
|
415
|
-
|
|
416
|
-
async function run() {
|
|
417
|
-
const result = await moov.sweeps.list({
|
|
418
|
-
accountID: "a227b50c-035d-4b7f-932c-a4b7e02aaf5c",
|
|
419
|
-
walletID: "d01e5b34-b207-4a5c-b249-6e049be6a841",
|
|
420
|
-
skip: 60,
|
|
421
|
-
count: 20,
|
|
422
|
-
});
|
|
423
|
-
|
|
424
|
-
console.log(result);
|
|
425
|
-
}
|
|
426
|
-
|
|
427
|
-
run();
|
|
428
|
-
```
|
|
429
|
-
|
|
430
|
-
### Standalone function
|
|
431
|
-
|
|
432
|
-
The standalone function version of this method:
|
|
433
|
-
|
|
434
|
-
```typescript
|
|
435
|
-
import { MoovCore } from "@moovio/sdk/core.js";
|
|
436
|
-
import { sweepsList } from "@moovio/sdk/funcs/sweepsList.js";
|
|
437
|
-
|
|
438
|
-
// Use `MoovCore` for best tree-shaking performance.
|
|
439
|
-
// You can create one instance of it to use across an application.
|
|
440
|
-
const moov = new MoovCore({
|
|
441
|
-
xMoovVersion: "v2024.01.00",
|
|
442
|
-
security: {
|
|
443
|
-
username: "",
|
|
444
|
-
password: "",
|
|
445
|
-
},
|
|
446
|
-
});
|
|
447
|
-
|
|
448
|
-
async function run() {
|
|
449
|
-
const res = await sweepsList(moov, {
|
|
450
|
-
accountID: "a227b50c-035d-4b7f-932c-a4b7e02aaf5c",
|
|
451
|
-
walletID: "d01e5b34-b207-4a5c-b249-6e049be6a841",
|
|
452
|
-
skip: 60,
|
|
453
|
-
count: 20,
|
|
454
|
-
});
|
|
455
|
-
if (res.ok) {
|
|
456
|
-
const { value: result } = res;
|
|
457
|
-
console.log(result);
|
|
458
|
-
} else {
|
|
459
|
-
console.log("sweepsList failed:", res.error);
|
|
460
|
-
}
|
|
461
|
-
}
|
|
462
|
-
|
|
463
|
-
run();
|
|
464
|
-
```
|
|
465
|
-
|
|
466
|
-
### Parameters
|
|
467
|
-
|
|
468
|
-
| Parameter | Type | Required | Description |
|
|
469
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
470
|
-
| `request` | [operations.ListSweepsRequest](../../models/operations/listsweepsrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
471
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
472
|
-
| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
|
|
473
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
474
|
-
|
|
475
|
-
### Response
|
|
476
|
-
|
|
477
|
-
**Promise\<[operations.ListSweepsResponse](../../models/operations/listsweepsresponse.md)\>**
|
|
478
|
-
|
|
479
|
-
### Errors
|
|
480
|
-
|
|
481
|
-
| Error Type | Status Code | Content Type |
|
|
482
|
-
| --------------- | --------------- | --------------- |
|
|
483
|
-
| errors.APIError | 4XX, 5XX | \*/\* |
|
|
484
|
-
|
|
485
|
-
## get
|
|
486
|
-
|
|
487
|
-
Get details on a specific sweep.
|
|
488
|
-
|
|
489
|
-
To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
|
|
490
|
-
you'll need to specify the `/accounts/{accountID}/wallets.read` scope.
|
|
491
|
-
|
|
492
|
-
### Example Usage
|
|
493
|
-
|
|
494
|
-
<!-- UsageSnippet language="typescript" operationID="getSweep" method="get" path="/accounts/{accountID}/wallets/{walletID}/sweeps/{sweepID}" -->
|
|
495
|
-
```typescript
|
|
496
|
-
import { Moov } from "@moovio/sdk";
|
|
497
|
-
|
|
498
|
-
const moov = new Moov({
|
|
499
|
-
xMoovVersion: "v2024.01.00",
|
|
500
|
-
security: {
|
|
501
|
-
username: "",
|
|
502
|
-
password: "",
|
|
503
|
-
},
|
|
504
|
-
});
|
|
505
|
-
|
|
506
|
-
async function run() {
|
|
507
|
-
const result = await moov.sweeps.get({
|
|
508
|
-
accountID: "481bc941-34a2-4c2a-a4f8-feaa9a25d630",
|
|
509
|
-
walletID: "e63a4638-ad67-44fb-9b59-ed7311023602",
|
|
510
|
-
sweepID: "c88c9731-06c2-4b4a-a7d2-34c8b936d9ae",
|
|
511
|
-
});
|
|
512
|
-
|
|
513
|
-
console.log(result);
|
|
514
|
-
}
|
|
515
|
-
|
|
516
|
-
run();
|
|
517
|
-
```
|
|
518
|
-
|
|
519
|
-
### Standalone function
|
|
520
|
-
|
|
521
|
-
The standalone function version of this method:
|
|
522
|
-
|
|
523
|
-
```typescript
|
|
524
|
-
import { MoovCore } from "@moovio/sdk/core.js";
|
|
525
|
-
import { sweepsGet } from "@moovio/sdk/funcs/sweepsGet.js";
|
|
526
|
-
|
|
527
|
-
// Use `MoovCore` for best tree-shaking performance.
|
|
528
|
-
// You can create one instance of it to use across an application.
|
|
529
|
-
const moov = new MoovCore({
|
|
530
|
-
xMoovVersion: "v2024.01.00",
|
|
531
|
-
security: {
|
|
532
|
-
username: "",
|
|
533
|
-
password: "",
|
|
534
|
-
},
|
|
535
|
-
});
|
|
536
|
-
|
|
537
|
-
async function run() {
|
|
538
|
-
const res = await sweepsGet(moov, {
|
|
539
|
-
accountID: "481bc941-34a2-4c2a-a4f8-feaa9a25d630",
|
|
540
|
-
walletID: "e63a4638-ad67-44fb-9b59-ed7311023602",
|
|
541
|
-
sweepID: "c88c9731-06c2-4b4a-a7d2-34c8b936d9ae",
|
|
542
|
-
});
|
|
543
|
-
if (res.ok) {
|
|
544
|
-
const { value: result } = res;
|
|
545
|
-
console.log(result);
|
|
546
|
-
} else {
|
|
547
|
-
console.log("sweepsGet failed:", res.error);
|
|
548
|
-
}
|
|
549
|
-
}
|
|
550
|
-
|
|
551
|
-
run();
|
|
552
|
-
```
|
|
553
|
-
|
|
554
|
-
### Parameters
|
|
555
|
-
|
|
556
|
-
| Parameter | Type | Required | Description |
|
|
557
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
558
|
-
| `request` | [operations.GetSweepRequest](../../models/operations/getsweeprequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
559
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
560
|
-
| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
|
|
561
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
562
|
-
|
|
563
|
-
### Response
|
|
564
|
-
|
|
565
|
-
**Promise\<[operations.GetSweepResponse](../../models/operations/getsweepresponse.md)\>**
|
|
566
|
-
|
|
567
|
-
### Errors
|
|
568
|
-
|
|
569
|
-
| Error Type | Status Code | Content Type |
|
|
570
|
-
| --------------- | --------------- | --------------- |
|
|
571
|
-
| errors.APIError | 4XX, 5XX | \*/\* |
|