@binance/simple-earn 11.0.0 → 11.1.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.
- package/dist/index.d.mts +7 -5
- package/dist/index.d.ts +7 -5
- package/dist/index.js +169 -93
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +170 -88
- package/dist/index.mjs.map +1 -1
- package/package.json +2 -2
package/dist/index.mjs
CHANGED
|
@@ -3,7 +3,7 @@ import { BadRequestError, ConfigurationRestAPI, ConnectorClientError, ForbiddenE
|
|
|
3
3
|
|
|
4
4
|
//#region package.json
|
|
5
5
|
var name = "@binance/simple-earn";
|
|
6
|
-
var version = "11.
|
|
6
|
+
var version = "11.1.0";
|
|
7
7
|
|
|
8
8
|
//#endregion
|
|
9
9
|
//#region src/rest-api/modules/bfusd-api.ts
|
|
@@ -26,30 +26,35 @@ const BfusdApiAxiosParamCreator = function(configuration) {
|
|
|
26
26
|
return {
|
|
27
27
|
getBfusdAccount: async (recvWindow) => {
|
|
28
28
|
const localVarQueryParameter = {};
|
|
29
|
+
const localVarBodyParameter = {};
|
|
29
30
|
if (recvWindow !== void 0 && recvWindow !== null) localVarQueryParameter["recvWindow"] = recvWindow;
|
|
30
31
|
let _timeUnit;
|
|
31
32
|
if ("timeUnit" in configuration) _timeUnit = configuration.timeUnit;
|
|
32
33
|
return {
|
|
33
34
|
endpoint: "/sapi/v1/bfusd/account",
|
|
34
35
|
method: "GET",
|
|
35
|
-
|
|
36
|
+
queryParams: localVarQueryParameter,
|
|
37
|
+
bodyParams: localVarBodyParameter,
|
|
36
38
|
timeUnit: _timeUnit
|
|
37
39
|
};
|
|
38
40
|
},
|
|
39
41
|
getBfusdQuotaDetails: async (recvWindow) => {
|
|
40
42
|
const localVarQueryParameter = {};
|
|
43
|
+
const localVarBodyParameter = {};
|
|
41
44
|
if (recvWindow !== void 0 && recvWindow !== null) localVarQueryParameter["recvWindow"] = recvWindow;
|
|
42
45
|
let _timeUnit;
|
|
43
46
|
if ("timeUnit" in configuration) _timeUnit = configuration.timeUnit;
|
|
44
47
|
return {
|
|
45
48
|
endpoint: "/sapi/v1/bfusd/quota",
|
|
46
49
|
method: "GET",
|
|
47
|
-
|
|
50
|
+
queryParams: localVarQueryParameter,
|
|
51
|
+
bodyParams: localVarBodyParameter,
|
|
48
52
|
timeUnit: _timeUnit
|
|
49
53
|
};
|
|
50
54
|
},
|
|
51
55
|
getBfusdRateHistory: async (startTime, endTime, current, size, recvWindow) => {
|
|
52
56
|
const localVarQueryParameter = {};
|
|
57
|
+
const localVarBodyParameter = {};
|
|
53
58
|
if (startTime !== void 0 && startTime !== null) localVarQueryParameter["startTime"] = startTime;
|
|
54
59
|
if (endTime !== void 0 && endTime !== null) localVarQueryParameter["endTime"] = endTime;
|
|
55
60
|
if (current !== void 0 && current !== null) localVarQueryParameter["current"] = current;
|
|
@@ -60,12 +65,14 @@ const BfusdApiAxiosParamCreator = function(configuration) {
|
|
|
60
65
|
return {
|
|
61
66
|
endpoint: "/sapi/v1/bfusd/history/rateHistory",
|
|
62
67
|
method: "GET",
|
|
63
|
-
|
|
68
|
+
queryParams: localVarQueryParameter,
|
|
69
|
+
bodyParams: localVarBodyParameter,
|
|
64
70
|
timeUnit: _timeUnit
|
|
65
71
|
};
|
|
66
72
|
},
|
|
67
73
|
getBfusdRedemptionHistory: async (startTime, endTime, current, size, recvWindow) => {
|
|
68
74
|
const localVarQueryParameter = {};
|
|
75
|
+
const localVarBodyParameter = {};
|
|
69
76
|
if (startTime !== void 0 && startTime !== null) localVarQueryParameter["startTime"] = startTime;
|
|
70
77
|
if (endTime !== void 0 && endTime !== null) localVarQueryParameter["endTime"] = endTime;
|
|
71
78
|
if (current !== void 0 && current !== null) localVarQueryParameter["current"] = current;
|
|
@@ -76,12 +83,14 @@ const BfusdApiAxiosParamCreator = function(configuration) {
|
|
|
76
83
|
return {
|
|
77
84
|
endpoint: "/sapi/v1/bfusd/history/redemptionHistory",
|
|
78
85
|
method: "GET",
|
|
79
|
-
|
|
86
|
+
queryParams: localVarQueryParameter,
|
|
87
|
+
bodyParams: localVarBodyParameter,
|
|
80
88
|
timeUnit: _timeUnit
|
|
81
89
|
};
|
|
82
90
|
},
|
|
83
91
|
getBfusdRewardsHistory: async (startTime, endTime, current, size, recvWindow) => {
|
|
84
92
|
const localVarQueryParameter = {};
|
|
93
|
+
const localVarBodyParameter = {};
|
|
85
94
|
if (startTime !== void 0 && startTime !== null) localVarQueryParameter["startTime"] = startTime;
|
|
86
95
|
if (endTime !== void 0 && endTime !== null) localVarQueryParameter["endTime"] = endTime;
|
|
87
96
|
if (current !== void 0 && current !== null) localVarQueryParameter["current"] = current;
|
|
@@ -92,12 +101,14 @@ const BfusdApiAxiosParamCreator = function(configuration) {
|
|
|
92
101
|
return {
|
|
93
102
|
endpoint: "/sapi/v1/bfusd/history/rewardsHistory",
|
|
94
103
|
method: "GET",
|
|
95
|
-
|
|
104
|
+
queryParams: localVarQueryParameter,
|
|
105
|
+
bodyParams: localVarBodyParameter,
|
|
96
106
|
timeUnit: _timeUnit
|
|
97
107
|
};
|
|
98
108
|
},
|
|
99
109
|
getBfusdSubscriptionHistory: async (asset, startTime, endTime, current, size, recvWindow) => {
|
|
100
110
|
const localVarQueryParameter = {};
|
|
111
|
+
const localVarBodyParameter = {};
|
|
101
112
|
if (asset !== void 0 && asset !== null) localVarQueryParameter["asset"] = asset;
|
|
102
113
|
if (startTime !== void 0 && startTime !== null) localVarQueryParameter["startTime"] = startTime;
|
|
103
114
|
if (endTime !== void 0 && endTime !== null) localVarQueryParameter["endTime"] = endTime;
|
|
@@ -109,7 +120,8 @@ const BfusdApiAxiosParamCreator = function(configuration) {
|
|
|
109
120
|
return {
|
|
110
121
|
endpoint: "/sapi/v1/bfusd/history/subscriptionHistory",
|
|
111
122
|
method: "GET",
|
|
112
|
-
|
|
123
|
+
queryParams: localVarQueryParameter,
|
|
124
|
+
bodyParams: localVarBodyParameter,
|
|
113
125
|
timeUnit: _timeUnit
|
|
114
126
|
};
|
|
115
127
|
},
|
|
@@ -117,6 +129,7 @@ const BfusdApiAxiosParamCreator = function(configuration) {
|
|
|
117
129
|
assertParamExists("redeemBfusd", "amount", amount);
|
|
118
130
|
assertParamExists("redeemBfusd", "type", type);
|
|
119
131
|
const localVarQueryParameter = {};
|
|
132
|
+
const localVarBodyParameter = {};
|
|
120
133
|
if (amount !== void 0 && amount !== null) localVarQueryParameter["amount"] = amount;
|
|
121
134
|
if (type !== void 0 && type !== null) localVarQueryParameter["type"] = type;
|
|
122
135
|
if (recvWindow !== void 0 && recvWindow !== null) localVarQueryParameter["recvWindow"] = recvWindow;
|
|
@@ -125,7 +138,8 @@ const BfusdApiAxiosParamCreator = function(configuration) {
|
|
|
125
138
|
return {
|
|
126
139
|
endpoint: "/sapi/v1/bfusd/redeem",
|
|
127
140
|
method: "POST",
|
|
128
|
-
|
|
141
|
+
queryParams: localVarQueryParameter,
|
|
142
|
+
bodyParams: localVarBodyParameter,
|
|
129
143
|
timeUnit: _timeUnit
|
|
130
144
|
};
|
|
131
145
|
},
|
|
@@ -133,6 +147,7 @@ const BfusdApiAxiosParamCreator = function(configuration) {
|
|
|
133
147
|
assertParamExists("subscribeBfusd", "asset", asset);
|
|
134
148
|
assertParamExists("subscribeBfusd", "amount", amount);
|
|
135
149
|
const localVarQueryParameter = {};
|
|
150
|
+
const localVarBodyParameter = {};
|
|
136
151
|
if (asset !== void 0 && asset !== null) localVarQueryParameter["asset"] = asset;
|
|
137
152
|
if (amount !== void 0 && amount !== null) localVarQueryParameter["amount"] = amount;
|
|
138
153
|
if (recvWindow !== void 0 && recvWindow !== null) localVarQueryParameter["recvWindow"] = recvWindow;
|
|
@@ -141,7 +156,8 @@ const BfusdApiAxiosParamCreator = function(configuration) {
|
|
|
141
156
|
return {
|
|
142
157
|
endpoint: "/sapi/v1/bfusd/subscribe",
|
|
143
158
|
method: "POST",
|
|
144
|
-
|
|
159
|
+
queryParams: localVarQueryParameter,
|
|
160
|
+
bodyParams: localVarBodyParameter,
|
|
145
161
|
timeUnit: _timeUnit
|
|
146
162
|
};
|
|
147
163
|
}
|
|
@@ -170,7 +186,7 @@ var BfusdApi = class {
|
|
|
170
186
|
*/
|
|
171
187
|
async getBfusdAccount(requestParameters = {}) {
|
|
172
188
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.getBfusdAccount(requestParameters?.recvWindow);
|
|
173
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
189
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
174
190
|
}
|
|
175
191
|
/**
|
|
176
192
|
* Get BFUSD quota details including fast redemption quota and standard redemption quota.
|
|
@@ -186,7 +202,7 @@ var BfusdApi = class {
|
|
|
186
202
|
*/
|
|
187
203
|
async getBfusdQuotaDetails(requestParameters = {}) {
|
|
188
204
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.getBfusdQuotaDetails(requestParameters?.recvWindow);
|
|
189
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
205
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
190
206
|
}
|
|
191
207
|
/**
|
|
192
208
|
* Get BFUSD rate history sorted by descending order.
|
|
@@ -207,7 +223,7 @@ var BfusdApi = class {
|
|
|
207
223
|
*/
|
|
208
224
|
async getBfusdRateHistory(requestParameters = {}) {
|
|
209
225
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.getBfusdRateHistory(requestParameters?.startTime, requestParameters?.endTime, requestParameters?.current, requestParameters?.size, requestParameters?.recvWindow);
|
|
210
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
226
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
211
227
|
}
|
|
212
228
|
/**
|
|
213
229
|
* Get BFUSD redemption history.
|
|
@@ -228,7 +244,7 @@ var BfusdApi = class {
|
|
|
228
244
|
*/
|
|
229
245
|
async getBfusdRedemptionHistory(requestParameters = {}) {
|
|
230
246
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.getBfusdRedemptionHistory(requestParameters?.startTime, requestParameters?.endTime, requestParameters?.current, requestParameters?.size, requestParameters?.recvWindow);
|
|
231
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
247
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
232
248
|
}
|
|
233
249
|
/**
|
|
234
250
|
* Get BFUSD rewards history.
|
|
@@ -249,7 +265,7 @@ var BfusdApi = class {
|
|
|
249
265
|
*/
|
|
250
266
|
async getBfusdRewardsHistory(requestParameters = {}) {
|
|
251
267
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.getBfusdRewardsHistory(requestParameters?.startTime, requestParameters?.endTime, requestParameters?.current, requestParameters?.size, requestParameters?.recvWindow);
|
|
252
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
268
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
253
269
|
}
|
|
254
270
|
/**
|
|
255
271
|
* Get BFUSD subscription history
|
|
@@ -270,7 +286,7 @@ var BfusdApi = class {
|
|
|
270
286
|
*/
|
|
271
287
|
async getBfusdSubscriptionHistory(requestParameters = {}) {
|
|
272
288
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.getBfusdSubscriptionHistory(requestParameters?.asset, requestParameters?.startTime, requestParameters?.endTime, requestParameters?.current, requestParameters?.size, requestParameters?.recvWindow);
|
|
273
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
289
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
274
290
|
}
|
|
275
291
|
/**
|
|
276
292
|
* Redeem BFUSD to USDT
|
|
@@ -288,7 +304,7 @@ var BfusdApi = class {
|
|
|
288
304
|
*/
|
|
289
305
|
async redeemBfusd(requestParameters) {
|
|
290
306
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.redeemBfusd(requestParameters?.amount, requestParameters?.type, requestParameters?.recvWindow);
|
|
291
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
307
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
292
308
|
}
|
|
293
309
|
/**
|
|
294
310
|
* Subscribe BFUSD
|
|
@@ -306,7 +322,7 @@ var BfusdApi = class {
|
|
|
306
322
|
*/
|
|
307
323
|
async subscribeBfusd(requestParameters) {
|
|
308
324
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.subscribeBfusd(requestParameters?.asset, requestParameters?.amount, requestParameters?.recvWindow);
|
|
309
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
325
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
310
326
|
}
|
|
311
327
|
};
|
|
312
328
|
|
|
@@ -331,6 +347,7 @@ const FlexibleLockedApiAxiosParamCreator = function(configuration) {
|
|
|
331
347
|
return {
|
|
332
348
|
getCollateralRecord: async (productId, startTime, endTime, current, size, recvWindow) => {
|
|
333
349
|
const localVarQueryParameter = {};
|
|
350
|
+
const localVarBodyParameter = {};
|
|
334
351
|
if (productId !== void 0 && productId !== null) localVarQueryParameter["productId"] = productId;
|
|
335
352
|
if (startTime !== void 0 && startTime !== null) localVarQueryParameter["startTime"] = startTime;
|
|
336
353
|
if (endTime !== void 0 && endTime !== null) localVarQueryParameter["endTime"] = endTime;
|
|
@@ -342,13 +359,15 @@ const FlexibleLockedApiAxiosParamCreator = function(configuration) {
|
|
|
342
359
|
return {
|
|
343
360
|
endpoint: "/sapi/v1/simple-earn/flexible/history/collateralRecord",
|
|
344
361
|
method: "GET",
|
|
345
|
-
|
|
362
|
+
queryParams: localVarQueryParameter,
|
|
363
|
+
bodyParams: localVarBodyParameter,
|
|
346
364
|
timeUnit: _timeUnit
|
|
347
365
|
};
|
|
348
366
|
},
|
|
349
367
|
getFlexiblePersonalLeftQuota: async (productId, recvWindow) => {
|
|
350
368
|
assertParamExists("getFlexiblePersonalLeftQuota", "productId", productId);
|
|
351
369
|
const localVarQueryParameter = {};
|
|
370
|
+
const localVarBodyParameter = {};
|
|
352
371
|
if (productId !== void 0 && productId !== null) localVarQueryParameter["productId"] = productId;
|
|
353
372
|
if (recvWindow !== void 0 && recvWindow !== null) localVarQueryParameter["recvWindow"] = recvWindow;
|
|
354
373
|
let _timeUnit;
|
|
@@ -356,12 +375,14 @@ const FlexibleLockedApiAxiosParamCreator = function(configuration) {
|
|
|
356
375
|
return {
|
|
357
376
|
endpoint: "/sapi/v1/simple-earn/flexible/personalLeftQuota",
|
|
358
377
|
method: "GET",
|
|
359
|
-
|
|
378
|
+
queryParams: localVarQueryParameter,
|
|
379
|
+
bodyParams: localVarBodyParameter,
|
|
360
380
|
timeUnit: _timeUnit
|
|
361
381
|
};
|
|
362
382
|
},
|
|
363
383
|
getFlexibleProductPosition: async (asset, productId, current, size, recvWindow) => {
|
|
364
384
|
const localVarQueryParameter = {};
|
|
385
|
+
const localVarBodyParameter = {};
|
|
365
386
|
if (asset !== void 0 && asset !== null) localVarQueryParameter["asset"] = asset;
|
|
366
387
|
if (productId !== void 0 && productId !== null) localVarQueryParameter["productId"] = productId;
|
|
367
388
|
if (current !== void 0 && current !== null) localVarQueryParameter["current"] = current;
|
|
@@ -372,12 +393,14 @@ const FlexibleLockedApiAxiosParamCreator = function(configuration) {
|
|
|
372
393
|
return {
|
|
373
394
|
endpoint: "/sapi/v1/simple-earn/flexible/position",
|
|
374
395
|
method: "GET",
|
|
375
|
-
|
|
396
|
+
queryParams: localVarQueryParameter,
|
|
397
|
+
bodyParams: localVarBodyParameter,
|
|
376
398
|
timeUnit: _timeUnit
|
|
377
399
|
};
|
|
378
400
|
},
|
|
379
401
|
getFlexibleRedemptionRecord: async (productId, redeemId, asset, startTime, endTime, current, size, recvWindow) => {
|
|
380
402
|
const localVarQueryParameter = {};
|
|
403
|
+
const localVarBodyParameter = {};
|
|
381
404
|
if (productId !== void 0 && productId !== null) localVarQueryParameter["productId"] = productId;
|
|
382
405
|
if (redeemId !== void 0 && redeemId !== null) localVarQueryParameter["redeemId"] = redeemId;
|
|
383
406
|
if (asset !== void 0 && asset !== null) localVarQueryParameter["asset"] = asset;
|
|
@@ -391,13 +414,15 @@ const FlexibleLockedApiAxiosParamCreator = function(configuration) {
|
|
|
391
414
|
return {
|
|
392
415
|
endpoint: "/sapi/v1/simple-earn/flexible/history/redemptionRecord",
|
|
393
416
|
method: "GET",
|
|
394
|
-
|
|
417
|
+
queryParams: localVarQueryParameter,
|
|
418
|
+
bodyParams: localVarBodyParameter,
|
|
395
419
|
timeUnit: _timeUnit
|
|
396
420
|
};
|
|
397
421
|
},
|
|
398
422
|
getFlexibleRewardsHistory: async (type, productId, asset, startTime, endTime, current, size, recvWindow) => {
|
|
399
423
|
assertParamExists("getFlexibleRewardsHistory", "type", type);
|
|
400
424
|
const localVarQueryParameter = {};
|
|
425
|
+
const localVarBodyParameter = {};
|
|
401
426
|
if (productId !== void 0 && productId !== null) localVarQueryParameter["productId"] = productId;
|
|
402
427
|
if (asset !== void 0 && asset !== null) localVarQueryParameter["asset"] = asset;
|
|
403
428
|
if (startTime !== void 0 && startTime !== null) localVarQueryParameter["startTime"] = startTime;
|
|
@@ -411,7 +436,8 @@ const FlexibleLockedApiAxiosParamCreator = function(configuration) {
|
|
|
411
436
|
return {
|
|
412
437
|
endpoint: "/sapi/v1/simple-earn/flexible/history/rewardsRecord",
|
|
413
438
|
method: "GET",
|
|
414
|
-
|
|
439
|
+
queryParams: localVarQueryParameter,
|
|
440
|
+
bodyParams: localVarBodyParameter,
|
|
415
441
|
timeUnit: _timeUnit
|
|
416
442
|
};
|
|
417
443
|
},
|
|
@@ -419,6 +445,7 @@ const FlexibleLockedApiAxiosParamCreator = function(configuration) {
|
|
|
419
445
|
assertParamExists("getFlexibleSubscriptionPreview", "productId", productId);
|
|
420
446
|
assertParamExists("getFlexibleSubscriptionPreview", "amount", amount);
|
|
421
447
|
const localVarQueryParameter = {};
|
|
448
|
+
const localVarBodyParameter = {};
|
|
422
449
|
if (productId !== void 0 && productId !== null) localVarQueryParameter["productId"] = productId;
|
|
423
450
|
if (amount !== void 0 && amount !== null) localVarQueryParameter["amount"] = amount;
|
|
424
451
|
if (recvWindow !== void 0 && recvWindow !== null) localVarQueryParameter["recvWindow"] = recvWindow;
|
|
@@ -427,12 +454,14 @@ const FlexibleLockedApiAxiosParamCreator = function(configuration) {
|
|
|
427
454
|
return {
|
|
428
455
|
endpoint: "/sapi/v1/simple-earn/flexible/subscriptionPreview",
|
|
429
456
|
method: "GET",
|
|
430
|
-
|
|
457
|
+
queryParams: localVarQueryParameter,
|
|
458
|
+
bodyParams: localVarBodyParameter,
|
|
431
459
|
timeUnit: _timeUnit
|
|
432
460
|
};
|
|
433
461
|
},
|
|
434
462
|
getFlexibleSubscriptionRecord: async (productId, purchaseId, asset, startTime, endTime, current, size, recvWindow) => {
|
|
435
463
|
const localVarQueryParameter = {};
|
|
464
|
+
const localVarBodyParameter = {};
|
|
436
465
|
if (productId !== void 0 && productId !== null) localVarQueryParameter["productId"] = productId;
|
|
437
466
|
if (purchaseId !== void 0 && purchaseId !== null) localVarQueryParameter["purchaseId"] = purchaseId;
|
|
438
467
|
if (asset !== void 0 && asset !== null) localVarQueryParameter["asset"] = asset;
|
|
@@ -446,13 +475,15 @@ const FlexibleLockedApiAxiosParamCreator = function(configuration) {
|
|
|
446
475
|
return {
|
|
447
476
|
endpoint: "/sapi/v1/simple-earn/flexible/history/subscriptionRecord",
|
|
448
477
|
method: "GET",
|
|
449
|
-
|
|
478
|
+
queryParams: localVarQueryParameter,
|
|
479
|
+
bodyParams: localVarBodyParameter,
|
|
450
480
|
timeUnit: _timeUnit
|
|
451
481
|
};
|
|
452
482
|
},
|
|
453
483
|
getLockedPersonalLeftQuota: async (projectId, recvWindow) => {
|
|
454
484
|
assertParamExists("getLockedPersonalLeftQuota", "projectId", projectId);
|
|
455
485
|
const localVarQueryParameter = {};
|
|
486
|
+
const localVarBodyParameter = {};
|
|
456
487
|
if (projectId !== void 0 && projectId !== null) localVarQueryParameter["projectId"] = projectId;
|
|
457
488
|
if (recvWindow !== void 0 && recvWindow !== null) localVarQueryParameter["recvWindow"] = recvWindow;
|
|
458
489
|
let _timeUnit;
|
|
@@ -460,12 +491,14 @@ const FlexibleLockedApiAxiosParamCreator = function(configuration) {
|
|
|
460
491
|
return {
|
|
461
492
|
endpoint: "/sapi/v1/simple-earn/locked/personalLeftQuota",
|
|
462
493
|
method: "GET",
|
|
463
|
-
|
|
494
|
+
queryParams: localVarQueryParameter,
|
|
495
|
+
bodyParams: localVarBodyParameter,
|
|
464
496
|
timeUnit: _timeUnit
|
|
465
497
|
};
|
|
466
498
|
},
|
|
467
499
|
getLockedProductPosition: async (asset, positionId, projectId, current, size, recvWindow) => {
|
|
468
500
|
const localVarQueryParameter = {};
|
|
501
|
+
const localVarBodyParameter = {};
|
|
469
502
|
if (asset !== void 0 && asset !== null) localVarQueryParameter["asset"] = asset;
|
|
470
503
|
if (positionId !== void 0 && positionId !== null) localVarQueryParameter["positionId"] = positionId;
|
|
471
504
|
if (projectId !== void 0 && projectId !== null) localVarQueryParameter["projectId"] = projectId;
|
|
@@ -477,12 +510,14 @@ const FlexibleLockedApiAxiosParamCreator = function(configuration) {
|
|
|
477
510
|
return {
|
|
478
511
|
endpoint: "/sapi/v1/simple-earn/locked/position",
|
|
479
512
|
method: "GET",
|
|
480
|
-
|
|
513
|
+
queryParams: localVarQueryParameter,
|
|
514
|
+
bodyParams: localVarBodyParameter,
|
|
481
515
|
timeUnit: _timeUnit
|
|
482
516
|
};
|
|
483
517
|
},
|
|
484
518
|
getLockedRedemptionRecord: async (positionId, redeemId, asset, startTime, endTime, current, size, recvWindow) => {
|
|
485
519
|
const localVarQueryParameter = {};
|
|
520
|
+
const localVarBodyParameter = {};
|
|
486
521
|
if (positionId !== void 0 && positionId !== null) localVarQueryParameter["positionId"] = positionId;
|
|
487
522
|
if (redeemId !== void 0 && redeemId !== null) localVarQueryParameter["redeemId"] = redeemId;
|
|
488
523
|
if (asset !== void 0 && asset !== null) localVarQueryParameter["asset"] = asset;
|
|
@@ -496,12 +531,14 @@ const FlexibleLockedApiAxiosParamCreator = function(configuration) {
|
|
|
496
531
|
return {
|
|
497
532
|
endpoint: "/sapi/v1/simple-earn/locked/history/redemptionRecord",
|
|
498
533
|
method: "GET",
|
|
499
|
-
|
|
534
|
+
queryParams: localVarQueryParameter,
|
|
535
|
+
bodyParams: localVarBodyParameter,
|
|
500
536
|
timeUnit: _timeUnit
|
|
501
537
|
};
|
|
502
538
|
},
|
|
503
539
|
getLockedRewardsHistory: async (positionId, asset, startTime, endTime, current, size, recvWindow) => {
|
|
504
540
|
const localVarQueryParameter = {};
|
|
541
|
+
const localVarBodyParameter = {};
|
|
505
542
|
if (positionId !== void 0 && positionId !== null) localVarQueryParameter["positionId"] = positionId;
|
|
506
543
|
if (asset !== void 0 && asset !== null) localVarQueryParameter["asset"] = asset;
|
|
507
544
|
if (startTime !== void 0 && startTime !== null) localVarQueryParameter["startTime"] = startTime;
|
|
@@ -514,7 +551,8 @@ const FlexibleLockedApiAxiosParamCreator = function(configuration) {
|
|
|
514
551
|
return {
|
|
515
552
|
endpoint: "/sapi/v1/simple-earn/locked/history/rewardsRecord",
|
|
516
553
|
method: "GET",
|
|
517
|
-
|
|
554
|
+
queryParams: localVarQueryParameter,
|
|
555
|
+
bodyParams: localVarBodyParameter,
|
|
518
556
|
timeUnit: _timeUnit
|
|
519
557
|
};
|
|
520
558
|
},
|
|
@@ -522,6 +560,7 @@ const FlexibleLockedApiAxiosParamCreator = function(configuration) {
|
|
|
522
560
|
assertParamExists("getLockedSubscriptionPreview", "projectId", projectId);
|
|
523
561
|
assertParamExists("getLockedSubscriptionPreview", "amount", amount);
|
|
524
562
|
const localVarQueryParameter = {};
|
|
563
|
+
const localVarBodyParameter = {};
|
|
525
564
|
if (projectId !== void 0 && projectId !== null) localVarQueryParameter["projectId"] = projectId;
|
|
526
565
|
if (amount !== void 0 && amount !== null) localVarQueryParameter["amount"] = amount;
|
|
527
566
|
if (autoSubscribe !== void 0 && autoSubscribe !== null) localVarQueryParameter["autoSubscribe"] = autoSubscribe;
|
|
@@ -531,12 +570,14 @@ const FlexibleLockedApiAxiosParamCreator = function(configuration) {
|
|
|
531
570
|
return {
|
|
532
571
|
endpoint: "/sapi/v1/simple-earn/locked/subscriptionPreview",
|
|
533
572
|
method: "GET",
|
|
534
|
-
|
|
573
|
+
queryParams: localVarQueryParameter,
|
|
574
|
+
bodyParams: localVarBodyParameter,
|
|
535
575
|
timeUnit: _timeUnit
|
|
536
576
|
};
|
|
537
577
|
},
|
|
538
578
|
getLockedSubscriptionRecord: async (purchaseId, asset, startTime, endTime, current, size, recvWindow) => {
|
|
539
579
|
const localVarQueryParameter = {};
|
|
580
|
+
const localVarBodyParameter = {};
|
|
540
581
|
if (purchaseId !== void 0 && purchaseId !== null) localVarQueryParameter["purchaseId"] = purchaseId;
|
|
541
582
|
if (asset !== void 0 && asset !== null) localVarQueryParameter["asset"] = asset;
|
|
542
583
|
if (startTime !== void 0 && startTime !== null) localVarQueryParameter["startTime"] = startTime;
|
|
@@ -549,13 +590,15 @@ const FlexibleLockedApiAxiosParamCreator = function(configuration) {
|
|
|
549
590
|
return {
|
|
550
591
|
endpoint: "/sapi/v1/simple-earn/locked/history/subscriptionRecord",
|
|
551
592
|
method: "GET",
|
|
552
|
-
|
|
593
|
+
queryParams: localVarQueryParameter,
|
|
594
|
+
bodyParams: localVarBodyParameter,
|
|
553
595
|
timeUnit: _timeUnit
|
|
554
596
|
};
|
|
555
597
|
},
|
|
556
598
|
getRateHistory: async (productId, aprPeriod, startTime, endTime, current, size, recvWindow) => {
|
|
557
599
|
assertParamExists("getRateHistory", "productId", productId);
|
|
558
600
|
const localVarQueryParameter = {};
|
|
601
|
+
const localVarBodyParameter = {};
|
|
559
602
|
if (productId !== void 0 && productId !== null) localVarQueryParameter["productId"] = productId;
|
|
560
603
|
if (aprPeriod !== void 0 && aprPeriod !== null) localVarQueryParameter["aprPeriod"] = aprPeriod;
|
|
561
604
|
if (startTime !== void 0 && startTime !== null) localVarQueryParameter["startTime"] = startTime;
|
|
@@ -568,12 +611,14 @@ const FlexibleLockedApiAxiosParamCreator = function(configuration) {
|
|
|
568
611
|
return {
|
|
569
612
|
endpoint: "/sapi/v1/simple-earn/flexible/history/rateHistory",
|
|
570
613
|
method: "GET",
|
|
571
|
-
|
|
614
|
+
queryParams: localVarQueryParameter,
|
|
615
|
+
bodyParams: localVarBodyParameter,
|
|
572
616
|
timeUnit: _timeUnit
|
|
573
617
|
};
|
|
574
618
|
},
|
|
575
619
|
getSimpleEarnFlexibleProductList: async (asset, current, size, recvWindow) => {
|
|
576
620
|
const localVarQueryParameter = {};
|
|
621
|
+
const localVarBodyParameter = {};
|
|
577
622
|
if (asset !== void 0 && asset !== null) localVarQueryParameter["asset"] = asset;
|
|
578
623
|
if (current !== void 0 && current !== null) localVarQueryParameter["current"] = current;
|
|
579
624
|
if (size !== void 0 && size !== null) localVarQueryParameter["size"] = size;
|
|
@@ -583,12 +628,14 @@ const FlexibleLockedApiAxiosParamCreator = function(configuration) {
|
|
|
583
628
|
return {
|
|
584
629
|
endpoint: "/sapi/v1/simple-earn/flexible/list",
|
|
585
630
|
method: "GET",
|
|
586
|
-
|
|
631
|
+
queryParams: localVarQueryParameter,
|
|
632
|
+
bodyParams: localVarBodyParameter,
|
|
587
633
|
timeUnit: _timeUnit
|
|
588
634
|
};
|
|
589
635
|
},
|
|
590
636
|
getSimpleEarnLockedProductList: async (asset, current, size, recvWindow) => {
|
|
591
637
|
const localVarQueryParameter = {};
|
|
638
|
+
const localVarBodyParameter = {};
|
|
592
639
|
if (asset !== void 0 && asset !== null) localVarQueryParameter["asset"] = asset;
|
|
593
640
|
if (current !== void 0 && current !== null) localVarQueryParameter["current"] = current;
|
|
594
641
|
if (size !== void 0 && size !== null) localVarQueryParameter["size"] = size;
|
|
@@ -598,13 +645,15 @@ const FlexibleLockedApiAxiosParamCreator = function(configuration) {
|
|
|
598
645
|
return {
|
|
599
646
|
endpoint: "/sapi/v1/simple-earn/locked/list",
|
|
600
647
|
method: "GET",
|
|
601
|
-
|
|
648
|
+
queryParams: localVarQueryParameter,
|
|
649
|
+
bodyParams: localVarBodyParameter,
|
|
602
650
|
timeUnit: _timeUnit
|
|
603
651
|
};
|
|
604
652
|
},
|
|
605
653
|
redeemFlexibleProduct: async (productId, redeemAll, amount, destAccount, recvWindow) => {
|
|
606
654
|
assertParamExists("redeemFlexibleProduct", "productId", productId);
|
|
607
655
|
const localVarQueryParameter = {};
|
|
656
|
+
const localVarBodyParameter = {};
|
|
608
657
|
if (productId !== void 0 && productId !== null) localVarQueryParameter["productId"] = productId;
|
|
609
658
|
if (redeemAll !== void 0 && redeemAll !== null) localVarQueryParameter["redeemAll"] = redeemAll;
|
|
610
659
|
if (amount !== void 0 && amount !== null) localVarQueryParameter["amount"] = amount;
|
|
@@ -615,13 +664,15 @@ const FlexibleLockedApiAxiosParamCreator = function(configuration) {
|
|
|
615
664
|
return {
|
|
616
665
|
endpoint: "/sapi/v1/simple-earn/flexible/redeem",
|
|
617
666
|
method: "POST",
|
|
618
|
-
|
|
667
|
+
queryParams: localVarQueryParameter,
|
|
668
|
+
bodyParams: localVarBodyParameter,
|
|
619
669
|
timeUnit: _timeUnit
|
|
620
670
|
};
|
|
621
671
|
},
|
|
622
672
|
redeemLockedProduct: async (positionId, recvWindow) => {
|
|
623
673
|
assertParamExists("redeemLockedProduct", "positionId", positionId);
|
|
624
674
|
const localVarQueryParameter = {};
|
|
675
|
+
const localVarBodyParameter = {};
|
|
625
676
|
if (positionId !== void 0 && positionId !== null) localVarQueryParameter["positionId"] = positionId;
|
|
626
677
|
if (recvWindow !== void 0 && recvWindow !== null) localVarQueryParameter["recvWindow"] = recvWindow;
|
|
627
678
|
let _timeUnit;
|
|
@@ -629,7 +680,8 @@ const FlexibleLockedApiAxiosParamCreator = function(configuration) {
|
|
|
629
680
|
return {
|
|
630
681
|
endpoint: "/sapi/v1/simple-earn/locked/redeem",
|
|
631
682
|
method: "POST",
|
|
632
|
-
|
|
683
|
+
queryParams: localVarQueryParameter,
|
|
684
|
+
bodyParams: localVarBodyParameter,
|
|
633
685
|
timeUnit: _timeUnit
|
|
634
686
|
};
|
|
635
687
|
},
|
|
@@ -637,6 +689,7 @@ const FlexibleLockedApiAxiosParamCreator = function(configuration) {
|
|
|
637
689
|
assertParamExists("setFlexibleAutoSubscribe", "productId", productId);
|
|
638
690
|
assertParamExists("setFlexibleAutoSubscribe", "autoSubscribe", autoSubscribe);
|
|
639
691
|
const localVarQueryParameter = {};
|
|
692
|
+
const localVarBodyParameter = {};
|
|
640
693
|
if (productId !== void 0 && productId !== null) localVarQueryParameter["productId"] = productId;
|
|
641
694
|
if (autoSubscribe !== void 0 && autoSubscribe !== null) localVarQueryParameter["autoSubscribe"] = autoSubscribe;
|
|
642
695
|
if (recvWindow !== void 0 && recvWindow !== null) localVarQueryParameter["recvWindow"] = recvWindow;
|
|
@@ -645,7 +698,8 @@ const FlexibleLockedApiAxiosParamCreator = function(configuration) {
|
|
|
645
698
|
return {
|
|
646
699
|
endpoint: "/sapi/v1/simple-earn/flexible/setAutoSubscribe",
|
|
647
700
|
method: "POST",
|
|
648
|
-
|
|
701
|
+
queryParams: localVarQueryParameter,
|
|
702
|
+
bodyParams: localVarBodyParameter,
|
|
649
703
|
timeUnit: _timeUnit
|
|
650
704
|
};
|
|
651
705
|
},
|
|
@@ -653,6 +707,7 @@ const FlexibleLockedApiAxiosParamCreator = function(configuration) {
|
|
|
653
707
|
assertParamExists("setLockedAutoSubscribe", "positionId", positionId);
|
|
654
708
|
assertParamExists("setLockedAutoSubscribe", "autoSubscribe", autoSubscribe);
|
|
655
709
|
const localVarQueryParameter = {};
|
|
710
|
+
const localVarBodyParameter = {};
|
|
656
711
|
if (positionId !== void 0 && positionId !== null) localVarQueryParameter["positionId"] = positionId;
|
|
657
712
|
if (autoSubscribe !== void 0 && autoSubscribe !== null) localVarQueryParameter["autoSubscribe"] = autoSubscribe;
|
|
658
713
|
if (recvWindow !== void 0 && recvWindow !== null) localVarQueryParameter["recvWindow"] = recvWindow;
|
|
@@ -661,7 +716,8 @@ const FlexibleLockedApiAxiosParamCreator = function(configuration) {
|
|
|
661
716
|
return {
|
|
662
717
|
endpoint: "/sapi/v1/simple-earn/locked/setAutoSubscribe",
|
|
663
718
|
method: "POST",
|
|
664
|
-
|
|
719
|
+
queryParams: localVarQueryParameter,
|
|
720
|
+
bodyParams: localVarBodyParameter,
|
|
665
721
|
timeUnit: _timeUnit
|
|
666
722
|
};
|
|
667
723
|
},
|
|
@@ -669,6 +725,7 @@ const FlexibleLockedApiAxiosParamCreator = function(configuration) {
|
|
|
669
725
|
assertParamExists("setLockedProductRedeemOption", "positionId", positionId);
|
|
670
726
|
assertParamExists("setLockedProductRedeemOption", "redeemTo", redeemTo);
|
|
671
727
|
const localVarQueryParameter = {};
|
|
728
|
+
const localVarBodyParameter = {};
|
|
672
729
|
if (positionId !== void 0 && positionId !== null) localVarQueryParameter["positionId"] = positionId;
|
|
673
730
|
if (redeemTo !== void 0 && redeemTo !== null) localVarQueryParameter["redeemTo"] = redeemTo;
|
|
674
731
|
if (recvWindow !== void 0 && recvWindow !== null) localVarQueryParameter["recvWindow"] = recvWindow;
|
|
@@ -677,19 +734,22 @@ const FlexibleLockedApiAxiosParamCreator = function(configuration) {
|
|
|
677
734
|
return {
|
|
678
735
|
endpoint: "/sapi/v1/simple-earn/locked/setRedeemOption",
|
|
679
736
|
method: "POST",
|
|
680
|
-
|
|
737
|
+
queryParams: localVarQueryParameter,
|
|
738
|
+
bodyParams: localVarBodyParameter,
|
|
681
739
|
timeUnit: _timeUnit
|
|
682
740
|
};
|
|
683
741
|
},
|
|
684
742
|
simpleAccount: async (recvWindow) => {
|
|
685
743
|
const localVarQueryParameter = {};
|
|
744
|
+
const localVarBodyParameter = {};
|
|
686
745
|
if (recvWindow !== void 0 && recvWindow !== null) localVarQueryParameter["recvWindow"] = recvWindow;
|
|
687
746
|
let _timeUnit;
|
|
688
747
|
if ("timeUnit" in configuration) _timeUnit = configuration.timeUnit;
|
|
689
748
|
return {
|
|
690
749
|
endpoint: "/sapi/v1/simple-earn/account",
|
|
691
750
|
method: "GET",
|
|
692
|
-
|
|
751
|
+
queryParams: localVarQueryParameter,
|
|
752
|
+
bodyParams: localVarBodyParameter,
|
|
693
753
|
timeUnit: _timeUnit
|
|
694
754
|
};
|
|
695
755
|
},
|
|
@@ -697,6 +757,7 @@ const FlexibleLockedApiAxiosParamCreator = function(configuration) {
|
|
|
697
757
|
assertParamExists("subscribeFlexibleProduct", "productId", productId);
|
|
698
758
|
assertParamExists("subscribeFlexibleProduct", "amount", amount);
|
|
699
759
|
const localVarQueryParameter = {};
|
|
760
|
+
const localVarBodyParameter = {};
|
|
700
761
|
if (productId !== void 0 && productId !== null) localVarQueryParameter["productId"] = productId;
|
|
701
762
|
if (amount !== void 0 && amount !== null) localVarQueryParameter["amount"] = amount;
|
|
702
763
|
if (autoSubscribe !== void 0 && autoSubscribe !== null) localVarQueryParameter["autoSubscribe"] = autoSubscribe;
|
|
@@ -707,7 +768,8 @@ const FlexibleLockedApiAxiosParamCreator = function(configuration) {
|
|
|
707
768
|
return {
|
|
708
769
|
endpoint: "/sapi/v1/simple-earn/flexible/subscribe",
|
|
709
770
|
method: "POST",
|
|
710
|
-
|
|
771
|
+
queryParams: localVarQueryParameter,
|
|
772
|
+
bodyParams: localVarBodyParameter,
|
|
711
773
|
timeUnit: _timeUnit
|
|
712
774
|
};
|
|
713
775
|
},
|
|
@@ -715,6 +777,7 @@ const FlexibleLockedApiAxiosParamCreator = function(configuration) {
|
|
|
715
777
|
assertParamExists("subscribeLockedProduct", "projectId", projectId);
|
|
716
778
|
assertParamExists("subscribeLockedProduct", "amount", amount);
|
|
717
779
|
const localVarQueryParameter = {};
|
|
780
|
+
const localVarBodyParameter = {};
|
|
718
781
|
if (projectId !== void 0 && projectId !== null) localVarQueryParameter["projectId"] = projectId;
|
|
719
782
|
if (amount !== void 0 && amount !== null) localVarQueryParameter["amount"] = amount;
|
|
720
783
|
if (autoSubscribe !== void 0 && autoSubscribe !== null) localVarQueryParameter["autoSubscribe"] = autoSubscribe;
|
|
@@ -726,7 +789,8 @@ const FlexibleLockedApiAxiosParamCreator = function(configuration) {
|
|
|
726
789
|
return {
|
|
727
790
|
endpoint: "/sapi/v1/simple-earn/locked/subscribe",
|
|
728
791
|
method: "POST",
|
|
729
|
-
|
|
792
|
+
queryParams: localVarQueryParameter,
|
|
793
|
+
bodyParams: localVarBodyParameter,
|
|
730
794
|
timeUnit: _timeUnit
|
|
731
795
|
};
|
|
732
796
|
}
|
|
@@ -760,7 +824,7 @@ var FlexibleLockedApi = class {
|
|
|
760
824
|
*/
|
|
761
825
|
async getCollateralRecord(requestParameters = {}) {
|
|
762
826
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.getCollateralRecord(requestParameters?.productId, requestParameters?.startTime, requestParameters?.endTime, requestParameters?.current, requestParameters?.size, requestParameters?.recvWindow);
|
|
763
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
827
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
764
828
|
}
|
|
765
829
|
/**
|
|
766
830
|
* Get Flexible Personal Left Quota
|
|
@@ -776,7 +840,7 @@ var FlexibleLockedApi = class {
|
|
|
776
840
|
*/
|
|
777
841
|
async getFlexiblePersonalLeftQuota(requestParameters) {
|
|
778
842
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.getFlexiblePersonalLeftQuota(requestParameters?.productId, requestParameters?.recvWindow);
|
|
779
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
843
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
780
844
|
}
|
|
781
845
|
/**
|
|
782
846
|
* Get Flexible Product Position
|
|
@@ -792,7 +856,7 @@ var FlexibleLockedApi = class {
|
|
|
792
856
|
*/
|
|
793
857
|
async getFlexibleProductPosition(requestParameters = {}) {
|
|
794
858
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.getFlexibleProductPosition(requestParameters?.asset, requestParameters?.productId, requestParameters?.current, requestParameters?.size, requestParameters?.recvWindow);
|
|
795
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
859
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
796
860
|
}
|
|
797
861
|
/**
|
|
798
862
|
* Get Flexible Redemption Record
|
|
@@ -813,7 +877,7 @@ var FlexibleLockedApi = class {
|
|
|
813
877
|
*/
|
|
814
878
|
async getFlexibleRedemptionRecord(requestParameters = {}) {
|
|
815
879
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.getFlexibleRedemptionRecord(requestParameters?.productId, requestParameters?.redeemId, requestParameters?.asset, requestParameters?.startTime, requestParameters?.endTime, requestParameters?.current, requestParameters?.size, requestParameters?.recvWindow);
|
|
816
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
880
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
817
881
|
}
|
|
818
882
|
/**
|
|
819
883
|
* Get Flexible Rewards History
|
|
@@ -834,7 +898,7 @@ var FlexibleLockedApi = class {
|
|
|
834
898
|
*/
|
|
835
899
|
async getFlexibleRewardsHistory(requestParameters) {
|
|
836
900
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.getFlexibleRewardsHistory(requestParameters?.type, requestParameters?.productId, requestParameters?.asset, requestParameters?.startTime, requestParameters?.endTime, requestParameters?.current, requestParameters?.size, requestParameters?.recvWindow);
|
|
837
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
901
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
838
902
|
}
|
|
839
903
|
/**
|
|
840
904
|
* Get Flexible Subscription Preview
|
|
@@ -850,7 +914,7 @@ var FlexibleLockedApi = class {
|
|
|
850
914
|
*/
|
|
851
915
|
async getFlexibleSubscriptionPreview(requestParameters) {
|
|
852
916
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.getFlexibleSubscriptionPreview(requestParameters?.productId, requestParameters?.amount, requestParameters?.recvWindow);
|
|
853
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
917
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
854
918
|
}
|
|
855
919
|
/**
|
|
856
920
|
* Get Flexible Subscription Record
|
|
@@ -871,7 +935,7 @@ var FlexibleLockedApi = class {
|
|
|
871
935
|
*/
|
|
872
936
|
async getFlexibleSubscriptionRecord(requestParameters = {}) {
|
|
873
937
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.getFlexibleSubscriptionRecord(requestParameters?.productId, requestParameters?.purchaseId, requestParameters?.asset, requestParameters?.startTime, requestParameters?.endTime, requestParameters?.current, requestParameters?.size, requestParameters?.recvWindow);
|
|
874
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
938
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
875
939
|
}
|
|
876
940
|
/**
|
|
877
941
|
* Get Locked Personal Left Quota
|
|
@@ -887,7 +951,7 @@ var FlexibleLockedApi = class {
|
|
|
887
951
|
*/
|
|
888
952
|
async getLockedPersonalLeftQuota(requestParameters) {
|
|
889
953
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.getLockedPersonalLeftQuota(requestParameters?.projectId, requestParameters?.recvWindow);
|
|
890
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
954
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
891
955
|
}
|
|
892
956
|
/**
|
|
893
957
|
* Get Locked Product Position
|
|
@@ -903,7 +967,7 @@ var FlexibleLockedApi = class {
|
|
|
903
967
|
*/
|
|
904
968
|
async getLockedProductPosition(requestParameters = {}) {
|
|
905
969
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.getLockedProductPosition(requestParameters?.asset, requestParameters?.positionId, requestParameters?.projectId, requestParameters?.current, requestParameters?.size, requestParameters?.recvWindow);
|
|
906
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
970
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
907
971
|
}
|
|
908
972
|
/**
|
|
909
973
|
* Get Locked Redemption Record
|
|
@@ -924,7 +988,7 @@ var FlexibleLockedApi = class {
|
|
|
924
988
|
*/
|
|
925
989
|
async getLockedRedemptionRecord(requestParameters = {}) {
|
|
926
990
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.getLockedRedemptionRecord(requestParameters?.positionId, requestParameters?.redeemId, requestParameters?.asset, requestParameters?.startTime, requestParameters?.endTime, requestParameters?.current, requestParameters?.size, requestParameters?.recvWindow);
|
|
927
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
991
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
928
992
|
}
|
|
929
993
|
/**
|
|
930
994
|
* Get Locked Rewards History
|
|
@@ -945,7 +1009,7 @@ var FlexibleLockedApi = class {
|
|
|
945
1009
|
*/
|
|
946
1010
|
async getLockedRewardsHistory(requestParameters = {}) {
|
|
947
1011
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.getLockedRewardsHistory(requestParameters?.positionId, requestParameters?.asset, requestParameters?.startTime, requestParameters?.endTime, requestParameters?.current, requestParameters?.size, requestParameters?.recvWindow);
|
|
948
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
1012
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
949
1013
|
}
|
|
950
1014
|
/**
|
|
951
1015
|
* Get Locked Subscription Preview
|
|
@@ -961,7 +1025,7 @@ var FlexibleLockedApi = class {
|
|
|
961
1025
|
*/
|
|
962
1026
|
async getLockedSubscriptionPreview(requestParameters) {
|
|
963
1027
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.getLockedSubscriptionPreview(requestParameters?.projectId, requestParameters?.amount, requestParameters?.autoSubscribe, requestParameters?.recvWindow);
|
|
964
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
1028
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
965
1029
|
}
|
|
966
1030
|
/**
|
|
967
1031
|
* Get Locked Subscription Record
|
|
@@ -982,7 +1046,7 @@ var FlexibleLockedApi = class {
|
|
|
982
1046
|
*/
|
|
983
1047
|
async getLockedSubscriptionRecord(requestParameters = {}) {
|
|
984
1048
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.getLockedSubscriptionRecord(requestParameters?.purchaseId, requestParameters?.asset, requestParameters?.startTime, requestParameters?.endTime, requestParameters?.current, requestParameters?.size, requestParameters?.recvWindow);
|
|
985
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
1049
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
986
1050
|
}
|
|
987
1051
|
/**
|
|
988
1052
|
* Get Rate History
|
|
@@ -1003,7 +1067,7 @@ var FlexibleLockedApi = class {
|
|
|
1003
1067
|
*/
|
|
1004
1068
|
async getRateHistory(requestParameters) {
|
|
1005
1069
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.getRateHistory(requestParameters?.productId, requestParameters?.aprPeriod, requestParameters?.startTime, requestParameters?.endTime, requestParameters?.current, requestParameters?.size, requestParameters?.recvWindow);
|
|
1006
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
1070
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
1007
1071
|
}
|
|
1008
1072
|
/**
|
|
1009
1073
|
* Get available Simple Earn flexible product list
|
|
@@ -1019,7 +1083,7 @@ var FlexibleLockedApi = class {
|
|
|
1019
1083
|
*/
|
|
1020
1084
|
async getSimpleEarnFlexibleProductList(requestParameters = {}) {
|
|
1021
1085
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.getSimpleEarnFlexibleProductList(requestParameters?.asset, requestParameters?.current, requestParameters?.size, requestParameters?.recvWindow);
|
|
1022
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
1086
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
1023
1087
|
}
|
|
1024
1088
|
/**
|
|
1025
1089
|
* Get Simple Earn Locked Product List
|
|
@@ -1037,7 +1101,7 @@ var FlexibleLockedApi = class {
|
|
|
1037
1101
|
*/
|
|
1038
1102
|
async getSimpleEarnLockedProductList(requestParameters = {}) {
|
|
1039
1103
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.getSimpleEarnLockedProductList(requestParameters?.asset, requestParameters?.current, requestParameters?.size, requestParameters?.recvWindow);
|
|
1040
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
1104
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
1041
1105
|
}
|
|
1042
1106
|
/**
|
|
1043
1107
|
* Redeem Flexible Product
|
|
@@ -1055,7 +1119,7 @@ var FlexibleLockedApi = class {
|
|
|
1055
1119
|
*/
|
|
1056
1120
|
async redeemFlexibleProduct(requestParameters) {
|
|
1057
1121
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.redeemFlexibleProduct(requestParameters?.productId, requestParameters?.redeemAll, requestParameters?.amount, requestParameters?.destAccount, requestParameters?.recvWindow);
|
|
1058
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
1122
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
1059
1123
|
}
|
|
1060
1124
|
/**
|
|
1061
1125
|
* Redeem Locked Product
|
|
@@ -1073,7 +1137,7 @@ var FlexibleLockedApi = class {
|
|
|
1073
1137
|
*/
|
|
1074
1138
|
async redeemLockedProduct(requestParameters) {
|
|
1075
1139
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.redeemLockedProduct(requestParameters?.positionId, requestParameters?.recvWindow);
|
|
1076
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
1140
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
1077
1141
|
}
|
|
1078
1142
|
/**
|
|
1079
1143
|
* Set Flexible Auto Subscribe
|
|
@@ -1089,7 +1153,7 @@ var FlexibleLockedApi = class {
|
|
|
1089
1153
|
*/
|
|
1090
1154
|
async setFlexibleAutoSubscribe(requestParameters) {
|
|
1091
1155
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.setFlexibleAutoSubscribe(requestParameters?.productId, requestParameters?.autoSubscribe, requestParameters?.recvWindow);
|
|
1092
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
1156
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
1093
1157
|
}
|
|
1094
1158
|
/**
|
|
1095
1159
|
* Set locked auto subscribe
|
|
@@ -1105,7 +1169,7 @@ var FlexibleLockedApi = class {
|
|
|
1105
1169
|
*/
|
|
1106
1170
|
async setLockedAutoSubscribe(requestParameters) {
|
|
1107
1171
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.setLockedAutoSubscribe(requestParameters?.positionId, requestParameters?.autoSubscribe, requestParameters?.recvWindow);
|
|
1108
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
1172
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
1109
1173
|
}
|
|
1110
1174
|
/**
|
|
1111
1175
|
* Set redeem option for Locked product
|
|
@@ -1121,7 +1185,7 @@ var FlexibleLockedApi = class {
|
|
|
1121
1185
|
*/
|
|
1122
1186
|
async setLockedProductRedeemOption(requestParameters) {
|
|
1123
1187
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.setLockedProductRedeemOption(requestParameters?.positionId, requestParameters?.redeemTo, requestParameters?.recvWindow);
|
|
1124
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
1188
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
1125
1189
|
}
|
|
1126
1190
|
/**
|
|
1127
1191
|
* Simple Account query
|
|
@@ -1137,7 +1201,7 @@ var FlexibleLockedApi = class {
|
|
|
1137
1201
|
*/
|
|
1138
1202
|
async simpleAccount(requestParameters = {}) {
|
|
1139
1203
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.simpleAccount(requestParameters?.recvWindow);
|
|
1140
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
1204
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
1141
1205
|
}
|
|
1142
1206
|
/**
|
|
1143
1207
|
* Subscribe Flexible Product
|
|
@@ -1155,7 +1219,7 @@ var FlexibleLockedApi = class {
|
|
|
1155
1219
|
*/
|
|
1156
1220
|
async subscribeFlexibleProduct(requestParameters) {
|
|
1157
1221
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.subscribeFlexibleProduct(requestParameters?.productId, requestParameters?.amount, requestParameters?.autoSubscribe, requestParameters?.sourceAccount, requestParameters?.recvWindow);
|
|
1158
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
1222
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
1159
1223
|
}
|
|
1160
1224
|
/**
|
|
1161
1225
|
* Subscribe Locked Product
|
|
@@ -1173,7 +1237,7 @@ var FlexibleLockedApi = class {
|
|
|
1173
1237
|
*/
|
|
1174
1238
|
async subscribeLockedProduct(requestParameters) {
|
|
1175
1239
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.subscribeLockedProduct(requestParameters?.projectId, requestParameters?.amount, requestParameters?.autoSubscribe, requestParameters?.sourceAccount, requestParameters?.redeemTo, requestParameters?.recvWindow);
|
|
1176
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
1240
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
1177
1241
|
}
|
|
1178
1242
|
};
|
|
1179
1243
|
|
|
@@ -1198,30 +1262,35 @@ const RwusdApiAxiosParamCreator = function(configuration) {
|
|
|
1198
1262
|
return {
|
|
1199
1263
|
getRwusdAccount: async (recvWindow) => {
|
|
1200
1264
|
const localVarQueryParameter = {};
|
|
1265
|
+
const localVarBodyParameter = {};
|
|
1201
1266
|
if (recvWindow !== void 0 && recvWindow !== null) localVarQueryParameter["recvWindow"] = recvWindow;
|
|
1202
1267
|
let _timeUnit;
|
|
1203
1268
|
if ("timeUnit" in configuration) _timeUnit = configuration.timeUnit;
|
|
1204
1269
|
return {
|
|
1205
1270
|
endpoint: "/sapi/v1/rwusd/account",
|
|
1206
1271
|
method: "GET",
|
|
1207
|
-
|
|
1272
|
+
queryParams: localVarQueryParameter,
|
|
1273
|
+
bodyParams: localVarBodyParameter,
|
|
1208
1274
|
timeUnit: _timeUnit
|
|
1209
1275
|
};
|
|
1210
1276
|
},
|
|
1211
1277
|
getRwusdQuotaDetails: async (recvWindow) => {
|
|
1212
1278
|
const localVarQueryParameter = {};
|
|
1279
|
+
const localVarBodyParameter = {};
|
|
1213
1280
|
if (recvWindow !== void 0 && recvWindow !== null) localVarQueryParameter["recvWindow"] = recvWindow;
|
|
1214
1281
|
let _timeUnit;
|
|
1215
1282
|
if ("timeUnit" in configuration) _timeUnit = configuration.timeUnit;
|
|
1216
1283
|
return {
|
|
1217
1284
|
endpoint: "/sapi/v1/rwusd/quota",
|
|
1218
1285
|
method: "GET",
|
|
1219
|
-
|
|
1286
|
+
queryParams: localVarQueryParameter,
|
|
1287
|
+
bodyParams: localVarBodyParameter,
|
|
1220
1288
|
timeUnit: _timeUnit
|
|
1221
1289
|
};
|
|
1222
1290
|
},
|
|
1223
1291
|
getRwusdRateHistory: async (startTime, endTime, current, size, recvWindow) => {
|
|
1224
1292
|
const localVarQueryParameter = {};
|
|
1293
|
+
const localVarBodyParameter = {};
|
|
1225
1294
|
if (startTime !== void 0 && startTime !== null) localVarQueryParameter["startTime"] = startTime;
|
|
1226
1295
|
if (endTime !== void 0 && endTime !== null) localVarQueryParameter["endTime"] = endTime;
|
|
1227
1296
|
if (current !== void 0 && current !== null) localVarQueryParameter["current"] = current;
|
|
@@ -1232,12 +1301,14 @@ const RwusdApiAxiosParamCreator = function(configuration) {
|
|
|
1232
1301
|
return {
|
|
1233
1302
|
endpoint: "/sapi/v1/rwusd/history/rateHistory",
|
|
1234
1303
|
method: "GET",
|
|
1235
|
-
|
|
1304
|
+
queryParams: localVarQueryParameter,
|
|
1305
|
+
bodyParams: localVarBodyParameter,
|
|
1236
1306
|
timeUnit: _timeUnit
|
|
1237
1307
|
};
|
|
1238
1308
|
},
|
|
1239
1309
|
getRwusdRedemptionHistory: async (startTime, endTime, current, size, recvWindow) => {
|
|
1240
1310
|
const localVarQueryParameter = {};
|
|
1311
|
+
const localVarBodyParameter = {};
|
|
1241
1312
|
if (startTime !== void 0 && startTime !== null) localVarQueryParameter["startTime"] = startTime;
|
|
1242
1313
|
if (endTime !== void 0 && endTime !== null) localVarQueryParameter["endTime"] = endTime;
|
|
1243
1314
|
if (current !== void 0 && current !== null) localVarQueryParameter["current"] = current;
|
|
@@ -1248,12 +1319,14 @@ const RwusdApiAxiosParamCreator = function(configuration) {
|
|
|
1248
1319
|
return {
|
|
1249
1320
|
endpoint: "/sapi/v1/rwusd/history/redemptionHistory",
|
|
1250
1321
|
method: "GET",
|
|
1251
|
-
|
|
1322
|
+
queryParams: localVarQueryParameter,
|
|
1323
|
+
bodyParams: localVarBodyParameter,
|
|
1252
1324
|
timeUnit: _timeUnit
|
|
1253
1325
|
};
|
|
1254
1326
|
},
|
|
1255
1327
|
getRwusdRewardsHistory: async (startTime, endTime, current, size, recvWindow) => {
|
|
1256
1328
|
const localVarQueryParameter = {};
|
|
1329
|
+
const localVarBodyParameter = {};
|
|
1257
1330
|
if (startTime !== void 0 && startTime !== null) localVarQueryParameter["startTime"] = startTime;
|
|
1258
1331
|
if (endTime !== void 0 && endTime !== null) localVarQueryParameter["endTime"] = endTime;
|
|
1259
1332
|
if (current !== void 0 && current !== null) localVarQueryParameter["current"] = current;
|
|
@@ -1264,12 +1337,14 @@ const RwusdApiAxiosParamCreator = function(configuration) {
|
|
|
1264
1337
|
return {
|
|
1265
1338
|
endpoint: "/sapi/v1/rwusd/history/rewardsHistory",
|
|
1266
1339
|
method: "GET",
|
|
1267
|
-
|
|
1340
|
+
queryParams: localVarQueryParameter,
|
|
1341
|
+
bodyParams: localVarBodyParameter,
|
|
1268
1342
|
timeUnit: _timeUnit
|
|
1269
1343
|
};
|
|
1270
1344
|
},
|
|
1271
1345
|
getRwusdSubscriptionHistory: async (asset, startTime, endTime, current, size, recvWindow) => {
|
|
1272
1346
|
const localVarQueryParameter = {};
|
|
1347
|
+
const localVarBodyParameter = {};
|
|
1273
1348
|
if (asset !== void 0 && asset !== null) localVarQueryParameter["asset"] = asset;
|
|
1274
1349
|
if (startTime !== void 0 && startTime !== null) localVarQueryParameter["startTime"] = startTime;
|
|
1275
1350
|
if (endTime !== void 0 && endTime !== null) localVarQueryParameter["endTime"] = endTime;
|
|
@@ -1281,7 +1356,8 @@ const RwusdApiAxiosParamCreator = function(configuration) {
|
|
|
1281
1356
|
return {
|
|
1282
1357
|
endpoint: "/sapi/v1/rwusd/history/subscriptionHistory",
|
|
1283
1358
|
method: "GET",
|
|
1284
|
-
|
|
1359
|
+
queryParams: localVarQueryParameter,
|
|
1360
|
+
bodyParams: localVarBodyParameter,
|
|
1285
1361
|
timeUnit: _timeUnit
|
|
1286
1362
|
};
|
|
1287
1363
|
},
|
|
@@ -1289,6 +1365,7 @@ const RwusdApiAxiosParamCreator = function(configuration) {
|
|
|
1289
1365
|
assertParamExists("redeemRwusd", "amount", amount);
|
|
1290
1366
|
assertParamExists("redeemRwusd", "type", type);
|
|
1291
1367
|
const localVarQueryParameter = {};
|
|
1368
|
+
const localVarBodyParameter = {};
|
|
1292
1369
|
if (amount !== void 0 && amount !== null) localVarQueryParameter["amount"] = amount;
|
|
1293
1370
|
if (type !== void 0 && type !== null) localVarQueryParameter["type"] = type;
|
|
1294
1371
|
if (recvWindow !== void 0 && recvWindow !== null) localVarQueryParameter["recvWindow"] = recvWindow;
|
|
@@ -1297,7 +1374,8 @@ const RwusdApiAxiosParamCreator = function(configuration) {
|
|
|
1297
1374
|
return {
|
|
1298
1375
|
endpoint: "/sapi/v1/rwusd/redeem",
|
|
1299
1376
|
method: "POST",
|
|
1300
|
-
|
|
1377
|
+
queryParams: localVarQueryParameter,
|
|
1378
|
+
bodyParams: localVarBodyParameter,
|
|
1301
1379
|
timeUnit: _timeUnit
|
|
1302
1380
|
};
|
|
1303
1381
|
},
|
|
@@ -1305,6 +1383,7 @@ const RwusdApiAxiosParamCreator = function(configuration) {
|
|
|
1305
1383
|
assertParamExists("subscribeRwusd", "asset", asset);
|
|
1306
1384
|
assertParamExists("subscribeRwusd", "amount", amount);
|
|
1307
1385
|
const localVarQueryParameter = {};
|
|
1386
|
+
const localVarBodyParameter = {};
|
|
1308
1387
|
if (asset !== void 0 && asset !== null) localVarQueryParameter["asset"] = asset;
|
|
1309
1388
|
if (amount !== void 0 && amount !== null) localVarQueryParameter["amount"] = amount;
|
|
1310
1389
|
if (recvWindow !== void 0 && recvWindow !== null) localVarQueryParameter["recvWindow"] = recvWindow;
|
|
@@ -1313,7 +1392,8 @@ const RwusdApiAxiosParamCreator = function(configuration) {
|
|
|
1313
1392
|
return {
|
|
1314
1393
|
endpoint: "/sapi/v1/rwusd/subscribe",
|
|
1315
1394
|
method: "POST",
|
|
1316
|
-
|
|
1395
|
+
queryParams: localVarQueryParameter,
|
|
1396
|
+
bodyParams: localVarBodyParameter,
|
|
1317
1397
|
timeUnit: _timeUnit
|
|
1318
1398
|
};
|
|
1319
1399
|
}
|
|
@@ -1342,7 +1422,7 @@ var RwusdApi = class {
|
|
|
1342
1422
|
*/
|
|
1343
1423
|
async getRwusdAccount(requestParameters = {}) {
|
|
1344
1424
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.getRwusdAccount(requestParameters?.recvWindow);
|
|
1345
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
1425
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
1346
1426
|
}
|
|
1347
1427
|
/**
|
|
1348
1428
|
* Get RWUSD quota details including subscription quota, fast redemption quota, and standard redemption quota.
|
|
@@ -1358,7 +1438,7 @@ var RwusdApi = class {
|
|
|
1358
1438
|
*/
|
|
1359
1439
|
async getRwusdQuotaDetails(requestParameters = {}) {
|
|
1360
1440
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.getRwusdQuotaDetails(requestParameters?.recvWindow);
|
|
1361
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
1441
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
1362
1442
|
}
|
|
1363
1443
|
/**
|
|
1364
1444
|
* Get RWUSD rate history sorted by descending order.
|
|
@@ -1379,7 +1459,7 @@ var RwusdApi = class {
|
|
|
1379
1459
|
*/
|
|
1380
1460
|
async getRwusdRateHistory(requestParameters = {}) {
|
|
1381
1461
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.getRwusdRateHistory(requestParameters?.startTime, requestParameters?.endTime, requestParameters?.current, requestParameters?.size, requestParameters?.recvWindow);
|
|
1382
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
1462
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
1383
1463
|
}
|
|
1384
1464
|
/**
|
|
1385
1465
|
* Get RWUSD redemption history.
|
|
@@ -1400,7 +1480,7 @@ var RwusdApi = class {
|
|
|
1400
1480
|
*/
|
|
1401
1481
|
async getRwusdRedemptionHistory(requestParameters = {}) {
|
|
1402
1482
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.getRwusdRedemptionHistory(requestParameters?.startTime, requestParameters?.endTime, requestParameters?.current, requestParameters?.size, requestParameters?.recvWindow);
|
|
1403
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
1483
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
1404
1484
|
}
|
|
1405
1485
|
/**
|
|
1406
1486
|
* Get RWUSD rewards history.
|
|
@@ -1421,7 +1501,7 @@ var RwusdApi = class {
|
|
|
1421
1501
|
*/
|
|
1422
1502
|
async getRwusdRewardsHistory(requestParameters = {}) {
|
|
1423
1503
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.getRwusdRewardsHistory(requestParameters?.startTime, requestParameters?.endTime, requestParameters?.current, requestParameters?.size, requestParameters?.recvWindow);
|
|
1424
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
1504
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
1425
1505
|
}
|
|
1426
1506
|
/**
|
|
1427
1507
|
* Get RWUSD subscription history
|
|
@@ -1442,7 +1522,7 @@ var RwusdApi = class {
|
|
|
1442
1522
|
*/
|
|
1443
1523
|
async getRwusdSubscriptionHistory(requestParameters = {}) {
|
|
1444
1524
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.getRwusdSubscriptionHistory(requestParameters?.asset, requestParameters?.startTime, requestParameters?.endTime, requestParameters?.current, requestParameters?.size, requestParameters?.recvWindow);
|
|
1445
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
1525
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
1446
1526
|
}
|
|
1447
1527
|
/**
|
|
1448
1528
|
* Redeem RWUSD to USDC
|
|
@@ -1460,7 +1540,7 @@ var RwusdApi = class {
|
|
|
1460
1540
|
*/
|
|
1461
1541
|
async redeemRwusd(requestParameters) {
|
|
1462
1542
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.redeemRwusd(requestParameters?.amount, requestParameters?.type, requestParameters?.recvWindow);
|
|
1463
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
1543
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
1464
1544
|
}
|
|
1465
1545
|
/**
|
|
1466
1546
|
* Subscribe RWUSD
|
|
@@ -1478,7 +1558,7 @@ var RwusdApi = class {
|
|
|
1478
1558
|
*/
|
|
1479
1559
|
async subscribeRwusd(requestParameters) {
|
|
1480
1560
|
const localVarAxiosArgs = await this.localVarAxiosParamCreator.subscribeRwusd(requestParameters?.asset, requestParameters?.amount, requestParameters?.recvWindow);
|
|
1481
|
-
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.
|
|
1561
|
+
return sendRequest(this.configuration, localVarAxiosArgs.endpoint, localVarAxiosArgs.method, localVarAxiosArgs.queryParams, localVarAxiosArgs.bodyParams, localVarAxiosArgs?.timeUnit, { isSigned: true });
|
|
1482
1562
|
}
|
|
1483
1563
|
};
|
|
1484
1564
|
|
|
@@ -1507,23 +1587,25 @@ var RestAPI = class {
|
|
|
1507
1587
|
* Generic function to send a request.
|
|
1508
1588
|
* @param endpoint - The API endpoint to call.
|
|
1509
1589
|
* @param method - HTTP method to use (GET, POST, DELETE, etc.).
|
|
1510
|
-
* @param
|
|
1590
|
+
* @param queryParams - Query parameters for the request.
|
|
1591
|
+
* @param bodyParams - Body parameters for the request.
|
|
1511
1592
|
*
|
|
1512
1593
|
* @returns A promise resolving to the response data object.
|
|
1513
1594
|
*/
|
|
1514
|
-
sendRequest(endpoint, method,
|
|
1515
|
-
return sendRequest(this.configuration, endpoint, method,
|
|
1595
|
+
sendRequest(endpoint, method, queryParams = {}, bodyParams = {}) {
|
|
1596
|
+
return sendRequest(this.configuration, endpoint, method, queryParams, bodyParams, void 0);
|
|
1516
1597
|
}
|
|
1517
1598
|
/**
|
|
1518
1599
|
* Generic function to send a signed request.
|
|
1519
1600
|
* @param endpoint - The API endpoint to call.
|
|
1520
1601
|
* @param method - HTTP method to use (GET, POST, DELETE, etc.).
|
|
1521
|
-
* @param
|
|
1602
|
+
* @param queryParams - Query parameters for the request.
|
|
1603
|
+
* @param bodyParams - Body parameters for the request.
|
|
1522
1604
|
*
|
|
1523
1605
|
* @returns A promise resolving to the response data object.
|
|
1524
1606
|
*/
|
|
1525
|
-
sendSignedRequest(endpoint, method,
|
|
1526
|
-
return sendRequest(this.configuration, endpoint, method,
|
|
1607
|
+
sendSignedRequest(endpoint, method, queryParams = {}, bodyParams = {}) {
|
|
1608
|
+
return sendRequest(this.configuration, endpoint, method, queryParams, bodyParams, void 0, { isSigned: true });
|
|
1527
1609
|
}
|
|
1528
1610
|
/**
|
|
1529
1611
|
* Get BFUSD account information.
|
|
@@ -2253,5 +2335,5 @@ var SimpleEarn = class {
|
|
|
2253
2335
|
};
|
|
2254
2336
|
|
|
2255
2337
|
//#endregion
|
|
2256
|
-
export { BadRequestError,
|
|
2338
|
+
export { BadRequestError, ConnectorClientError, ForbiddenError, NetworkError, NotFoundError, RateLimitBanError, RequiredError, SIMPLE_EARN_REST_API_PROD_URL, ServerError, SimpleEarn, rest_api_exports as SimpleEarnRestAPI, TooManyRequestsError, UnauthorizedError };
|
|
2257
2339
|
//# sourceMappingURL=index.mjs.map
|