@meteora-ag/dynamic-bonding-curve-sdk 1.4.5 → 1.4.6-rc.1
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/README.md +15 -4
- package/dist/index.cjs +205 -180
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +398 -349
- package/dist/index.d.ts +398 -349
- package/dist/index.js +205 -180
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -13,7 +13,7 @@ type DynamicBondingCurve = {
|
|
|
13
13
|
address: 'dbcij3LWUppWqq96dh6gJWwBifmcGfLSB5D4DuSMaqN';
|
|
14
14
|
metadata: {
|
|
15
15
|
name: 'dynamicBondingCurve';
|
|
16
|
-
version: '0.1.
|
|
16
|
+
version: '0.1.7';
|
|
17
17
|
spec: '0.1.0';
|
|
18
18
|
description: 'Created with Anchor';
|
|
19
19
|
};
|
|
@@ -118,6 +118,68 @@ type DynamicBondingCurve = {
|
|
|
118
118
|
}
|
|
119
119
|
];
|
|
120
120
|
},
|
|
121
|
+
{
|
|
122
|
+
name: 'claimPoolCreationFee';
|
|
123
|
+
discriminator: [246, 51, 18, 222, 80, 42, 236, 205];
|
|
124
|
+
accounts: [
|
|
125
|
+
{
|
|
126
|
+
name: 'pool';
|
|
127
|
+
writable: true;
|
|
128
|
+
},
|
|
129
|
+
{
|
|
130
|
+
name: 'claimFeeOperator';
|
|
131
|
+
docs: ['Claim fee operator'];
|
|
132
|
+
},
|
|
133
|
+
{
|
|
134
|
+
name: 'operator';
|
|
135
|
+
docs: ['Operator'];
|
|
136
|
+
signer: true;
|
|
137
|
+
relations: ['claimFeeOperator'];
|
|
138
|
+
},
|
|
139
|
+
{
|
|
140
|
+
name: 'treasury';
|
|
141
|
+
writable: true;
|
|
142
|
+
address: '4EWqcx3aNZmMetCnxwLYwyNjan6XLGp3Ca2W316vrSjv';
|
|
143
|
+
},
|
|
144
|
+
{
|
|
145
|
+
name: 'systemProgram';
|
|
146
|
+
address: '11111111111111111111111111111111';
|
|
147
|
+
},
|
|
148
|
+
{
|
|
149
|
+
name: 'eventAuthority';
|
|
150
|
+
pda: {
|
|
151
|
+
seeds: [
|
|
152
|
+
{
|
|
153
|
+
kind: 'const';
|
|
154
|
+
value: [
|
|
155
|
+
95,
|
|
156
|
+
95,
|
|
157
|
+
101,
|
|
158
|
+
118,
|
|
159
|
+
101,
|
|
160
|
+
110,
|
|
161
|
+
116,
|
|
162
|
+
95,
|
|
163
|
+
97,
|
|
164
|
+
117,
|
|
165
|
+
116,
|
|
166
|
+
104,
|
|
167
|
+
111,
|
|
168
|
+
114,
|
|
169
|
+
105,
|
|
170
|
+
116,
|
|
171
|
+
121
|
|
172
|
+
];
|
|
173
|
+
}
|
|
174
|
+
];
|
|
175
|
+
};
|
|
176
|
+
},
|
|
177
|
+
{
|
|
178
|
+
name: 'program';
|
|
179
|
+
}
|
|
180
|
+
];
|
|
181
|
+
args: [];
|
|
182
|
+
},
|
|
121
183
|
{
|
|
122
184
|
name: 'claimProtocolFee';
|
|
123
185
|
discriminator: [165, 228, 133, 48, 99, 249, 255, 33];
|
|
@@ -794,7 +856,7 @@ type DynamicBondingCurve = {
|
|
|
794
856
|
},
|
|
795
857
|
{
|
|
796
858
|
name: 'createPartnerMetadata';
|
|
797
|
-
docs: ['PARTNER FUNCTIONS
|
|
859
|
+
docs: ['PARTNER FUNCTIONS ///'];
|
|
798
860
|
discriminator: [192, 168, 234, 191, 188, 226, 227, 255];
|
|
799
861
|
accounts: [
|
|
800
862
|
{
|
|
@@ -1918,11 +1980,9 @@ type DynamicBondingCurve = {
|
|
|
1918
1980
|
name: 'virtualPool';
|
|
1919
1981
|
docs: ['virtual pool'];
|
|
1920
1982
|
writable: true;
|
|
1921
|
-
relations: ['migrationMetadata'];
|
|
1922
1983
|
},
|
|
1923
1984
|
{
|
|
1924
1985
|
name: 'migrationMetadata';
|
|
1925
|
-
docs: ['migration metadata'];
|
|
1926
1986
|
},
|
|
1927
1987
|
{
|
|
1928
1988
|
name: 'config';
|
|
@@ -2032,32 +2092,15 @@ type DynamicBondingCurve = {
|
|
|
2032
2092
|
},
|
|
2033
2093
|
{
|
|
2034
2094
|
name: 'config';
|
|
2035
|
-
relations: ['virtualPool'];
|
|
2036
2095
|
},
|
|
2037
2096
|
{
|
|
2038
2097
|
name: 'migrationMetadata';
|
|
2039
|
-
writable: true;
|
|
2040
|
-
pda: {
|
|
2041
|
-
seeds: [
|
|
2042
|
-
{
|
|
2043
|
-
kind: 'const';
|
|
2044
|
-
value: [100, 97, 109, 109, 95, 118, 50];
|
|
2045
|
-
},
|
|
2046
|
-
{
|
|
2047
|
-
kind: 'account';
|
|
2048
|
-
path: 'virtualPool';
|
|
2049
|
-
}
|
|
2050
|
-
];
|
|
2051
|
-
};
|
|
2052
2098
|
},
|
|
2053
2099
|
{
|
|
2054
2100
|
name: 'payer';
|
|
2055
|
-
writable: true;
|
|
2056
|
-
signer: true;
|
|
2057
2101
|
},
|
|
2058
2102
|
{
|
|
2059
2103
|
name: 'systemProgram';
|
|
2060
|
-
address: '11111111111111111111111111111111';
|
|
2061
2104
|
},
|
|
2062
2105
|
{
|
|
2063
2106
|
name: 'eventAuthority';
|
|
@@ -2677,6 +2720,27 @@ type DynamicBondingCurve = {
|
|
|
2677
2720
|
];
|
|
2678
2721
|
args: [];
|
|
2679
2722
|
},
|
|
2723
|
+
{
|
|
2724
|
+
name: 'withdrawLamportsFromPoolAuthority';
|
|
2725
|
+
discriminator: [20, 185, 242, 240, 129, 24, 212, 194];
|
|
2726
|
+
accounts: [
|
|
2727
|
+
{
|
|
2728
|
+
name: 'poolAuthority';
|
|
2729
|
+
writable: true;
|
|
2730
|
+
address: 'FhVo3mqL8PW5pH5U2CN4XE33DokiyZnUwuGpH2hmHLuM';
|
|
2731
|
+
},
|
|
2732
|
+
{
|
|
2733
|
+
name: 'receiver';
|
|
2734
|
+
writable: true;
|
|
2735
|
+
address: '4EWqcx3aNZmMetCnxwLYwyNjan6XLGp3Ca2W316vrSjv';
|
|
2736
|
+
},
|
|
2737
|
+
{
|
|
2738
|
+
name: 'systemProgram';
|
|
2739
|
+
address: '11111111111111111111111111111111';
|
|
2740
|
+
}
|
|
2741
|
+
];
|
|
2742
|
+
args: [];
|
|
2743
|
+
},
|
|
2680
2744
|
{
|
|
2681
2745
|
name: 'withdrawLeftover';
|
|
2682
2746
|
discriminator: [20, 198, 202, 237, 235, 243, 183, 66];
|
|
@@ -2904,10 +2968,6 @@ type DynamicBondingCurve = {
|
|
|
2904
2968
|
name: 'meteoraDammMigrationMetadata';
|
|
2905
2969
|
discriminator: [17, 155, 141, 215, 207, 4, 133, 156];
|
|
2906
2970
|
},
|
|
2907
|
-
{
|
|
2908
|
-
name: 'meteoraDammV2Metadata';
|
|
2909
|
-
discriminator: [104, 221, 219, 203, 10, 142, 250, 163];
|
|
2910
|
-
},
|
|
2911
2971
|
{
|
|
2912
2972
|
name: 'partnerMetadata';
|
|
2913
2973
|
discriminator: [68, 68, 130, 19, 16, 209, 98, 156];
|
|
@@ -2930,6 +2990,10 @@ type DynamicBondingCurve = {
|
|
|
2930
2990
|
name: 'evtClaimCreatorTradingFee';
|
|
2931
2991
|
discriminator: [154, 228, 215, 202, 133, 155, 214, 138];
|
|
2932
2992
|
},
|
|
2993
|
+
{
|
|
2994
|
+
name: 'evtClaimPoolCreationFee';
|
|
2995
|
+
discriminator: [149, 111, 149, 44, 136, 64, 175, 62];
|
|
2996
|
+
},
|
|
2933
2997
|
{
|
|
2934
2998
|
name: 'evtClaimProtocolFee';
|
|
2935
2999
|
discriminator: [186, 244, 75, 251, 188, 13, 25, 33];
|
|
@@ -2954,10 +3018,6 @@ type DynamicBondingCurve = {
|
|
|
2954
3018
|
name: 'evtCreateConfigV2';
|
|
2955
3019
|
discriminator: [163, 74, 66, 187, 119, 195, 26, 144];
|
|
2956
3020
|
},
|
|
2957
|
-
{
|
|
2958
|
-
name: 'evtCreateDammV2MigrationMetadata';
|
|
2959
|
-
discriminator: [103, 111, 132, 168, 140, 253, 150, 114];
|
|
2960
|
-
},
|
|
2961
3021
|
{
|
|
2962
3022
|
name: 'evtCreateMeteoraMigrationMetadata';
|
|
2963
3023
|
discriminator: [99, 167, 133, 63, 214, 143, 175, 139];
|
|
@@ -3260,6 +3320,16 @@ type DynamicBondingCurve = {
|
|
|
3260
3320
|
code: 6048;
|
|
3261
3321
|
name: 'nextSqrtPriceIsSmallerThanStartSqrtPrice';
|
|
3262
3322
|
msg: 'Next sqrt price is smaller than start sqrt price';
|
|
3323
|
+
},
|
|
3324
|
+
{
|
|
3325
|
+
code: 6049;
|
|
3326
|
+
name: 'invalidMinBaseFee';
|
|
3327
|
+
msg: 'Invalid min base fee';
|
|
3328
|
+
},
|
|
3329
|
+
{
|
|
3330
|
+
code: 6050;
|
|
3331
|
+
name: 'accountInvariantViolation';
|
|
3332
|
+
msg: 'Account invariant violation';
|
|
3263
3333
|
}
|
|
3264
3334
|
];
|
|
3265
3335
|
types: [
|
|
@@ -3683,6 +3753,26 @@ type DynamicBondingCurve = {
|
|
|
3683
3753
|
];
|
|
3684
3754
|
};
|
|
3685
3755
|
},
|
|
3756
|
+
{
|
|
3757
|
+
name: 'evtClaimPoolCreationFee';
|
|
3758
|
+
type: {
|
|
3759
|
+
kind: 'struct';
|
|
3760
|
+
fields: [
|
|
3761
|
+
{
|
|
3762
|
+
name: 'pool';
|
|
3763
|
+
type: 'pubkey';
|
|
3764
|
+
},
|
|
3765
|
+
{
|
|
3766
|
+
name: 'treasury';
|
|
3767
|
+
type: 'pubkey';
|
|
3768
|
+
},
|
|
3769
|
+
{
|
|
3770
|
+
name: 'creationFee';
|
|
3771
|
+
type: 'u64';
|
|
3772
|
+
}
|
|
3773
|
+
];
|
|
3774
|
+
};
|
|
3775
|
+
},
|
|
3686
3776
|
{
|
|
3687
3777
|
name: 'evtClaimProtocolFee';
|
|
3688
3778
|
type: {
|
|
@@ -3904,18 +3994,6 @@ type DynamicBondingCurve = {
|
|
|
3904
3994
|
];
|
|
3905
3995
|
};
|
|
3906
3996
|
},
|
|
3907
|
-
{
|
|
3908
|
-
name: 'evtCreateDammV2MigrationMetadata';
|
|
3909
|
-
type: {
|
|
3910
|
-
kind: 'struct';
|
|
3911
|
-
fields: [
|
|
3912
|
-
{
|
|
3913
|
-
name: 'virtualPool';
|
|
3914
|
-
type: 'pubkey';
|
|
3915
|
-
}
|
|
3916
|
-
];
|
|
3917
|
-
};
|
|
3918
|
-
},
|
|
3919
3997
|
{
|
|
3920
3998
|
name: 'evtCreateMeteoraMigrationMetadata';
|
|
3921
3999
|
type: {
|
|
@@ -4499,44 +4577,6 @@ type DynamicBondingCurve = {
|
|
|
4499
4577
|
];
|
|
4500
4578
|
};
|
|
4501
4579
|
},
|
|
4502
|
-
{
|
|
4503
|
-
name: 'meteoraDammV2Metadata';
|
|
4504
|
-
serialization: 'bytemuck';
|
|
4505
|
-
repr: {
|
|
4506
|
-
kind: 'c';
|
|
4507
|
-
};
|
|
4508
|
-
type: {
|
|
4509
|
-
kind: 'struct';
|
|
4510
|
-
fields: [
|
|
4511
|
-
{
|
|
4512
|
-
name: 'virtualPool';
|
|
4513
|
-
docs: ['pool'];
|
|
4514
|
-
type: 'pubkey';
|
|
4515
|
-
},
|
|
4516
|
-
{
|
|
4517
|
-
name: 'padding0';
|
|
4518
|
-
docs: [
|
|
4519
|
-
'!!! BE CAREFUL to use tomestone field, previous is pool creator'
|
|
4520
|
-
];
|
|
4521
|
-
type: {
|
|
4522
|
-
array: ['u8', 32];
|
|
4523
|
-
};
|
|
4524
|
-
},
|
|
4525
|
-
{
|
|
4526
|
-
name: 'partner';
|
|
4527
|
-
docs: ['partner'];
|
|
4528
|
-
type: 'pubkey';
|
|
4529
|
-
},
|
|
4530
|
-
{
|
|
4531
|
-
name: 'padding';
|
|
4532
|
-
docs: ['Reserve'];
|
|
4533
|
-
type: {
|
|
4534
|
-
array: ['u8', 126];
|
|
4535
|
-
};
|
|
4536
|
-
}
|
|
4537
|
-
];
|
|
4538
|
-
};
|
|
4539
|
-
},
|
|
4540
4580
|
{
|
|
4541
4581
|
name: 'migratedPoolFee';
|
|
4542
4582
|
type: {
|
|
@@ -5245,11 +5285,21 @@ type DynamicBondingCurve = {
|
|
|
5245
5285
|
docs: ['creator quote fee'];
|
|
5246
5286
|
type: 'u64';
|
|
5247
5287
|
},
|
|
5288
|
+
{
|
|
5289
|
+
name: 'creationFeeBits';
|
|
5290
|
+
type: 'u8';
|
|
5291
|
+
},
|
|
5292
|
+
{
|
|
5293
|
+
name: 'padding0';
|
|
5294
|
+
type: {
|
|
5295
|
+
array: ['u8', 7];
|
|
5296
|
+
};
|
|
5297
|
+
},
|
|
5248
5298
|
{
|
|
5249
5299
|
name: 'padding1';
|
|
5250
5300
|
docs: ['Padding for further use'];
|
|
5251
5301
|
type: {
|
|
5252
|
-
array: ['u64',
|
|
5302
|
+
array: ['u64', 6];
|
|
5253
5303
|
};
|
|
5254
5304
|
}
|
|
5255
5305
|
];
|
|
@@ -5347,55 +5397,26 @@ declare class DynamicBondingCurveProgram {
|
|
|
5347
5397
|
}
|
|
5348
5398
|
|
|
5349
5399
|
type DynamicCurveProgram = Program<DynamicBondingCurve>;
|
|
5350
|
-
type
|
|
5351
|
-
type ClaimProtocolFeeAccounts = Accounts<DynamicBondingCurve['instructions']['1']>['claimProtocolFee'];
|
|
5352
|
-
type ClaimTradingFeeAccounts = Accounts<DynamicBondingCurve['instructions']['2']>['claimTradingFee'];
|
|
5353
|
-
type CloseClaimFeeOperatorAccounts = Accounts<DynamicBondingCurve['instructions']['3']>['closeClaimFeeOperator'];
|
|
5354
|
-
type CreateClaimFeeOperatorAccounts = Accounts<DynamicBondingCurve['instructions']['4']>['createClaimFeeOperator'];
|
|
5355
|
-
type CreateConfigAccounts = Accounts<DynamicBondingCurve['instructions']['5']>['createConfig'];
|
|
5356
|
-
type CreateLockerAccounts = Accounts<DynamicBondingCurve['instructions']['6']>['createLocker'];
|
|
5357
|
-
type CreatePartnerMetadata = Accounts<DynamicBondingCurve['instructions']['7']>['createPartnerMetadata'];
|
|
5358
|
-
type CreateVirtualPoolMetadata = Accounts<DynamicBondingCurve['instructions']['8']>['createVirtualPoolMetadata'];
|
|
5359
|
-
type CreatorWithdrawSurplusAccounts = Accounts<DynamicBondingCurve['instructions']['9']>['creatorWithdrawSurplus'];
|
|
5360
|
-
type InitializeVirtualPoolWithSplTokenAccounts = Accounts<DynamicBondingCurve['instructions']['10']>['initializeVirtualPoolWithSplToken'];
|
|
5361
|
-
type InitializeVirtualPoolWithToken2022Accounts = Accounts<DynamicBondingCurve['instructions']['11']>['initializeVirtualPoolWithToken2022'];
|
|
5362
|
-
type MigrateMeteoraDammAccounts = Accounts<DynamicBondingCurve['instructions']['12']>['migrateMeteoraDamm'];
|
|
5363
|
-
type MigrateMeteoraDammClaimLpTokenAccounts = Accounts<DynamicBondingCurve['instructions']['13']>['migrateMeteoraDammClaimLpToken'];
|
|
5364
|
-
type MigrateMeteoraDammLockLpTokenAccounts = Accounts<DynamicBondingCurve['instructions']['14']>['migrateMeteoraDammLockLpToken'];
|
|
5365
|
-
type MigrationDammV2Accounts = Accounts<DynamicBondingCurve['instructions']['15']>['migrationDammV2'];
|
|
5366
|
-
type MigrationDammV2CreateMetadataAccounts = Accounts<DynamicBondingCurve['instructions']['16']>['migrationDammV2CreateMetadata'];
|
|
5367
|
-
type MigrationMeteoraDammCreateMetadataAccounts = Accounts<DynamicBondingCurve['instructions']['17']>['migrationMeteoraDammCreateMetadata'];
|
|
5368
|
-
type PartnerWithdrawSurplusAccounts = Accounts<DynamicBondingCurve['instructions']['18']>['partnerWithdrawSurplus'];
|
|
5369
|
-
type SwapAccounts = Accounts<DynamicBondingCurve['instructions']['20']>['swap'];
|
|
5370
|
-
type Swap2Accounts = Accounts<DynamicBondingCurve['instructions']['21']>['swap2'];
|
|
5371
|
-
type TransferPoolCreatorAccounts = Accounts<DynamicBondingCurve['instructions']['22']>['transferPoolCreator'];
|
|
5372
|
-
type WithdrawLeftoverAccounts = Accounts<DynamicBondingCurve['instructions']['23']>['withdrawLeftover'];
|
|
5373
|
-
type WithdrawMigrationFeeAccounts = Accounts<DynamicBondingCurve['instructions']['24']>['withdrawMigrationFee'];
|
|
5400
|
+
type CreateConfigAccounts = Accounts<DynamicBondingCurve['instructions']['6']>['createConfig'];
|
|
5374
5401
|
type ConfigParameters = IdlTypes<DynamicBondingCurve>['configParameters'];
|
|
5375
|
-
type MigratedPoolFee = IdlTypes<DynamicBondingCurve>['migratedPoolFee'];
|
|
5376
5402
|
type LockedVestingParameters = IdlTypes<DynamicBondingCurve>['lockedVestingParams'];
|
|
5377
5403
|
type InitializePoolParameters = IdlTypes<DynamicBondingCurve>['initializePoolParameters'];
|
|
5378
|
-
type SwapParameters = IdlTypes<DynamicBondingCurve>['swapParameters'];
|
|
5379
5404
|
type PoolFeeParameters = IdlTypes<DynamicBondingCurve>['poolFeeParameters'];
|
|
5380
5405
|
type DynamicFeeParameters = IdlTypes<DynamicBondingCurve>['dynamicFeeParameters'];
|
|
5381
5406
|
type LiquidityDistributionParameters = IdlTypes<DynamicBondingCurve>['liquidityDistributionParameters'];
|
|
5382
5407
|
type PoolFeesConfig = IdlTypes<DynamicBondingCurve>['poolFeesConfig'];
|
|
5383
|
-
type DynamicFeeConfig = IdlTypes<DynamicBondingCurve>['dynamicFeeConfig'];
|
|
5384
5408
|
type BaseFeeConfig = IdlTypes<DynamicBondingCurve>['baseFeeConfig'];
|
|
5409
|
+
type DynamicFeeConfig = IdlTypes<DynamicBondingCurve>['dynamicFeeConfig'];
|
|
5385
5410
|
type PoolFees = IdlTypes<DynamicBondingCurve>['poolFees'];
|
|
5386
|
-
type
|
|
5411
|
+
type MigratedPoolFee = IdlTypes<DynamicBondingCurve>['migratedPoolFee'];
|
|
5387
5412
|
type SwapResult = IdlTypes<DynamicBondingCurve>['swapResult'];
|
|
5388
5413
|
type SwapResult2 = IdlTypes<DynamicBondingCurve>['swapResult2'];
|
|
5389
5414
|
type CreatePartnerMetadataParameters = IdlTypes<DynamicBondingCurve>['createPartnerMetadataParameters'];
|
|
5390
|
-
type
|
|
5391
|
-
type
|
|
5392
|
-
type Config = IdlAccounts<DynamicBondingCurve>['config'];
|
|
5415
|
+
type PoolConfig = IdlAccounts<DynamicBondingCurve>['poolConfig'];
|
|
5416
|
+
type VirtualPool = IdlAccounts<DynamicBondingCurve>['virtualPool'];
|
|
5393
5417
|
type MeteoraDammMigrationMetadata = IdlAccounts<DynamicBondingCurve>['meteoraDammMigrationMetadata'];
|
|
5394
|
-
type MeteoraDammV2MigrationMetadata = IdlAccounts<DynamicBondingCurve>['meteoraDammV2Metadata'];
|
|
5395
5418
|
type LockEscrow = IdlAccounts<DynamicBondingCurve>['lockEscrow'];
|
|
5396
5419
|
type VolatilityTracker = IdlTypes<DynamicBondingCurve>['volatilityTracker'];
|
|
5397
|
-
type VirtualPool = IdlAccounts<DynamicBondingCurve>['virtualPool'];
|
|
5398
|
-
type PoolConfig = IdlAccounts<DynamicBondingCurve>['poolConfig'];
|
|
5399
5420
|
type PartnerMetadata = IdlAccounts<DynamicBondingCurve>['partnerMetadata'];
|
|
5400
5421
|
type VirtualPoolMetadata = IdlAccounts<DynamicBondingCurve>['virtualPoolMetadata'];
|
|
5401
5422
|
declare enum ActivationType {
|
|
@@ -5458,13 +5479,12 @@ declare enum SwapMode {
|
|
|
5458
5479
|
PartialFill = 1,
|
|
5459
5480
|
ExactOut = 2
|
|
5460
5481
|
}
|
|
5461
|
-
type
|
|
5462
|
-
type
|
|
5482
|
+
type CreateConfigParams = Omit<CreateConfigAccounts, 'program' | 'eventAuthority' | 'systemProgram'> & ConfigParameters;
|
|
5483
|
+
type CreateDammV1MigrationMetadataParams = {
|
|
5463
5484
|
payer: PublicKey;
|
|
5464
5485
|
virtualPool: PublicKey;
|
|
5465
5486
|
config: PublicKey;
|
|
5466
5487
|
};
|
|
5467
|
-
type CreateDammV2MigrationMetadataParam = CreateDammV1MigrationMetadataParam;
|
|
5468
5488
|
type BaseFee = {
|
|
5469
5489
|
cliffFeeNumerator: BN;
|
|
5470
5490
|
firstFactor: number;
|
|
@@ -5498,7 +5518,7 @@ type BaseFeeParams = {
|
|
|
5498
5518
|
baseFeeMode: BaseFeeMode.RateLimiter;
|
|
5499
5519
|
rateLimiterParam: RateLimiterParams;
|
|
5500
5520
|
};
|
|
5501
|
-
type
|
|
5521
|
+
type BuildCurveBaseParams = {
|
|
5502
5522
|
totalTokenSupply: number;
|
|
5503
5523
|
migrationOption: MigrationOption;
|
|
5504
5524
|
tokenBaseDecimal: TokenDecimal;
|
|
@@ -5527,25 +5547,25 @@ type BuildCurveBaseParam = {
|
|
|
5527
5547
|
poolFeeBps: number;
|
|
5528
5548
|
};
|
|
5529
5549
|
};
|
|
5530
|
-
type
|
|
5550
|
+
type BuildCurveParams = BuildCurveBaseParams & {
|
|
5531
5551
|
percentageSupplyOnMigration: number;
|
|
5532
5552
|
migrationQuoteThreshold: number;
|
|
5533
5553
|
};
|
|
5534
|
-
type
|
|
5554
|
+
type BuildCurveWithMarketCapParams = BuildCurveBaseParams & {
|
|
5535
5555
|
initialMarketCap: number;
|
|
5536
5556
|
migrationMarketCap: number;
|
|
5537
5557
|
};
|
|
5538
|
-
type
|
|
5558
|
+
type BuildCurveWithTwoSegmentsParams = BuildCurveBaseParams & {
|
|
5539
5559
|
initialMarketCap: number;
|
|
5540
5560
|
migrationMarketCap: number;
|
|
5541
5561
|
percentageSupplyOnMigration: number;
|
|
5542
5562
|
};
|
|
5543
|
-
type
|
|
5563
|
+
type BuildCurveWithLiquidityWeightsParams = BuildCurveBaseParams & {
|
|
5544
5564
|
initialMarketCap: number;
|
|
5545
5565
|
migrationMarketCap: number;
|
|
5546
5566
|
liquidityWeights: number[];
|
|
5547
5567
|
};
|
|
5548
|
-
type
|
|
5568
|
+
type InitializePoolBaseParams = {
|
|
5549
5569
|
name: string;
|
|
5550
5570
|
symbol: string;
|
|
5551
5571
|
uri: string;
|
|
@@ -5559,7 +5579,7 @@ type InitializePoolBaseParam = {
|
|
|
5559
5579
|
quoteMint: PublicKey;
|
|
5560
5580
|
mintMetadata?: PublicKey;
|
|
5561
5581
|
};
|
|
5562
|
-
type
|
|
5582
|
+
type CreatePoolParams = {
|
|
5563
5583
|
name: string;
|
|
5564
5584
|
symbol: string;
|
|
5565
5585
|
uri: string;
|
|
@@ -5568,50 +5588,50 @@ type CreatePoolParam = {
|
|
|
5568
5588
|
config: PublicKey;
|
|
5569
5589
|
baseMint: PublicKey;
|
|
5570
5590
|
};
|
|
5571
|
-
type
|
|
5572
|
-
preCreatePoolParam:
|
|
5591
|
+
type CreateConfigAndPoolParams = CreateConfigParams & {
|
|
5592
|
+
preCreatePoolParam: PreCreatePoolParams;
|
|
5573
5593
|
};
|
|
5574
|
-
type
|
|
5575
|
-
firstBuyParam?:
|
|
5594
|
+
type CreateConfigAndPoolWithFirstBuyParams = CreateConfigAndPoolParams & {
|
|
5595
|
+
firstBuyParam?: FirstBuyParams;
|
|
5576
5596
|
};
|
|
5577
|
-
type
|
|
5578
|
-
createPoolParam:
|
|
5579
|
-
firstBuyParam?:
|
|
5597
|
+
type CreatePoolWithFirstBuyParams = {
|
|
5598
|
+
createPoolParam: CreatePoolParams;
|
|
5599
|
+
firstBuyParam?: FirstBuyParams;
|
|
5580
5600
|
};
|
|
5581
|
-
type
|
|
5582
|
-
createPoolParam:
|
|
5583
|
-
partnerFirstBuyParam?:
|
|
5584
|
-
creatorFirstBuyParam?:
|
|
5601
|
+
type CreatePoolWithPartnerAndCreatorFirstBuyParams = {
|
|
5602
|
+
createPoolParam: CreatePoolParams;
|
|
5603
|
+
partnerFirstBuyParam?: PartnerFirstBuyParams;
|
|
5604
|
+
creatorFirstBuyParam?: CreatorFirstBuyParams;
|
|
5585
5605
|
};
|
|
5586
|
-
type
|
|
5606
|
+
type PreCreatePoolParams = {
|
|
5587
5607
|
name: string;
|
|
5588
5608
|
symbol: string;
|
|
5589
5609
|
uri: string;
|
|
5590
5610
|
poolCreator: PublicKey;
|
|
5591
5611
|
baseMint: PublicKey;
|
|
5592
5612
|
};
|
|
5593
|
-
type
|
|
5613
|
+
type FirstBuyParams = {
|
|
5594
5614
|
buyer: PublicKey;
|
|
5595
5615
|
receiver?: PublicKey;
|
|
5596
5616
|
buyAmount: BN;
|
|
5597
5617
|
minimumAmountOut: BN;
|
|
5598
5618
|
referralTokenAccount: PublicKey | null;
|
|
5599
5619
|
};
|
|
5600
|
-
type
|
|
5620
|
+
type PartnerFirstBuyParams = {
|
|
5601
5621
|
partner: PublicKey;
|
|
5602
5622
|
receiver: PublicKey;
|
|
5603
5623
|
buyAmount: BN;
|
|
5604
5624
|
minimumAmountOut: BN;
|
|
5605
5625
|
referralTokenAccount: PublicKey | null;
|
|
5606
5626
|
};
|
|
5607
|
-
type
|
|
5627
|
+
type CreatorFirstBuyParams = {
|
|
5608
5628
|
creator: PublicKey;
|
|
5609
5629
|
receiver: PublicKey;
|
|
5610
5630
|
buyAmount: BN;
|
|
5611
5631
|
minimumAmountOut: BN;
|
|
5612
5632
|
referralTokenAccount: PublicKey | null;
|
|
5613
5633
|
};
|
|
5614
|
-
type
|
|
5634
|
+
type SwapParams = {
|
|
5615
5635
|
owner: PublicKey;
|
|
5616
5636
|
pool: PublicKey;
|
|
5617
5637
|
amountIn: BN;
|
|
@@ -5620,7 +5640,7 @@ type SwapParam = {
|
|
|
5620
5640
|
referralTokenAccount: PublicKey | null;
|
|
5621
5641
|
payer?: PublicKey;
|
|
5622
5642
|
};
|
|
5623
|
-
type
|
|
5643
|
+
type Swap2Params = {
|
|
5624
5644
|
owner: PublicKey;
|
|
5625
5645
|
pool: PublicKey;
|
|
5626
5646
|
swapBaseForQuote: boolean;
|
|
@@ -5639,7 +5659,7 @@ type Swap2Param = {
|
|
|
5639
5659
|
amountOut: BN;
|
|
5640
5660
|
maximumAmountIn: BN;
|
|
5641
5661
|
});
|
|
5642
|
-
type
|
|
5662
|
+
type SwapQuoteParams = {
|
|
5643
5663
|
virtualPool: VirtualPool;
|
|
5644
5664
|
config: PoolConfig;
|
|
5645
5665
|
swapBaseForQuote: boolean;
|
|
@@ -5648,7 +5668,7 @@ type SwapQuoteParam = {
|
|
|
5648
5668
|
hasReferral: boolean;
|
|
5649
5669
|
currentPoint: BN;
|
|
5650
5670
|
};
|
|
5651
|
-
type
|
|
5671
|
+
type SwapQuote2Params = {
|
|
5652
5672
|
virtualPool: VirtualPool;
|
|
5653
5673
|
config: PoolConfig;
|
|
5654
5674
|
swapBaseForQuote: boolean;
|
|
@@ -5665,33 +5685,28 @@ type SwapQuote2Param = {
|
|
|
5665
5685
|
swapMode: SwapMode.ExactOut;
|
|
5666
5686
|
amountOut: BN;
|
|
5667
5687
|
});
|
|
5668
|
-
type
|
|
5669
|
-
virtualPool: VirtualPool;
|
|
5670
|
-
config: PoolConfig;
|
|
5671
|
-
currentPoint: BN;
|
|
5672
|
-
};
|
|
5673
|
-
type MigrateToDammV1Param = {
|
|
5688
|
+
type MigrateToDammV1Params = {
|
|
5674
5689
|
payer: PublicKey;
|
|
5675
5690
|
virtualPool: PublicKey;
|
|
5676
5691
|
dammConfig: PublicKey;
|
|
5677
5692
|
};
|
|
5678
|
-
type
|
|
5693
|
+
type MigrateToDammV2Params = MigrateToDammV1Params;
|
|
5679
5694
|
type MigrateToDammV2Response = {
|
|
5680
5695
|
transaction: Transaction;
|
|
5681
5696
|
firstPositionNftKeypair: Keypair;
|
|
5682
5697
|
secondPositionNftKeypair: Keypair;
|
|
5683
5698
|
};
|
|
5684
|
-
type
|
|
5699
|
+
type DammLpTokenParams = {
|
|
5685
5700
|
payer: PublicKey;
|
|
5686
5701
|
virtualPool: PublicKey;
|
|
5687
5702
|
dammConfig: PublicKey;
|
|
5688
5703
|
isPartner: boolean;
|
|
5689
5704
|
};
|
|
5690
|
-
type
|
|
5705
|
+
type CreateLockerParams = {
|
|
5691
5706
|
payer: PublicKey;
|
|
5692
5707
|
virtualPool: PublicKey;
|
|
5693
5708
|
};
|
|
5694
|
-
type
|
|
5709
|
+
type ClaimTradingFeeParams = {
|
|
5695
5710
|
feeClaimer: PublicKey;
|
|
5696
5711
|
payer: PublicKey;
|
|
5697
5712
|
pool: PublicKey;
|
|
@@ -5700,7 +5715,7 @@ type ClaimTradingFeeParam = {
|
|
|
5700
5715
|
receiver?: PublicKey;
|
|
5701
5716
|
tempWSolAcc?: PublicKey;
|
|
5702
5717
|
};
|
|
5703
|
-
type
|
|
5718
|
+
type ClaimTradingFee2Params = {
|
|
5704
5719
|
feeClaimer: PublicKey;
|
|
5705
5720
|
payer: PublicKey;
|
|
5706
5721
|
pool: PublicKey;
|
|
@@ -5708,7 +5723,7 @@ type ClaimTradingFee2Param = {
|
|
|
5708
5723
|
maxQuoteAmount: BN;
|
|
5709
5724
|
receiver: PublicKey;
|
|
5710
5725
|
};
|
|
5711
|
-
type
|
|
5726
|
+
type ClaimPartnerTradingFeeWithQuoteMintNotSolParams = {
|
|
5712
5727
|
feeClaimer: PublicKey;
|
|
5713
5728
|
payer: PublicKey;
|
|
5714
5729
|
feeReceiver: PublicKey;
|
|
@@ -5719,10 +5734,10 @@ type ClaimPartnerTradingFeeWithQuoteMintNotSolParam = {
|
|
|
5719
5734
|
tokenBaseProgram: PublicKey;
|
|
5720
5735
|
tokenQuoteProgram: PublicKey;
|
|
5721
5736
|
};
|
|
5722
|
-
type
|
|
5737
|
+
type ClaimPartnerTradingFeeWithQuoteMintSolParams = ClaimPartnerTradingFeeWithQuoteMintNotSolParams & {
|
|
5723
5738
|
tempWSolAcc: PublicKey;
|
|
5724
5739
|
};
|
|
5725
|
-
type
|
|
5740
|
+
type ClaimCreatorTradingFeeParams = {
|
|
5726
5741
|
creator: PublicKey;
|
|
5727
5742
|
payer: PublicKey;
|
|
5728
5743
|
pool: PublicKey;
|
|
@@ -5731,7 +5746,7 @@ type ClaimCreatorTradingFeeParam = {
|
|
|
5731
5746
|
receiver?: PublicKey;
|
|
5732
5747
|
tempWSolAcc?: PublicKey;
|
|
5733
5748
|
};
|
|
5734
|
-
type
|
|
5749
|
+
type ClaimCreatorTradingFee2Params = {
|
|
5735
5750
|
creator: PublicKey;
|
|
5736
5751
|
payer: PublicKey;
|
|
5737
5752
|
pool: PublicKey;
|
|
@@ -5739,7 +5754,7 @@ type ClaimCreatorTradingFee2Param = {
|
|
|
5739
5754
|
maxQuoteAmount: BN;
|
|
5740
5755
|
receiver: PublicKey;
|
|
5741
5756
|
};
|
|
5742
|
-
type
|
|
5757
|
+
type ClaimCreatorTradingFeeWithQuoteMintNotSolParams = {
|
|
5743
5758
|
creator: PublicKey;
|
|
5744
5759
|
payer: PublicKey;
|
|
5745
5760
|
feeReceiver: PublicKey;
|
|
@@ -5749,22 +5764,22 @@ type ClaimCreatorTradingFeeWithQuoteMintNotSolParam = {
|
|
|
5749
5764
|
tokenBaseProgram: PublicKey;
|
|
5750
5765
|
tokenQuoteProgram: PublicKey;
|
|
5751
5766
|
};
|
|
5752
|
-
type
|
|
5767
|
+
type ClaimCreatorTradingFeeWithQuoteMintSolParams = ClaimCreatorTradingFeeWithQuoteMintNotSolParams & {
|
|
5753
5768
|
tempWSolAcc: PublicKey;
|
|
5754
5769
|
};
|
|
5755
|
-
type
|
|
5770
|
+
type PartnerWithdrawSurplusParams = {
|
|
5756
5771
|
feeClaimer: PublicKey;
|
|
5757
5772
|
virtualPool: PublicKey;
|
|
5758
5773
|
};
|
|
5759
|
-
type
|
|
5774
|
+
type CreatorWithdrawSurplusParams = {
|
|
5760
5775
|
creator: PublicKey;
|
|
5761
5776
|
virtualPool: PublicKey;
|
|
5762
5777
|
};
|
|
5763
|
-
type
|
|
5778
|
+
type WithdrawLeftoverParams = {
|
|
5764
5779
|
payer: PublicKey;
|
|
5765
5780
|
virtualPool: PublicKey;
|
|
5766
5781
|
};
|
|
5767
|
-
type
|
|
5782
|
+
type CreateVirtualPoolMetadataParams = {
|
|
5768
5783
|
virtualPool: PublicKey;
|
|
5769
5784
|
name: string;
|
|
5770
5785
|
website: string;
|
|
@@ -5772,19 +5787,19 @@ type CreateVirtualPoolMetadataParam = {
|
|
|
5772
5787
|
creator: PublicKey;
|
|
5773
5788
|
payer: PublicKey;
|
|
5774
5789
|
};
|
|
5775
|
-
type
|
|
5790
|
+
type CreatePartnerMetadataParams = {
|
|
5776
5791
|
name: string;
|
|
5777
5792
|
website: string;
|
|
5778
5793
|
logo: string;
|
|
5779
5794
|
feeClaimer: PublicKey;
|
|
5780
5795
|
payer: PublicKey;
|
|
5781
5796
|
};
|
|
5782
|
-
type
|
|
5797
|
+
type TransferPoolCreatorParams = {
|
|
5783
5798
|
virtualPool: PublicKey;
|
|
5784
5799
|
creator: PublicKey;
|
|
5785
5800
|
newCreator: PublicKey;
|
|
5786
5801
|
};
|
|
5787
|
-
type
|
|
5802
|
+
type WithdrawMigrationFeeParams = {
|
|
5788
5803
|
virtualPool: PublicKey;
|
|
5789
5804
|
sender: PublicKey;
|
|
5790
5805
|
};
|
|
@@ -5848,14 +5863,14 @@ declare class MigrationService extends DynamicBondingCurveProgram {
|
|
|
5848
5863
|
* @param virtualPool - The virtual pool address
|
|
5849
5864
|
* @returns A create locker transaction
|
|
5850
5865
|
*/
|
|
5851
|
-
createLocker(params:
|
|
5866
|
+
createLocker(params: CreateLockerParams): Promise<Transaction>;
|
|
5852
5867
|
/**
|
|
5853
5868
|
* Withdraw leftover
|
|
5854
5869
|
* @param payer - The payer of the transaction
|
|
5855
5870
|
* @param virtualPool - The virtual pool address
|
|
5856
5871
|
* @returns A withdraw leftover transaction
|
|
5857
5872
|
*/
|
|
5858
|
-
withdrawLeftover(params:
|
|
5873
|
+
withdrawLeftover(params: WithdrawLeftoverParams): Promise<Transaction>;
|
|
5859
5874
|
/**
|
|
5860
5875
|
* Create metadata for the migration of Meteora DAMM V1
|
|
5861
5876
|
* @param payer - The payer of the transaction
|
|
@@ -5863,7 +5878,7 @@ declare class MigrationService extends DynamicBondingCurveProgram {
|
|
|
5863
5878
|
* @param config - The config address
|
|
5864
5879
|
* @returns A migration transaction
|
|
5865
5880
|
*/
|
|
5866
|
-
createDammV1MigrationMetadata(params:
|
|
5881
|
+
createDammV1MigrationMetadata(params: CreateDammV1MigrationMetadataParams): Promise<Transaction>;
|
|
5867
5882
|
/**
|
|
5868
5883
|
* Migrate to DAMM V1
|
|
5869
5884
|
* @param payer - The payer of the transaction
|
|
@@ -5871,7 +5886,7 @@ declare class MigrationService extends DynamicBondingCurveProgram {
|
|
|
5871
5886
|
* @param dammConfig - The damm config address
|
|
5872
5887
|
* @returns A migrate transaction
|
|
5873
5888
|
*/
|
|
5874
|
-
migrateToDammV1(params:
|
|
5889
|
+
migrateToDammV1(params: MigrateToDammV1Params): Promise<Transaction>;
|
|
5875
5890
|
/**
|
|
5876
5891
|
* Lock DAMM V1 LP token for creator or partner
|
|
5877
5892
|
* @param payer - The payer of the transaction
|
|
@@ -5880,7 +5895,7 @@ declare class MigrationService extends DynamicBondingCurveProgram {
|
|
|
5880
5895
|
* @param isPartner - Whether the partner is locking the LP token
|
|
5881
5896
|
* @returns A lock transaction
|
|
5882
5897
|
*/
|
|
5883
|
-
lockDammV1LpToken(params:
|
|
5898
|
+
lockDammV1LpToken(params: DammLpTokenParams): Promise<Transaction>;
|
|
5884
5899
|
/**
|
|
5885
5900
|
* Claim DAMM V1 LP token for creator or partner
|
|
5886
5901
|
* @param payer - The payer of the transaction
|
|
@@ -5889,15 +5904,7 @@ declare class MigrationService extends DynamicBondingCurveProgram {
|
|
|
5889
5904
|
* @param isPartner - Whether the partner is claiming the LP token
|
|
5890
5905
|
* @returns A claim transaction
|
|
5891
5906
|
*/
|
|
5892
|
-
claimDammV1LpToken(params:
|
|
5893
|
-
/**
|
|
5894
|
-
* Create metadata for the migration of Meteora DAMM V2
|
|
5895
|
-
* @param payer - The payer of the transaction
|
|
5896
|
-
* @param virtualPool - The virtual pool address
|
|
5897
|
-
* @param config - The config address
|
|
5898
|
-
* @returns A migration transaction
|
|
5899
|
-
*/
|
|
5900
|
-
createDammV2MigrationMetadata(params: CreateDammV2MigrationMetadataParam): Promise<Transaction>;
|
|
5907
|
+
claimDammV1LpToken(params: DammLpTokenParams): Promise<Transaction>;
|
|
5901
5908
|
/**
|
|
5902
5909
|
* Migrate to DAMM V2
|
|
5903
5910
|
* @param payer - The payer of the transaction
|
|
@@ -5905,7 +5912,7 @@ declare class MigrationService extends DynamicBondingCurveProgram {
|
|
|
5905
5912
|
* @param dammConfig - The damm config address
|
|
5906
5913
|
* @returns A migrate transaction
|
|
5907
5914
|
*/
|
|
5908
|
-
migrateToDammV2(params:
|
|
5915
|
+
migrateToDammV2(params: MigrateToDammV2Params): Promise<MigrateToDammV2Response>;
|
|
5909
5916
|
}
|
|
5910
5917
|
|
|
5911
5918
|
declare class PartnerService extends DynamicBondingCurveProgram {
|
|
@@ -5921,7 +5928,7 @@ declare class PartnerService extends DynamicBondingCurveProgram {
|
|
|
5921
5928
|
* @param payer - The payer of the transaction
|
|
5922
5929
|
* @returns A new config
|
|
5923
5930
|
*/
|
|
5924
|
-
createConfig(params:
|
|
5931
|
+
createConfig(params: CreateConfigParams): Promise<Transaction>;
|
|
5925
5932
|
/**
|
|
5926
5933
|
* Create partner metadata
|
|
5927
5934
|
* @param name - The name of the partner
|
|
@@ -5931,7 +5938,7 @@ declare class PartnerService extends DynamicBondingCurveProgram {
|
|
|
5931
5938
|
* @param payer - The payer of the transaction
|
|
5932
5939
|
* @returns A create partner metadata transaction
|
|
5933
5940
|
*/
|
|
5934
|
-
createPartnerMetadata(params:
|
|
5941
|
+
createPartnerMetadata(params: CreatePartnerMetadataParams): Promise<Transaction>;
|
|
5935
5942
|
/**
|
|
5936
5943
|
* Private method to claim trading fee with quote mint SOL
|
|
5937
5944
|
* @param feeClaimer - The partner's fee claimer address
|
|
@@ -5972,7 +5979,7 @@ declare class PartnerService extends DynamicBondingCurveProgram {
|
|
|
5972
5979
|
* @param tempWSolAcc - The temporary wallet that will receive the SOL (Optional)
|
|
5973
5980
|
* @returns A claim trading fee transaction
|
|
5974
5981
|
*/
|
|
5975
|
-
claimPartnerTradingFee(params:
|
|
5982
|
+
claimPartnerTradingFee(params: ClaimTradingFeeParams): Promise<Transaction>;
|
|
5976
5983
|
/**
|
|
5977
5984
|
* Claim partner trading fee
|
|
5978
5985
|
* @param feeClaimer - The partner's fee claimer address
|
|
@@ -5983,21 +5990,21 @@ declare class PartnerService extends DynamicBondingCurveProgram {
|
|
|
5983
5990
|
* @param receiver - The wallet that will receive the tokens
|
|
5984
5991
|
* @returns A claim trading fee transaction
|
|
5985
5992
|
*/
|
|
5986
|
-
claimPartnerTradingFee2(params:
|
|
5993
|
+
claimPartnerTradingFee2(params: ClaimTradingFee2Params): Promise<Transaction>;
|
|
5987
5994
|
/**
|
|
5988
5995
|
* Partner withdraw surplus
|
|
5989
5996
|
* @param feeClaimer - The partner's fee claimer address
|
|
5990
5997
|
* @param virtualPool - The virtual pool address
|
|
5991
5998
|
* @returns A partner withdraw surplus transaction
|
|
5992
5999
|
*/
|
|
5993
|
-
partnerWithdrawSurplus(params:
|
|
6000
|
+
partnerWithdrawSurplus(params: PartnerWithdrawSurplusParams): Promise<Transaction>;
|
|
5994
6001
|
/**
|
|
5995
6002
|
* Partner withdraw migration fee
|
|
5996
6003
|
* @param virtualPool - The virtual pool address
|
|
5997
6004
|
* @param sender - The sender of the pool
|
|
5998
6005
|
* @returns A partner withdraw migration fee transaction
|
|
5999
6006
|
*/
|
|
6000
|
-
partnerWithdrawMigrationFee(params:
|
|
6007
|
+
partnerWithdrawMigrationFee(params: WithdrawMigrationFeeParams): Promise<Transaction>;
|
|
6001
6008
|
}
|
|
6002
6009
|
|
|
6003
6010
|
declare class PoolService extends DynamicBondingCurveProgram {
|
|
@@ -6088,7 +6095,7 @@ declare class PoolService extends DynamicBondingCurveProgram {
|
|
|
6088
6095
|
* @param baseMint - The base mint address
|
|
6089
6096
|
* @returns A new pool
|
|
6090
6097
|
*/
|
|
6091
|
-
createPool(params:
|
|
6098
|
+
createPool(params: CreatePoolParams): Promise<Transaction>;
|
|
6092
6099
|
/**
|
|
6093
6100
|
* Create a new config and pool
|
|
6094
6101
|
* @param config - The config address
|
|
@@ -6100,7 +6107,7 @@ declare class PoolService extends DynamicBondingCurveProgram {
|
|
|
6100
6107
|
* @param preCreatePoolParam - The parameters for the pool
|
|
6101
6108
|
* @returns A new config and pool
|
|
6102
6109
|
*/
|
|
6103
|
-
createConfigAndPool(params:
|
|
6110
|
+
createConfigAndPool(params: CreateConfigAndPoolParams): Promise<Transaction>;
|
|
6104
6111
|
/**
|
|
6105
6112
|
* Create a new config and pool and buy tokens
|
|
6106
6113
|
* @param config - The config address
|
|
@@ -6113,7 +6120,7 @@ declare class PoolService extends DynamicBondingCurveProgram {
|
|
|
6113
6120
|
* @param firstBuyParam - The parameters for the first buy
|
|
6114
6121
|
* @returns An object containing the new config transaction, new pool transaction, and first buy transaction
|
|
6115
6122
|
*/
|
|
6116
|
-
createConfigAndPoolWithFirstBuy(params:
|
|
6123
|
+
createConfigAndPoolWithFirstBuy(params: CreateConfigAndPoolWithFirstBuyParams): Promise<{
|
|
6117
6124
|
createConfigTx: Transaction;
|
|
6118
6125
|
createPoolTx: Transaction;
|
|
6119
6126
|
swapBuyTx: Transaction | undefined;
|
|
@@ -6124,7 +6131,7 @@ declare class PoolService extends DynamicBondingCurveProgram {
|
|
|
6124
6131
|
* @param firstBuyParam - The parameters for the first buy
|
|
6125
6132
|
* @returns An object containing the new pool transaction and swap buy transaction
|
|
6126
6133
|
*/
|
|
6127
|
-
createPoolWithFirstBuy(params:
|
|
6134
|
+
createPoolWithFirstBuy(params: CreatePoolWithFirstBuyParams): Promise<{
|
|
6128
6135
|
createPoolTx: Transaction;
|
|
6129
6136
|
swapBuyTx: Transaction | undefined;
|
|
6130
6137
|
}>;
|
|
@@ -6135,7 +6142,7 @@ declare class PoolService extends DynamicBondingCurveProgram {
|
|
|
6135
6142
|
* @param creatorFirstBuyParam - The parameters for the creator first buy
|
|
6136
6143
|
* @returns An object containing the new pool transaction and swap buy transactions for partner and creator
|
|
6137
6144
|
*/
|
|
6138
|
-
createPoolWithPartnerAndCreatorFirstBuy(params:
|
|
6145
|
+
createPoolWithPartnerAndCreatorFirstBuy(params: CreatePoolWithPartnerAndCreatorFirstBuyParams): Promise<{
|
|
6139
6146
|
createPoolTx: Transaction;
|
|
6140
6147
|
partnerSwapBuyTx: Transaction | undefined;
|
|
6141
6148
|
creatorSwapBuyTx: Transaction | undefined;
|
|
@@ -6151,7 +6158,7 @@ declare class PoolService extends DynamicBondingCurveProgram {
|
|
|
6151
6158
|
* @param payer - The payer of the swap (optional)
|
|
6152
6159
|
* @returns A swap transaction
|
|
6153
6160
|
*/
|
|
6154
|
-
swap(params:
|
|
6161
|
+
swap(params: SwapParams): Promise<Transaction>;
|
|
6155
6162
|
/**
|
|
6156
6163
|
* Swap V2 between base and quote (included SwapMode: ExactIn, PartialFill, ExactOut)
|
|
6157
6164
|
* @param owner - The owner of the swap
|
|
@@ -6166,7 +6173,7 @@ declare class PoolService extends DynamicBondingCurveProgram {
|
|
|
6166
6173
|
* @param maximumAmountIn - The maximum amount in (for ExactOut)
|
|
6167
6174
|
* @returns A swap transaction
|
|
6168
6175
|
*/
|
|
6169
|
-
swap2(params:
|
|
6176
|
+
swap2(params: Swap2Params): Promise<Transaction>;
|
|
6170
6177
|
/**
|
|
6171
6178
|
* Calculate the amount out for a swap (quote) (for swap1)
|
|
6172
6179
|
* @param virtualPool - The virtual pool
|
|
@@ -6178,7 +6185,7 @@ declare class PoolService extends DynamicBondingCurveProgram {
|
|
|
6178
6185
|
* @param currentPoint - The current point
|
|
6179
6186
|
* @returns The swap quote result
|
|
6180
6187
|
*/
|
|
6181
|
-
swapQuote(params:
|
|
6188
|
+
swapQuote(params: SwapQuoteParams): SwapQuoteResult;
|
|
6182
6189
|
/**
|
|
6183
6190
|
* Calculate the amount out for a swap (quote) based on swap mode (for swap2)
|
|
6184
6191
|
* @param virtualPool - The virtual pool
|
|
@@ -6192,7 +6199,7 @@ declare class PoolService extends DynamicBondingCurveProgram {
|
|
|
6192
6199
|
* @param amountOut - The amount out (for ExactOut)
|
|
6193
6200
|
* @returns The swap quote result
|
|
6194
6201
|
*/
|
|
6195
|
-
swapQuote2(params:
|
|
6202
|
+
swapQuote2(params: SwapQuote2Params): SwapQuote2Result;
|
|
6196
6203
|
}
|
|
6197
6204
|
|
|
6198
6205
|
declare class CreatorService extends DynamicBondingCurveProgram {
|
|
@@ -6208,7 +6215,7 @@ declare class CreatorService extends DynamicBondingCurveProgram {
|
|
|
6208
6215
|
* @param payer - The payer of the transaction
|
|
6209
6216
|
* @returns A create virtual pool metadata transaction
|
|
6210
6217
|
*/
|
|
6211
|
-
createPoolMetadata(params:
|
|
6218
|
+
createPoolMetadata(params: CreateVirtualPoolMetadataParams): Promise<Transaction>;
|
|
6212
6219
|
/**
|
|
6213
6220
|
* Private method to claim trading fee with quote mint SOL
|
|
6214
6221
|
* @param creator - The creator of the pool
|
|
@@ -6247,7 +6254,7 @@ declare class CreatorService extends DynamicBondingCurveProgram {
|
|
|
6247
6254
|
* @param tempWSolAcc - The temporary wallet that will receive the SOL (Optional)
|
|
6248
6255
|
* @returns A claim creator trading fee transaction
|
|
6249
6256
|
*/
|
|
6250
|
-
claimCreatorTradingFee(params:
|
|
6257
|
+
claimCreatorTradingFee(params: ClaimCreatorTradingFeeParams): Promise<Transaction>;
|
|
6251
6258
|
/**
|
|
6252
6259
|
* Claim creator trading fee
|
|
6253
6260
|
* @param creator - The creator of the pool
|
|
@@ -6258,14 +6265,14 @@ declare class CreatorService extends DynamicBondingCurveProgram {
|
|
|
6258
6265
|
* @param receiver - The wallet that will receive the tokens
|
|
6259
6266
|
* @returns A claim creator trading fee transaction
|
|
6260
6267
|
*/
|
|
6261
|
-
claimCreatorTradingFee2(params:
|
|
6268
|
+
claimCreatorTradingFee2(params: ClaimCreatorTradingFee2Params): Promise<Transaction>;
|
|
6262
6269
|
/**
|
|
6263
6270
|
* Withdraw creator surplus
|
|
6264
6271
|
* @param creator - The creator of the pool
|
|
6265
6272
|
* @param virtualPool - The virtual pool address
|
|
6266
6273
|
* @returns A creator withdraw surplus transaction
|
|
6267
6274
|
*/
|
|
6268
|
-
creatorWithdrawSurplus(params:
|
|
6275
|
+
creatorWithdrawSurplus(params: CreatorWithdrawSurplusParams): Promise<Transaction>;
|
|
6269
6276
|
/**
|
|
6270
6277
|
* Transfer pool creator
|
|
6271
6278
|
* @param virtualPool - The virtual pool address
|
|
@@ -6273,14 +6280,14 @@ declare class CreatorService extends DynamicBondingCurveProgram {
|
|
|
6273
6280
|
* @param newCreator - The new creator of the pool
|
|
6274
6281
|
* @returns A transfer pool creator transaction
|
|
6275
6282
|
*/
|
|
6276
|
-
transferPoolCreator(params:
|
|
6283
|
+
transferPoolCreator(params: TransferPoolCreatorParams): Promise<Transaction>;
|
|
6277
6284
|
/**
|
|
6278
6285
|
* Creator withdraw migration fee
|
|
6279
6286
|
* @param virtualPool - The virtual pool address
|
|
6280
6287
|
* @param sender - The sender of the pool
|
|
6281
6288
|
* @returns A creator withdraw migration fee transaction
|
|
6282
6289
|
*/
|
|
6283
|
-
creatorWithdrawMigrationFee(params:
|
|
6290
|
+
creatorWithdrawMigrationFee(params: WithdrawMigrationFeeParams): Promise<Transaction>;
|
|
6284
6291
|
}
|
|
6285
6292
|
|
|
6286
6293
|
declare class StateService extends DynamicBondingCurveProgram {
|
|
@@ -6464,17 +6471,16 @@ declare const MAX_SQRT_PRICE: BN$1;
|
|
|
6464
6471
|
declare const RESOLUTION = 64;
|
|
6465
6472
|
declare const ONE_Q64: BN$1;
|
|
6466
6473
|
declare const FEE_DENOMINATOR = 1000000000;
|
|
6467
|
-
declare const MIN_FEE_BPS =
|
|
6474
|
+
declare const MIN_FEE_BPS = 25;
|
|
6468
6475
|
declare const MAX_FEE_BPS = 9900;
|
|
6469
|
-
declare const MIN_FEE_NUMERATOR =
|
|
6476
|
+
declare const MIN_FEE_NUMERATOR = 2500000;
|
|
6470
6477
|
declare const MAX_FEE_NUMERATOR = 990000000;
|
|
6471
6478
|
declare const BASIS_POINT_MAX = 10000;
|
|
6472
6479
|
declare const MAX_CURVE_POINT = 16;
|
|
6473
6480
|
declare const PARTNER_SURPLUS_SHARE = 80;
|
|
6474
6481
|
declare const SWAP_BUFFER_PERCENTAGE = 25;
|
|
6475
|
-
declare const MAX_MIGRATION_FEE_PERCENTAGE =
|
|
6482
|
+
declare const MAX_MIGRATION_FEE_PERCENTAGE = 99;
|
|
6476
6483
|
declare const MAX_CREATOR_MIGRATION_FEE_PERCENTAGE = 100;
|
|
6477
|
-
declare const MAX_SWALLOW_PERCENTAGE = 20;
|
|
6478
6484
|
declare const MAX_RATE_LIMITER_DURATION_IN_SECONDS = 43200;
|
|
6479
6485
|
declare const MAX_RATE_LIMITER_DURATION_IN_SLOTS = 108000;
|
|
6480
6486
|
declare const SLOT_DURATION = 400;
|
|
@@ -7191,7 +7197,7 @@ declare function validateMigratedPoolFee(migratedPoolFee: MigratedPoolFee, migra
|
|
|
7191
7197
|
* Validate the config parameters
|
|
7192
7198
|
* @param configParam - The config parameters
|
|
7193
7199
|
*/
|
|
7194
|
-
declare function validateConfigParameters(configParam: Omit<
|
|
7200
|
+
declare function validateConfigParameters(configParam: Omit<CreateConfigParams, 'config' | 'feeClaimer' | 'quoteMint' | 'payer'>): void;
|
|
7195
7201
|
/**
|
|
7196
7202
|
* Validate that the base token type matches the pool config token type
|
|
7197
7203
|
* @param baseTokenType - The base token type from create pool parameters
|
|
@@ -7215,31 +7221,35 @@ declare function validateBalance(connection: Connection, owner: PublicKey, input
|
|
|
7215
7221
|
* @returns true if the amount is valid, throws error if invalid
|
|
7216
7222
|
*/
|
|
7217
7223
|
declare function validateSwapAmount(amountIn: BN$1): boolean;
|
|
7224
|
+
declare function validateMigrationFee(migrationFee: {
|
|
7225
|
+
feePercentage: number;
|
|
7226
|
+
creatorFeePercentage: number;
|
|
7227
|
+
}): boolean;
|
|
7218
7228
|
|
|
7219
7229
|
/**
|
|
7220
7230
|
* Build a custom constant product curve
|
|
7221
7231
|
* @param buildCurveParam - The parameters for the custom constant product curve
|
|
7222
7232
|
* @returns The build custom constant product curve
|
|
7223
7233
|
*/
|
|
7224
|
-
declare function buildCurve(buildCurveParam:
|
|
7234
|
+
declare function buildCurve(buildCurveParam: BuildCurveParams): ConfigParameters;
|
|
7225
7235
|
/**
|
|
7226
7236
|
* Build a custom constant product curve by market cap
|
|
7227
7237
|
* @param buildCurveByMarketCapParam - The parameters for the custom constant product curve by market cap
|
|
7228
7238
|
* @returns The build custom constant product curve by market cap
|
|
7229
7239
|
*/
|
|
7230
|
-
declare function buildCurveWithMarketCap(buildCurveWithMarketCapParam:
|
|
7240
|
+
declare function buildCurveWithMarketCap(buildCurveWithMarketCapParam: BuildCurveWithMarketCapParams): ConfigParameters;
|
|
7231
7241
|
/**
|
|
7232
7242
|
* Build a custom constant product curve by market cap
|
|
7233
7243
|
* @param buildCurveWithTwoSegmentsParam - The parameters for the custom constant product curve by market cap
|
|
7234
7244
|
* @returns The build custom constant product curve by market cap
|
|
7235
7245
|
*/
|
|
7236
|
-
declare function buildCurveWithTwoSegments(buildCurveWithTwoSegmentsParam:
|
|
7246
|
+
declare function buildCurveWithTwoSegments(buildCurveWithTwoSegmentsParam: BuildCurveWithTwoSegmentsParams): ConfigParameters;
|
|
7237
7247
|
/**
|
|
7238
7248
|
* Build a custom curve graph with liquidity weights, changing the curve shape based on the liquidity weights
|
|
7239
7249
|
* @param buildCurveWithLiquidityWeightsParam - The parameters for the custom constant product curve with liquidity weights
|
|
7240
7250
|
* @returns The build custom constant product curve with liquidity weights
|
|
7241
7251
|
*/
|
|
7242
|
-
declare function buildCurveWithLiquidityWeights(buildCurveWithLiquidityWeightsParam:
|
|
7252
|
+
declare function buildCurveWithLiquidityWeights(buildCurveWithLiquidityWeightsParam: BuildCurveWithLiquidityWeightsParams): ConfigParameters;
|
|
7243
7253
|
|
|
7244
7254
|
/**
|
|
7245
7255
|
* Program IDL in camelCase format in order to be used in JS/TS.
|
|
@@ -14642,12 +14652,6 @@ declare function getNextSqrtPriceFromQuoteAmountInRoundingDown(sqrtPrice: BN$1,
|
|
|
14642
14652
|
* @throws Error if calculation fails due to overflow or type conversion
|
|
14643
14653
|
*/
|
|
14644
14654
|
declare function toNumerator(bps: BN$1, feeDenominator: BN$1): BN$1;
|
|
14645
|
-
/**
|
|
14646
|
-
* Get maximum swallow quote amount
|
|
14647
|
-
* @param config Pool config state
|
|
14648
|
-
* @returns Maximum swallow quote amount
|
|
14649
|
-
*/
|
|
14650
|
-
declare function getMaxSwallowQuoteAmount(config: PoolConfig): BN$1;
|
|
14651
14655
|
/**
|
|
14652
14656
|
* Get fee mode
|
|
14653
14657
|
* @param collectFeeMode Collect fee mode
|
|
@@ -14993,6 +14997,7 @@ declare function isDynamicFeeEnabled(dynamicFee: DynamicFeeConfig): boolean;
|
|
|
14993
14997
|
* Get variable fee numerator from dynamic fee
|
|
14994
14998
|
* @param dynamicFee Dynamic fee parameters
|
|
14995
14999
|
* @param volatilityTracker Volatility tracker
|
|
15000
|
+
* formula: dynamic_fee_numerator = ((volatility_accumulator * bin_step)^2 * variable_fee_control + 99_999_999_999) / 100_000_000_000
|
|
14996
15001
|
* @returns Variable fee numerator
|
|
14997
15002
|
*/
|
|
14998
15003
|
declare function getVariableFeeNumerator(dynamicFee: DynamicFeeConfig, volatilityTracker: VolatilityTracker): BN$1;
|
|
@@ -15134,7 +15139,7 @@ declare function getFeeNumeratorFromIncludedAmount(cliffFeeNumerator: BN$1, refe
|
|
|
15134
15139
|
var address = "dbcij3LWUppWqq96dh6gJWwBifmcGfLSB5D4DuSMaqN";
|
|
15135
15140
|
var metadata = {
|
|
15136
15141
|
name: "dynamic_bonding_curve",
|
|
15137
|
-
version: "0.1.
|
|
15142
|
+
version: "0.1.7",
|
|
15138
15143
|
spec: "0.1.0",
|
|
15139
15144
|
description: "Created with Anchor"
|
|
15140
15145
|
};
|
|
@@ -15272,6 +15277,84 @@ var instructions = [
|
|
|
15272
15277
|
}
|
|
15273
15278
|
]
|
|
15274
15279
|
},
|
|
15280
|
+
{
|
|
15281
|
+
name: "claim_pool_creation_fee",
|
|
15282
|
+
discriminator: [
|
|
15283
|
+
246,
|
|
15284
|
+
51,
|
|
15285
|
+
18,
|
|
15286
|
+
222,
|
|
15287
|
+
80,
|
|
15288
|
+
42,
|
|
15289
|
+
236,
|
|
15290
|
+
205
|
|
15291
|
+
],
|
|
15292
|
+
accounts: [
|
|
15293
|
+
{
|
|
15294
|
+
name: "pool",
|
|
15295
|
+
writable: true
|
|
15296
|
+
},
|
|
15297
|
+
{
|
|
15298
|
+
name: "claim_fee_operator",
|
|
15299
|
+
docs: [
|
|
15300
|
+
"Claim fee operator"
|
|
15301
|
+
]
|
|
15302
|
+
},
|
|
15303
|
+
{
|
|
15304
|
+
name: "operator",
|
|
15305
|
+
docs: [
|
|
15306
|
+
"Operator"
|
|
15307
|
+
],
|
|
15308
|
+
signer: true,
|
|
15309
|
+
relations: [
|
|
15310
|
+
"claim_fee_operator"
|
|
15311
|
+
]
|
|
15312
|
+
},
|
|
15313
|
+
{
|
|
15314
|
+
name: "treasury",
|
|
15315
|
+
writable: true,
|
|
15316
|
+
address: "4EWqcx3aNZmMetCnxwLYwyNjan6XLGp3Ca2W316vrSjv"
|
|
15317
|
+
},
|
|
15318
|
+
{
|
|
15319
|
+
name: "system_program",
|
|
15320
|
+
address: "11111111111111111111111111111111"
|
|
15321
|
+
},
|
|
15322
|
+
{
|
|
15323
|
+
name: "event_authority",
|
|
15324
|
+
pda: {
|
|
15325
|
+
seeds: [
|
|
15326
|
+
{
|
|
15327
|
+
kind: "const",
|
|
15328
|
+
value: [
|
|
15329
|
+
95,
|
|
15330
|
+
95,
|
|
15331
|
+
101,
|
|
15332
|
+
118,
|
|
15333
|
+
101,
|
|
15334
|
+
110,
|
|
15335
|
+
116,
|
|
15336
|
+
95,
|
|
15337
|
+
97,
|
|
15338
|
+
117,
|
|
15339
|
+
116,
|
|
15340
|
+
104,
|
|
15341
|
+
111,
|
|
15342
|
+
114,
|
|
15343
|
+
105,
|
|
15344
|
+
116,
|
|
15345
|
+
121
|
|
15346
|
+
]
|
|
15347
|
+
}
|
|
15348
|
+
]
|
|
15349
|
+
}
|
|
15350
|
+
},
|
|
15351
|
+
{
|
|
15352
|
+
name: "program"
|
|
15353
|
+
}
|
|
15354
|
+
],
|
|
15355
|
+
args: [
|
|
15356
|
+
]
|
|
15357
|
+
},
|
|
15275
15358
|
{
|
|
15276
15359
|
name: "claim_protocol_fee",
|
|
15277
15360
|
discriminator: [
|
|
@@ -16088,7 +16171,7 @@ var instructions = [
|
|
|
16088
16171
|
{
|
|
16089
16172
|
name: "create_partner_metadata",
|
|
16090
16173
|
docs: [
|
|
16091
|
-
"PARTNER FUNCTIONS
|
|
16174
|
+
"PARTNER FUNCTIONS ///"
|
|
16092
16175
|
],
|
|
16093
16176
|
discriminator: [
|
|
16094
16177
|
192,
|
|
@@ -17399,16 +17482,10 @@ var instructions = [
|
|
|
17399
17482
|
docs: [
|
|
17400
17483
|
"virtual pool"
|
|
17401
17484
|
],
|
|
17402
|
-
writable: true
|
|
17403
|
-
relations: [
|
|
17404
|
-
"migration_metadata"
|
|
17405
|
-
]
|
|
17485
|
+
writable: true
|
|
17406
17486
|
},
|
|
17407
17487
|
{
|
|
17408
|
-
name: "migration_metadata"
|
|
17409
|
-
docs: [
|
|
17410
|
-
"migration metadata"
|
|
17411
|
-
]
|
|
17488
|
+
name: "migration_metadata"
|
|
17412
17489
|
},
|
|
17413
17490
|
{
|
|
17414
17491
|
name: "config",
|
|
@@ -17537,43 +17614,16 @@ var instructions = [
|
|
|
17537
17614
|
name: "virtual_pool"
|
|
17538
17615
|
},
|
|
17539
17616
|
{
|
|
17540
|
-
name: "config"
|
|
17541
|
-
relations: [
|
|
17542
|
-
"virtual_pool"
|
|
17543
|
-
]
|
|
17617
|
+
name: "config"
|
|
17544
17618
|
},
|
|
17545
17619
|
{
|
|
17546
|
-
name: "migration_metadata"
|
|
17547
|
-
writable: true,
|
|
17548
|
-
pda: {
|
|
17549
|
-
seeds: [
|
|
17550
|
-
{
|
|
17551
|
-
kind: "const",
|
|
17552
|
-
value: [
|
|
17553
|
-
100,
|
|
17554
|
-
97,
|
|
17555
|
-
109,
|
|
17556
|
-
109,
|
|
17557
|
-
95,
|
|
17558
|
-
118,
|
|
17559
|
-
50
|
|
17560
|
-
]
|
|
17561
|
-
},
|
|
17562
|
-
{
|
|
17563
|
-
kind: "account",
|
|
17564
|
-
path: "virtual_pool"
|
|
17565
|
-
}
|
|
17566
|
-
]
|
|
17567
|
-
}
|
|
17620
|
+
name: "migration_metadata"
|
|
17568
17621
|
},
|
|
17569
17622
|
{
|
|
17570
|
-
name: "payer"
|
|
17571
|
-
writable: true,
|
|
17572
|
-
signer: true
|
|
17623
|
+
name: "payer"
|
|
17573
17624
|
},
|
|
17574
17625
|
{
|
|
17575
|
-
name: "system_program"
|
|
17576
|
-
address: "11111111111111111111111111111111"
|
|
17626
|
+
name: "system_program"
|
|
17577
17627
|
},
|
|
17578
17628
|
{
|
|
17579
17629
|
name: "event_authority",
|
|
@@ -18360,6 +18410,37 @@ var instructions = [
|
|
|
18360
18410
|
args: [
|
|
18361
18411
|
]
|
|
18362
18412
|
},
|
|
18413
|
+
{
|
|
18414
|
+
name: "withdraw_lamports_from_pool_authority",
|
|
18415
|
+
discriminator: [
|
|
18416
|
+
20,
|
|
18417
|
+
185,
|
|
18418
|
+
242,
|
|
18419
|
+
240,
|
|
18420
|
+
129,
|
|
18421
|
+
24,
|
|
18422
|
+
212,
|
|
18423
|
+
194
|
|
18424
|
+
],
|
|
18425
|
+
accounts: [
|
|
18426
|
+
{
|
|
18427
|
+
name: "pool_authority",
|
|
18428
|
+
writable: true,
|
|
18429
|
+
address: "FhVo3mqL8PW5pH5U2CN4XE33DokiyZnUwuGpH2hmHLuM"
|
|
18430
|
+
},
|
|
18431
|
+
{
|
|
18432
|
+
name: "receiver",
|
|
18433
|
+
writable: true,
|
|
18434
|
+
address: "4EWqcx3aNZmMetCnxwLYwyNjan6XLGp3Ca2W316vrSjv"
|
|
18435
|
+
},
|
|
18436
|
+
{
|
|
18437
|
+
name: "system_program",
|
|
18438
|
+
address: "11111111111111111111111111111111"
|
|
18439
|
+
}
|
|
18440
|
+
],
|
|
18441
|
+
args: [
|
|
18442
|
+
]
|
|
18443
|
+
},
|
|
18363
18444
|
{
|
|
18364
18445
|
name: "withdraw_leftover",
|
|
18365
18446
|
discriminator: [
|
|
@@ -18674,19 +18755,6 @@ var accounts = [
|
|
|
18674
18755
|
156
|
|
18675
18756
|
]
|
|
18676
18757
|
},
|
|
18677
|
-
{
|
|
18678
|
-
name: "MeteoraDammV2Metadata",
|
|
18679
|
-
discriminator: [
|
|
18680
|
-
104,
|
|
18681
|
-
221,
|
|
18682
|
-
219,
|
|
18683
|
-
203,
|
|
18684
|
-
10,
|
|
18685
|
-
142,
|
|
18686
|
-
250,
|
|
18687
|
-
163
|
|
18688
|
-
]
|
|
18689
|
-
},
|
|
18690
18758
|
{
|
|
18691
18759
|
name: "PartnerMetadata",
|
|
18692
18760
|
discriminator: [
|
|
@@ -18754,6 +18822,19 @@ var events = [
|
|
|
18754
18822
|
138
|
|
18755
18823
|
]
|
|
18756
18824
|
},
|
|
18825
|
+
{
|
|
18826
|
+
name: "EvtClaimPoolCreationFee",
|
|
18827
|
+
discriminator: [
|
|
18828
|
+
149,
|
|
18829
|
+
111,
|
|
18830
|
+
149,
|
|
18831
|
+
44,
|
|
18832
|
+
136,
|
|
18833
|
+
64,
|
|
18834
|
+
175,
|
|
18835
|
+
62
|
|
18836
|
+
]
|
|
18837
|
+
},
|
|
18757
18838
|
{
|
|
18758
18839
|
name: "EvtClaimProtocolFee",
|
|
18759
18840
|
discriminator: [
|
|
@@ -18832,19 +18913,6 @@ var events = [
|
|
|
18832
18913
|
144
|
|
18833
18914
|
]
|
|
18834
18915
|
},
|
|
18835
|
-
{
|
|
18836
|
-
name: "EvtCreateDammV2MigrationMetadata",
|
|
18837
|
-
discriminator: [
|
|
18838
|
-
103,
|
|
18839
|
-
111,
|
|
18840
|
-
132,
|
|
18841
|
-
168,
|
|
18842
|
-
140,
|
|
18843
|
-
253,
|
|
18844
|
-
150,
|
|
18845
|
-
114
|
|
18846
|
-
]
|
|
18847
|
-
},
|
|
18848
18916
|
{
|
|
18849
18917
|
name: "EvtCreateMeteoraMigrationMetadata",
|
|
18850
18918
|
discriminator: [
|
|
@@ -19273,6 +19341,16 @@ var errors = [
|
|
|
19273
19341
|
code: 6048,
|
|
19274
19342
|
name: "NextSqrtPriceIsSmallerThanStartSqrtPrice",
|
|
19275
19343
|
msg: "Next sqrt price is smaller than start sqrt price"
|
|
19344
|
+
},
|
|
19345
|
+
{
|
|
19346
|
+
code: 6049,
|
|
19347
|
+
name: "InvalidMinBaseFee",
|
|
19348
|
+
msg: "Invalid min base fee"
|
|
19349
|
+
},
|
|
19350
|
+
{
|
|
19351
|
+
code: 6050,
|
|
19352
|
+
name: "AccountInvariantViolation",
|
|
19353
|
+
msg: "Account invariant violation"
|
|
19276
19354
|
}
|
|
19277
19355
|
];
|
|
19278
19356
|
var types = [
|
|
@@ -19728,6 +19806,26 @@ var types = [
|
|
|
19728
19806
|
]
|
|
19729
19807
|
}
|
|
19730
19808
|
},
|
|
19809
|
+
{
|
|
19810
|
+
name: "EvtClaimPoolCreationFee",
|
|
19811
|
+
type: {
|
|
19812
|
+
kind: "struct",
|
|
19813
|
+
fields: [
|
|
19814
|
+
{
|
|
19815
|
+
name: "pool",
|
|
19816
|
+
type: "pubkey"
|
|
19817
|
+
},
|
|
19818
|
+
{
|
|
19819
|
+
name: "treasury",
|
|
19820
|
+
type: "pubkey"
|
|
19821
|
+
},
|
|
19822
|
+
{
|
|
19823
|
+
name: "creation_fee",
|
|
19824
|
+
type: "u64"
|
|
19825
|
+
}
|
|
19826
|
+
]
|
|
19827
|
+
}
|
|
19828
|
+
},
|
|
19731
19829
|
{
|
|
19732
19830
|
name: "EvtClaimProtocolFee",
|
|
19733
19831
|
type: {
|
|
@@ -19955,18 +20053,6 @@ var types = [
|
|
|
19955
20053
|
]
|
|
19956
20054
|
}
|
|
19957
20055
|
},
|
|
19958
|
-
{
|
|
19959
|
-
name: "EvtCreateDammV2MigrationMetadata",
|
|
19960
|
-
type: {
|
|
19961
|
-
kind: "struct",
|
|
19962
|
-
fields: [
|
|
19963
|
-
{
|
|
19964
|
-
name: "virtual_pool",
|
|
19965
|
-
type: "pubkey"
|
|
19966
|
-
}
|
|
19967
|
-
]
|
|
19968
|
-
}
|
|
19969
|
-
},
|
|
19970
20056
|
{
|
|
19971
20057
|
name: "EvtCreateMeteoraMigrationMetadata",
|
|
19972
20058
|
type: {
|
|
@@ -20584,56 +20670,6 @@ var types = [
|
|
|
20584
20670
|
]
|
|
20585
20671
|
}
|
|
20586
20672
|
},
|
|
20587
|
-
{
|
|
20588
|
-
name: "MeteoraDammV2Metadata",
|
|
20589
|
-
serialization: "bytemuck",
|
|
20590
|
-
repr: {
|
|
20591
|
-
kind: "c"
|
|
20592
|
-
},
|
|
20593
|
-
type: {
|
|
20594
|
-
kind: "struct",
|
|
20595
|
-
fields: [
|
|
20596
|
-
{
|
|
20597
|
-
name: "virtual_pool",
|
|
20598
|
-
docs: [
|
|
20599
|
-
"pool"
|
|
20600
|
-
],
|
|
20601
|
-
type: "pubkey"
|
|
20602
|
-
},
|
|
20603
|
-
{
|
|
20604
|
-
name: "padding_0",
|
|
20605
|
-
docs: [
|
|
20606
|
-
"!!! BE CAREFUL to use tomestone field, previous is pool creator"
|
|
20607
|
-
],
|
|
20608
|
-
type: {
|
|
20609
|
-
array: [
|
|
20610
|
-
"u8",
|
|
20611
|
-
32
|
|
20612
|
-
]
|
|
20613
|
-
}
|
|
20614
|
-
},
|
|
20615
|
-
{
|
|
20616
|
-
name: "partner",
|
|
20617
|
-
docs: [
|
|
20618
|
-
"partner"
|
|
20619
|
-
],
|
|
20620
|
-
type: "pubkey"
|
|
20621
|
-
},
|
|
20622
|
-
{
|
|
20623
|
-
name: "_padding",
|
|
20624
|
-
docs: [
|
|
20625
|
-
"Reserve"
|
|
20626
|
-
],
|
|
20627
|
-
type: {
|
|
20628
|
-
array: [
|
|
20629
|
-
"u8",
|
|
20630
|
-
126
|
|
20631
|
-
]
|
|
20632
|
-
}
|
|
20633
|
-
}
|
|
20634
|
-
]
|
|
20635
|
-
}
|
|
20636
|
-
},
|
|
20637
20673
|
{
|
|
20638
20674
|
name: "MigratedPoolFee",
|
|
20639
20675
|
type: {
|
|
@@ -21499,6 +21535,19 @@ var types = [
|
|
|
21499
21535
|
],
|
|
21500
21536
|
type: "u64"
|
|
21501
21537
|
},
|
|
21538
|
+
{
|
|
21539
|
+
name: "creation_fee_bits",
|
|
21540
|
+
type: "u8"
|
|
21541
|
+
},
|
|
21542
|
+
{
|
|
21543
|
+
name: "_padding_0",
|
|
21544
|
+
type: {
|
|
21545
|
+
array: [
|
|
21546
|
+
"u8",
|
|
21547
|
+
7
|
|
21548
|
+
]
|
|
21549
|
+
}
|
|
21550
|
+
},
|
|
21502
21551
|
{
|
|
21503
21552
|
name: "_padding_1",
|
|
21504
21553
|
docs: [
|
|
@@ -21507,7 +21556,7 @@ var types = [
|
|
|
21507
21556
|
type: {
|
|
21508
21557
|
array: [
|
|
21509
21558
|
"u64",
|
|
21510
|
-
|
|
21559
|
+
6
|
|
21511
21560
|
]
|
|
21512
21561
|
}
|
|
21513
21562
|
}
|
|
@@ -21613,4 +21662,4 @@ var idl = {
|
|
|
21613
21662
|
types: types
|
|
21614
21663
|
};
|
|
21615
21664
|
|
|
21616
|
-
export { ActivationType, BASE_ADDRESS, BASIS_POINT_MAX, BIN_STEP_BPS_DEFAULT, BIN_STEP_BPS_U128_DEFAULT, type BaseFee, type BaseFeeConfig, type BaseFeeHandler, BaseFeeMode, type BaseFeeParams, type
|
|
21665
|
+
export { ActivationType, BASE_ADDRESS, BASIS_POINT_MAX, BIN_STEP_BPS_DEFAULT, BIN_STEP_BPS_U128_DEFAULT, type BaseFee, type BaseFeeConfig, type BaseFeeHandler, BaseFeeMode, type BaseFeeParams, type BuildCurveBaseParams, type BuildCurveParams, type BuildCurveWithLiquidityWeightsParams, type BuildCurveWithMarketCapParams, type BuildCurveWithTwoSegmentsParams, type ClaimCreatorTradingFee2Params, type ClaimCreatorTradingFeeParams, type ClaimCreatorTradingFeeWithQuoteMintNotSolParams, type ClaimCreatorTradingFeeWithQuoteMintSolParams, type ClaimPartnerTradingFeeWithQuoteMintNotSolParams, type ClaimPartnerTradingFeeWithQuoteMintSolParams, type ClaimTradingFee2Params, type ClaimTradingFeeParams, CollectFeeMode, type ConfigParameters, type CreateConfigAccounts, type CreateConfigAndPoolParams, type CreateConfigAndPoolWithFirstBuyParams, type CreateConfigParams, type CreateDammV1MigrationMetadataParams, type CreateLockerParams, type CreatePartnerMetadataParameters, type CreatePartnerMetadataParams, type CreatePoolParams, type CreatePoolWithFirstBuyParams, type CreatePoolWithPartnerAndCreatorFirstBuyParams, type CreateVirtualPoolMetadataParams, type CreatorFirstBuyParams, CreatorService, type CreatorWithdrawSurplusParams, DAMM_V1_MIGRATION_FEE_ADDRESS, DAMM_V1_PROGRAM_ID, DAMM_V2_MIGRATION_FEE_ADDRESS, DAMM_V2_PROGRAM_ID, DYNAMIC_BONDING_CURVE_PROGRAM_ID, DYNAMIC_FEE_DECAY_PERIOD_DEFAULT, DYNAMIC_FEE_FILTER_PERIOD_DEFAULT, DYNAMIC_FEE_REDUCTION_FACTOR_DEFAULT, DYNAMIC_FEE_ROUNDING_OFFSET, DYNAMIC_FEE_SCALING_FACTOR, type DammLpTokenParams, DammV2DynamicFeeMode, DynamicBondingCurveClient, idl as DynamicBondingCurveIdl, DynamicBondingCurveProgram, type DynamicBondingCurve as DynamicBondingCurveTypes, type DynamicCurveProgram, type DynamicFeeConfig, type DynamicFeeParameters, FEE_DENOMINATOR, type FeeMode, type FeeOnAmountResult, FeeRateLimiter, type FeeResult, FeeScheduler, type FeeSchedulerParams, type FirstBuyParams, type InitializePoolBaseParams, type InitializePoolParameters, LOCKER_PROGRAM_ID, type LiquidityDistributionParameters, type LockEscrow, type LockedVestingParameters, type LockedVestingParams, MAX_CREATOR_MIGRATION_FEE_PERCENTAGE, MAX_CURVE_POINT, MAX_DYNAMIC_FEE_PERCENTAGE, MAX_FEE_BPS, MAX_FEE_NUMERATOR, MAX_MIGRATED_POOL_FEE_BPS, MAX_MIGRATION_FEE_PERCENTAGE, MAX_PRICE_CHANGE_BPS_DEFAULT, MAX_RATE_LIMITER_DURATION_IN_SECONDS, MAX_RATE_LIMITER_DURATION_IN_SLOTS, MAX_SQRT_PRICE, METAPLEX_PROGRAM_ID, MIN_FEE_BPS, MIN_FEE_NUMERATOR, MIN_MIGRATED_POOL_FEE_BPS, MIN_SQRT_PRICE, type MeteoraDammMigrationMetadata, type MigrateToDammV1Params, type MigrateToDammV2Params, type MigrateToDammV2Response, type MigratedPoolFee, MigrationFeeOption, MigrationOption, MigrationService, OFFSET, ONE_Q64, PARTNER_SURPLUS_SHARE, type PartnerFirstBuyParams, type PartnerMetadata, PartnerService, type PartnerWithdrawSurplusParams, type PoolConfig, type PoolFeeParameters, type PoolFees, type PoolFeesConfig, PoolService, type PreCreatePoolParams, type PrepareSwapParams, RESOLUTION, type RateLimiterParams, Rounding, SLOT_DURATION, SWAP_BUFFER_PERCENTAGE, SafeMath, StateService, type Swap2Params, type SwapAmount, SwapMode, type SwapParams, type SwapQuote2Params, type SwapQuote2Result, type SwapQuoteParams, type SwapQuoteResult, type SwapResult, type SwapResult2, TIMESTAMP_DURATION, TokenDecimal, TokenType, TokenUpdateAuthorityOption, TradeDirection, type TransferPoolCreatorParams, U128_MAX, U16_MAX, U64_MAX, VAULT_PROGRAM_ID, type VirtualPool, type VirtualPoolMetadata, type VolatilityTracker, type WithdrawLeftoverParams, type WithdrawMigrationFeeParams, bpsToFeeNumerator, buildCurve, buildCurveWithLiquidityWeights, buildCurveWithMarketCap, buildCurveWithTwoSegments, calculateBaseToQuoteFromAmountIn, calculateBaseToQuoteFromAmountOut, calculateFeeSchedulerEndingBaseFeeBps, calculateQuoteToBaseFromAmountIn, calculateQuoteToBaseFromAmountOut, checkRateLimiterApplied, cleanUpTokenAccountTx, convertDecimalToBN, convertToLamports, createDammV1Program, createDammV2Program, createDbcProgram, createInitializePermissionlessDynamicVaultIx, createLockEscrowIx, createProgramAccountFilter, createVaultProgram, deriveBaseKeyForLocker, deriveDammV1EventAuthority, deriveDammV1LockEscrowAddress, deriveDammV1LpMintAddress, deriveDammV1MigrationMetadataAddress, deriveDammV1PoolAddress, deriveDammV1PoolAuthority, deriveDammV1ProtocolFeeAddress, deriveDammV1VaultLPAddress, deriveDammV2EventAuthority, deriveDammV2LockEscrowAddress, deriveDammV2MigrationMetadataAddress, deriveDammV2PoolAddress, deriveDammV2PoolAuthority, deriveDammV2TokenVaultAddress, deriveDbcEventAuthority, deriveDbcPoolAddress, deriveDbcPoolAuthority, deriveDbcPoolMetadata, deriveDbcTokenVaultAddress, deriveEscrow, deriveLockerEventAuthority, deriveMintMetadata, derivePartnerMetadata, derivePositionAddress, derivePositionNftAccount, deriveTokenVaultKey, deriveVaultAddress, deriveVaultLpMintAddress, deriveVaultPdas, feeNumeratorToBps, findAssociatedTokenAddress, fromDecimalToBN, getAccountCreationTimestamp, getAccountCreationTimestamps, getAccountData, getBaseFeeHandler, getBaseFeeNumerator, getBaseFeeNumeratorByPeriod, getBaseFeeParams, getBaseTokenForSwap, getCheckedAmounts, getCurrentPoint, getDeltaAmountBaseUnsigned, getDeltaAmountBaseUnsigned256, getDeltaAmountBaseUnsignedUnchecked, getDeltaAmountQuoteUnsigned, getDeltaAmountQuoteUnsigned256, getDeltaAmountQuoteUnsignedUnchecked, getDynamicFeeParams, getExcludedFeeAmount, getFeeMode, getFeeNumeratorFromExcludedAmount, getFeeNumeratorFromIncludedAmount, getFeeNumeratorOnExponentialFeeScheduler, getFeeNumeratorOnLinearFeeScheduler, getFeeOnAmount, getFeeSchedulerParams, getFirstCurve, getFirstKey, getIncludedFeeAmount, getInitialLiquidityFromDeltaBase, getInitialLiquidityFromDeltaQuote, getLiquidity, getLockedVestingParams, getMaxBaseFeeNumerator, getMaxIndex, getMaxOutAmountWithMinBaseFee, getMigratedPoolFeeParams, getMigrationBaseToken, getMigrationQuoteAmount, getMigrationQuoteAmountFromMigrationQuoteThreshold, getMigrationQuoteThresholdFromMigrationQuoteAmount, getMigrationThresholdPrice, getMinBaseFeeNumerator, getNextSqrtPriceFromBaseAmountInRoundingUp, getNextSqrtPriceFromBaseAmountOutRoundingUp, getNextSqrtPriceFromInput, getNextSqrtPriceFromOutput, getNextSqrtPriceFromQuoteAmountInRoundingDown, getNextSqrtPriceFromQuoteAmountOutRoundingDown, getOrCreateATAInstruction, getPercentageSupplyOnMigration, getPriceFromSqrtPrice, getQuoteReserveFromNextSqrtPrice, getRateLimiterExcludedFeeAmount, getRateLimiterParams, getSecondKey, getSqrtPriceFromMarketCap, getSqrtPriceFromPrice, getSwapAmountWithBuffer, getSwapResult, getSwapResultFromExactInput, getSwapResultFromExactOutput, getSwapResultFromPartialInput, getTokenDecimals, getTokenProgram, getTokenType, getTokenomics, getTotalFeeNumerator, getTotalFeeNumeratorFromExcludedFeeAmount, getTotalFeeNumeratorFromIncludedFeeAmount, getTotalSupplyFromCurve, getTotalTokenSupply, getTotalVestingAmount, getTwoCurve, getVariableFeeNumerator, isDefaultLockedVesting, isDynamicFeeEnabled, isNativeSol, isNonZeroRateLimiter, isRateLimiterApplied, isZeroRateLimiter, mulDiv, mulShr, pow, prepareSwapAmountParam, prepareTokenAccountTx, splitFees, sqrt, swapQuote, swapQuoteExactIn, swapQuoteExactOut, swapQuotePartialFill, toNumerator, unwrapSOLInstruction, validateActivationType, validateBalance, validateBaseTokenType, validateCollectFeeMode, validateConfigParameters, validateCurve, validateFeeRateLimiter, validateFeeScheduler, validateLPPercentages, validateMigratedPoolFee, validateMigrationAndTokenType, validateMigrationFee, validateMigrationFeeOption, validatePoolFees, validateSwapAmount, validateTokenDecimals, validateTokenSupply, validateTokenUpdateAuthorityOptions, wrapSOLInstruction };
|