flash-sdk 1.0.44 → 1.0.46
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/PerpetualsClient.d.ts +21 -6
- package/dist/PerpetualsClient.js +575 -379
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +1 -1
@@ -2358,7 +2358,7 @@ export declare class PerpetualsClient {
|
|
2358
2358
|
getAumView: (poolName: string) => Promise<any>;
|
2359
2359
|
getAumTrx: (poolName: string) => Promise<string>;
|
2360
2360
|
getAumSdk: (poolAccount: PoolAccount, token_prices: OraclePrice[], token_ema_prices: OraclePrice[], custodies: CustodyAccount[], aum_calc_mode: AumCalcMode, currentTime: BN) => BN;
|
2361
|
-
openPosition: (marketSymbol: string, collateralSymbol: string, priceAfterSlippage: BN, collateralWithfee: BN,
|
2361
|
+
openPosition: (marketSymbol: string, collateralSymbol: string, priceAfterSlippage: BN, collateralWithfee: BN, size: BN, side: Side, poolConfig: PoolConfig, skipBalanceChecks?: boolean) => Promise<{
|
2362
2362
|
instructions: TransactionInstruction[];
|
2363
2363
|
additionalSigners: Signer[];
|
2364
2364
|
}>;
|
@@ -2366,10 +2366,25 @@ export declare class PerpetualsClient {
|
|
2366
2366
|
instructions: TransactionInstruction[];
|
2367
2367
|
additionalSigners: Signer[];
|
2368
2368
|
}>;
|
2369
|
-
swap: (
|
2370
|
-
|
2371
|
-
|
2372
|
-
|
2373
|
-
|
2369
|
+
swap: (userInputTokenSymbol: string, userOutputTokenSymbol: string, amountIn: BN, minAmountOut: BN, poolConfig: PoolConfig, createUserATA?: boolean, unWrapSol?: boolean, skipBalanceChecks?: boolean) => Promise<{
|
2370
|
+
instructions: TransactionInstruction[];
|
2371
|
+
additionalSigners: Signer[];
|
2372
|
+
}>;
|
2373
|
+
addCollateral: (collateralWithFee: BN, marketSymbol: string, collateralSymbol: string, positionPubKey: PublicKey, poolConfig: PoolConfig, skipBalanceChecks?: boolean) => Promise<{
|
2374
|
+
instructions: TransactionInstruction[];
|
2375
|
+
additionalSigners: Signer[];
|
2376
|
+
}>;
|
2377
|
+
removeCollateral: (collateralWithFee: BN, marketSymbol: string, collateralSymbol: string, positionPubKey: PublicKey, poolConfig: PoolConfig, createUserATA?: boolean, closeUsersWSOLATA?: boolean) => Promise<{
|
2378
|
+
instructions: TransactionInstruction[];
|
2379
|
+
additionalSigners: Signer[];
|
2380
|
+
}>;
|
2381
|
+
addLiquidity: (payTokenSymbol: string, tokenAmountIn: BN, minLpAmountOut: BN, poolConfig: PoolConfig, skipBalanceChecks?: boolean) => Promise<{
|
2382
|
+
instructions: TransactionInstruction[];
|
2383
|
+
additionalSigners: Signer[];
|
2384
|
+
}>;
|
2385
|
+
removeLiquidity: (recieveTokenSymbol: string, liquidityAmountIn: BN, minTokenAmountOut: BN, poolConfig: PoolConfig, closeLpATA?: boolean, createUserATA?: boolean, closeUsersWSOLATA?: boolean) => Promise<{
|
2386
|
+
instructions: TransactionInstruction[];
|
2387
|
+
additionalSigners: Signer[];
|
2388
|
+
}>;
|
2374
2389
|
sendTransaction(ixs: TransactionInstruction[], opts?: SendTransactionOpts): Promise<string>;
|
2375
2390
|
}
|