clanker-sdk 4.2.7 → 4.2.9

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/cli/cli.js CHANGED
@@ -9,12 +9,12 @@ var __export = (target, all) => {
9
9
  __defProp(target, name, { get: all[name], enumerable: true });
10
10
  };
11
11
 
12
- // node_modules/tsup/assets/esm_shims.js
12
+ // node_modules/.pnpm/tsup@8.4.0_typescript@5.8.3/node_modules/tsup/assets/esm_shims.js
13
13
  import { fileURLToPath } from "url";
14
14
  import path from "path";
15
15
  var getFilename, getDirname, __dirname;
16
16
  var init_esm_shims = __esm({
17
- "node_modules/tsup/assets/esm_shims.js"() {
17
+ "node_modules/.pnpm/tsup@8.4.0_typescript@5.8.3/node_modules/tsup/assets/esm_shims.js"() {
18
18
  "use strict";
19
19
  getFilename = () => fileURLToPath(import.meta.url);
20
20
  getDirname = () => path.dirname(getFilename());
@@ -6748,7 +6748,11 @@ var init_write_clanker_contracts = __esm({
6748
6748
  }
6749
6749
  }
6750
6750
  try {
6751
- const txHash = await writeContract(wallet, tx);
6751
+ const txHash = await writeContract(wallet, {
6752
+ ...tx,
6753
+ dataSuffix: tx.dataSuffix
6754
+ // biome-ignore lint/suspicious/noExplicitAny: It's difficult to type tx correctly with viem's generic constraints
6755
+ });
6752
6756
  return { txHash };
6753
6757
  } catch (e) {
6754
6758
  return { error: understandError(e) };
@@ -6769,7 +6773,7 @@ async function simulateDeployToken(tx, account, publicClient) {
6769
6773
  }
6770
6774
  return simulateClankerContract(publicClient, account, tx);
6771
6775
  }
6772
- async function deployToken(tx, wallet, publicClient) {
6776
+ async function deployToken(tx, wallet, publicClient, options) {
6773
6777
  const account = wallet?.account;
6774
6778
  if (!account) {
6775
6779
  throw new Error("Wallet account required for deployToken");
@@ -6784,14 +6788,18 @@ async function deployToken(tx, wallet, publicClient) {
6784
6788
  `Token chainId doesn't match wallet chainId: ${tx.chainId} != ${wallet.chain?.id}`
6785
6789
  );
6786
6790
  }
6787
- const { gas, error: gasError } = await estimateGasClankerContract(publicClient, account, tx);
6791
+ const { gas, error: gasError } = await estimateGasClankerContract(publicClient, account, {
6792
+ ...tx,
6793
+ dataSuffix: options?.dataSuffix
6794
+ });
6788
6795
  if (gasError) return { error: gasError };
6789
6796
  const { txHash, error: txError } = await writeClankerContract(
6790
6797
  publicClient,
6791
6798
  wallet,
6792
6799
  {
6793
6800
  ...tx,
6794
- gas: gas * 12n / 10n
6801
+ gas: gas * 12n / 10n,
6802
+ dataSuffix: options?.dataSuffix
6795
6803
  },
6796
6804
  {
6797
6805
  simulate: true
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env node
2
2
 
3
- // node_modules/tsup/assets/esm_shims.js
3
+ // node_modules/.pnpm/tsup@8.4.0_typescript@5.8.3/node_modules/tsup/assets/esm_shims.js
4
4
  import { fileURLToPath } from "url";
5
5
  import path from "path";
6
6
  var getFilename = () => fileURLToPath(import.meta.url);
@@ -6599,7 +6599,11 @@ var writeClankerContract = async (client, wallet, tx, options) => {
6599
6599
  }
6600
6600
  }
6601
6601
  try {
6602
- const txHash = await writeContract(wallet, tx);
6602
+ const txHash = await writeContract(wallet, {
6603
+ ...tx,
6604
+ dataSuffix: tx.dataSuffix
6605
+ // biome-ignore lint/suspicious/noExplicitAny: It's difficult to type tx correctly with viem's generic constraints
6606
+ });
6603
6607
  return { txHash };
6604
6608
  } catch (e) {
6605
6609
  return { error: understandError(e) };
@@ -6615,7 +6619,7 @@ async function simulateDeployToken(tx, account, publicClient) {
6615
6619
  }
6616
6620
  return simulateClankerContract(publicClient, account, tx);
6617
6621
  }
6618
- async function deployToken(tx, wallet, publicClient) {
6622
+ async function deployToken(tx, wallet, publicClient, options) {
6619
6623
  const account = wallet?.account;
6620
6624
  if (!account) {
6621
6625
  throw new Error("Wallet account required for deployToken");
@@ -6630,14 +6634,18 @@ async function deployToken(tx, wallet, publicClient) {
6630
6634
  `Token chainId doesn't match wallet chainId: ${tx.chainId} != ${wallet.chain?.id}`
6631
6635
  );
6632
6636
  }
6633
- const { gas, error: gasError } = await estimateGasClankerContract(publicClient, account, tx);
6637
+ const { gas, error: gasError } = await estimateGasClankerContract(publicClient, account, {
6638
+ ...tx,
6639
+ dataSuffix: options?.dataSuffix
6640
+ });
6634
6641
  if (gasError) return { error: gasError };
6635
6642
  const { txHash, error: txError } = await writeClankerContract(
6636
6643
  publicClient,
6637
6644
  wallet,
6638
6645
  {
6639
6646
  ...tx,
6640
- gas: gas * 12n / 10n
6647
+ gas: gas * 12n / 10n,
6648
+ dataSuffix: options?.dataSuffix
6641
6649
  },
6642
6650
  {
6643
6651
  simulate: true
@@ -18134,4 +18134,9 @@ declare function encodeFeeConfig(tokenConfig: z.infer<typeof clankerTokenV4>, cl
18134
18134
  poolData: `0x${string}`;
18135
18135
  };
18136
18136
 
18137
- export { type ClankerTokenV4 as C, type RelatedV3_1 as R, type Type as T, type Chain as a, type ClankerDeployment as b, type RelatedV4 as c, CLANKERS as d, encodeFeeConfig as e, type Clankers as f, Chains as g, ClankerDeployments as h, clankerConfigFor as i };
18137
+ type DeployTokenOptions = {
18138
+ /** Data to append to the end of the transaction calldata (e.g., Base builder codes) */
18139
+ dataSuffix?: `0x${string}`;
18140
+ };
18141
+
18142
+ export { type ClankerTokenV4 as C, type DeployTokenOptions as D, type RelatedV3_1 as R, type Type as T, type Chain as a, type ClankerDeployment as b, type RelatedV4 as c, CLANKERS as d, encodeFeeConfig as e, type Clankers as f, Chains as g, ClankerDeployments as h, clankerConfigFor as i };
package/dist/index.d.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  export { C as ClankerTokenV3 } from './clankerTokenV3-BqHTF9QY.js';
2
- import { a as Chain, C as ClankerTokenV4, b as ClankerDeployment } from './clankerTokenV4-nI7uj0d1.js';
3
- export { d as CLANKERS, g as Chains, h as ClankerDeployments, f as Clankers, R as RelatedV3_1, c as RelatedV4, T as Type, i as clankerConfigFor } from './clankerTokenV4-nI7uj0d1.js';
2
+ import { a as Chain, C as ClankerTokenV4, b as ClankerDeployment } from './deploy-BvFgwMVl.js';
3
+ export { d as CLANKERS, g as Chains, h as ClankerDeployments, f as Clankers, D as DeployTokenOptions, R as RelatedV3_1, c as RelatedV4, T as Type, i as clankerConfigFor } from './deploy-BvFgwMVl.js';
4
4
  import { ContractConstructorArgs, Hex, PublicClient } from 'viem';
5
5
  import { C as ClankerToken_v3_1_abi, a as ClankerToken_v4_abi } from './ClankerToken-Dra5lppJ.js';
6
6
  import { StandardMerkleTree } from '@openzeppelin/merkle-tree';
@@ -1,6 +1,308 @@
1
- import { WalletClient, Transport, Chain, Account, PublicClient } from 'viem';
1
+ import * as viem from 'viem';
2
+ import { Abi, WalletClient, Transport, Chain, Account, PublicClient } from 'viem';
2
3
  import { C as ClankerError } from '../errors-5Gv28Tkr.js';
3
4
 
5
+ /**
6
+ * Clanker factory addresses on Base by version
7
+ */
8
+ declare const LEGACY_FACTORIES: {
9
+ readonly 0: "0x250c9FB2b411B48273f69879007803790A6AeA47";
10
+ readonly 1: "0x9B84fcE5Dcd9a38d2D01d5D72373F6b6b067c3e1";
11
+ readonly 2: "0x732560fa1d1A76350b1A500155BA978031B53833";
12
+ readonly 3: "0x375C15db32D28cEcdcAB5C03Ab889bf15cbD2c5E";
13
+ readonly 3.1: "0x2A787b2362021cC3eEa3C24C4748a6cD5B687382";
14
+ };
15
+ type LegacyVersion = 0 | 1 | 2 | 3 | 3.1;
16
+ type LegacyFeeClaimsConfig$1 = {
17
+ wallet?: WalletClient<Transport, Chain, Account>;
18
+ publicClient?: PublicClient;
19
+ };
20
+ /**
21
+ * Transaction config for legacy fee claiming.
22
+ * Compatible with walletClient.writeContract()
23
+ */
24
+ type LegacyClaimTransactionConfig = {
25
+ address: `0x${string}`;
26
+ abi: Abi;
27
+ functionName: string;
28
+ args: readonly unknown[];
29
+ };
30
+ /**
31
+ * v0/v1 locker params - required for versions 0 and 1
32
+ */
33
+ type LockerParams = {
34
+ /** The locker contract address that holds the LP position */
35
+ locker: `0x${string}`;
36
+ /** The Uniswap V3 position NFT ID */
37
+ positionId: bigint;
38
+ /** The address to receive the fees */
39
+ recipient: `0x${string}`;
40
+ };
41
+ /**
42
+ * Input for claiming legacy creator fees.
43
+ *
44
+ * For v2/v3/v3.1: Only `token` and `version` are required.
45
+ * For v0/v1: Additional `lockerParams` are required.
46
+ */
47
+ type ClaimLegacyCreatorFeesInput = {
48
+ /** The Clanker token address */
49
+ token: `0x${string}`;
50
+ /** Token version */
51
+ version: 2 | 3 | 3.1;
52
+ } | {
53
+ /** The Clanker token address */
54
+ token: `0x${string}`;
55
+ /** Token version */
56
+ version: 0 | 1;
57
+ /** Required for v0/v1: locker info from TokenCreated event */
58
+ lockerParams: LockerParams;
59
+ };
60
+ /**
61
+ * Legacy Creator Fee Claims for Clanker v0–v3.1 on Base.
62
+ *
63
+ * @example
64
+ * ```ts
65
+ * const clanker = new LegacyCreatorFees({ wallet, publicClient });
66
+ *
67
+ * // v2/v3/v3.1 - simple!
68
+ * await clanker.claimLegacyCreatorFees({ token: '0x...', version: 3.1 });
69
+ *
70
+ * // v0/v1 - need locker info
71
+ * await clanker.claimLegacyCreatorFees({
72
+ * token: '0x...',
73
+ * version: 1,
74
+ * lockerParams: { locker: '0x...', positionId: 123n, recipient: '0x...' }
75
+ * });
76
+ * ```
77
+ */
78
+ declare class LegacyCreatorFees {
79
+ readonly wallet?: WalletClient<Transport, Chain, Account>;
80
+ readonly publicClient?: PublicClient;
81
+ constructor(config?: LegacyFeeClaimsConfig$1);
82
+ private assertBase;
83
+ /**
84
+ * Get a transaction config for claiming legacy creator fees.
85
+ *
86
+ * @param input Token address, version, and locker params (for v0/v1)
87
+ * @returns Transaction config
88
+ */
89
+ getClaimLegacyCreatorFeesTransaction(input: ClaimLegacyCreatorFeesInput): LegacyClaimTransactionConfig;
90
+ /**
91
+ * Get a transaction config for claiming via meta-locker (some v0 tokens).
92
+ *
93
+ * @param locker The locker contract address
94
+ * @param positionId The Uniswap V3 position NFT ID
95
+ * @returns Transaction config
96
+ */
97
+ getMetaLockerClaimTransaction(locker: `0x${string}`, positionId: bigint): LegacyClaimTransactionConfig;
98
+ /**
99
+ * Simulate claiming legacy creator fees.
100
+ *
101
+ * @param input Token address, version, and locker params (for v0/v1)
102
+ * @param account Optional account to simulate from
103
+ * @returns Simulation result or error
104
+ */
105
+ claimLegacyCreatorFeesSimulate(input: ClaimLegacyCreatorFeesInput, account?: Account): Promise<viem.SimulateContractReturnType<Abi | readonly unknown[], string, readonly unknown[], Chain | undefined, undefined, undefined, undefined, readonly [never], undefined> | {
106
+ error: ClankerError;
107
+ }>;
108
+ /**
109
+ * Claim legacy creator fees.
110
+ *
111
+ * @param input Token address, version, and locker params (for v0/v1)
112
+ * @returns Transaction hash or error
113
+ */
114
+ claimLegacyCreatorFees(input: ClaimLegacyCreatorFeesInput): Promise<{
115
+ txHash: `0x${string}`;
116
+ error: undefined;
117
+ } | {
118
+ txHash: undefined;
119
+ error: ClankerError;
120
+ }>;
121
+ }
122
+ /**
123
+ * Get a transaction config for claiming legacy creator fees.
124
+ *
125
+ * @param input Token address, version, and locker params (for v0/v1)
126
+ * @returns Transaction config
127
+ *
128
+ * @example
129
+ * ```ts
130
+ * // v3.1 token - simple
131
+ * const tx = getClaimLegacyCreatorFeesTransaction({
132
+ * token: '0x...',
133
+ * version: 3.1
134
+ * });
135
+ *
136
+ * // v1 token - need locker info
137
+ * const tx = getClaimLegacyCreatorFeesTransaction({
138
+ * token: '0x...',
139
+ * version: 1,
140
+ * lockerParams: { locker: '0x...', positionId: 123n, recipient: '0x...' }
141
+ * });
142
+ *
143
+ * await walletClient.writeContract(tx);
144
+ * ```
145
+ */
146
+ declare function getClaimLegacyCreatorFeesTransaction(input: ClaimLegacyCreatorFeesInput): LegacyClaimTransactionConfig;
147
+
148
+ /**
149
+ * Base chain ID
150
+ */
151
+ declare const BASE_CHAIN_ID: 8453;
152
+ /**
153
+ * Uniswap V3 addresses on Base
154
+ */
155
+ declare const UNISWAP_V3_BASE: {
156
+ readonly factory: "0x33128a8fC17869897dcE68Ed026d694621f6FDfD";
157
+ readonly nonfungiblePositionManager: "0x03a520b32C04BF3bEEf7BEb72E919cf822Ed34f1";
158
+ readonly weth: "0x4200000000000000000000000000000000000006";
159
+ };
160
+ /**
161
+ * Clanker factories on Base (v0–v3.1)
162
+ */
163
+ declare const CLANKER_FACTORIES_BASE: {
164
+ readonly clanker_v0: "0x250c9FB2b411B48273f69879007803790A6AeA47";
165
+ readonly clanker_v1: "0x9B84fcE5Dcd9a38d2D01d5D72373F6b6b067c3e1";
166
+ readonly clanker_v2: "0x732560fa1d1A76350b1A500155BA978031B53833";
167
+ readonly clanker_v3: "0x375C15db32D28cEcdcAB5C03Ab889bf15cbD2c5E";
168
+ readonly clanker_v3_presale: "0x71cDc0bDF30F5601fb0ac80Cf1d20B771342C035";
169
+ readonly clanker_v3_1: "0x2A787b2362021cC3eEa3C24C4748a6cD5B687382";
170
+ };
171
+ /**
172
+ * Legacy token type labels for v0–v3.1
173
+ */
174
+ type LegacyTokenType = 'proxy' | 'clanker' | 'clanker_v2' | 'clanker_v3' | 'clanker_v3_1';
175
+ declare const ClankerClaimRewardsAbi: readonly [{
176
+ readonly type: "function";
177
+ readonly name: "claimRewards";
178
+ readonly stateMutability: "nonpayable";
179
+ readonly inputs: readonly [{
180
+ readonly name: "token";
181
+ readonly type: "address";
182
+ }];
183
+ readonly outputs: readonly [];
184
+ }];
185
+ declare const LockerCollectFeesAbi: readonly [{
186
+ readonly type: "function";
187
+ readonly name: "collectFees";
188
+ readonly stateMutability: "nonpayable";
189
+ readonly inputs: readonly [{
190
+ readonly name: "_recipient";
191
+ readonly type: "address";
192
+ }, {
193
+ readonly name: "_tokenId";
194
+ readonly type: "uint256";
195
+ }];
196
+ readonly outputs: readonly [];
197
+ }];
198
+ declare const MetaLockerCollectFeesAbi: readonly [{
199
+ readonly type: "function";
200
+ readonly name: "collectFees";
201
+ readonly stateMutability: "nonpayable";
202
+ readonly inputs: readonly [{
203
+ readonly name: "_tokenId";
204
+ readonly type: "uint256";
205
+ }];
206
+ readonly outputs: readonly [];
207
+ }];
208
+ declare const ClankerTokenDeployerAbi: readonly [{
209
+ readonly type: "function";
210
+ readonly name: "deployer";
211
+ readonly stateMutability: "view";
212
+ readonly inputs: readonly [];
213
+ readonly outputs: readonly [{
214
+ readonly name: "";
215
+ readonly type: "address";
216
+ }];
217
+ }];
218
+ declare const NonfungiblePositionManagerOwnerOfAbi: readonly [{
219
+ readonly type: "function";
220
+ readonly name: "ownerOf";
221
+ readonly stateMutability: "view";
222
+ readonly inputs: readonly [{
223
+ readonly name: "tokenId";
224
+ readonly type: "uint256";
225
+ }];
226
+ readonly outputs: readonly [{
227
+ readonly name: "";
228
+ readonly type: "address";
229
+ }];
230
+ }];
231
+ declare const NonfungiblePositionManagerPositionsAbi: readonly [{
232
+ readonly type: "function";
233
+ readonly name: "positions";
234
+ readonly stateMutability: "view";
235
+ readonly inputs: readonly [{
236
+ readonly name: "tokenId";
237
+ readonly type: "uint256";
238
+ }];
239
+ readonly outputs: readonly [{
240
+ readonly name: "nonce";
241
+ readonly type: "uint96";
242
+ }, {
243
+ readonly name: "operator";
244
+ readonly type: "address";
245
+ }, {
246
+ readonly name: "token0";
247
+ readonly type: "address";
248
+ }, {
249
+ readonly name: "token1";
250
+ readonly type: "address";
251
+ }, {
252
+ readonly name: "fee";
253
+ readonly type: "uint24";
254
+ }, {
255
+ readonly name: "tickLower";
256
+ readonly type: "int24";
257
+ }, {
258
+ readonly name: "tickUpper";
259
+ readonly type: "int24";
260
+ }, {
261
+ readonly name: "liquidity";
262
+ readonly type: "uint128";
263
+ }, {
264
+ readonly name: "feeGrowthInside0LastX128";
265
+ readonly type: "uint256";
266
+ }, {
267
+ readonly name: "feeGrowthInside1LastX128";
268
+ readonly type: "uint256";
269
+ }, {
270
+ readonly name: "tokensOwed0";
271
+ readonly type: "uint128";
272
+ }, {
273
+ readonly name: "tokensOwed1";
274
+ readonly type: "uint128";
275
+ }];
276
+ }];
277
+ declare const NonfungiblePositionManagerCollectAbi: readonly [{
278
+ readonly type: "function";
279
+ readonly name: "collect";
280
+ readonly stateMutability: "payable";
281
+ readonly inputs: readonly [{
282
+ readonly name: "params";
283
+ readonly type: "tuple";
284
+ readonly components: readonly [{
285
+ readonly name: "tokenId";
286
+ readonly type: "uint256";
287
+ }, {
288
+ readonly name: "recipient";
289
+ readonly type: "address";
290
+ }, {
291
+ readonly name: "amount0Max";
292
+ readonly type: "uint128";
293
+ }, {
294
+ readonly name: "amount1Max";
295
+ readonly type: "uint128";
296
+ }];
297
+ }];
298
+ readonly outputs: readonly [{
299
+ readonly name: "amount0";
300
+ readonly type: "uint256";
301
+ }, {
302
+ readonly name: "amount1";
303
+ readonly type: "uint256";
304
+ }];
305
+ }];
4
306
  /**
5
307
  * Contract address for ClankerSafeErc20Spender on Base network
6
308
  */
@@ -9,6 +311,54 @@ type LegacyFeeClaimsConfig = {
9
311
  wallet?: WalletClient<Transport, Chain, Account>;
10
312
  publicClient?: PublicClient;
11
313
  };
314
+ /**
315
+ * Input arguments for building a legacy fee claim transaction
316
+ */
317
+ type LegacyClaimArgs = {
318
+ /** Must be 8453 (Base) */
319
+ chainId: number;
320
+ /** The Clanker token contract address */
321
+ token: `0x${string}`;
322
+ /** Token type label (proxy, clanker, clanker_v2, clanker_v3, clanker_v3_1) */
323
+ tokenType?: LegacyTokenType;
324
+ /** Factory address (required for v2–v3.1 factory claim) */
325
+ factory?: `0x${string}`;
326
+ /** Locker address (required for v0–v1 locker claim) */
327
+ locker?: `0x${string}`;
328
+ /** Uniswap V3 position NFT ID (required for v0–v1 claim and claimable estimation) */
329
+ positionId?: bigint;
330
+ /** Recipient address (required for Locker.collectFees) */
331
+ recipient?: `0x${string}`;
332
+ /** Wallet address for v1 deployer gating and optional simulate account */
333
+ walletAddress?: `0x${string}`;
334
+ };
335
+ /** @deprecated Use LegacyClaimArgs instead */
336
+ type LegacyClaimFeesInput = LegacyClaimArgs;
337
+ /**
338
+ * Transaction kind for legacy fee claims
339
+ */
340
+ type LegacyClaimTxKind = 'factory.claimRewards' | 'locker.collectFees' | 'metaLocker.collectFees';
341
+ /**
342
+ * Transaction output for legacy fee claims
343
+ */
344
+ type LegacyClaimTx = {
345
+ kind: LegacyClaimTxKind;
346
+ to: `0x${string}`;
347
+ data: `0x${string}`;
348
+ value?: bigint;
349
+ };
350
+ /** @deprecated Use LegacyClaimTx instead */
351
+ type LegacyClaimFeesTransaction = LegacyClaimTx;
352
+ /**
353
+ * Result of estimating claimable fees
354
+ */
355
+ type LegacyClaimableFees = {
356
+ positionOwner: `0x${string}`;
357
+ token0: `0x${string}`;
358
+ token1: `0x${string}`;
359
+ amount0: bigint;
360
+ amount1: bigint;
361
+ };
12
362
  /**
13
363
  * SDK for claiming legacy fees from Clanker v0-v3.1 tokens.
14
364
  *
@@ -24,6 +374,24 @@ declare class LegacyFeeClaims {
24
374
  readonly wallet?: WalletClient<Transport, Chain, Account>;
25
375
  readonly publicClient?: PublicClient;
26
376
  constructor(config?: LegacyFeeClaimsConfig);
377
+ private assertBaseChain;
378
+ /**
379
+ * Build a Base-only transaction for claiming legacy fees (v0-v3.1).
380
+ *
381
+ * @param args Claim arguments
382
+ * @returns Transaction object with { kind, to, data, value? }
383
+ */
384
+ getClaimLegacyFeesTransaction(args: LegacyClaimArgs): Promise<LegacyClaimTx>;
385
+ /**
386
+ * Estimate claimable Uniswap v3 LP fees for a legacy position on Base.
387
+ *
388
+ * @param opts Options with chainId and positionId
389
+ * @returns Claimable fees with position owner, token0, token1, amount0, amount1
390
+ */
391
+ getLegacyClaimableFees(opts: {
392
+ chainId: number;
393
+ positionId: bigint;
394
+ }): Promise<LegacyClaimableFees>;
27
395
  /**
28
396
  * Get an abi-typed transaction for initializing token creator ownership.
29
397
  *
@@ -2682,5 +3050,29 @@ declare function getTokenCreatorTransferTransaction({ safe, token, recipient, }:
2682
3050
  functionName: "tokenCreatorTransfer";
2683
3051
  args: readonly [`0x${string}`, `0x${string}`, `0x${string}`];
2684
3052
  };
3053
+ /**
3054
+ * Build a claim transaction for legacy Clanker v0–v3.1 fees on Base.
3055
+ *
3056
+ * - v2/v3/v3.1: call factory.claimRewards(token)
3057
+ * - v0/v1: call locker.collectFees(recipient, tokenId) or metaLocker.collectFees(tokenId)
3058
+ *
3059
+ * @param publicClient Viem public client for Base
3060
+ * @param args Claim arguments
3061
+ * @returns Transaction object with { kind, to, data, value? }
3062
+ */
3063
+ declare function getClaimLegacyFeesTransaction(publicClient: PublicClient, args: LegacyClaimArgs): Promise<LegacyClaimTx>;
3064
+ /**
3065
+ * Estimate claimable Uniswap V3 LP fees for a legacy position on Base.
3066
+ *
3067
+ * Reads ownerOf(positionId) and simulates collect() to get the claimable amounts.
3068
+ *
3069
+ * @param publicClient Viem public client for Base
3070
+ * @param opts Options with chainId and positionId
3071
+ * @returns Claimable fees with positionOwner, token0, token1, amount0, amount1
3072
+ */
3073
+ declare function getLegacyClaimableFees(publicClient: PublicClient, opts: {
3074
+ chainId: number;
3075
+ positionId: bigint;
3076
+ }): Promise<LegacyClaimableFees>;
2685
3077
 
2686
- export { EXPECTED_MERKLE_ROOT, LEGACY_FEE_CLAIMS_ADDRESS, LegacyFeeClaims, type MerkleProofResult, type TokenCreatorEntry, getInitializeTokenCreatorTransaction, getTokenCreatorMerkleProof, getTokenCreatorTransferTransaction, getUpdateTokenCreatorTransaction, parseTokenCreatorCSV };
3078
+ export { BASE_CHAIN_ID, CLANKER_FACTORIES_BASE, type ClaimLegacyCreatorFeesInput, ClankerClaimRewardsAbi, ClankerTokenDeployerAbi, EXPECTED_MERKLE_ROOT, LEGACY_FACTORIES, LEGACY_FEE_CLAIMS_ADDRESS, type LegacyClaimArgs, type LegacyClaimFeesInput, type LegacyClaimFeesTransaction, type LegacyClaimTransactionConfig, type LegacyClaimTx, type LegacyClaimTxKind, type LegacyClaimableFees, LegacyCreatorFees, LegacyFeeClaims, type LegacyTokenType, type LegacyVersion, LockerCollectFeesAbi, type LockerParams, type MerkleProofResult, MetaLockerCollectFeesAbi, NonfungiblePositionManagerCollectAbi, NonfungiblePositionManagerOwnerOfAbi, NonfungiblePositionManagerPositionsAbi, type TokenCreatorEntry, UNISWAP_V3_BASE, getClaimLegacyCreatorFeesTransaction, getClaimLegacyFeesTransaction, getInitializeTokenCreatorTransaction, getLegacyClaimableFees, getTokenCreatorMerkleProof, getTokenCreatorTransferTransaction, getUpdateTokenCreatorTransaction, parseTokenCreatorCSV };