Fix type definitions for TokenSwap class (#809)
This commit is contained in:
parent
fec7794c22
commit
9ddcd77f3e
|
@ -84,11 +84,12 @@ declare module '@solana/spl-token-swap' {
|
||||||
authority: PublicKey,
|
authority: PublicKey,
|
||||||
tokenAccountA: PublicKey,
|
tokenAccountA: PublicKey,
|
||||||
tokenAccountB: PublicKey,
|
tokenAccountB: PublicKey,
|
||||||
tokenPool: PublicKey,
|
poolToken: PublicKey,
|
||||||
mintA: PublicKey,
|
mintA: PublicKey,
|
||||||
mintB: PublicKey,
|
mintB: PublicKey,
|
||||||
feeAccount: PublicKey,
|
feeAccount: PublicKey,
|
||||||
tokenAccountPool: PublicKey,
|
tokenAccountPool: PublicKey,
|
||||||
|
swapProgramId: PublicKey,
|
||||||
tokenProgramId: PublicKey,
|
tokenProgramId: PublicKey,
|
||||||
nonce: number,
|
nonce: number,
|
||||||
curveType: number,
|
curveType: number,
|
||||||
|
@ -100,7 +101,6 @@ declare module '@solana/spl-token-swap' {
|
||||||
ownerWithdrawFeeDenominator: number,
|
ownerWithdrawFeeDenominator: number,
|
||||||
hostFeeNumerator: number,
|
hostFeeNumerator: number,
|
||||||
hostFeeDenominator: number,
|
hostFeeDenominator: number,
|
||||||
swapProgramId: PublicKey,
|
|
||||||
): Promise<TokenSwap>;
|
): Promise<TokenSwap>;
|
||||||
|
|
||||||
swap(
|
swap(
|
||||||
|
@ -130,14 +130,9 @@ declare module '@solana/spl-token-swap' {
|
||||||
): TransactionInstruction;
|
): TransactionInstruction;
|
||||||
|
|
||||||
deposit(
|
deposit(
|
||||||
authority: PublicKey,
|
userAccountA: PublicKey,
|
||||||
sourceA: PublicKey,
|
userAccountB: PublicKey,
|
||||||
sourceB: PublicKey,
|
|
||||||
intoA: PublicKey,
|
|
||||||
intoB: PublicKey,
|
|
||||||
poolToken: PublicKey,
|
|
||||||
poolAccount: PublicKey,
|
poolAccount: PublicKey,
|
||||||
tokenProgramId: PublicKey,
|
|
||||||
poolTokenAmount: number | Numberu64,
|
poolTokenAmount: number | Numberu64,
|
||||||
maximumTokenA: number | Numberu64,
|
maximumTokenA: number | Numberu64,
|
||||||
maximumTokenB: number | Numberu64,
|
maximumTokenB: number | Numberu64,
|
||||||
|
|
|
@ -46,7 +46,6 @@ declare module '@solana/spl-token-swap' {
|
||||||
): Promise<number>;
|
): Promise<number>;
|
||||||
|
|
||||||
static createInitSwapInstruction(
|
static createInitSwapInstruction(
|
||||||
programId: PublicKey,
|
|
||||||
tokenSwapAccount: Account,
|
tokenSwapAccount: Account,
|
||||||
authority: PublicKey,
|
authority: PublicKey,
|
||||||
tokenAccountA: PublicKey,
|
tokenAccountA: PublicKey,
|
||||||
|
@ -55,6 +54,7 @@ declare module '@solana/spl-token-swap' {
|
||||||
feeAccount: PublicKey,
|
feeAccount: PublicKey,
|
||||||
tokenAccountPool: PublicKey,
|
tokenAccountPool: PublicKey,
|
||||||
tokenProgramId: PublicKey,
|
tokenProgramId: PublicKey,
|
||||||
|
swapProgramId: PublicKey,
|
||||||
nonce: number,
|
nonce: number,
|
||||||
curveType: number,
|
curveType: number,
|
||||||
tradeFeeNumerator: number,
|
tradeFeeNumerator: number,
|
||||||
|
@ -81,11 +81,12 @@ declare module '@solana/spl-token-swap' {
|
||||||
authority: PublicKey,
|
authority: PublicKey,
|
||||||
tokenAccountA: PublicKey,
|
tokenAccountA: PublicKey,
|
||||||
tokenAccountB: PublicKey,
|
tokenAccountB: PublicKey,
|
||||||
tokenPool: PublicKey,
|
poolToken: PublicKey,
|
||||||
mintA: PublicKey,
|
mintA: PublicKey,
|
||||||
mintB: PublicKey,
|
mintB: PublicKey,
|
||||||
feeAccount: PublicKey,
|
feeAccount: PublicKey,
|
||||||
tokenAccountPool: PublicKey,
|
tokenAccountPool: PublicKey,
|
||||||
|
swapProgramId: PublicKey,
|
||||||
tokenProgramId: PublicKey,
|
tokenProgramId: PublicKey,
|
||||||
nonce: number,
|
nonce: number,
|
||||||
curveType: number,
|
curveType: number,
|
||||||
|
@ -97,7 +98,6 @@ declare module '@solana/spl-token-swap' {
|
||||||
ownerWithdrawFeeDenominator: number,
|
ownerWithdrawFeeDenominator: number,
|
||||||
hostFeeNumerator: number,
|
hostFeeNumerator: number,
|
||||||
hostFeeDenominator: number,
|
hostFeeDenominator: number,
|
||||||
programId: PublicKey,
|
|
||||||
): Promise<TokenSwap>;
|
): Promise<TokenSwap>;
|
||||||
|
|
||||||
swap(
|
swap(
|
||||||
|
@ -127,14 +127,9 @@ declare module '@solana/spl-token-swap' {
|
||||||
): TransactionInstruction;
|
): TransactionInstruction;
|
||||||
|
|
||||||
deposit(
|
deposit(
|
||||||
authority: PublicKey,
|
userAccountA: PublicKey,
|
||||||
sourceA: PublicKey,
|
userAccountB: PublicKey,
|
||||||
sourceB: PublicKey,
|
|
||||||
intoA: PublicKey,
|
|
||||||
intoB: PublicKey,
|
|
||||||
poolToken: PublicKey,
|
|
||||||
poolAccount: PublicKey,
|
poolAccount: PublicKey,
|
||||||
tokenProgramId: PublicKey,
|
|
||||||
poolTokenAmount: number | Numberu64,
|
poolTokenAmount: number | Numberu64,
|
||||||
maximumTokenA: number | Numberu64,
|
maximumTokenA: number | Numberu64,
|
||||||
maximumTokenB: number | Numberu64,
|
maximumTokenB: number | Numberu64,
|
||||||
|
|
Loading…
Reference in New Issue