@pendle/sdk-boros 0.3.5 → 0.3.7-khanh
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/backend/secrettune/BorosBackendSDK.d.ts +155 -91
- package/dist/backend/secrettune/BorosBackendSDK.js +92 -12
- package/dist/backend/secrettune/BorosBackendSDK.js.map +1 -1
- package/dist/contracts/viemAbis.d.ts +679 -103
- package/dist/contracts/viemAbis.js +358 -47
- package/dist/contracts/viemAbis.js.map +1 -1
- package/dist/entities/exchange/exchange.d.ts +457 -3
- package/dist/entities/exchange/exchange.js +2 -22
- package/dist/entities/exchange/exchange.js.map +1 -1
- package/dist/entities/exchange/utils.d.ts +114 -0
- package/dist/entities/multiTokenMerkleDistributor/RewardDistributor.d.ts +16 -0
- package/dist/entities/multiTokenMerkleDistributor/RewardDistributor.js +18 -0
- package/dist/entities/multiTokenMerkleDistributor/RewardDistributor.js.map +1 -0
- package/dist/entities/multiTokenMerkleDistributor/constants.d.ts +1 -0
- package/dist/entities/multiTokenMerkleDistributor/constants.js +2 -1
- package/dist/entities/multiTokenMerkleDistributor/constants.js.map +1 -1
- package/dist/entities/multiTokenMerkleDistributor/index.d.ts +1 -1
- package/dist/entities/multiTokenMerkleDistributor/index.js +1 -1
- package/dist/entities/multiTokenMerkleDistributor/index.js.map +1 -1
- package/dist/entities/multiTokenMerkleDistributor/makerIncentiveRewardsDistributor.d.ts +12 -0
- package/dist/entities/multiTokenMerkleDistributor/makerIncentiveRewardsDistributor.js +25 -0
- package/dist/entities/multiTokenMerkleDistributor/makerIncentiveRewardsDistributor.js.map +1 -0
- package/dist/entities/multiTokenMerkleDistributor/{multiTokenMerkleDistributor.d.ts → multiTokenMerkleDistributorContract.d.ts} +4 -3
- package/dist/entities/multiTokenMerkleDistributor/{multiTokenMerkleDistributor.js → multiTokenMerkleDistributorContract.js} +9 -8
- package/dist/entities/multiTokenMerkleDistributor/multiTokenMerkleDistributorContract.js.map +1 -0
- package/dist/entities/multiTokenMerkleDistributor/referralRewardsDistributor.d.ts +12 -1
- package/dist/entities/multiTokenMerkleDistributor/referralRewardsDistributor.js +22 -0
- package/dist/entities/multiTokenMerkleDistributor/referralRewardsDistributor.js.map +1 -1
- package/dist/errors/PendleContractError/customHandler.d.ts +2 -0
- package/dist/errors/PendleContractError/customHandler.js +8 -0
- package/dist/errors/PendleContractError/customHandler.js.map +1 -0
- package/dist/errors/PendleContractError/type.d.ts +14 -3
- package/dist/errors/ViemErrorDecoder.js.map +1 -1
- package/dist/types/encoders.d.ts +1 -2
- package/dist/types/encoders.js +1 -1
- package/dist/types/encoders.js.map +1 -1
- package/package.json +2 -2
- package/dist/entities/multiTokenMerkleDistributor/multiTokenMerkleDistributor.js.map +0 -1
|
@@ -48,6 +48,7 @@ export interface MarketMetadataResponse {
|
|
|
48
48
|
icon: string;
|
|
49
49
|
isWhitelisted: boolean;
|
|
50
50
|
fundingRateSymbol: string;
|
|
51
|
+
realtimeFundingRateLink: string;
|
|
51
52
|
}
|
|
52
53
|
export interface MarketDataResponse {
|
|
53
54
|
volume24h: number;
|
|
@@ -58,6 +59,7 @@ export interface MarketDataResponse {
|
|
|
58
59
|
floatingApr: number;
|
|
59
60
|
longYieldApr?: number;
|
|
60
61
|
nextSettlementTime?: number;
|
|
62
|
+
timeToMaturity?: number;
|
|
61
63
|
}
|
|
62
64
|
export interface MarketResponse {
|
|
63
65
|
marketId: number;
|
|
@@ -87,14 +89,12 @@ export interface MarketTradesResponse {
|
|
|
87
89
|
}
|
|
88
90
|
export interface CandleResponse {
|
|
89
91
|
ts: number;
|
|
90
|
-
t: number;
|
|
91
92
|
o: number;
|
|
92
93
|
h: number;
|
|
93
94
|
l: number;
|
|
94
95
|
c: number;
|
|
95
96
|
v: number;
|
|
96
97
|
u: number;
|
|
97
|
-
i: number;
|
|
98
98
|
iofr: boolean;
|
|
99
99
|
}
|
|
100
100
|
export interface ChartResponse {
|
|
@@ -162,6 +162,7 @@ export interface GetAMMInfoByAmmIdResponse {
|
|
|
162
162
|
}
|
|
163
163
|
export interface DepositStateResponse {
|
|
164
164
|
collateralBalance: string;
|
|
165
|
+
maintenanceMargin: string;
|
|
165
166
|
marginRatio: number;
|
|
166
167
|
}
|
|
167
168
|
export interface DepositSimulationResponse {
|
|
@@ -179,6 +180,7 @@ export interface WithdrawSimulationResponse {
|
|
|
179
180
|
}
|
|
180
181
|
export interface CashTransferStateResponse {
|
|
181
182
|
collateralBalance: string;
|
|
183
|
+
maintenanceMargin: string;
|
|
182
184
|
marginRatio: number;
|
|
183
185
|
}
|
|
184
186
|
export interface CashTransferPrePostSimulationResponse {
|
|
@@ -189,6 +191,21 @@ export interface CashTransferSimulationResponse {
|
|
|
189
191
|
crossAccState: CashTransferPrePostSimulationResponse;
|
|
190
192
|
isolatedAccState: CashTransferPrePostSimulationResponse;
|
|
191
193
|
}
|
|
194
|
+
export interface ContractSwapPositionResponse {
|
|
195
|
+
size: string;
|
|
196
|
+
cost: string;
|
|
197
|
+
rate: number;
|
|
198
|
+
}
|
|
199
|
+
export interface PlaceOrderSimulationResponseV2 {
|
|
200
|
+
preUserInfoActivePositionSize: string;
|
|
201
|
+
matched: ContractSwapPositionResponse;
|
|
202
|
+
marginRequired: string;
|
|
203
|
+
liquidationApr?: number;
|
|
204
|
+
priceImpact: number;
|
|
205
|
+
fee: string;
|
|
206
|
+
actualLeverage: number;
|
|
207
|
+
status: string;
|
|
208
|
+
}
|
|
192
209
|
export interface PlaceOrderStateResponse {
|
|
193
210
|
totalCash: string;
|
|
194
211
|
availableInitialMargin: string;
|
|
@@ -196,11 +213,6 @@ export interface PlaceOrderStateResponse {
|
|
|
196
213
|
marginRatio: number;
|
|
197
214
|
activePositionSize: string;
|
|
198
215
|
}
|
|
199
|
-
export interface ContractSwapPositionResponse {
|
|
200
|
-
size: string;
|
|
201
|
-
cost: string;
|
|
202
|
-
rate: number;
|
|
203
|
-
}
|
|
204
216
|
export interface PlaceOrderSimulationResponse {
|
|
205
217
|
preUserInfo: PlaceOrderStateResponse;
|
|
206
218
|
postUserInfo: PlaceOrderStateResponse;
|
|
@@ -222,26 +234,6 @@ export interface CancelOrderSimulationResponse {
|
|
|
222
234
|
preUserInfo: UserInfoResponse;
|
|
223
235
|
postUserInfo: UserInfoResponse;
|
|
224
236
|
}
|
|
225
|
-
export interface ModifyOrderSimulationResponse {
|
|
226
|
-
preUserInfo: PlaceOrderStateResponse;
|
|
227
|
-
postUserInfo: PlaceOrderStateResponse;
|
|
228
|
-
marginRequired: string;
|
|
229
|
-
liquidationApr: number;
|
|
230
|
-
profit25PercentApr: number;
|
|
231
|
-
priceImpact: number;
|
|
232
|
-
fee: string;
|
|
233
|
-
}
|
|
234
|
-
export interface CloseActivePositionSimulationResponse {
|
|
235
|
-
preUserInfo: PlaceOrderStateResponse;
|
|
236
|
-
postUserInfo: PlaceOrderStateResponse;
|
|
237
|
-
matched: ContractSwapPositionResponse;
|
|
238
|
-
marginRequired: string;
|
|
239
|
-
liquidationApr?: number;
|
|
240
|
-
profit25PercentApr: number;
|
|
241
|
-
priceImpact: number;
|
|
242
|
-
fee: string;
|
|
243
|
-
actualLeverage: number;
|
|
244
|
-
}
|
|
245
237
|
export interface AddLiquiditySingleCashStateResponse {
|
|
246
238
|
collateralBalance: string;
|
|
247
239
|
marginRatio: number;
|
|
@@ -352,46 +344,6 @@ export interface UpdateAccountSettingBodyDto {
|
|
|
352
344
|
agent: string;
|
|
353
345
|
timestamp: number;
|
|
354
346
|
}
|
|
355
|
-
export interface PositionValueResponse {
|
|
356
|
-
settledPosition: string;
|
|
357
|
-
remainingPosition: string;
|
|
358
|
-
}
|
|
359
|
-
export interface PositionPnlResponse {
|
|
360
|
-
rateSettlementPnl: string;
|
|
361
|
-
unrealisedPnl: string;
|
|
362
|
-
}
|
|
363
|
-
export interface ActivePnlPositionResponse {
|
|
364
|
-
id: string;
|
|
365
|
-
marketId: number;
|
|
366
|
-
side: 0 | 1;
|
|
367
|
-
notionalSize: string;
|
|
368
|
-
positionValue: PositionValueResponse;
|
|
369
|
-
underlyingApy: number;
|
|
370
|
-
fixedApr: number;
|
|
371
|
-
impliedApr: number;
|
|
372
|
-
liquidationApr: number;
|
|
373
|
-
pnl: PositionPnlResponse;
|
|
374
|
-
initialMargin: string;
|
|
375
|
-
marketAcc: string;
|
|
376
|
-
accountId: number;
|
|
377
|
-
profit25PercentApr: number;
|
|
378
|
-
}
|
|
379
|
-
export interface ClosedPnlPositionResponse {
|
|
380
|
-
id: string;
|
|
381
|
-
marketId: number;
|
|
382
|
-
side: 0 | 1;
|
|
383
|
-
timeClosed: number;
|
|
384
|
-
positionSize: string;
|
|
385
|
-
avgFixedApr: number;
|
|
386
|
-
avgUnderlyingApr: number;
|
|
387
|
-
pnl: string;
|
|
388
|
-
marketAcc: string;
|
|
389
|
-
accountId: number;
|
|
390
|
-
}
|
|
391
|
-
export interface ClosedPnlPositionsResponse {
|
|
392
|
-
results: ClosedPnlPositionResponse[];
|
|
393
|
-
total: number;
|
|
394
|
-
}
|
|
395
347
|
export interface PnlTransactionResponse {
|
|
396
348
|
id: string;
|
|
397
349
|
marketId: number;
|
|
@@ -427,7 +379,6 @@ export interface LimitOrderResponse {
|
|
|
427
379
|
unfilledSize: string;
|
|
428
380
|
impliedApr: number;
|
|
429
381
|
tick: number;
|
|
430
|
-
orderValue: string;
|
|
431
382
|
marginRequired: string;
|
|
432
383
|
orderId: string;
|
|
433
384
|
root: string;
|
|
@@ -444,6 +395,25 @@ export interface LimitOrdersResponse {
|
|
|
444
395
|
results: LimitOrderResponse[];
|
|
445
396
|
total: number;
|
|
446
397
|
}
|
|
398
|
+
export interface FundLocationResponse {
|
|
399
|
+
fundType: "wallet" | "cross_account" | "isolated_account";
|
|
400
|
+
marketId?: number;
|
|
401
|
+
}
|
|
402
|
+
export interface TransferLogResponse {
|
|
403
|
+
transferLogId: string;
|
|
404
|
+
blockTimestamp: number;
|
|
405
|
+
root: string;
|
|
406
|
+
accountId: number;
|
|
407
|
+
tokenId: number;
|
|
408
|
+
amount: string;
|
|
409
|
+
fromFundLocation: FundLocationResponse;
|
|
410
|
+
toFundLocation: FundLocationResponse;
|
|
411
|
+
status: "pending" | "success" | "failed";
|
|
412
|
+
}
|
|
413
|
+
export interface TransferLogsResponse {
|
|
414
|
+
total: number;
|
|
415
|
+
results: TransferLogResponse[];
|
|
416
|
+
}
|
|
447
417
|
export interface SettlementResponse {
|
|
448
418
|
id: string;
|
|
449
419
|
timestamp: number;
|
|
@@ -461,6 +431,10 @@ export interface SettlementsResponse {
|
|
|
461
431
|
results: SettlementResponse[];
|
|
462
432
|
total: number;
|
|
463
433
|
}
|
|
434
|
+
export interface PositionValueResponse {
|
|
435
|
+
settledPosition: string;
|
|
436
|
+
remainingPosition: string;
|
|
437
|
+
}
|
|
464
438
|
export interface PnlResponse {
|
|
465
439
|
rateSettlementPnl: string;
|
|
466
440
|
unrealisedPnl: string;
|
|
@@ -490,6 +464,10 @@ export interface MarketAccCollateralResponse {
|
|
|
490
464
|
maintMargin: string;
|
|
491
465
|
marginRatio: number;
|
|
492
466
|
}
|
|
467
|
+
export interface WithdrawalResponse {
|
|
468
|
+
lastWithdrawalRequestTime: number;
|
|
469
|
+
lastWithdrawalAmount: string;
|
|
470
|
+
}
|
|
493
471
|
export interface CollateralSummaryResponse {
|
|
494
472
|
tokenId: number;
|
|
495
473
|
isolatedPositions: MarketAccCollateralResponse[];
|
|
@@ -499,6 +477,7 @@ export interface CollateralSummaryResponse {
|
|
|
499
477
|
oneMonthAgoNetBalance: string;
|
|
500
478
|
oneMonthAgoAggregatedVaultTransfer: string;
|
|
501
479
|
oneMonthAgoAggregatedAmmTransfer: string;
|
|
480
|
+
withdrawal: WithdrawalResponse;
|
|
502
481
|
}
|
|
503
482
|
export interface AllCollateralSummaryResponse {
|
|
504
483
|
collaterals: CollateralSummaryResponse[];
|
|
@@ -539,10 +518,7 @@ export interface GetUserReferralInfoResponse {
|
|
|
539
518
|
referrer?: string;
|
|
540
519
|
referrerCode?: string;
|
|
541
520
|
referralJoinDate?: string;
|
|
542
|
-
|
|
543
|
-
totalSettledVolume: number;
|
|
544
|
-
totalPayableFee: number;
|
|
545
|
-
totalSharedFee: number;
|
|
521
|
+
totalTradeInUsd: number;
|
|
546
522
|
}
|
|
547
523
|
export interface CheckReferralExistBodyDto {
|
|
548
524
|
code: string;
|
|
@@ -587,11 +563,32 @@ export interface ReferralRewardResponse {
|
|
|
587
563
|
totalReferralRewards: Reward[];
|
|
588
564
|
unclaimedReferralRewards: Reward[];
|
|
589
565
|
}
|
|
566
|
+
export interface UserMerkleResponse {
|
|
567
|
+
tokens: string[];
|
|
568
|
+
accruedAmounts: string[];
|
|
569
|
+
proofs: string[][];
|
|
570
|
+
}
|
|
590
571
|
export interface FaucetDto {
|
|
591
572
|
addresses: string[];
|
|
592
573
|
ethAmount: number;
|
|
593
574
|
btcAmount: number;
|
|
594
575
|
}
|
|
576
|
+
export interface GlobalConfigsResponse {
|
|
577
|
+
coolDown: number;
|
|
578
|
+
}
|
|
579
|
+
export interface MarketWeeklyIncentiveResponse {
|
|
580
|
+
marketId: number;
|
|
581
|
+
totalMakerVolume: number;
|
|
582
|
+
makerVolume: number;
|
|
583
|
+
rewardAmount: number;
|
|
584
|
+
}
|
|
585
|
+
export interface WeeklyIncentiveResponse {
|
|
586
|
+
timestamp: string;
|
|
587
|
+
marketWeeklyIncentives: MarketWeeklyIncentiveResponse[];
|
|
588
|
+
}
|
|
589
|
+
export interface MakerIncentiveActivitiesResponse {
|
|
590
|
+
weeklyIncentives: WeeklyIncentiveResponse[];
|
|
591
|
+
}
|
|
595
592
|
import type { AxiosInstance, AxiosRequestConfig, AxiosResponse, ResponseType } from "axios";
|
|
596
593
|
export type QueryParamsType = Record<string | number, any>;
|
|
597
594
|
export interface FullRequestParams extends Omit<AxiosRequestConfig, "data" | "params" | "url" | "responseType"> {
|
|
@@ -675,6 +672,13 @@ export declare class Sdk<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
675
672
|
tokenId: number;
|
|
676
673
|
amount: string;
|
|
677
674
|
}, params?: RequestParams) => Promise<AxiosResponse<DepositSimulationResponse, any>>;
|
|
675
|
+
simulationsControllerGetDepositV2: (query: {
|
|
676
|
+
userAddress: string;
|
|
677
|
+
tokenId: number;
|
|
678
|
+
amount: string;
|
|
679
|
+
accountId: number;
|
|
680
|
+
marketId: number;
|
|
681
|
+
}, params?: RequestParams) => Promise<AxiosResponse<DepositSimulationResponse, any>>;
|
|
678
682
|
simulationsControllerGetWithdraw: (query: {
|
|
679
683
|
userAddress: string;
|
|
680
684
|
tokenId: number;
|
|
@@ -686,6 +690,15 @@ export declare class Sdk<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
686
690
|
isDeposit: boolean;
|
|
687
691
|
amount: string;
|
|
688
692
|
}, params?: RequestParams) => Promise<AxiosResponse<CashTransferSimulationResponse, any>>;
|
|
693
|
+
simulationsControllerGetPlaceOrderV2: (query: {
|
|
694
|
+
marketAcc?: string;
|
|
695
|
+
marketId: number;
|
|
696
|
+
side: 0 | 1;
|
|
697
|
+
size: string;
|
|
698
|
+
limitTick?: number;
|
|
699
|
+
tif: 0 | 1 | 2 | 3;
|
|
700
|
+
slippage?: number;
|
|
701
|
+
}, params?: RequestParams) => Promise<AxiosResponse<PlaceOrderSimulationResponseV2, any>>;
|
|
689
702
|
simulationsControllerGetPlaceOrder: (query: {
|
|
690
703
|
marketAcc: string;
|
|
691
704
|
marketId: number;
|
|
@@ -702,15 +715,15 @@ export declare class Sdk<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
702
715
|
cancelAll: boolean;
|
|
703
716
|
orderIds?: string[];
|
|
704
717
|
}, params?: RequestParams) => Promise<AxiosResponse<CancelOrderSimulationResponse, any>>;
|
|
705
|
-
|
|
706
|
-
marketAcc: string;
|
|
718
|
+
simulationsControllerCloseActiveMarketPositionV2: (query: {
|
|
707
719
|
marketId: number;
|
|
708
|
-
orderId: string;
|
|
709
720
|
side: 0 | 1;
|
|
710
721
|
size: string;
|
|
711
|
-
limitTick
|
|
722
|
+
limitTick?: number;
|
|
712
723
|
tif: 0 | 1 | 2 | 3;
|
|
713
|
-
|
|
724
|
+
slippage?: number;
|
|
725
|
+
marketAcc: string;
|
|
726
|
+
}, params?: RequestParams) => Promise<AxiosResponse<PlaceOrderSimulationResponseV2, any>>;
|
|
714
727
|
simulationsControllerCloseActiveMarketPosition: (query: {
|
|
715
728
|
marketAcc: string;
|
|
716
729
|
marketId: number;
|
|
@@ -718,7 +731,7 @@ export declare class Sdk<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
718
731
|
size: string;
|
|
719
732
|
rate?: number;
|
|
720
733
|
slippage?: number;
|
|
721
|
-
}, params?: RequestParams) => Promise<AxiosResponse<
|
|
734
|
+
}, params?: RequestParams) => Promise<AxiosResponse<PlaceOrderSimulationResponse, any>>;
|
|
722
735
|
simulationsControllerGetAddLiquiditySingleCashToAmm: (query: {
|
|
723
736
|
userAddress: string;
|
|
724
737
|
accountId: number;
|
|
@@ -741,16 +754,45 @@ export declare class Sdk<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
741
754
|
tokenId: number;
|
|
742
755
|
amount: string;
|
|
743
756
|
}, params?: RequestParams) => Promise<AxiosResponse<GetCalldataResponse, any>>;
|
|
757
|
+
calldataControllerGetDepositCalldataV2: (query: {
|
|
758
|
+
userAddress: string;
|
|
759
|
+
tokenId: number;
|
|
760
|
+
amount: string;
|
|
761
|
+
accountId: number;
|
|
762
|
+
marketId: number;
|
|
763
|
+
}, params?: RequestParams) => Promise<AxiosResponse<GetCalldataResponse, any>>;
|
|
744
764
|
calldataControllerGetWithdrawCalldata: (query: {
|
|
745
765
|
userAddress: string;
|
|
746
766
|
tokenId: number;
|
|
747
767
|
amount: string;
|
|
748
768
|
}, params?: RequestParams) => Promise<AxiosResponse<GetCalldataResponse, any>>;
|
|
769
|
+
calldataControllerGetWithdrawRequestCalldata: (query: {
|
|
770
|
+
userAddress: string;
|
|
771
|
+
tokenId: number;
|
|
772
|
+
amount: string;
|
|
773
|
+
}, params?: RequestParams) => Promise<AxiosResponse<GetCalldataResponse, any>>;
|
|
774
|
+
calldataControllerGetWithdrawCancelCalldata: (query: {
|
|
775
|
+
userAddress: string;
|
|
776
|
+
tokenId: number;
|
|
777
|
+
}, params?: RequestParams) => Promise<AxiosResponse<GetCalldataResponse, any>>;
|
|
778
|
+
calldataControllerGetWithdrawFinalizeCalldata: (query: {
|
|
779
|
+
userAddress: string;
|
|
780
|
+
tokenId: number;
|
|
781
|
+
}, params?: RequestParams) => Promise<AxiosResponse<GetCalldataResponse, any>>;
|
|
749
782
|
calldataControllerGetPositionTransferCalldata: (query: {
|
|
750
783
|
marketId: number;
|
|
751
784
|
isDeposit: boolean;
|
|
752
785
|
amount: string;
|
|
753
786
|
}, params?: RequestParams) => Promise<AxiosResponse<AgentExecuteParamsResponse, any>>;
|
|
787
|
+
calldataControllerGetPlaceOrderCalldataV2: (query: {
|
|
788
|
+
marketId: number;
|
|
789
|
+
side: 0 | 1;
|
|
790
|
+
size: string;
|
|
791
|
+
limitTick?: number;
|
|
792
|
+
tif: 0 | 1 | 2 | 3;
|
|
793
|
+
slippage?: number;
|
|
794
|
+
marketAcc: string;
|
|
795
|
+
}, params?: RequestParams) => Promise<AxiosResponse<AgentExecuteParamsResponse, any>>;
|
|
754
796
|
calldataControllerGetPlaceOrderCalldata: (query: {
|
|
755
797
|
marketAcc: string;
|
|
756
798
|
marketId: number;
|
|
@@ -767,6 +809,15 @@ export declare class Sdk<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
767
809
|
cancelAll: boolean;
|
|
768
810
|
orderIds?: string;
|
|
769
811
|
}, params?: RequestParams) => Promise<AxiosResponse<AgentExecuteParamsResponse, any>>;
|
|
812
|
+
calldataControllerGetCloseActiveMarketPositionV2: (query: {
|
|
813
|
+
marketId: number;
|
|
814
|
+
side: 0 | 1;
|
|
815
|
+
size: string;
|
|
816
|
+
limitTick?: number;
|
|
817
|
+
tif: 0 | 1 | 2 | 3;
|
|
818
|
+
slippage?: number;
|
|
819
|
+
marketAcc: string;
|
|
820
|
+
}, params?: RequestParams) => Promise<AxiosResponse<AgentExecuteParamsResponse, any>>;
|
|
770
821
|
calldataControllerGetCloseActiveMarketPosition: (query: {
|
|
771
822
|
marketAcc: string;
|
|
772
823
|
marketId: number;
|
|
@@ -809,19 +860,6 @@ export declare class Sdk<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
809
860
|
accountsControllerUpdateAccountSettings: (data: UpdateAccountSettingBodyDto, params?: RequestParams) => Promise<AxiosResponse<void, any>>;
|
|
810
861
|
};
|
|
811
862
|
pnL: {
|
|
812
|
-
pnlControllerGetActivePnlPositions: (query: {
|
|
813
|
-
userAddress: string;
|
|
814
|
-
accountId: number;
|
|
815
|
-
marketId?: number;
|
|
816
|
-
}, params?: RequestParams) => Promise<AxiosResponse<ActivePnlPositionResponse[], any>>;
|
|
817
|
-
pnlControllerGetClosedPnlPositions: (query: {
|
|
818
|
-
userAddress: string;
|
|
819
|
-
accountId: number;
|
|
820
|
-
marketId?: number;
|
|
821
|
-
limit?: number;
|
|
822
|
-
skip?: number;
|
|
823
|
-
orderBy?: string;
|
|
824
|
-
}, params?: RequestParams) => Promise<AxiosResponse<ClosedPnlPositionsResponse, any>>;
|
|
825
863
|
pnlControllerGetPnlTransactions: (query: {
|
|
826
864
|
userAddress: string;
|
|
827
865
|
accountId: number;
|
|
@@ -847,6 +885,23 @@ export declare class Sdk<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
847
885
|
orderType?: 0 | 1;
|
|
848
886
|
orderBy?: string;
|
|
849
887
|
}, params?: RequestParams) => Promise<AxiosResponse<LimitOrdersResponse, any>>;
|
|
888
|
+
pnlControllerGetFilledLimitOrders: (query?: {
|
|
889
|
+
userAddress?: string;
|
|
890
|
+
accountId?: number;
|
|
891
|
+
marketId?: number;
|
|
892
|
+
skip?: number;
|
|
893
|
+
limit?: number;
|
|
894
|
+
orderType?: 0 | 1;
|
|
895
|
+
status?: 0 | 1 | 2 | 3 | 4;
|
|
896
|
+
orderBy?: string;
|
|
897
|
+
}, params?: RequestParams) => Promise<AxiosResponse<LimitOrdersResponse, any>>;
|
|
898
|
+
pnlControllerGetTransferLogs: (query: {
|
|
899
|
+
skip?: number;
|
|
900
|
+
limit?: number;
|
|
901
|
+
root: string;
|
|
902
|
+
accountId: number;
|
|
903
|
+
tokenId?: number;
|
|
904
|
+
}, params?: RequestParams) => Promise<AxiosResponse<TransferLogsResponse, any>>;
|
|
850
905
|
};
|
|
851
906
|
settlement: {
|
|
852
907
|
settlementControllerGetSettlements: (query: {
|
|
@@ -894,7 +949,16 @@ export declare class Sdk<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
894
949
|
referralControllerGetReferralActivities: (userAddress: string, params?: RequestParams) => Promise<AxiosResponse<ReferralActivitiesResponse, any>>;
|
|
895
950
|
referralControllerGetReferralRewards: (userAddress: string, params?: RequestParams) => Promise<AxiosResponse<ReferralRewardResponse, any>>;
|
|
896
951
|
};
|
|
952
|
+
merkels: {
|
|
953
|
+
merklesControllerGetMerkleByUserAndCampaign: (campaignId: string, user: string, params?: RequestParams) => Promise<AxiosResponse<UserMerkleResponse, any>>;
|
|
954
|
+
};
|
|
897
955
|
admin: {
|
|
898
956
|
adminControllerTransferMockToken: (data: FaucetDto, params?: RequestParams) => Promise<AxiosResponse<void, any>>;
|
|
899
957
|
};
|
|
958
|
+
configs: {
|
|
959
|
+
configsControllerGetGlobalConfigs: (params?: RequestParams) => Promise<AxiosResponse<GlobalConfigsResponse, any>>;
|
|
960
|
+
};
|
|
961
|
+
incentives: {
|
|
962
|
+
incentivesControllerGetMakerIncentives: (maker: string, params?: RequestParams) => Promise<AxiosResponse<MakerIncentiveActivitiesResponse, any>>;
|
|
963
|
+
};
|
|
900
964
|
}
|
|
@@ -171,6 +171,13 @@ class Sdk extends HttpClient {
|
|
|
171
171
|
format: "json",
|
|
172
172
|
...params,
|
|
173
173
|
}),
|
|
174
|
+
simulationsControllerGetDepositV2: (query, params = {}) => this.request({
|
|
175
|
+
path: `/v2/simulations/deposit`,
|
|
176
|
+
method: "GET",
|
|
177
|
+
query: query,
|
|
178
|
+
format: "json",
|
|
179
|
+
...params,
|
|
180
|
+
}),
|
|
174
181
|
simulationsControllerGetWithdraw: (query, params = {}) => this.request({
|
|
175
182
|
path: `/v1/simulations/withdraw`,
|
|
176
183
|
method: "GET",
|
|
@@ -185,6 +192,13 @@ class Sdk extends HttpClient {
|
|
|
185
192
|
format: "json",
|
|
186
193
|
...params,
|
|
187
194
|
}),
|
|
195
|
+
simulationsControllerGetPlaceOrderV2: (query, params = {}) => this.request({
|
|
196
|
+
path: `/v2/simulations/place-order`,
|
|
197
|
+
method: "GET",
|
|
198
|
+
query: query,
|
|
199
|
+
format: "json",
|
|
200
|
+
...params,
|
|
201
|
+
}),
|
|
188
202
|
simulationsControllerGetPlaceOrder: (query, params = {}) => this.request({
|
|
189
203
|
path: `/v1/simulations/place-order`,
|
|
190
204
|
method: "GET",
|
|
@@ -199,8 +213,8 @@ class Sdk extends HttpClient {
|
|
|
199
213
|
format: "json",
|
|
200
214
|
...params,
|
|
201
215
|
}),
|
|
202
|
-
|
|
203
|
-
path: `/
|
|
216
|
+
simulationsControllerCloseActiveMarketPositionV2: (query, params = {}) => this.request({
|
|
217
|
+
path: `/v2/simulations/close-active-position`,
|
|
204
218
|
method: "GET",
|
|
205
219
|
query: query,
|
|
206
220
|
format: "json",
|
|
@@ -244,6 +258,13 @@ class Sdk extends HttpClient {
|
|
|
244
258
|
format: "json",
|
|
245
259
|
...params,
|
|
246
260
|
}),
|
|
261
|
+
calldataControllerGetDepositCalldataV2: (query, params = {}) => this.request({
|
|
262
|
+
path: `/v2/calldata/deposit`,
|
|
263
|
+
method: "GET",
|
|
264
|
+
query: query,
|
|
265
|
+
format: "json",
|
|
266
|
+
...params,
|
|
267
|
+
}),
|
|
247
268
|
calldataControllerGetWithdrawCalldata: (query, params = {}) => this.request({
|
|
248
269
|
path: `/v1/calldata/withdraw`,
|
|
249
270
|
method: "GET",
|
|
@@ -251,6 +272,27 @@ class Sdk extends HttpClient {
|
|
|
251
272
|
format: "json",
|
|
252
273
|
...params,
|
|
253
274
|
}),
|
|
275
|
+
calldataControllerGetWithdrawRequestCalldata: (query, params = {}) => this.request({
|
|
276
|
+
path: `/v1/calldata/withdraw/request`,
|
|
277
|
+
method: "GET",
|
|
278
|
+
query: query,
|
|
279
|
+
format: "json",
|
|
280
|
+
...params,
|
|
281
|
+
}),
|
|
282
|
+
calldataControllerGetWithdrawCancelCalldata: (query, params = {}) => this.request({
|
|
283
|
+
path: `/v1/calldata/withdraw/cancel`,
|
|
284
|
+
method: "GET",
|
|
285
|
+
query: query,
|
|
286
|
+
format: "json",
|
|
287
|
+
...params,
|
|
288
|
+
}),
|
|
289
|
+
calldataControllerGetWithdrawFinalizeCalldata: (query, params = {}) => this.request({
|
|
290
|
+
path: `/v1/calldata/withdraw/finalize`,
|
|
291
|
+
method: "GET",
|
|
292
|
+
query: query,
|
|
293
|
+
format: "json",
|
|
294
|
+
...params,
|
|
295
|
+
}),
|
|
254
296
|
calldataControllerGetPositionTransferCalldata: (query, params = {}) => this.request({
|
|
255
297
|
path: `/v1/calldata/cash-transfer`,
|
|
256
298
|
method: "GET",
|
|
@@ -258,6 +300,13 @@ class Sdk extends HttpClient {
|
|
|
258
300
|
format: "json",
|
|
259
301
|
...params,
|
|
260
302
|
}),
|
|
303
|
+
calldataControllerGetPlaceOrderCalldataV2: (query, params = {}) => this.request({
|
|
304
|
+
path: `/v2/calldata/place-order`,
|
|
305
|
+
method: "GET",
|
|
306
|
+
query: query,
|
|
307
|
+
format: "json",
|
|
308
|
+
...params,
|
|
309
|
+
}),
|
|
261
310
|
calldataControllerGetPlaceOrderCalldata: (query, params = {}) => this.request({
|
|
262
311
|
path: `/v1/calldata/place-order`,
|
|
263
312
|
method: "GET",
|
|
@@ -280,6 +329,13 @@ class Sdk extends HttpClient {
|
|
|
280
329
|
format: "json",
|
|
281
330
|
...params,
|
|
282
331
|
}),
|
|
332
|
+
calldataControllerGetCloseActiveMarketPositionV2: (query, params = {}) => this.request({
|
|
333
|
+
path: `/v2/calldata/close-active-position`,
|
|
334
|
+
method: "GET",
|
|
335
|
+
query: query,
|
|
336
|
+
format: "json",
|
|
337
|
+
...params,
|
|
338
|
+
}),
|
|
283
339
|
calldataControllerGetCloseActiveMarketPosition: (query, params = {}) => this.request({
|
|
284
340
|
path: `/v1/calldata/close-active-position`,
|
|
285
341
|
method: "GET",
|
|
@@ -357,36 +413,36 @@ class Sdk extends HttpClient {
|
|
|
357
413
|
}),
|
|
358
414
|
};
|
|
359
415
|
pnL = {
|
|
360
|
-
|
|
361
|
-
path: `/v1/pnl/
|
|
416
|
+
pnlControllerGetPnlTransactions: (query, params = {}) => this.request({
|
|
417
|
+
path: `/v1/pnl/transactions`,
|
|
362
418
|
method: "GET",
|
|
363
419
|
query: query,
|
|
364
420
|
format: "json",
|
|
365
421
|
...params,
|
|
366
422
|
}),
|
|
367
|
-
|
|
368
|
-
path: `/v1/pnl/
|
|
423
|
+
pnlControllerGetHistoricalPnlChart: (query, params = {}) => this.request({
|
|
424
|
+
path: `/v1/pnl/historical-chart`,
|
|
369
425
|
method: "GET",
|
|
370
426
|
query: query,
|
|
371
427
|
format: "json",
|
|
372
428
|
...params,
|
|
373
429
|
}),
|
|
374
|
-
|
|
375
|
-
path: `/v1/pnl/
|
|
430
|
+
pnlControllerGetLimitOrders: (query, params = {}) => this.request({
|
|
431
|
+
path: `/v1/pnl/limit-orders`,
|
|
376
432
|
method: "GET",
|
|
377
433
|
query: query,
|
|
378
434
|
format: "json",
|
|
379
435
|
...params,
|
|
380
436
|
}),
|
|
381
|
-
|
|
382
|
-
path: `/v1/pnl/
|
|
437
|
+
pnlControllerGetFilledLimitOrders: (query, params = {}) => this.request({
|
|
438
|
+
path: `/v1/pnl/limit-orders/filled`,
|
|
383
439
|
method: "GET",
|
|
384
440
|
query: query,
|
|
385
441
|
format: "json",
|
|
386
442
|
...params,
|
|
387
443
|
}),
|
|
388
|
-
|
|
389
|
-
path: `/v1/pnl/
|
|
444
|
+
pnlControllerGetTransferLogs: (query, params = {}) => this.request({
|
|
445
|
+
path: `/v1/pnl/transfer-logs`,
|
|
390
446
|
method: "GET",
|
|
391
447
|
query: query,
|
|
392
448
|
format: "json",
|
|
@@ -486,6 +542,14 @@ class Sdk extends HttpClient {
|
|
|
486
542
|
...params,
|
|
487
543
|
}),
|
|
488
544
|
};
|
|
545
|
+
merkels = {
|
|
546
|
+
merklesControllerGetMerkleByUserAndCampaign: (campaignId, user, params = {}) => this.request({
|
|
547
|
+
path: `/v1/merkels/${campaignId}/user/${user}`,
|
|
548
|
+
method: "GET",
|
|
549
|
+
format: "json",
|
|
550
|
+
...params,
|
|
551
|
+
}),
|
|
552
|
+
};
|
|
489
553
|
admin = {
|
|
490
554
|
adminControllerTransferMockToken: (data, params = {}) => this.request({
|
|
491
555
|
path: `/v1/admin/faucet`,
|
|
@@ -496,6 +560,22 @@ class Sdk extends HttpClient {
|
|
|
496
560
|
...params,
|
|
497
561
|
}),
|
|
498
562
|
};
|
|
563
|
+
configs = {
|
|
564
|
+
configsControllerGetGlobalConfigs: (params = {}) => this.request({
|
|
565
|
+
path: `/v1/configs`,
|
|
566
|
+
method: "GET",
|
|
567
|
+
format: "json",
|
|
568
|
+
...params,
|
|
569
|
+
}),
|
|
570
|
+
};
|
|
571
|
+
incentives = {
|
|
572
|
+
incentivesControllerGetMakerIncentives: (maker, params = {}) => this.request({
|
|
573
|
+
path: `/v1/incentives/maker-incentives/${maker}`,
|
|
574
|
+
method: "GET",
|
|
575
|
+
format: "json",
|
|
576
|
+
...params,
|
|
577
|
+
}),
|
|
578
|
+
};
|
|
499
579
|
}
|
|
500
580
|
exports.Sdk = Sdk;
|
|
501
581
|
//# sourceMappingURL=BorosBackendSDK.js.map
|