@picon-finance/dlmm-sdk 2.0.3 → 2.0.4
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/generated/instructions/acceptAdminAuthority.d.ts +12 -11
- package/dist/generated/instructions/acceptAdminAuthority.d.ts.map +1 -1
- package/dist/generated/instructions/acceptAdminAuthority.js +16 -4
- package/dist/generated/instructions/claimFee.d.ts +19 -18
- package/dist/generated/instructions/claimFee.d.ts.map +1 -1
- package/dist/generated/instructions/claimFee.js +52 -12
- package/dist/generated/instructions/claimProtocolFee.d.ts +30 -29
- package/dist/generated/instructions/claimProtocolFee.d.ts.map +1 -1
- package/dist/generated/instructions/claimProtocolFee.js +90 -20
- package/dist/generated/instructions/closePosition.d.ts +18 -17
- package/dist/generated/instructions/closePosition.d.ts.map +1 -1
- package/dist/generated/instructions/closePosition.js +38 -10
- package/dist/generated/instructions/createAdminConfig.d.ts +18 -17
- package/dist/generated/instructions/createAdminConfig.d.ts.map +1 -1
- package/dist/generated/instructions/createAdminConfig.js +54 -12
- package/dist/generated/instructions/createBinArray.d.ts +16 -15
- package/dist/generated/instructions/createBinArray.d.ts.map +1 -1
- package/dist/generated/instructions/createBinArray.js +28 -10
- package/dist/generated/instructions/createPool.d.ts +30 -29
- package/dist/generated/instructions/createPool.d.ts.map +1 -1
- package/dist/generated/instructions/createPool.js +98 -22
- package/dist/generated/instructions/deleteBinArray.d.ts +18 -17
- package/dist/generated/instructions/deleteBinArray.d.ts.map +1 -1
- package/dist/generated/instructions/deleteBinArray.js +54 -12
- package/dist/generated/instructions/depositByWeight.d.ts +19 -18
- package/dist/generated/instructions/depositByWeight.d.ts.map +1 -1
- package/dist/generated/instructions/depositByWeight.js +52 -12
- package/dist/generated/instructions/openPosition.d.ts +28 -27
- package/dist/generated/instructions/openPosition.d.ts.map +1 -1
- package/dist/generated/instructions/openPosition.js +64 -16
- package/dist/generated/instructions/resetAdminAuthority.d.ts +16 -15
- package/dist/generated/instructions/resetAdminAuthority.d.ts.map +1 -1
- package/dist/generated/instructions/resetAdminAuthority.js +44 -10
- package/dist/generated/instructions/setMetadataUpdateAuthority.d.ts +12 -11
- package/dist/generated/instructions/setMetadataUpdateAuthority.d.ts.map +1 -1
- package/dist/generated/instructions/setMetadataUpdateAuthority.js +24 -6
- package/dist/generated/instructions/setPoolDynamicFeeConfig.d.ts +14 -13
- package/dist/generated/instructions/setPoolDynamicFeeConfig.d.ts.map +1 -1
- package/dist/generated/instructions/setPoolDynamicFeeConfig.js +26 -8
- package/dist/generated/instructions/setPoolProtocolShare.d.ts +14 -13
- package/dist/generated/instructions/setPoolProtocolShare.d.ts.map +1 -1
- package/dist/generated/instructions/setPoolProtocolShare.js +26 -8
- package/dist/generated/instructions/swapExactIn.d.ts +15 -14
- package/dist/generated/instructions/swapExactIn.d.ts.map +1 -1
- package/dist/generated/instructions/swapExactIn.js +36 -9
- package/dist/generated/instructions/swapExactOut.d.ts +15 -14
- package/dist/generated/instructions/swapExactOut.d.ts.map +1 -1
- package/dist/generated/instructions/swapExactOut.js +36 -9
- package/dist/generated/instructions/syncPool.d.ts +7 -6
- package/dist/generated/instructions/syncPool.d.ts.map +1 -1
- package/dist/generated/instructions/syncPool.js +4 -3
- package/dist/generated/instructions/transferAdminAuthority.d.ts +12 -11
- package/dist/generated/instructions/transferAdminAuthority.d.ts.map +1 -1
- package/dist/generated/instructions/transferAdminAuthority.js +24 -6
- package/dist/generated/instructions/withdraw.d.ts +19 -18
- package/dist/generated/instructions/withdraw.d.ts.map +1 -1
- package/dist/generated/instructions/withdraw.js +52 -12
- package/package.json +5 -5
- package/src/generated/instructions/acceptAdminAuthority.ts +68 -25
- package/src/generated/instructions/claimFee.ts +218 -83
- package/src/generated/instructions/claimProtocolFee.ts +346 -131
- package/src/generated/instructions/closePosition.ts +160 -61
- package/src/generated/instructions/createAdminConfig.ts +172 -63
- package/src/generated/instructions/createBinArray.ts +124 -51
- package/src/generated/instructions/createPool.ts +354 -133
- package/src/generated/instructions/deleteBinArray.ts +172 -63
- package/src/generated/instructions/depositByWeight.ts +218 -83
- package/src/generated/instructions/openPosition.ts +300 -117
- package/src/generated/instructions/resetAdminAuthority.ts +138 -51
- package/src/generated/instructions/setMetadataUpdateAuthority.ts +74 -27
- package/src/generated/instructions/setPoolDynamicFeeConfig.ts +98 -39
- package/src/generated/instructions/setPoolProtocolShare.ts +98 -39
- package/src/generated/instructions/swapExactIn.ts +155 -60
- package/src/generated/instructions/swapExactOut.ts +155 -60
- package/src/generated/instructions/syncPool.ts +37 -12
- package/src/generated/instructions/transferAdminAuthority.ts +74 -27
- package/src/generated/instructions/withdraw.ts +218 -83
|
@@ -5,7 +5,8 @@
|
|
|
5
5
|
*
|
|
6
6
|
* @see https://github.com/codama-idl/codama
|
|
7
7
|
*/
|
|
8
|
-
import { type AccountMeta, type AccountSignerMeta, type Address, type FixedSizeCodec, type FixedSizeDecoder, type FixedSizeEncoder, type Instruction, type InstructionWithAccounts, type InstructionWithData, type ReadonlySignerAccount, type ReadonlyUint8Array, type
|
|
8
|
+
import { type AccountMeta, type AccountSignerMeta, type Address, type FixedSizeCodec, type FixedSizeDecoder, type FixedSizeEncoder, type Instruction, type InstructionWithAccounts, type InstructionWithData, type ReadonlySignerAccount, type ReadonlyUint8Array, type WritableAccount } from "@solana/kit";
|
|
9
|
+
import { type InstructionAccountInput, type InstructionAccountInputAddress, type InstructionSignerInput, type ResolvedInstructionAccountMeta } from "@solana/program-client-core";
|
|
9
10
|
import { PICON_DLMM_PROGRAM_ADDRESS } from "../programs/index.js";
|
|
10
11
|
export declare const ACCEPT_ADMIN_AUTHORITY_DISCRIMINATOR: ReadonlyUint8Array;
|
|
11
12
|
export declare function getAcceptAdminAuthorityDiscriminatorBytes(): ReadonlyUint8Array;
|
|
@@ -21,20 +22,20 @@ export type AcceptAdminAuthorityInstructionDataArgs = {};
|
|
|
21
22
|
export declare function getAcceptAdminAuthorityInstructionDataEncoder(): FixedSizeEncoder<AcceptAdminAuthorityInstructionDataArgs>;
|
|
22
23
|
export declare function getAcceptAdminAuthorityInstructionDataDecoder(): FixedSizeDecoder<AcceptAdminAuthorityInstructionData>;
|
|
23
24
|
export declare function getAcceptAdminAuthorityInstructionDataCodec(): FixedSizeCodec<AcceptAdminAuthorityInstructionDataArgs, AcceptAdminAuthorityInstructionData>;
|
|
24
|
-
export type AcceptAdminAuthorityAsyncInput<TAccountPendingAuthority extends
|
|
25
|
-
pendingAuthority:
|
|
26
|
-
adminConfig?:
|
|
25
|
+
export type AcceptAdminAuthorityAsyncInput<TAccountPendingAuthority extends InstructionSignerInput = InstructionSignerInput, TAccountAdminConfig extends InstructionAccountInput = InstructionAccountInput> = {
|
|
26
|
+
pendingAuthority: TAccountPendingAuthority;
|
|
27
|
+
adminConfig?: TAccountAdminConfig;
|
|
27
28
|
};
|
|
28
|
-
export declare function getAcceptAdminAuthorityInstructionAsync<TAccountPendingAuthority extends
|
|
29
|
+
export declare function getAcceptAdminAuthorityInstructionAsync<TAccountPendingAuthority extends InstructionSignerInput, TAccountAdminConfig extends InstructionAccountInput, TProgramAddress extends Address = typeof PICON_DLMM_PROGRAM_ADDRESS>(input: AcceptAdminAuthorityAsyncInput<TAccountPendingAuthority, TAccountAdminConfig>, config?: {
|
|
29
30
|
programAddress?: TProgramAddress;
|
|
30
|
-
}): Promise<AcceptAdminAuthorityInstruction<TProgramAddress, TAccountPendingAuthority, TAccountAdminConfig
|
|
31
|
-
export type AcceptAdminAuthorityInput<TAccountPendingAuthority extends
|
|
32
|
-
pendingAuthority:
|
|
33
|
-
adminConfig:
|
|
31
|
+
}): Promise<AcceptAdminAuthorityInstruction<TProgramAddress, ResolvedInstructionAccountMeta<TAccountPendingAuthority, InstructionAccountInputAddress<TAccountPendingAuthority>>, ResolvedInstructionAccountMeta<TAccountAdminConfig, InstructionAccountInputAddress<TAccountAdminConfig>>>>;
|
|
32
|
+
export type AcceptAdminAuthorityInput<TAccountPendingAuthority extends InstructionSignerInput = InstructionSignerInput, TAccountAdminConfig extends InstructionAccountInput = InstructionAccountInput> = {
|
|
33
|
+
pendingAuthority: TAccountPendingAuthority;
|
|
34
|
+
adminConfig: TAccountAdminConfig;
|
|
34
35
|
};
|
|
35
|
-
export declare function getAcceptAdminAuthorityInstruction<TAccountPendingAuthority extends
|
|
36
|
+
export declare function getAcceptAdminAuthorityInstruction<TAccountPendingAuthority extends InstructionSignerInput, TAccountAdminConfig extends InstructionAccountInput, TProgramAddress extends Address = typeof PICON_DLMM_PROGRAM_ADDRESS>(input: AcceptAdminAuthorityInput<TAccountPendingAuthority, TAccountAdminConfig>, config?: {
|
|
36
37
|
programAddress?: TProgramAddress;
|
|
37
|
-
}): AcceptAdminAuthorityInstruction<TProgramAddress, TAccountPendingAuthority, TAccountAdminConfig
|
|
38
|
+
}): AcceptAdminAuthorityInstruction<TProgramAddress, ResolvedInstructionAccountMeta<TAccountPendingAuthority, InstructionAccountInputAddress<TAccountPendingAuthority>>, ResolvedInstructionAccountMeta<TAccountAdminConfig, InstructionAccountInputAddress<TAccountAdminConfig>>>;
|
|
38
39
|
export type ParsedAcceptAdminAuthorityInstruction<TProgram extends string = typeof PICON_DLMM_PROGRAM_ADDRESS, TAccountMetas extends readonly AccountMeta[] = readonly AccountMeta[]> = {
|
|
39
40
|
programAddress: Address<TProgram>;
|
|
40
41
|
accounts: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"acceptAdminAuthority.d.ts","sourceRoot":"","sources":["../../../src/generated/instructions/acceptAdminAuthority.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAWL,KAAK,WAAW,EAChB,KAAK,iBAAiB,EACtB,KAAK,OAAO,EACZ,KAAK,cAAc,EACnB,KAAK,gBAAgB,EACrB,KAAK,gBAAgB,EACrB,KAAK,WAAW,EAChB,KAAK,uBAAuB,EAC5B,KAAK,mBAAmB,EACxB,KAAK,qBAAqB,EAC1B,KAAK,kBAAkB,EACvB,KAAK,
|
|
1
|
+
{"version":3,"file":"acceptAdminAuthority.d.ts","sourceRoot":"","sources":["../../../src/generated/instructions/acceptAdminAuthority.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAWL,KAAK,WAAW,EAChB,KAAK,iBAAiB,EACtB,KAAK,OAAO,EACZ,KAAK,cAAc,EACnB,KAAK,gBAAgB,EACrB,KAAK,gBAAgB,EACrB,KAAK,WAAW,EAChB,KAAK,uBAAuB,EAC5B,KAAK,mBAAmB,EACxB,KAAK,qBAAqB,EAC1B,KAAK,kBAAkB,EACvB,KAAK,eAAe,EACrB,MAAM,aAAa,CAAC;AACrB,OAAO,EAEL,KAAK,uBAAuB,EAC5B,KAAK,8BAA8B,EACnC,KAAK,sBAAsB,EAE3B,KAAK,8BAA8B,EACpC,MAAM,6BAA6B,CAAC;AAErC,OAAO,EAAE,0BAA0B,EAAE,MAAM,sBAAsB,CAAC;AAElE,eAAO,MAAM,oCAAoC,EAAE,kBACG,CAAC;AAEvD,wBAAgB,yCAAyC,IAAI,kBAAkB,CAI9E;AAED,MAAM,MAAM,+BAA+B,CACzC,QAAQ,SAAS,MAAM,GAAG,OAAO,0BAA0B,EAC3D,wBAAwB,SAAS,MAAM,GAAG,WAAW,CAAC,MAAM,CAAC,GAAG,MAAM,EACtE,mBAAmB,SAAS,MAAM,GAAG,WAAW,CAAC,MAAM,CAAC,GAAG,MAAM,EACjE,kBAAkB,SAAS,SAAS,WAAW,CAAC,MAAM,CAAC,EAAE,GAAG,EAAE,IAC5D,WAAW,CAAC,QAAQ,CAAC,GACvB,mBAAmB,CAAC,kBAAkB,CAAC,GACvC,uBAAuB,CACrB;IACE,wBAAwB,SAAS,MAAM,GACnC,qBAAqB,CAAC,wBAAwB,CAAC,GAC7C,iBAAiB,CAAC,wBAAwB,CAAC,GAC7C,wBAAwB;IAC5B,mBAAmB,SAAS,MAAM,GAC9B,eAAe,CAAC,mBAAmB,CAAC,GACpC,mBAAmB;IACvB,GAAG,kBAAkB;CACtB,CACF,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BAAsB,EACvD,mBAAmB,SAAS,uBAAuB,EACnD,eAAe,SAAS,OAAO,GAAG,OAAO,0BAA0B,EAEnE,KAAK,EAAE,yBAAyB,CAC9B,wBAAwB,EACxB,mBAAmB,CACpB,EACD,MAAM,CAAC,EAAE;IAAE,cAAc,CAAC,EAAE,eAAe,CAAA;CAAE,GAC5C,+BAA+B,CAChC,eAAe,EACf,8BAA8B,CAC5B,wBAAwB,EACxB,8BAA8B,CAAC,wBAAwB,CAAC,CACzD,EACD,8BAA8B,CAC5B,mBAAmB,EACnB,8BAA8B,CAAC,mBAAmB,CAAC,CACpD,CACF,CA2CA;AAED,MAAM,MAAM,qCAAqC,CAC/C,QAAQ,SAAS,MAAM,GAAG,OAAO,0BAA0B,EAC3D,aAAa,SAAS,SAAS,WAAW,EAAE,GAAG,SAAS,WAAW,EAAE,IACnE;IACF,cAAc,EAAE,OAAO,CAAC,QAAQ,CAAC,CAAC;IAClC,QAAQ,EAAE;QACR,gBAAgB,EAAE,aAAa,CAAC,CAAC,CAAC,CAAC;QACnC,WAAW,EAAE,aAAa,CAAC,CAAC,CAAC,CAAC;KAC/B,CAAC;IACF,IAAI,EAAE,mCAAmC,CAAC;CAC3C,CAAC;AAEF,wBAAgB,oCAAoC,CAClD,QAAQ,SAAS,MAAM,EACvB,aAAa,SAAS,SAAS,WAAW,EAAE,EAE5C,WAAW,EAAE,WAAW,CAAC,QAAQ,CAAC,GAChC,uBAAuB,CAAC,aAAa,CAAC,GACtC,mBAAmB,CAAC,kBAAkB,CAAC,GACxC,qCAAqC,CAAC,QAAQ,EAAE,aAAa,CAAC,CA0BhE"}
|
|
@@ -30,20 +30,26 @@ export function getAcceptAdminAuthorityInstructionDataCodec() {
|
|
|
30
30
|
export async function getAcceptAdminAuthorityInstructionAsync(input, config) {
|
|
31
31
|
// Program address.
|
|
32
32
|
const programAddress = config?.programAddress ?? PICON_DLMM_PROGRAM_ADDRESS;
|
|
33
|
+
// Account meta helper.
|
|
34
|
+
const getAccountMeta = getAccountMetaFactory(programAddress, "programId");
|
|
33
35
|
// Original accounts.
|
|
34
36
|
const originalAccounts = {
|
|
35
37
|
pendingAuthority: {
|
|
36
38
|
value: input.pendingAuthority ?? null,
|
|
39
|
+
isSigner: true,
|
|
37
40
|
isWritable: false,
|
|
38
41
|
},
|
|
39
|
-
adminConfig: {
|
|
42
|
+
adminConfig: {
|
|
43
|
+
value: input.adminConfig ?? null,
|
|
44
|
+
isSigner: false,
|
|
45
|
+
isWritable: true,
|
|
46
|
+
},
|
|
40
47
|
};
|
|
41
48
|
const accounts = originalAccounts;
|
|
42
49
|
// Resolve default values.
|
|
43
50
|
if (!accounts.adminConfig.value) {
|
|
44
51
|
accounts.adminConfig.value = await findAdminConfigPda({ programAddress });
|
|
45
52
|
}
|
|
46
|
-
const getAccountMeta = getAccountMetaFactory(programAddress, "programId");
|
|
47
53
|
return Object.freeze({
|
|
48
54
|
accounts: [
|
|
49
55
|
getAccountMeta("pendingAuthority", accounts.pendingAuthority),
|
|
@@ -56,16 +62,22 @@ export async function getAcceptAdminAuthorityInstructionAsync(input, config) {
|
|
|
56
62
|
export function getAcceptAdminAuthorityInstruction(input, config) {
|
|
57
63
|
// Program address.
|
|
58
64
|
const programAddress = config?.programAddress ?? PICON_DLMM_PROGRAM_ADDRESS;
|
|
65
|
+
// Account meta helper.
|
|
66
|
+
const getAccountMeta = getAccountMetaFactory(programAddress, "programId");
|
|
59
67
|
// Original accounts.
|
|
60
68
|
const originalAccounts = {
|
|
61
69
|
pendingAuthority: {
|
|
62
70
|
value: input.pendingAuthority ?? null,
|
|
71
|
+
isSigner: true,
|
|
63
72
|
isWritable: false,
|
|
64
73
|
},
|
|
65
|
-
adminConfig: {
|
|
74
|
+
adminConfig: {
|
|
75
|
+
value: input.adminConfig ?? null,
|
|
76
|
+
isSigner: false,
|
|
77
|
+
isWritable: true,
|
|
78
|
+
},
|
|
66
79
|
};
|
|
67
80
|
const accounts = originalAccounts;
|
|
68
|
-
const getAccountMeta = getAccountMetaFactory(programAddress, "programId");
|
|
69
81
|
return Object.freeze({
|
|
70
82
|
accounts: [
|
|
71
83
|
getAccountMeta("pendingAuthority", accounts.pendingAuthority),
|
|
@@ -5,7 +5,8 @@
|
|
|
5
5
|
*
|
|
6
6
|
* @see https://github.com/codama-idl/codama
|
|
7
7
|
*/
|
|
8
|
-
import { type AccountMeta, type AccountSignerMeta, type Address, type Codec, type Decoder, type Encoder, type Instruction, type InstructionWithAccounts, type InstructionWithData, type Option, type OptionOrNullable, type ReadonlyAccount, type ReadonlySignerAccount, type ReadonlyUint8Array, type
|
|
8
|
+
import { type AccountMeta, type AccountSignerMeta, type Address, type Codec, type Decoder, type Encoder, type Instruction, type InstructionWithAccounts, type InstructionWithData, type Option, type OptionOrNullable, type ReadonlyAccount, type ReadonlySignerAccount, type ReadonlyUint8Array, type WritableAccount } from "@solana/kit";
|
|
9
|
+
import { type InstructionAccountInput, type InstructionAccountInputAddress, type InstructionSignerInput, type ResolvedInstructionAccountMeta } from "@solana/program-client-core";
|
|
9
10
|
import { PICON_DLMM_PROGRAM_ADDRESS } from "../programs/index.js";
|
|
10
11
|
import { type RemainingAccountsScheme, type RemainingAccountsSchemeArgs } from "../types/index.js";
|
|
11
12
|
export declare const CLAIM_FEE_DISCRIMINATOR: ReadonlyUint8Array;
|
|
@@ -41,28 +42,28 @@ export type ClaimFeeInstructionDataArgs = {
|
|
|
41
42
|
export declare function getClaimFeeInstructionDataEncoder(): Encoder<ClaimFeeInstructionDataArgs>;
|
|
42
43
|
export declare function getClaimFeeInstructionDataDecoder(): Decoder<ClaimFeeInstructionData>;
|
|
43
44
|
export declare function getClaimFeeInstructionDataCodec(): Codec<ClaimFeeInstructionDataArgs, ClaimFeeInstructionData>;
|
|
44
|
-
export type ClaimFeeInput<TAccountOwner extends
|
|
45
|
-
owner:
|
|
46
|
-
pool:
|
|
47
|
-
position:
|
|
48
|
-
positionTokenAccount:
|
|
49
|
-
tokenMintX:
|
|
50
|
-
tokenMintY:
|
|
51
|
-
tokenOwnerAccountX:
|
|
52
|
-
tokenOwnerAccountY:
|
|
53
|
-
tokenVaultX:
|
|
54
|
-
tokenVaultY:
|
|
55
|
-
tokenProgramX:
|
|
56
|
-
tokenProgramY:
|
|
57
|
-
lowerBinArray:
|
|
58
|
-
upperBinArray?:
|
|
45
|
+
export type ClaimFeeInput<TAccountOwner extends InstructionSignerInput = InstructionSignerInput, TAccountPool extends InstructionAccountInput = InstructionAccountInput, TAccountPosition extends InstructionAccountInput = InstructionAccountInput, TAccountPositionTokenAccount extends InstructionAccountInput = InstructionAccountInput, TAccountTokenMintX extends InstructionAccountInput = InstructionAccountInput, TAccountTokenMintY extends InstructionAccountInput = InstructionAccountInput, TAccountTokenOwnerAccountX extends InstructionAccountInput = InstructionAccountInput, TAccountTokenOwnerAccountY extends InstructionAccountInput = InstructionAccountInput, TAccountTokenVaultX extends InstructionAccountInput = InstructionAccountInput, TAccountTokenVaultY extends InstructionAccountInput = InstructionAccountInput, TAccountTokenProgramX extends InstructionAccountInput = InstructionAccountInput, TAccountTokenProgramY extends InstructionAccountInput = InstructionAccountInput, TAccountLowerBinArray extends InstructionAccountInput = InstructionAccountInput, TAccountUpperBinArray extends InstructionAccountInput = InstructionAccountInput> = {
|
|
46
|
+
owner: TAccountOwner;
|
|
47
|
+
pool: TAccountPool;
|
|
48
|
+
position: TAccountPosition;
|
|
49
|
+
positionTokenAccount: TAccountPositionTokenAccount;
|
|
50
|
+
tokenMintX: TAccountTokenMintX;
|
|
51
|
+
tokenMintY: TAccountTokenMintY;
|
|
52
|
+
tokenOwnerAccountX: TAccountTokenOwnerAccountX;
|
|
53
|
+
tokenOwnerAccountY: TAccountTokenOwnerAccountY;
|
|
54
|
+
tokenVaultX: TAccountTokenVaultX;
|
|
55
|
+
tokenVaultY: TAccountTokenVaultY;
|
|
56
|
+
tokenProgramX: TAccountTokenProgramX;
|
|
57
|
+
tokenProgramY: TAccountTokenProgramY;
|
|
58
|
+
lowerBinArray: TAccountLowerBinArray;
|
|
59
|
+
upperBinArray?: TAccountUpperBinArray;
|
|
59
60
|
lowerBinId: ClaimFeeInstructionDataArgs["lowerBinId"];
|
|
60
61
|
upperBinId: ClaimFeeInstructionDataArgs["upperBinId"];
|
|
61
62
|
remainingAccountsScheme: ClaimFeeInstructionDataArgs["remainingAccountsScheme"];
|
|
62
63
|
};
|
|
63
|
-
export declare function getClaimFeeInstruction<TAccountOwner extends
|
|
64
|
+
export declare function getClaimFeeInstruction<TAccountOwner extends InstructionSignerInput, TAccountPool extends InstructionAccountInput, TAccountPosition extends InstructionAccountInput, TAccountPositionTokenAccount extends InstructionAccountInput, TAccountTokenMintX extends InstructionAccountInput, TAccountTokenMintY extends InstructionAccountInput, TAccountTokenOwnerAccountX extends InstructionAccountInput, TAccountTokenOwnerAccountY extends InstructionAccountInput, TAccountTokenVaultX extends InstructionAccountInput, TAccountTokenVaultY extends InstructionAccountInput, TAccountTokenProgramX extends InstructionAccountInput, TAccountTokenProgramY extends InstructionAccountInput, TAccountLowerBinArray extends InstructionAccountInput, TAccountUpperBinArray extends InstructionAccountInput, TProgramAddress extends Address = typeof PICON_DLMM_PROGRAM_ADDRESS>(input: ClaimFeeInput<TAccountOwner, TAccountPool, TAccountPosition, TAccountPositionTokenAccount, TAccountTokenMintX, TAccountTokenMintY, TAccountTokenOwnerAccountX, TAccountTokenOwnerAccountY, TAccountTokenVaultX, TAccountTokenVaultY, TAccountTokenProgramX, TAccountTokenProgramY, TAccountLowerBinArray, TAccountUpperBinArray>, config?: {
|
|
64
65
|
programAddress?: TProgramAddress;
|
|
65
|
-
}): ClaimFeeInstruction<TProgramAddress, TAccountOwner, TAccountPool, TAccountPosition, TAccountPositionTokenAccount, TAccountTokenMintX, TAccountTokenMintY, TAccountTokenOwnerAccountX, TAccountTokenOwnerAccountY, TAccountTokenVaultX, TAccountTokenVaultY, TAccountTokenProgramX, TAccountTokenProgramY, TAccountLowerBinArray, TAccountUpperBinArray
|
|
66
|
+
}): ClaimFeeInstruction<TProgramAddress, ResolvedInstructionAccountMeta<TAccountOwner, InstructionAccountInputAddress<TAccountOwner>>, ResolvedInstructionAccountMeta<TAccountPool, InstructionAccountInputAddress<TAccountPool>>, ResolvedInstructionAccountMeta<TAccountPosition, InstructionAccountInputAddress<TAccountPosition>>, ResolvedInstructionAccountMeta<TAccountPositionTokenAccount, InstructionAccountInputAddress<TAccountPositionTokenAccount>>, ResolvedInstructionAccountMeta<TAccountTokenMintX, InstructionAccountInputAddress<TAccountTokenMintX>>, ResolvedInstructionAccountMeta<TAccountTokenMintY, InstructionAccountInputAddress<TAccountTokenMintY>>, ResolvedInstructionAccountMeta<TAccountTokenOwnerAccountX, InstructionAccountInputAddress<TAccountTokenOwnerAccountX>>, ResolvedInstructionAccountMeta<TAccountTokenOwnerAccountY, InstructionAccountInputAddress<TAccountTokenOwnerAccountY>>, ResolvedInstructionAccountMeta<TAccountTokenVaultX, InstructionAccountInputAddress<TAccountTokenVaultX>>, ResolvedInstructionAccountMeta<TAccountTokenVaultY, InstructionAccountInputAddress<TAccountTokenVaultY>>, ResolvedInstructionAccountMeta<TAccountTokenProgramX, InstructionAccountInputAddress<TAccountTokenProgramX>>, ResolvedInstructionAccountMeta<TAccountTokenProgramY, InstructionAccountInputAddress<TAccountTokenProgramY>>, ResolvedInstructionAccountMeta<TAccountLowerBinArray, InstructionAccountInputAddress<TAccountLowerBinArray>>, ResolvedInstructionAccountMeta<TAccountUpperBinArray, InstructionAccountInputAddress<TAccountUpperBinArray>>>;
|
|
66
67
|
export type ParsedClaimFeeInstruction<TProgram extends string = typeof PICON_DLMM_PROGRAM_ADDRESS, TAccountMetas extends readonly AccountMeta[] = readonly AccountMeta[]> = {
|
|
67
68
|
programAddress: Address<TProgram>;
|
|
68
69
|
accounts: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"claimFee.d.ts","sourceRoot":"","sources":["../../../src/generated/instructions/claimFee.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,O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,CAAC,CAAC,CAAC;QAC7B,UAAU,EAAE,aAAa,CAAC,CAAC,CAAC,CAAC;QAC7B,kBAAkB,EAAE,aAAa,CAAC,CAAC,CAAC,CAAC;QACrC,kBAAkB,EAAE,aAAa,CAAC,CAAC,CAAC,CAAC;QACrC,WAAW,EAAE,aAAa,CAAC,CAAC,CAAC,CAAC;QAC9B,WAAW,EAAE,aAAa,CAAC,CAAC,CAAC,CAAC;QAC9B,aAAa,EAAE,aAAa,CAAC,EAAE,CAAC,CAAC;QACjC,aAAa,EAAE,aAAa,CAAC,EAAE,CAAC,CAAC;QACjC,aAAa,EAAE,aAAa,CAAC,EAAE,CAAC,CAAC;QACjC,aAAa,CAAC,EAAE,aAAa,CAAC,EAAE,CAAC,GAAG,SAAS,CAAC;KAC/C,CAAC;IACF,IAAI,EAAE,uBAAuB,CAAC;CAC/B,CAAC;AAEF,wBAAgB,wBAAwB,CACtC,QAAQ,SAAS,MAAM,EACvB,aAAa,SAAS,SAAS,WAAW,EAAE,EAE5C,WAAW,EAAE,WAAW,CAAC,QAAQ,CAAC,GAChC,uBAAuB,CAAC,aAAa,CAAC,GACtC,mBAAmB,CAAC,kBAAkB,CAAC,GACxC,yBAAyB,CAAC,QAAQ,EAAE,aAAa,CAAC,CA0CpD"}
|
|
@@ -43,36 +43,76 @@ export function getClaimFeeInstructionDataCodec() {
|
|
|
43
43
|
export function getClaimFeeInstruction(input, config) {
|
|
44
44
|
// Program address.
|
|
45
45
|
const programAddress = config?.programAddress ?? PICON_DLMM_PROGRAM_ADDRESS;
|
|
46
|
+
// Account meta helper.
|
|
47
|
+
const getAccountMeta = getAccountMetaFactory(programAddress, "programId");
|
|
46
48
|
// Original accounts.
|
|
47
49
|
const originalAccounts = {
|
|
48
|
-
owner: { value: input.owner ?? null, isWritable: false },
|
|
49
|
-
pool: { value: input.pool ?? null, isWritable: false },
|
|
50
|
-
position: {
|
|
50
|
+
owner: { value: input.owner ?? null, isSigner: true, isWritable: false },
|
|
51
|
+
pool: { value: input.pool ?? null, isSigner: false, isWritable: false },
|
|
52
|
+
position: {
|
|
53
|
+
value: input.position ?? null,
|
|
54
|
+
isSigner: false,
|
|
55
|
+
isWritable: true,
|
|
56
|
+
},
|
|
51
57
|
positionTokenAccount: {
|
|
52
58
|
value: input.positionTokenAccount ?? null,
|
|
59
|
+
isSigner: false,
|
|
60
|
+
isWritable: false,
|
|
61
|
+
},
|
|
62
|
+
tokenMintX: {
|
|
63
|
+
value: input.tokenMintX ?? null,
|
|
64
|
+
isSigner: false,
|
|
65
|
+
isWritable: false,
|
|
66
|
+
},
|
|
67
|
+
tokenMintY: {
|
|
68
|
+
value: input.tokenMintY ?? null,
|
|
69
|
+
isSigner: false,
|
|
53
70
|
isWritable: false,
|
|
54
71
|
},
|
|
55
|
-
tokenMintX: { value: input.tokenMintX ?? null, isWritable: false },
|
|
56
|
-
tokenMintY: { value: input.tokenMintY ?? null, isWritable: false },
|
|
57
72
|
tokenOwnerAccountX: {
|
|
58
73
|
value: input.tokenOwnerAccountX ?? null,
|
|
74
|
+
isSigner: false,
|
|
59
75
|
isWritable: true,
|
|
60
76
|
},
|
|
61
77
|
tokenOwnerAccountY: {
|
|
62
78
|
value: input.tokenOwnerAccountY ?? null,
|
|
79
|
+
isSigner: false,
|
|
80
|
+
isWritable: true,
|
|
81
|
+
},
|
|
82
|
+
tokenVaultX: {
|
|
83
|
+
value: input.tokenVaultX ?? null,
|
|
84
|
+
isSigner: false,
|
|
85
|
+
isWritable: true,
|
|
86
|
+
},
|
|
87
|
+
tokenVaultY: {
|
|
88
|
+
value: input.tokenVaultY ?? null,
|
|
89
|
+
isSigner: false,
|
|
63
90
|
isWritable: true,
|
|
64
91
|
},
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
92
|
+
tokenProgramX: {
|
|
93
|
+
value: input.tokenProgramX ?? null,
|
|
94
|
+
isSigner: false,
|
|
95
|
+
isWritable: false,
|
|
96
|
+
},
|
|
97
|
+
tokenProgramY: {
|
|
98
|
+
value: input.tokenProgramY ?? null,
|
|
99
|
+
isSigner: false,
|
|
100
|
+
isWritable: false,
|
|
101
|
+
},
|
|
102
|
+
lowerBinArray: {
|
|
103
|
+
value: input.lowerBinArray ?? null,
|
|
104
|
+
isSigner: false,
|
|
105
|
+
isWritable: false,
|
|
106
|
+
},
|
|
107
|
+
upperBinArray: {
|
|
108
|
+
value: input.upperBinArray ?? null,
|
|
109
|
+
isSigner: false,
|
|
110
|
+
isWritable: false,
|
|
111
|
+
},
|
|
71
112
|
};
|
|
72
113
|
const accounts = originalAccounts;
|
|
73
114
|
// Original args.
|
|
74
115
|
const args = { ...input };
|
|
75
|
-
const getAccountMeta = getAccountMetaFactory(programAddress, "programId");
|
|
76
116
|
return Object.freeze({
|
|
77
117
|
accounts: [
|
|
78
118
|
getAccountMeta("owner", accounts.owner),
|
|
@@ -5,7 +5,8 @@
|
|
|
5
5
|
*
|
|
6
6
|
* @see https://github.com/codama-idl/codama
|
|
7
7
|
*/
|
|
8
|
-
import { type AccountMeta, type AccountSignerMeta, type Address, type Codec, type Decoder, type Encoder, type Instruction, type InstructionWithAccounts, type InstructionWithData, type Option, type OptionOrNullable, type ReadonlyAccount, type ReadonlySignerAccount, type ReadonlyUint8Array, type
|
|
8
|
+
import { type AccountMeta, type AccountSignerMeta, type Address, type Codec, type Decoder, type Encoder, type Instruction, type InstructionWithAccounts, type InstructionWithData, type Option, type OptionOrNullable, type ReadonlyAccount, type ReadonlySignerAccount, type ReadonlyUint8Array, type WritableAccount } from "@solana/kit";
|
|
9
|
+
import { type InstructionAccountInput, type InstructionAccountInputAddress, type InstructionSignerInput, type ResolvedInstructionAccountMeta } from "@solana/program-client-core";
|
|
9
10
|
import { PICON_DLMM_PROGRAM_ADDRESS } from "../programs/index.js";
|
|
10
11
|
import { type RemainingAccountsScheme, type RemainingAccountsSchemeArgs } from "../types/index.js";
|
|
11
12
|
export declare const CLAIM_PROTOCOL_FEE_DISCRIMINATOR: ReadonlyUint8Array;
|
|
@@ -34,40 +35,40 @@ export type ClaimProtocolFeeInstructionDataArgs = {
|
|
|
34
35
|
export declare function getClaimProtocolFeeInstructionDataEncoder(): Encoder<ClaimProtocolFeeInstructionDataArgs>;
|
|
35
36
|
export declare function getClaimProtocolFeeInstructionDataDecoder(): Decoder<ClaimProtocolFeeInstructionData>;
|
|
36
37
|
export declare function getClaimProtocolFeeInstructionDataCodec(): Codec<ClaimProtocolFeeInstructionDataArgs, ClaimProtocolFeeInstructionData>;
|
|
37
|
-
export type ClaimProtocolFeeAsyncInput<TAccountAuthority extends
|
|
38
|
-
authority:
|
|
39
|
-
adminConfig?:
|
|
40
|
-
pool:
|
|
41
|
-
tokenMintX:
|
|
42
|
-
tokenMintY:
|
|
43
|
-
tokenVaultX:
|
|
44
|
-
tokenVaultY:
|
|
45
|
-
tokenAdminAccountX:
|
|
46
|
-
tokenAdminAccountY:
|
|
47
|
-
tokenProgramX:
|
|
48
|
-
tokenProgramY:
|
|
38
|
+
export type ClaimProtocolFeeAsyncInput<TAccountAuthority extends InstructionSignerInput = InstructionSignerInput, TAccountAdminConfig extends InstructionAccountInput = InstructionAccountInput, TAccountPool extends InstructionAccountInput = InstructionAccountInput, TAccountTokenMintX extends InstructionAccountInput = InstructionAccountInput, TAccountTokenMintY extends InstructionAccountInput = InstructionAccountInput, TAccountTokenVaultX extends InstructionAccountInput = InstructionAccountInput, TAccountTokenVaultY extends InstructionAccountInput = InstructionAccountInput, TAccountTokenAdminAccountX extends InstructionAccountInput = InstructionAccountInput, TAccountTokenAdminAccountY extends InstructionAccountInput = InstructionAccountInput, TAccountTokenProgramX extends InstructionAccountInput = InstructionAccountInput, TAccountTokenProgramY extends InstructionAccountInput = InstructionAccountInput> = {
|
|
39
|
+
authority: TAccountAuthority;
|
|
40
|
+
adminConfig?: TAccountAdminConfig;
|
|
41
|
+
pool: TAccountPool;
|
|
42
|
+
tokenMintX: TAccountTokenMintX;
|
|
43
|
+
tokenMintY: TAccountTokenMintY;
|
|
44
|
+
tokenVaultX: TAccountTokenVaultX;
|
|
45
|
+
tokenVaultY: TAccountTokenVaultY;
|
|
46
|
+
tokenAdminAccountX: TAccountTokenAdminAccountX;
|
|
47
|
+
tokenAdminAccountY: TAccountTokenAdminAccountY;
|
|
48
|
+
tokenProgramX: TAccountTokenProgramX;
|
|
49
|
+
tokenProgramY: TAccountTokenProgramY;
|
|
49
50
|
remainingAccountsScheme: ClaimProtocolFeeInstructionDataArgs["remainingAccountsScheme"];
|
|
50
51
|
};
|
|
51
|
-
export declare function getClaimProtocolFeeInstructionAsync<TAccountAuthority extends
|
|
52
|
+
export declare function getClaimProtocolFeeInstructionAsync<TAccountAuthority extends InstructionSignerInput, TAccountAdminConfig extends InstructionAccountInput, TAccountPool extends InstructionAccountInput, TAccountTokenMintX extends InstructionAccountInput, TAccountTokenMintY extends InstructionAccountInput, TAccountTokenVaultX extends InstructionAccountInput, TAccountTokenVaultY extends InstructionAccountInput, TAccountTokenAdminAccountX extends InstructionAccountInput, TAccountTokenAdminAccountY extends InstructionAccountInput, TAccountTokenProgramX extends InstructionAccountInput, TAccountTokenProgramY extends InstructionAccountInput, TProgramAddress extends Address = typeof PICON_DLMM_PROGRAM_ADDRESS>(input: ClaimProtocolFeeAsyncInput<TAccountAuthority, TAccountAdminConfig, TAccountPool, TAccountTokenMintX, TAccountTokenMintY, TAccountTokenVaultX, TAccountTokenVaultY, TAccountTokenAdminAccountX, TAccountTokenAdminAccountY, TAccountTokenProgramX, TAccountTokenProgramY>, config?: {
|
|
52
53
|
programAddress?: TProgramAddress;
|
|
53
|
-
}): Promise<ClaimProtocolFeeInstruction<TProgramAddress, TAccountAuthority, TAccountAdminConfig, TAccountPool, TAccountTokenMintX, TAccountTokenMintY, TAccountTokenVaultX, TAccountTokenVaultY, TAccountTokenAdminAccountX, TAccountTokenAdminAccountY, TAccountTokenProgramX, TAccountTokenProgramY
|
|
54
|
-
export type ClaimProtocolFeeInput<TAccountAuthority extends
|
|
55
|
-
authority:
|
|
56
|
-
adminConfig:
|
|
57
|
-
pool:
|
|
58
|
-
tokenMintX:
|
|
59
|
-
tokenMintY:
|
|
60
|
-
tokenVaultX:
|
|
61
|
-
tokenVaultY:
|
|
62
|
-
tokenAdminAccountX:
|
|
63
|
-
tokenAdminAccountY:
|
|
64
|
-
tokenProgramX:
|
|
65
|
-
tokenProgramY:
|
|
54
|
+
}): Promise<ClaimProtocolFeeInstruction<TProgramAddress, ResolvedInstructionAccountMeta<TAccountAuthority, InstructionAccountInputAddress<TAccountAuthority>>, ResolvedInstructionAccountMeta<TAccountAdminConfig, InstructionAccountInputAddress<TAccountAdminConfig>>, ResolvedInstructionAccountMeta<TAccountPool, InstructionAccountInputAddress<TAccountPool>>, ResolvedInstructionAccountMeta<TAccountTokenMintX, InstructionAccountInputAddress<TAccountTokenMintX>>, ResolvedInstructionAccountMeta<TAccountTokenMintY, InstructionAccountInputAddress<TAccountTokenMintY>>, ResolvedInstructionAccountMeta<TAccountTokenVaultX, InstructionAccountInputAddress<TAccountTokenVaultX>>, ResolvedInstructionAccountMeta<TAccountTokenVaultY, InstructionAccountInputAddress<TAccountTokenVaultY>>, ResolvedInstructionAccountMeta<TAccountTokenAdminAccountX, InstructionAccountInputAddress<TAccountTokenAdminAccountX>>, ResolvedInstructionAccountMeta<TAccountTokenAdminAccountY, InstructionAccountInputAddress<TAccountTokenAdminAccountY>>, ResolvedInstructionAccountMeta<TAccountTokenProgramX, InstructionAccountInputAddress<TAccountTokenProgramX>>, ResolvedInstructionAccountMeta<TAccountTokenProgramY, InstructionAccountInputAddress<TAccountTokenProgramY>>>>;
|
|
55
|
+
export type ClaimProtocolFeeInput<TAccountAuthority extends InstructionSignerInput = InstructionSignerInput, TAccountAdminConfig extends InstructionAccountInput = InstructionAccountInput, TAccountPool extends InstructionAccountInput = InstructionAccountInput, TAccountTokenMintX extends InstructionAccountInput = InstructionAccountInput, TAccountTokenMintY extends InstructionAccountInput = InstructionAccountInput, TAccountTokenVaultX extends InstructionAccountInput = InstructionAccountInput, TAccountTokenVaultY extends InstructionAccountInput = InstructionAccountInput, TAccountTokenAdminAccountX extends InstructionAccountInput = InstructionAccountInput, TAccountTokenAdminAccountY extends InstructionAccountInput = InstructionAccountInput, TAccountTokenProgramX extends InstructionAccountInput = InstructionAccountInput, TAccountTokenProgramY extends InstructionAccountInput = InstructionAccountInput> = {
|
|
56
|
+
authority: TAccountAuthority;
|
|
57
|
+
adminConfig: TAccountAdminConfig;
|
|
58
|
+
pool: TAccountPool;
|
|
59
|
+
tokenMintX: TAccountTokenMintX;
|
|
60
|
+
tokenMintY: TAccountTokenMintY;
|
|
61
|
+
tokenVaultX: TAccountTokenVaultX;
|
|
62
|
+
tokenVaultY: TAccountTokenVaultY;
|
|
63
|
+
tokenAdminAccountX: TAccountTokenAdminAccountX;
|
|
64
|
+
tokenAdminAccountY: TAccountTokenAdminAccountY;
|
|
65
|
+
tokenProgramX: TAccountTokenProgramX;
|
|
66
|
+
tokenProgramY: TAccountTokenProgramY;
|
|
66
67
|
remainingAccountsScheme: ClaimProtocolFeeInstructionDataArgs["remainingAccountsScheme"];
|
|
67
68
|
};
|
|
68
|
-
export declare function getClaimProtocolFeeInstruction<TAccountAuthority extends
|
|
69
|
+
export declare function getClaimProtocolFeeInstruction<TAccountAuthority extends InstructionSignerInput, TAccountAdminConfig extends InstructionAccountInput, TAccountPool extends InstructionAccountInput, TAccountTokenMintX extends InstructionAccountInput, TAccountTokenMintY extends InstructionAccountInput, TAccountTokenVaultX extends InstructionAccountInput, TAccountTokenVaultY extends InstructionAccountInput, TAccountTokenAdminAccountX extends InstructionAccountInput, TAccountTokenAdminAccountY extends InstructionAccountInput, TAccountTokenProgramX extends InstructionAccountInput, TAccountTokenProgramY extends InstructionAccountInput, TProgramAddress extends Address = typeof PICON_DLMM_PROGRAM_ADDRESS>(input: ClaimProtocolFeeInput<TAccountAuthority, TAccountAdminConfig, TAccountPool, TAccountTokenMintX, TAccountTokenMintY, TAccountTokenVaultX, TAccountTokenVaultY, TAccountTokenAdminAccountX, TAccountTokenAdminAccountY, TAccountTokenProgramX, TAccountTokenProgramY>, config?: {
|
|
69
70
|
programAddress?: TProgramAddress;
|
|
70
|
-
}): ClaimProtocolFeeInstruction<TProgramAddress, TAccountAuthority, TAccountAdminConfig, TAccountPool, TAccountTokenMintX, TAccountTokenMintY, TAccountTokenVaultX, TAccountTokenVaultY, TAccountTokenAdminAccountX, TAccountTokenAdminAccountY, TAccountTokenProgramX, TAccountTokenProgramY
|
|
71
|
+
}): ClaimProtocolFeeInstruction<TProgramAddress, ResolvedInstructionAccountMeta<TAccountAuthority, InstructionAccountInputAddress<TAccountAuthority>>, ResolvedInstructionAccountMeta<TAccountAdminConfig, InstructionAccountInputAddress<TAccountAdminConfig>>, ResolvedInstructionAccountMeta<TAccountPool, InstructionAccountInputAddress<TAccountPool>>, ResolvedInstructionAccountMeta<TAccountTokenMintX, InstructionAccountInputAddress<TAccountTokenMintX>>, ResolvedInstructionAccountMeta<TAccountTokenMintY, InstructionAccountInputAddress<TAccountTokenMintY>>, ResolvedInstructionAccountMeta<TAccountTokenVaultX, InstructionAccountInputAddress<TAccountTokenVaultX>>, ResolvedInstructionAccountMeta<TAccountTokenVaultY, InstructionAccountInputAddress<TAccountTokenVaultY>>, ResolvedInstructionAccountMeta<TAccountTokenAdminAccountX, InstructionAccountInputAddress<TAccountTokenAdminAccountX>>, ResolvedInstructionAccountMeta<TAccountTokenAdminAccountY, InstructionAccountInputAddress<TAccountTokenAdminAccountY>>, ResolvedInstructionAccountMeta<TAccountTokenProgramX, InstructionAccountInputAddress<TAccountTokenProgramX>>, ResolvedInstructionAccountMeta<TAccountTokenProgramY, InstructionAccountInputAddress<TAccountTokenProgramY>>>;
|
|
71
72
|
export type ParsedClaimProtocolFeeInstruction<TProgram extends string = typeof PICON_DLMM_PROGRAM_ADDRESS, TAccountMetas extends readonly AccountMeta[] = readonly AccountMeta[]> = {
|
|
72
73
|
programAddress: Address<TProgram>;
|
|
73
74
|
accounts: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"claimProtocolFee.d.ts","sourceRoot":"","sources":["../../../src/generated/instructions/claimProtocolFee.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAaL,KAAK,WAAW,EAChB,KAAK,iBAAiB,EACtB,KAAK,OAAO,EACZ,KAAK,KAAK,EACV,KAAK,OAAO,EACZ,KAAK,OAAO,EACZ,KAAK,WAAW,EAChB,KAAK,uBAAuB,EAC5B,KAAK,mBAAmB,EACxB,KAAK,MAAM,EACX,KAAK,gBAAgB,EACrB,KAAK,eAAe,EACpB,KAAK,qBAAqB,EAC1B,KAAK,kBAAkB,EACvB,KAAK,
|
|
1
|
+
{"version":3,"file":"claimProtocolFee.d.ts","sourceRoot":"","sources":["../../../src/generated/instructions/claimProtocolFee.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAaL,KAAK,WAAW,EAChB,KAAK,iBAAiB,EACtB,KAAK,OAAO,EACZ,KAAK,KAAK,EACV,KAAK,OAAO,EACZ,KAAK,OAAO,EACZ,KAAK,WAAW,EAChB,KAAK,uBAAuB,EAC5B,KAAK,mBAAmB,EACxB,KAAK,MAAM,EACX,KAAK,gBAAgB,EACrB,KAAK,eAAe,EACpB,KAAK,qBAAqB,EAC1B,KAAK,kBAAkB,EACvB,KAAK,eAAe,EACrB,MAAM,aAAa,CAAC;AACrB,OAAO,EAEL,KAAK,uBAAuB,EAC5B,KAAK,8BAA8B,EACnC,KAAK,sBAAsB,EAE3B,KAAK,8BAA8B,EACpC,MAAM,6BAA6B,CAAC;AAErC,OAAO,EAAE,0BAA0B,EAAE,MAAM,sBAAsB,CAAC;AAClE,OAAO,EAGL,KAAK,uBAAuB,EAC5B,KAAK,2BAA2B,EACjC,MAAM,mBAAmB,CAAC;AAE3B,eAAO,MAAM,gCAAgC,EAAE,kBACQ,CAAC;AAExD,wBAAgB,qCAAqC,IAAI,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AC5B,WAAW,EAAE,aAAa,CAAC,CAAC,CAAC,CAAC;QAC9B,IAAI,EAAE,aAAa,CAAC,CAAC,CAAC,CAAC;QACvB,UAAU,EAAE,aAAa,CAAC,CAAC,CAAC,CAAC;QAC7B,UAAU,EAAE,aAAa,CAAC,CAAC,CAAC,CAAC;QAC7B,WAAW,EAAE,aAAa,CAAC,CAAC,CAAC,CAAC;QAC9B,WAAW,EAAE,aAAa,CAAC,CAAC,CAAC,CAAC;QAC9B,kBAAkB,EAAE,aAAa,CAAC,CAAC,CAAC,CAAC;QACrC,kBAAkB,EAAE,aAAa,CAAC,CAAC,CAAC,CAAC;QACrC,aAAa,EAAE,aAAa,CAAC,CAAC,CAAC,CAAC;QAChC,aAAa,EAAE,aAAa,CAAC,EAAE,CAAC,CAAC;KAClC,CAAC;IACF,IAAI,EAAE,+BAA+B,CAAC;CACvC,CAAC;AAEF,wBAAgB,gCAAgC,CAC9C,QAAQ,SAAS,MAAM,EACvB,aAAa,SAAS,SAAS,WAAW,EAAE,EAE5C,WAAW,EAAE,WAAW,CAAC,QAAQ,CAAC,GAChC,uBAAuB,CAAC,aAAa,CAAC,GACtC,mBAAmB,CAAC,kBAAkB,CAAC,GACxC,iCAAiC,CAAC,QAAQ,EAAE,aAAa,CAAC,CAiC5D"}
|
|
@@ -38,25 +38,61 @@ export function getClaimProtocolFeeInstructionDataCodec() {
|
|
|
38
38
|
export async function getClaimProtocolFeeInstructionAsync(input, config) {
|
|
39
39
|
// Program address.
|
|
40
40
|
const programAddress = config?.programAddress ?? PICON_DLMM_PROGRAM_ADDRESS;
|
|
41
|
+
// Account meta helper.
|
|
42
|
+
const getAccountMeta = getAccountMetaFactory(programAddress, "programId");
|
|
41
43
|
// Original accounts.
|
|
42
44
|
const originalAccounts = {
|
|
43
|
-
authority: {
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
45
|
+
authority: {
|
|
46
|
+
value: input.authority ?? null,
|
|
47
|
+
isSigner: true,
|
|
48
|
+
isWritable: false,
|
|
49
|
+
},
|
|
50
|
+
adminConfig: {
|
|
51
|
+
value: input.adminConfig ?? null,
|
|
52
|
+
isSigner: false,
|
|
53
|
+
isWritable: false,
|
|
54
|
+
},
|
|
55
|
+
pool: { value: input.pool ?? null, isSigner: false, isWritable: true },
|
|
56
|
+
tokenMintX: {
|
|
57
|
+
value: input.tokenMintX ?? null,
|
|
58
|
+
isSigner: false,
|
|
59
|
+
isWritable: false,
|
|
60
|
+
},
|
|
61
|
+
tokenMintY: {
|
|
62
|
+
value: input.tokenMintY ?? null,
|
|
63
|
+
isSigner: false,
|
|
64
|
+
isWritable: false,
|
|
65
|
+
},
|
|
66
|
+
tokenVaultX: {
|
|
67
|
+
value: input.tokenVaultX ?? null,
|
|
68
|
+
isSigner: false,
|
|
69
|
+
isWritable: true,
|
|
70
|
+
},
|
|
71
|
+
tokenVaultY: {
|
|
72
|
+
value: input.tokenVaultY ?? null,
|
|
73
|
+
isSigner: false,
|
|
74
|
+
isWritable: true,
|
|
75
|
+
},
|
|
50
76
|
tokenAdminAccountX: {
|
|
51
77
|
value: input.tokenAdminAccountX ?? null,
|
|
78
|
+
isSigner: false,
|
|
52
79
|
isWritable: true,
|
|
53
80
|
},
|
|
54
81
|
tokenAdminAccountY: {
|
|
55
82
|
value: input.tokenAdminAccountY ?? null,
|
|
83
|
+
isSigner: false,
|
|
56
84
|
isWritable: true,
|
|
57
85
|
},
|
|
58
|
-
tokenProgramX: {
|
|
59
|
-
|
|
86
|
+
tokenProgramX: {
|
|
87
|
+
value: input.tokenProgramX ?? null,
|
|
88
|
+
isSigner: false,
|
|
89
|
+
isWritable: false,
|
|
90
|
+
},
|
|
91
|
+
tokenProgramY: {
|
|
92
|
+
value: input.tokenProgramY ?? null,
|
|
93
|
+
isSigner: false,
|
|
94
|
+
isWritable: false,
|
|
95
|
+
},
|
|
60
96
|
};
|
|
61
97
|
const accounts = originalAccounts;
|
|
62
98
|
// Original args.
|
|
@@ -65,7 +101,6 @@ export async function getClaimProtocolFeeInstructionAsync(input, config) {
|
|
|
65
101
|
if (!accounts.adminConfig.value) {
|
|
66
102
|
accounts.adminConfig.value = await findAdminConfigPda({ programAddress });
|
|
67
103
|
}
|
|
68
|
-
const getAccountMeta = getAccountMetaFactory(programAddress, "programId");
|
|
69
104
|
return Object.freeze({
|
|
70
105
|
accounts: [
|
|
71
106
|
getAccountMeta("authority", accounts.authority),
|
|
@@ -87,30 +122,65 @@ export async function getClaimProtocolFeeInstructionAsync(input, config) {
|
|
|
87
122
|
export function getClaimProtocolFeeInstruction(input, config) {
|
|
88
123
|
// Program address.
|
|
89
124
|
const programAddress = config?.programAddress ?? PICON_DLMM_PROGRAM_ADDRESS;
|
|
125
|
+
// Account meta helper.
|
|
126
|
+
const getAccountMeta = getAccountMetaFactory(programAddress, "programId");
|
|
90
127
|
// Original accounts.
|
|
91
128
|
const originalAccounts = {
|
|
92
|
-
authority: {
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
129
|
+
authority: {
|
|
130
|
+
value: input.authority ?? null,
|
|
131
|
+
isSigner: true,
|
|
132
|
+
isWritable: false,
|
|
133
|
+
},
|
|
134
|
+
adminConfig: {
|
|
135
|
+
value: input.adminConfig ?? null,
|
|
136
|
+
isSigner: false,
|
|
137
|
+
isWritable: false,
|
|
138
|
+
},
|
|
139
|
+
pool: { value: input.pool ?? null, isSigner: false, isWritable: true },
|
|
140
|
+
tokenMintX: {
|
|
141
|
+
value: input.tokenMintX ?? null,
|
|
142
|
+
isSigner: false,
|
|
143
|
+
isWritable: false,
|
|
144
|
+
},
|
|
145
|
+
tokenMintY: {
|
|
146
|
+
value: input.tokenMintY ?? null,
|
|
147
|
+
isSigner: false,
|
|
148
|
+
isWritable: false,
|
|
149
|
+
},
|
|
150
|
+
tokenVaultX: {
|
|
151
|
+
value: input.tokenVaultX ?? null,
|
|
152
|
+
isSigner: false,
|
|
153
|
+
isWritable: true,
|
|
154
|
+
},
|
|
155
|
+
tokenVaultY: {
|
|
156
|
+
value: input.tokenVaultY ?? null,
|
|
157
|
+
isSigner: false,
|
|
158
|
+
isWritable: true,
|
|
159
|
+
},
|
|
99
160
|
tokenAdminAccountX: {
|
|
100
161
|
value: input.tokenAdminAccountX ?? null,
|
|
162
|
+
isSigner: false,
|
|
101
163
|
isWritable: true,
|
|
102
164
|
},
|
|
103
165
|
tokenAdminAccountY: {
|
|
104
166
|
value: input.tokenAdminAccountY ?? null,
|
|
167
|
+
isSigner: false,
|
|
105
168
|
isWritable: true,
|
|
106
169
|
},
|
|
107
|
-
tokenProgramX: {
|
|
108
|
-
|
|
170
|
+
tokenProgramX: {
|
|
171
|
+
value: input.tokenProgramX ?? null,
|
|
172
|
+
isSigner: false,
|
|
173
|
+
isWritable: false,
|
|
174
|
+
},
|
|
175
|
+
tokenProgramY: {
|
|
176
|
+
value: input.tokenProgramY ?? null,
|
|
177
|
+
isSigner: false,
|
|
178
|
+
isWritable: false,
|
|
179
|
+
},
|
|
109
180
|
};
|
|
110
181
|
const accounts = originalAccounts;
|
|
111
182
|
// Original args.
|
|
112
183
|
const args = { ...input };
|
|
113
|
-
const getAccountMeta = getAccountMetaFactory(programAddress, "programId");
|
|
114
184
|
return Object.freeze({
|
|
115
185
|
accounts: [
|
|
116
186
|
getAccountMeta("authority", accounts.authority),
|