@gabox-labs/sdk 0.6.0 → 0.7.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.
@@ -1,4 +1,42 @@
1
1
  import { AccountMeta, Address, AddressesByLookupTableAddress, Instruction, Rpc, RpcSubscriptions, SolanaRpcApi, SolanaRpcSubscriptionsApi, TransactionMessage, TransactionMessageWithBlockhashLifetime, TransactionMessageWithFeePayerSigner, TransactionSigner } from "@solana/kit";
2
+ //#region src/route/types.d.ts
3
+ /** Which of the two swap modes produced a route. */
4
+ type RouteMode = 'exactOut' | 'exactIn';
5
+ /** One priced swap, ready to put in a transaction message. */
6
+ type Route = {
7
+ /** The swap's own instructions, in order. No compute budget instruction is included. */
8
+ instructions: Instruction[];
9
+ /** The lookup tables the instructions above were compressed against. */
10
+ lookupTables: AddressesByLookupTableAddress;
11
+ /** The input amount. Exact for an exact-in route, a maximum for an exact-out one. */
12
+ inAmount: bigint;
13
+ /** The output amount. Exact for an exact-out route, a minimum for an exact-in one. */
14
+ outAmount: bigint;
15
+ mode: RouteMode;
16
+ /**
17
+ * The compute units this route needs, on top of what the Gabox instruction uses.
18
+ *
19
+ * The swap shares one transaction with the Gabox instruction, so it shares the budget too. Each
20
+ * provider states its own figure: Jupiter returns one with the route, and the CPMM provider uses
21
+ * a measured number, because it is always one pool. A builder adds this to its own limit and caps
22
+ * the total at the runtime's ceiling.
23
+ */
24
+ computeUnits: number;
25
+ };
26
+ /**
27
+ * Something that can price and build a swap between two mints for one wallet.
28
+ *
29
+ * `client` comes first, the way every chain-touching function in this SDK takes it. `user` is the
30
+ * wallet that will sign: its token accounts are the swap's own source and destination, and the
31
+ * provider creates whichever of them is missing.
32
+ */
33
+ type RouteProvider = {
34
+ /** Buy exactly `amount` of `output`, spending as much `input` as the route needs. */
35
+ exactOut(client: GaboxClient, input: Address, output: Address, amount: bigint, user: Address): Promise<Route>;
36
+ /** Spend exactly `amount` of `input` and take whatever `output` it buys. */
37
+ exactIn(client: GaboxClient, input: Address, output: Address, amount: bigint, user: Address): Promise<Route>;
38
+ };
39
+ //#endregion
2
40
  //#region src/rpc.d.ts
3
41
  type Cluster = 'devnet' | 'mainnet-beta' | 'localnet';
4
42
  /** Solana's public endpoints, and the test validator's default ports. */
@@ -25,6 +63,16 @@ type ClientConfig = {
25
63
  * which only devnet has today; other clusters default to none. Pass `{}` to disable compression.
26
64
  */
27
65
  addressLookupTables?: AddressesByLookupTableAddress;
66
+ /**
67
+ * How a buyer pays in SOL for a machine priced in another token.
68
+ *
69
+ * Mainnet defaults to Jupiter, which is where the liquidity is. Devnet and localnet default to
70
+ * none, because Jupiter does not serve them: pass `raydiumCpmmRoute(pool)` with a CPMM pool that
71
+ * holds the SOL/quote pair. `null` disables the swap leg, and `buyPack`'s `payWith: 'sol'` then
72
+ * fails on a pool quoted in anything but WSOL. Creating a machine never needs it: the creator
73
+ * pays the seed in the machine's own quote token.
74
+ */
75
+ route?: RouteProvider | null;
28
76
  };
29
77
  /**
30
78
  * Everything the SDK needs to talk to one cluster. Pass it to every chain-touching function.
@@ -39,6 +87,8 @@ type GaboxClient = Readonly<{
39
87
  rpc: GaboxRpc;
40
88
  rpcSubscriptions: GaboxRpcSubscriptions;
41
89
  addressLookupTables: AddressesByLookupTableAddress;
90
+ /** The swap provider a SOL payment routes through, or `null` when this cluster has none. */
91
+ route: RouteProvider | null;
42
92
  }>;
43
93
  /**
44
94
  * The cluster a URL names, from its text alone. A substring check, deliberately: providers spell
@@ -59,6 +109,13 @@ declare function websocketUrlFor(url: string): string;
59
109
  * the pair: the subscription reports the change, and the RPC reads the account that changed.
60
110
  */
61
111
  declare function createClient(config: ClientConfig): GaboxClient;
112
+ /**
113
+ * The swap provider a cluster gets when the caller names none.
114
+ *
115
+ * Jupiter on mainnet, nothing anywhere else. Jupiter's API only prices mainnet liquidity, and a
116
+ * devnet caller has to say which pool to route through, so there is nothing to guess.
117
+ */
118
+ declare function defaultRoute(cluster: Cluster): RouteProvider | null;
62
119
  //#endregion
63
120
  //#region src/raydium/abi.d.ts
64
121
  /** One account slot: its IDL name and the privileges the venue's own ABI gives it. */
@@ -74,7 +131,12 @@ type VenueInstructionAbi = {
74
131
  };
75
132
  /**
76
133
  * The Raydium deployment of one cluster. Mainnet and devnet run different programs, so every
77
- * address here differs between the two, and so does the quote the curve must raise.
134
+ * address here differs between the two.
135
+ *
136
+ * Two things are deliberately absent, and both for the same reason: the program reads them from
137
+ * the chain instead of pinning them. The CPMM fee tier comes from the Gabox platform config and
138
+ * from the migrated pool's own data. The quote assets come from Raydium's own LaunchLab
139
+ * `GlobalConfig` accounts, one per quote mint, so there is no list of quotes here.
78
140
  */
79
141
  type RaydiumClusterIds = {
80
142
  /** Raydium LaunchLab, the bonding curve a Gabox coin launches and trades on first. */
@@ -83,8 +145,6 @@ type RaydiumClusterIds = {
83
145
  readonly launchlabAuthority: Address;
84
146
  /** PDA(["__event_authority"], launchlab). */
85
147
  readonly launchlabEventAuthority: Address;
86
- /** PDA(["global_config", WSOL, u8 0, u16 big-endian 0], launchlab). Holds the curve settings. */
87
- readonly solGlobalConfig: Address;
88
148
  /** PDA(["platform_config", PLATFORM_ADMIN], launchlab). The Gabox platform on LaunchLab. */
89
149
  readonly gaboxPlatform: Address;
90
150
  /** Raydium CPMM, the pool a Gabox coin graduates into. */
@@ -92,17 +152,21 @@ type RaydiumClusterIds = {
92
152
  /** PDA(["vault_and_lp_mint_auth_seed"], cpmm). */
93
153
  readonly cpmmAuthority: Address;
94
154
  /**
95
- * The quote the curve must raise before the coin graduates, in lamports.
155
+ * The raise a WSOL-quoted curve must reach before the coin graduates, in lamports.
96
156
  *
97
- * There is no fee tier here on purpose. The Gabox platform config names the CPMM fee tier a coin
98
- * graduates into, and a migrated pool records it again in its own data. Both are read from the
99
- * chain, never compiled in.
157
+ * The program pins this one value, and only for a WSOL pool: it knows what SOL is worth to its
158
+ * own product and cannot say the same about USDC or a stock token. A pool quoted in any other
159
+ * asset picks its own raise, and LaunchLab checks it against `min_quote_fund_raising` in that
160
+ * quote's own global config.
100
161
  */
101
162
  readonly launchQuoteRaise: bigint;
102
163
  };
103
164
  declare const RAYDIUM_MAINNET_IDS: RaydiumClusterIds;
104
165
  declare const RAYDIUM_DEVNET_IDS: RaydiumClusterIds;
105
- /** Wrapped SOL. The only quote Gabox accepts today, on both venues. */
166
+ /**
167
+ * Wrapped SOL: the default quote, and the one every price in SOL is measured in. Gabox accepts any
168
+ * quote Raydium enabled on LaunchLab, so this is not the only one.
169
+ */
106
170
  declare const WSOL_MINT: Address;
107
171
  /** Metaplex Token Metadata, which LaunchLab's create instruction writes to. */
108
172
  declare const METAPLEX_PROGRAM_ADDRESS: Address;
@@ -115,8 +179,13 @@ declare const PLATFORM_ADMIN: Address;
115
179
  declare const LAUNCH_SUPPLY = 1000000000000000n;
116
180
  /** The part of the supply the LaunchLab curve sells: 793,100,000 coins. */
117
181
  declare const LAUNCH_TOTAL_BASE_SELL = 793100000000000n;
118
- /** Classic SPL Token. LaunchLab pins it on both sides of every Gabox launch and trade. */
182
+ /** Classic SPL Token. The base coin is always under it, on both venues. */
119
183
  declare const TOKEN_PROGRAM_ADDRESS: Address;
184
+ /**
185
+ * Token-2022. A quote mint may be under it, inside the bounded profile the program's
186
+ * `tokens::validate_quote_mint` accepts. The base coin never is.
187
+ */
188
+ declare const TOKEN_2022_PROGRAM_ADDRESS: Address;
120
189
  declare const ASSOCIATED_TOKEN_PROGRAM_ADDRESS: Address;
121
190
  declare const SYSTEM_PROGRAM_ADDRESS: Address;
122
191
  /** The rent sysvar. LaunchLab's create instruction still takes it. */
@@ -236,7 +305,7 @@ declare const SHARE_FEE_RATE = 0n;
236
305
  declare const CONSTANT_CURVE_TAG = 0;
237
306
  /** `migrate_type` 1: the coin graduates into a CPMM pool, not into an AMM pool. */
238
307
  declare const MIGRATE_TO_CPMM = 1;
239
- /** `AmmCreatorFeeOn::QuoteToken`, so the CPMM creator fee is paid in WSOL. */
308
+ /** `AmmCreatorFeeOn::QuoteToken`, so the CPMM creator fee is paid in the pool's quote asset. */
240
309
  declare const CREATOR_FEE_ON_QUOTE = 0;
241
310
  /** LaunchLab pool `status`: still selling on the curve. */
242
311
  declare const LAUNCHLAB_STATUS_FUND = 0;
@@ -268,6 +337,25 @@ declare function tokenAccountOwnerAndMint(data: Uint8Array): {
268
337
  mint: Address;
269
338
  owner: Address;
270
339
  };
340
+ /**
341
+ * The `decimals` of a mint. Both token programs share the first 82 bytes, so one reader covers a
342
+ * classic SPL mint and a Token-2022 one.
343
+ */
344
+ declare function mintDecimals(data: Uint8Array): number;
345
+ /**
346
+ * The `symbol` of a Metaplex token metadata account, or `null` when it carries none.
347
+ *
348
+ * Layout: a one-byte key, `update_authority` and `mint`, then the three Borsh strings `name`,
349
+ * `symbol` and `uri`. Metaplex stores them at their maximum length, NUL padded.
350
+ */
351
+ declare function metaplexSymbol(data: Uint8Array): string | null;
352
+ /**
353
+ * The `symbol` a Token-2022 mint stores in its own `TokenMetadata` extension, or `null`.
354
+ *
355
+ * The extensions are a TLV list: a u16 type, a u16 length, then the value. The metadata value is
356
+ * `update_authority`, `mint`, then the Borsh strings `name`, `symbol` and `uri`.
357
+ */
358
+ declare function token2022Symbol(data: Uint8Array): string | null;
271
359
  /** The curve pool of one coin, as far as pricing and routing need it. */
272
360
  type LaunchlabPoolState = {
273
361
  /** 0 while the curve still sells, 1 while Raydium migrates the coin, 2 once it has graduated. */
@@ -301,7 +389,13 @@ type LaunchlabPoolState = {
301
389
  /** The bytes the decoder above reads, discriminator included. The account itself is longer. */
302
390
  declare const LAUNCHLAB_POOL_STATE_HEAD_SIZE = 367;
303
391
  declare function decodeLaunchlabPool(data: Uint8Array): LaunchlabPoolState;
304
- /** LaunchLab's settings for one quote asset. Gabox reads the trade fee and the migrate fee. */
392
+ /**
393
+ * LaunchLab's settings for one quote asset.
394
+ *
395
+ * One of these exists for every quote Raydium enabled, and only Raydium's admin can create one. So
396
+ * the account itself is what proves a quote is allowed: the program checks the same four things in
397
+ * `venue/launch.rs` before it opens a pool.
398
+ */
305
399
  type LaunchlabGlobalConfig = {
306
400
  /** 0 is the constant product curve, the only shape Gabox launches. */
307
401
  curveType: number;
@@ -310,6 +404,8 @@ type LaunchlabGlobalConfig = {
310
404
  migrateFee: bigint;
311
405
  /** Raydium's own share of every curve trade, out of 1,000,000. */
312
406
  tradeFeeRate: bigint;
407
+ /** The smallest raise LaunchLab accepts for this quote, in its own base units. */
408
+ minQuoteFundRaising: bigint;
313
409
  quoteMint: Address;
314
410
  };
315
411
  declare const LAUNCHLAB_GLOBAL_CONFIG_HEAD_SIZE = 115;
@@ -535,6 +631,18 @@ declare function cpmmSwapBaseInput(sides: CpmmSwapSides, rates: CpmmFeeRates, am
535
631
  //#endregion
536
632
  //#region src/raydium/venue.d.ts
537
633
  type VenueKind = 'launchlab' | 'cpmm';
634
+ /**
635
+ * The quote asset one pool is bound to, as the pool records it.
636
+ *
637
+ * `config` is LaunchLab's global config for the mint: the account that proves Raydium enabled the
638
+ * quote, and the account both venues check the trade against. `tokenProgram` owns the mint, and the
639
+ * user's quote ATA lives under it.
640
+ */
641
+ type QuoteBinding = {
642
+ mint: Address;
643
+ config: Address;
644
+ tokenProgram: Address;
645
+ };
538
646
  /** Everything `resolveVenue` learned, plus the pure functions that follow from it. */
539
647
  type ResolvedVenue = {
540
648
  kind: VenueKind;
@@ -542,6 +650,10 @@ type ResolvedVenue = {
542
650
  program: Address;
543
651
  mint: Address;
544
652
  quoteMint: Address;
653
+ /** The token program the quote mint lives under: classic SPL Token, or Token-2022. */
654
+ quoteTokenProgram: Address;
655
+ /** The trader's quote ATA. Both venues settle here, and the program pins this address. */
656
+ userQuoteToken: Address;
545
657
  /** The venue's own pool: the LaunchLab curve pool, or the migrated CPMM pool. */
546
658
  poolState: Address;
547
659
  /** The LaunchLab pool's `status`: 0 funding, 1 migrating, 2 graduated. */
@@ -556,9 +668,9 @@ type ResolvedVenue = {
556
668
  buyAccounts: AccountMeta[];
557
669
  /** The ordered account list for a sale. */
558
670
  sellAccounts: AccountMeta[];
559
- /** WSOL an exact-coins-out buy of `tokens` costs right now, the venue's fees included. */
671
+ /** Quote token an exact-coins-out buy of `tokens` costs right now, the venue's fees included. */
560
672
  quoteBuy(tokens: bigint): bigint;
561
- /** WSOL a sale of `tokens` returns right now, net of the venue's fees. */
673
+ /** Quote token a sale of `tokens` returns right now, net of the venue's fees. */
562
674
  quoteSell(tokens: bigint): bigint;
563
675
  };
564
676
  type ResolveVenueOptions = {
@@ -567,14 +679,20 @@ type ResolveVenueOptions = {
567
679
  user: Address;
568
680
  /** Force a venue instead of reading the pool's `status`. A wrong choice fails on chain. */
569
681
  venue?: VenueKind;
682
+ /** The pool's quote binding. Read from the Gabox pool when it is left out. */
683
+ quote?: QuoteBinding;
570
684
  };
685
+ /** The quote binding a Gabox pool records. One account read. */
686
+ declare function fetchQuoteBinding(client: GaboxClient, mint: Address): Promise<QuoteBinding>;
571
687
  /**
572
- * The user's WSOL associated token account.
688
+ * The user's quote associated token account, under the quote's own token program.
573
689
  *
574
- * Both venues settle in WSOL, never in native SOL. This account must exist and hold enough before a
575
- * pack is bought, and sale proceeds land in it. Every builder in `tx/` wraps the SOL it needs into
576
- * this account and closes it again in the same transaction.
690
+ * Both venues settle in this account, never in native SOL. It must exist and hold enough before a
691
+ * pack is bought, and sale proceeds land in it. For a WSOL-quoted pool every builder in `tx/` wraps
692
+ * the SOL it needs into this account and closes it again in the same transaction.
577
693
  */
694
+ declare function quoteAccountFor(user: Address, quoteMint: Address, quoteTokenProgram?: Address): Promise<Address>;
695
+ /** The user's WSOL associated token account. WSOL is always classic SPL Token. */
578
696
  declare function wsolAccountFor(user: Address): Promise<Address>;
579
697
  /** What LaunchLab's global config and the Gabox platform config say about a curve trade. */
580
698
  type CurveSettings = {
@@ -584,8 +702,14 @@ type CurveSettings = {
584
702
  /** `cpswap_config` on the platform config: the CPMM fee tier a Gabox coin graduates into. */
585
703
  cpswapConfig: Address;
586
704
  };
587
- /** Read the two pinned config accounts and take the four numbers a quote needs out of them. */
588
- declare function fetchCurveSettings(client: GaboxClient, ids?: RaydiumIds): Promise<CurveSettings>;
705
+ /**
706
+ * Read the quote's global config and the Gabox platform config, and take the four numbers a quote
707
+ * needs out of them.
708
+ *
709
+ * `quoteConfig` is the LaunchLab global config of the pool's quote asset: `pool.quoteConfig`, or
710
+ * the address `raydium.fetchQuoteConfig` derives for a coin that has no pool yet.
711
+ */
712
+ declare function fetchCurveSettings(client: GaboxClient, quoteConfig: Address, ids?: RaydiumIds): Promise<CurveSettings>;
589
713
  declare function resolveVenue(client: GaboxClient, options: ResolveVenueOptions): Promise<ResolvedVenue>;
590
714
  /** A CPMM pool that has proved, from its own data, that it is a coin's migrated pool. */
591
715
  type MigratedCpmmPool = {
@@ -598,6 +722,7 @@ type FindCpmmPoolOptions = {
598
722
  creator: Address;
599
723
  /** The fee tier the Gabox platform config names. Read it with `fetchCurveSettings`. */
600
724
  cpswapConfig: Address;
725
+ /** The pool's quote mint. Defaults to WSOL, which is the default quote. */
601
726
  quoteMint?: Address;
602
727
  };
603
728
  /**
@@ -630,12 +755,13 @@ declare function findCpmmPool(client: GaboxClient, options: FindCpmmPoolOptions)
630
755
  *
631
756
  * `creator_fee_on` is 0 when the fee follows the input token, 1 when it is always token 0, and 2
632
757
  * when it is always token 1. LaunchLab migrates a Gabox coin with `AmmCreatorFeeOn::QuoteToken`, so
633
- * the pool charges the creator fee in WSOL only: on the input of a buy, on the output of a sale.
758
+ * the pool charges the creator fee in the quote token only: on the input of a buy, on the output of
759
+ * a sale.
634
760
  */
635
761
  declare function creatorFeeOnInput(pool: CpmmPoolState, inputMint: Address): boolean;
636
762
  /**
637
- * WSOL an exact-coins-out buy of `tokens` costs right now, on whichever venue the coin trades.
638
- * Pass `pool.packTokens` for the pack price.
763
+ * Quote token an exact-coins-out buy of `tokens` costs right now, on whichever venue the coin
764
+ * trades. Pass `pool.packTokens` for the pack price.
639
765
  *
640
766
  * Use `resolveVenue` when you also need the account list, which every transaction builder does.
641
767
  * This is for a price display.
@@ -643,23 +769,33 @@ declare function creatorFeeOnInput(pool: CpmmPoolState, inputMint: Address): boo
643
769
  declare function curveQuote(client: GaboxClient, mint: Address, tokens: bigint, options?: {
644
770
  user?: Address;
645
771
  venue?: VenueKind;
772
+ quote?: QuoteBinding;
646
773
  }): Promise<bigint>;
647
- /** WSOL a sale of `tokens` returns right now, net of the venue's fees. */
774
+ /** Quote token a sale of `tokens` returns right now, net of the venue's fees. */
648
775
  declare function sellQuote(client: GaboxClient, mint: Address, tokens: bigint, options?: {
649
776
  user?: Address;
650
777
  venue?: VenueKind;
778
+ quote?: QuoteBinding;
651
779
  }): Promise<bigint>;
652
780
  /**
653
- * WSOL an exact-coins-out buy of `tokens` would cost on a curve that does not exist yet, fees
654
- * included.
781
+ * Quote token an exact-coins-out buy of `tokens` would cost on a curve that does not exist yet,
782
+ * fees included.
655
783
  *
656
784
  * This is what the seed costs. `initialize_pool` buys it in the same transaction that creates the
657
785
  * coin, so the curve is a brand-new LaunchLab curve with the pinned Gabox launch shape at that
658
786
  * moment. Exact, unless Raydium changes a fee rate between this read and the send.
659
787
  */
660
- declare function newCurveBuyCost(client: GaboxClient, tokens: bigint): Promise<bigint>;
661
- /** The starting reserves of a brand-new Gabox curve on this cluster. */
662
- declare function newCurveReserves(ids: RaydiumIds, migrateFee: bigint): CurveReserves;
788
+ declare function newCurveBuyCost(client: GaboxClient, tokens: bigint, launch: {
789
+ quoteConfig: Address;
790
+ raise: bigint;
791
+ }): Promise<bigint>;
792
+ /**
793
+ * The starting reserves of a brand-new Gabox curve.
794
+ *
795
+ * `raise` is `total_quote_fund_raising`, in the quote's own base units. It is the one launch number
796
+ * the client picks, so the reserves follow it.
797
+ */
798
+ declare function newCurveReserves(raise: bigint, migrateFee: bigint): CurveReserves;
663
799
  //#endregion
664
800
  //#region src/tx/message.d.ts
665
801
  /**
@@ -724,8 +860,10 @@ type LaunchlabTradeAccountsInput = {
724
860
  user: Address;
725
861
  /** The trader's coin ATA. `buy_pack` passes the same address as its own `user_tokens`. */
726
862
  userBaseToken: Address;
727
- /** The trader's WSOL ATA. Both venues settle here. */
863
+ /** The trader's quote ATA, under the quote's own token program. Both venues settle here. */
728
864
  userQuoteToken: Address;
865
+ /** The quote mint's token program: classic SPL Token, or Token-2022. */
866
+ quoteTokenProgram: Address;
729
867
  /** `[platform_config, quote_mint]` under LaunchLab. */
730
868
  platformFeeVault: Address;
731
869
  /** `[creator, quote_mint]` under LaunchLab, where `creator` is the coin creator. */
@@ -760,6 +898,9 @@ type CpmmTradeAccountsInput = {
760
898
  user: Address;
761
899
  userBaseToken: Address;
762
900
  userQuoteToken: Address;
901
+ /** The two token programs the pool records. Read them from the pool account, never derive them. */
902
+ baseTokenProgram: Address;
903
+ quoteTokenProgram: Address;
763
904
  };
764
905
  /** `swap_base_output`: 13 accounts. Note the argument order is `(max_amount_in, amount_out)`. */
765
906
  declare const cpmmBuyAccounts: (input: CpmmTradeAccountsInput) => AccountMeta[];
@@ -768,59 +909,87 @@ declare const cpmmSellAccounts: (input: CpmmTradeAccountsInput) => AccountMeta[]
768
909
  //#endregion
769
910
  //#region src/raydium/claim.d.ts
770
911
  /**
771
- * The instructions of a curve fee claim: create the WSOL account, claim, close it.
912
+ * The instructions of a curve fee claim, for one quote asset: create the quote account, claim, and
913
+ * close it again when the quote is WSOL.
772
914
  *
773
- * This sweeps **every** coin this wallet launched, because LaunchLab keeps one vault per wallet per
774
- * quote asset. There is no per-coin version.
915
+ * This sweeps **every** coin this wallet launched against that quote, because LaunchLab keeps one
916
+ * vault per wallet per quote asset. There is no per-coin version, and a creator with machines in
917
+ * two quote assets claims once per asset.
775
918
  */
776
- declare function getClaimCreatorFeeInstructions(creator: TransactionSigner, ids: RaydiumIds): Promise<Instruction[]>;
919
+ declare function getClaimCreatorFeeInstructions(creator: TransactionSigner, ids: RaydiumIds, quote: {
920
+ mint: Address;
921
+ tokenProgram: Address;
922
+ }): Promise<Instruction[]>;
777
923
  type ClaimCreatorFeeInput = {
778
924
  creator: TransactionSigner;
925
+ /** The quote asset to claim. Defaults to wrapped SOL. One claim per quote asset. */
926
+ quoteMint?: Address;
779
927
  } & Partial<BuildOptions>;
780
928
  /**
781
- * Claim the curve creator fee and receive it as SOL.
929
+ * Claim the curve creator fee for one quote asset.
782
930
  *
783
- * One transaction, three instructions. It sweeps every coin this wallet launched on LaunchLab.
931
+ * A WSOL claim arrives as SOL, because the builder closes the WSOL account. Any other quote arrives
932
+ * as that token, in the creator's own account.
784
933
  */
785
934
  declare function claimCreatorFee(client: GaboxClient, input: ClaimCreatorFeeInput): Promise<GaboxTransactionMessage>;
786
935
  /**
787
- * The instructions of a graduated coin's fee collection: create the WSOL account, collect, close.
936
+ * The instructions of a graduated coin's fee collection: create the quote account, collect, and
937
+ * close it again when the quote is WSOL.
788
938
  *
789
939
  * This is per coin. `collect_creator_fee` pays out both sides of the pair, so anything owed in the
790
940
  * coin itself lands in the creator's coin account and stays there.
941
+ *
942
+ * The coin's quote asset comes from its Gabox pool, so a caller never has to name it.
791
943
  */
792
944
  declare function getCollectCreatorFeeInstructions(client: GaboxClient, input: {
793
945
  mint: Address;
794
946
  creator: TransactionSigner;
947
+ quote?: QuoteBinding;
795
948
  }, ids?: RaydiumIds): Promise<Instruction[]>;
796
949
  type CollectCreatorFeeInput = {
797
950
  mint: Address;
798
951
  creator: TransactionSigner;
952
+ /** The coin's quote binding, when it is already at hand. Read from the Gabox pool otherwise. */
953
+ quote?: QuoteBinding;
799
954
  } & Partial<BuildOptions>;
800
- /** Collect one graduated coin's CPMM creator fee and receive the WSOL side as SOL. */
955
+ /**
956
+ * Collect one graduated coin's CPMM creator fee.
957
+ *
958
+ * A WSOL-quoted coin pays the quote side out as SOL, because the builder closes the WSOL account.
959
+ * Any other quote arrives as that token.
960
+ */
801
961
  declare function collectCreatorFee(client: GaboxClient, input: CollectCreatorFeeInput): Promise<GaboxTransactionMessage>;
802
- /** What a creator can collect right now. Every amount is in base units. */
962
+ /** What a creator can collect right now, for one quote asset. Every amount is in base units. */
803
963
  type CreatorFees = {
804
- /** WSOL waiting in the LaunchLab creator fee vault, across every coin this wallet launched. */
805
- curveLamports: bigint;
964
+ /** The quote asset these three amounts are measured against. */
965
+ quoteMint: Address;
806
966
  /**
807
- * WSOL the migrated CPMM pool of `mint` owes this creator. `0n` when the coin has not graduated,
808
- * and `0n` when no `mint` was passed.
967
+ * Quote token waiting in the LaunchLab creator fee vault, across every coin this wallet launched
968
+ * against that quote.
809
969
  */
810
- cpmmLamports: bigint;
970
+ curveQuote: bigint;
971
+ /**
972
+ * Quote token the migrated CPMM pool of `mint` owes this creator. `0n` when the coin has not
973
+ * graduated, and `0n` when no `mint` was passed.
974
+ */
975
+ cpmmQuote: bigint;
811
976
  /** Coins the same pool owes this creator. CPMM can charge the fee on either side. */
812
977
  cpmmTokens: bigint;
813
978
  };
814
979
  /**
815
- * Read both places a creator's fees can sit.
980
+ * Read both places a creator's fees can sit, for one quote asset.
981
+ *
982
+ * `quoteMint` defaults to wrapped SOL. LaunchLab keeps one vault per wallet per quote, so a creator
983
+ * with machines in two quote assets reads this twice.
816
984
  *
817
985
  * `mint` is optional. Without it only the curve vault is read, which is the one number that covers
818
- * every coin at once. With it the coin's CPMM pool is read too, and a coin that has not graduated
819
- * reports zeros rather than failing.
986
+ * every coin of that quote at once. With it the coin's CPMM pool is read too, and a coin that has
987
+ * not graduated reports zeros rather than failing.
820
988
  */
821
989
  declare function fetchCreatorFees(client: GaboxClient, input: {
822
990
  creator: Address;
823
991
  mint?: Address;
992
+ quoteMint?: Address;
824
993
  }): Promise<CreatorFees>;
825
994
  //#endregion
826
995
  //#region src/raydium/launch.d.ts
@@ -837,6 +1006,14 @@ type LaunchInput = {
837
1006
  symbol: string;
838
1007
  /** The metadata URI. Metaplex stores it on the mint's metadata account. */
839
1008
  uri: string;
1009
+ /** The quote asset the coin is priced in. */
1010
+ quoteMint: Address;
1011
+ /** LaunchLab's global config for that quote: `["global_config", quote_mint, 0u8, 0u16]`. */
1012
+ quoteConfig: Address;
1013
+ /** The token program that owns the quote mint: classic SPL Token, or Token-2022. */
1014
+ quoteTokenProgram: Address;
1015
+ /** `total_quote_fund_raising`, in the quote's own base units. */
1016
+ raise: bigint;
840
1017
  };
841
1018
  /**
842
1019
  * Build `initialize_v2` for one cluster's LaunchLab. `ids` is `raydiumIds(client.cluster)`.
@@ -906,29 +1083,103 @@ declare const cpmmCreatorFeeShare: (cpmm: Address, creator: Address, ammConfig:
906
1083
  /** An associated token account. Off-curve owners are allowed: pool PDAs are all off-curve. */
907
1084
  declare const ata: (owner: Address, mint: Address, tokenProgram?: Address) => Promise<Address>;
908
1085
  //#endregion
1086
+ //#region src/raydium/quote.d.ts
1087
+ /** LaunchLab's settings for one quote, and the address they were read from. */
1088
+ type QuoteConfig = LaunchlabGlobalConfig & {
1089
+ /** `["global_config", quote_mint, u8 0, u16 big-endian 0]` under LaunchLab. */
1090
+ address: Address;
1091
+ };
1092
+ /** Everything a pool, a price and an account list need to know about a quote asset. */
1093
+ type QuoteAsset = {
1094
+ mint: Address;
1095
+ /** The LaunchLab global config `initialize_pool` proves the quote with. */
1096
+ config: Address;
1097
+ /** Classic SPL Token, or Token-2022. The user's quote ATA lives under it. */
1098
+ tokenProgram: Address;
1099
+ decimals: number;
1100
+ /** From Metaplex, or from the Token-2022 metadata extension. `null` when the mint has none. */
1101
+ symbol: string | null;
1102
+ /** Raydium's own share of every curve trade, out of 1,000,000. */
1103
+ tradeFeeRate: bigint;
1104
+ /** The quote LaunchLab keeps at graduation. The starting reserves depend on it. */
1105
+ migrateFee: bigint;
1106
+ /** The smallest `raise` LaunchLab accepts for this quote, in the quote's base units. */
1107
+ minQuoteFundRaising: bigint;
1108
+ };
1109
+ /**
1110
+ * LaunchLab's global config for one quote mint, or `null` when Raydium enabled no such quote.
1111
+ *
1112
+ * Index 0 is the usual config, and the constant-product curve is the only shape Gabox launches, so
1113
+ * those two are fixed here. The decoded `quoteMint` has to be the mint asked for: a config for a
1114
+ * different quote would price the wrong asset.
1115
+ */
1116
+ declare function fetchQuoteConfig(client: GaboxClient, mint: Address, ids?: RaydiumIds): Promise<QuoteConfig | null>;
1117
+ /** Can a Gabox machine be quoted in this mint? One account read. */
1118
+ declare function isQuoteSupported(client: GaboxClient, mint: Address): Promise<boolean>;
1119
+ /**
1120
+ * The full quote asset: its LaunchLab config, its token program, its decimals and its symbol.
1121
+ *
1122
+ * Two round trips. The first reads the global config, because the config address is derived from
1123
+ * the mint. The second reads the mint and its Metaplex metadata account together.
1124
+ *
1125
+ * Throws when Raydium has no config for the mint, because no pool can be created or traded then.
1126
+ */
1127
+ declare function fetchQuoteAsset(client: GaboxClient, mint: Address, ids?: RaydiumIds): Promise<QuoteAsset>;
1128
+ /** What a price display needs about a quote mint: its program, its decimals and its symbol. */
1129
+ type QuoteDisplay = {
1130
+ tokenProgram: Address;
1131
+ decimals: number;
1132
+ symbol: string | null;
1133
+ };
1134
+ /**
1135
+ * Read a quote mint and its Metaplex metadata in one call.
1136
+ *
1137
+ * A Token-2022 mint may carry its own `TokenMetadata` extension, and that one wins: it is the
1138
+ * issuer's own record. A classic SPL mint keeps its symbol in a Metaplex account, and a mint with
1139
+ * neither reports `null`.
1140
+ */
1141
+ declare function fetchQuoteDisplay(client: GaboxClient, mint: Address): Promise<QuoteDisplay>;
1142
+ //#endregion
1143
+ //#region src/raydium/read.d.ts
1144
+ /** An account that may not exist, with its raw bytes and its owning program. */
1145
+ type MaybeAccount$1 = {
1146
+ data: Uint8Array;
1147
+ owner: Address;
1148
+ } | null;
1149
+ /** Read several accounts in one call. A missing account comes back as `null`, not as an error. */
1150
+ declare function readAccounts(rpc: GaboxRpc, addresses: Address[]): Promise<MaybeAccount$1[]>;
1151
+ /** Decode one base64 account payload the RPC returned inside another shape. */
1152
+ declare const decodeBase64: (encoded: string) => Uint8Array;
1153
+ //#endregion
909
1154
  //#region src/raydium/trade.d.ts
910
1155
  type CurveBuyExactInInput = {
911
1156
  mint: Address;
912
1157
  /** The coin creator, so the creator fee vault can be derived. Read it off the pool. */
913
1158
  creator: Address;
914
- /** The wallet spending. It signs, and its WSOL ATA must already hold `quoteIn`. */
1159
+ /** The wallet spending. It signs, and its quote ATA must already hold `quoteIn`. */
915
1160
  user: TransactionSigner;
916
- /** WSOL to spend, fees included. */
1161
+ /** Quote token to spend, fees included. */
917
1162
  quoteIn: bigint;
918
1163
  /** The floor on the coins received. Use `curveBuyExactIn` from `curve.ts` to compute it. */
919
1164
  minTokensOut: bigint;
1165
+ /** The pool's quote mint. Defaults to wrapped SOL. */
1166
+ quoteMint?: Address;
1167
+ /** The quote mint's token program. Defaults to classic SPL Token, which is what WSOL uses. */
1168
+ quoteTokenProgram?: Address;
920
1169
  };
921
1170
  /**
922
- * `buy_exact_in` on the curve: spend exactly `quoteIn` WSOL and take whatever coins it buys.
1171
+ * `buy_exact_in` on the curve: spend exactly `quoteIn` of the quote token and take whatever coins
1172
+ * it buys.
923
1173
  *
924
1174
  * LaunchLab caps the trade at what the curve has left to sell, so a spend larger than the rest of
925
- * the raise still succeeds and graduates the coin. Wrap the SOL into the user's WSOL ATA first and
926
- * close it afterwards, the same way the Gabox builders do.
1175
+ * the raise still succeeds and graduates the coin. Fund the user's quote ATA first. On a WSOL pool
1176
+ * that means wrapping the SOL and closing the account afterwards, the same way the Gabox builders
1177
+ * do.
927
1178
  */
928
1179
  declare function getCurveBuyExactInInstruction(client: GaboxClient, input: CurveBuyExactInInput, ids?: RaydiumIds): Promise<Instruction>;
929
1180
  declare namespace index_d_exports {
930
- export { ASSOCIATED_TOKEN_PROGRAM_ADDRESS, CONSTANT_CURVE_TAG, CPMM_AMM_CONFIG_DISCRIMINATOR, CPMM_AMM_CONFIG_HEAD_SIZE, CPMM_COLLECT_CREATOR_FEE, CPMM_POOL_OFFSETS, CPMM_POOL_STATE_DISCRIMINATOR, CPMM_POOL_STATE_HEAD_SIZE, CPMM_POOL_STATE_SIZE, CPMM_SEEDS, CPMM_SWAP_BASE_INPUT, CPMM_SWAP_BASE_OUTPUT, CREATOR_FEE_ON_QUOTE, ClaimCreatorFeeInput, CollectCreatorFeeInput, CpmmAmmConfig, CpmmFeeRates, CpmmPoolState, CpmmSwapSides, CpmmTradeAccountsInput, CreatorFees, CurveBuyExactInInput, CurveFeeRates, CurveReserves, CurveSettings, FindCpmmPoolOptions, LAUNCHLAB_BUY_EXACT_IN, LAUNCHLAB_BUY_EXACT_OUT, LAUNCHLAB_CLAIM_CREATOR_FEE, LAUNCHLAB_GLOBAL_CONFIG_DISCRIMINATOR, LAUNCHLAB_GLOBAL_CONFIG_HEAD_SIZE, LAUNCHLAB_INITIALIZE, LAUNCHLAB_PLATFORM_CONFIG_DISCRIMINATOR, LAUNCHLAB_PLATFORM_CONFIG_HEAD_SIZE, LAUNCHLAB_POOL_STATE_DISCRIMINATOR, LAUNCHLAB_POOL_STATE_HEAD_SIZE, LAUNCHLAB_SEEDS, LAUNCHLAB_SELL_EXACT_IN, LAUNCHLAB_STATUS_FUND, LAUNCHLAB_STATUS_MIGRATE, LAUNCHLAB_STATUS_TRADE, LAUNCH_DECIMALS, LAUNCH_SUPPLY, LAUNCH_TOTAL_BASE_SELL, LaunchInput, LaunchParams, LaunchlabGlobalConfig, LaunchlabPlatformConfig, LaunchlabPoolState, LaunchlabTradeAccountsInput, METADATA_LIMITS, METADATA_SEED, METAPLEX_PROGRAM_ADDRESS, MIGRATE_TO_CPMM, MigratedCpmmPool, PLATFORM_ADMIN, RATE_DENOMINATOR, RAYDIUM_DEVNET_IDS, RAYDIUM_IDS, RAYDIUM_MAINNET_IDS, RENT_SYSVAR_ADDRESS, RaydiumClusterIds, RaydiumIds, ResolveVenueOptions, ResolvedVenue, SHARE_FEE_RATE, SYSTEM_PROGRAM_ADDRESS, TOKEN_PROGRAM_ADDRESS, VenueAccountSpec, VenueInstructionAbi, VenueKind, WSOL_MINT, ata, ceilDiv, ceilDivRate, claimCreatorFee, collectCreatorFee, compareAddresses, cpmmAuthority, cpmmBuyAccounts, cpmmCreatorFeeShare, cpmmPoolAddress, cpmmPoolMatches, cpmmSellAccounts, cpmmSwapBaseInput, cpmmSwapBaseOutput, creatorFeeOnInput, creatorFeeVaultAddress, creatorFeeVaultAuthority, curveBuyExactIn, curveBuyExactOut, curveQuote, curveSellExactIn, decodeCpmmAmmConfig, decodeCpmmPool, decodeLaunchlabGlobalConfig, decodeLaunchlabPlatformConfig, decodeLaunchlabPool, fetchCreatorFees, fetchCurveSettings, findCpmmPool, getClaimCreatorFeeInstructions, getCollectCreatorFeeInstructions, getCurveBuyExactInInstruction, getLaunchInstruction, initialCurve, launchlabAuthority, launchlabBuyAccounts, launchlabBuyExactInAccounts, launchlabEventAuthority, launchlabGlobalConfig, launchlabPlatformConfig, launchlabPoolAddress, launchlabSellAccounts, launchlabVaultAddress, metadataAddress, newCurveBuyCost, newCurveReserves, order, platformFeeVaultAddress, preFeeAmount, raydiumIds, remainingBase, resolveVenue, sellQuote, sortedMints, tokenAccountAmount, tokenAccountOwnerAndMint, totalCurveFeeRate, wsolAccountFor };
1181
+ export { ASSOCIATED_TOKEN_PROGRAM_ADDRESS, CONSTANT_CURVE_TAG, CPMM_AMM_CONFIG_DISCRIMINATOR, CPMM_AMM_CONFIG_HEAD_SIZE, CPMM_COLLECT_CREATOR_FEE, CPMM_POOL_OFFSETS, CPMM_POOL_STATE_DISCRIMINATOR, CPMM_POOL_STATE_HEAD_SIZE, CPMM_POOL_STATE_SIZE, CPMM_SEEDS, CPMM_SWAP_BASE_INPUT, CPMM_SWAP_BASE_OUTPUT, CREATOR_FEE_ON_QUOTE, ClaimCreatorFeeInput, CollectCreatorFeeInput, CpmmAmmConfig, CpmmFeeRates, CpmmPoolState, CpmmSwapSides, CpmmTradeAccountsInput, CreatorFees, CurveBuyExactInInput, CurveFeeRates, CurveReserves, CurveSettings, FindCpmmPoolOptions, LAUNCHLAB_BUY_EXACT_IN, LAUNCHLAB_BUY_EXACT_OUT, LAUNCHLAB_CLAIM_CREATOR_FEE, LAUNCHLAB_GLOBAL_CONFIG_DISCRIMINATOR, LAUNCHLAB_GLOBAL_CONFIG_HEAD_SIZE, LAUNCHLAB_INITIALIZE, LAUNCHLAB_PLATFORM_CONFIG_DISCRIMINATOR, LAUNCHLAB_PLATFORM_CONFIG_HEAD_SIZE, LAUNCHLAB_POOL_STATE_DISCRIMINATOR, LAUNCHLAB_POOL_STATE_HEAD_SIZE, LAUNCHLAB_SEEDS, LAUNCHLAB_SELL_EXACT_IN, LAUNCHLAB_STATUS_FUND, LAUNCHLAB_STATUS_MIGRATE, LAUNCHLAB_STATUS_TRADE, LAUNCH_DECIMALS, LAUNCH_SUPPLY, LAUNCH_TOTAL_BASE_SELL, LaunchInput, LaunchParams, LaunchlabGlobalConfig, LaunchlabPlatformConfig, LaunchlabPoolState, LaunchlabTradeAccountsInput, METADATA_LIMITS, METADATA_SEED, METAPLEX_PROGRAM_ADDRESS, MIGRATE_TO_CPMM, MaybeAccount$1 as MaybeAccount, MigratedCpmmPool, PLATFORM_ADMIN, QuoteAsset, QuoteBinding, QuoteConfig, QuoteDisplay, RATE_DENOMINATOR, RAYDIUM_DEVNET_IDS, RAYDIUM_IDS, RAYDIUM_MAINNET_IDS, RENT_SYSVAR_ADDRESS, RaydiumClusterIds, RaydiumIds, ResolveVenueOptions, ResolvedVenue, SHARE_FEE_RATE, SYSTEM_PROGRAM_ADDRESS, TOKEN_2022_PROGRAM_ADDRESS, TOKEN_PROGRAM_ADDRESS, VenueAccountSpec, VenueInstructionAbi, VenueKind, WSOL_MINT, ata, ceilDiv, ceilDivRate, claimCreatorFee, collectCreatorFee, compareAddresses, cpmmAuthority, cpmmBuyAccounts, cpmmCreatorFeeShare, cpmmPoolAddress, cpmmPoolMatches, cpmmSellAccounts, cpmmSwapBaseInput, cpmmSwapBaseOutput, creatorFeeOnInput, creatorFeeVaultAddress, creatorFeeVaultAuthority, curveBuyExactIn, curveBuyExactOut, curveQuote, curveSellExactIn, decodeBase64, decodeCpmmAmmConfig, decodeCpmmPool, decodeLaunchlabGlobalConfig, decodeLaunchlabPlatformConfig, decodeLaunchlabPool, fetchCreatorFees, fetchCurveSettings, fetchQuoteAsset, fetchQuoteBinding, fetchQuoteConfig, fetchQuoteDisplay, findCpmmPool, getClaimCreatorFeeInstructions, getCollectCreatorFeeInstructions, getCurveBuyExactInInstruction, getLaunchInstruction, initialCurve, isQuoteSupported, launchlabAuthority, launchlabBuyAccounts, launchlabBuyExactInAccounts, launchlabEventAuthority, launchlabGlobalConfig, launchlabPlatformConfig, launchlabPoolAddress, launchlabSellAccounts, launchlabVaultAddress, metadataAddress, metaplexSymbol, mintDecimals, newCurveBuyCost, newCurveReserves, order, platformFeeVaultAddress, preFeeAmount, quoteAccountFor, raydiumIds, readAccounts, remainingBase, resolveVenue, sellQuote, sortedMints, token2022Symbol, tokenAccountAmount, tokenAccountOwnerAndMint, totalCurveFeeRate, wsolAccountFor };
931
1182
  }
932
1183
  //#endregion
933
- export { resolveVenue as $, raydiumIds as $t, cpmmBuyAccounts as A, Cluster as An, decodeCpmmAmmConfig as At, CurveSettings as B, LAUNCHLAB_SEEDS as Bt, claimCreatorFee as C, SYSTEM_PROGRAM_ADDRESS as Cn, CpmmPoolState as Ct, getCollectCreatorFeeInstructions as D, WSOL_MINT as Dn, LaunchlabGlobalConfig as Dt, getClaimCreatorFeeInstructions as E, VenueInstructionAbi as En, LAUNCHLAB_POOL_STATE_HEAD_SIZE as Et, order as F, GaboxRpcSubscriptions as Fn, tokenAccountAmount as Ft, VenueKind as G, METADATA_LIMITS as Gt, MigratedCpmmPool as H, LAUNCHLAB_STATUS_MIGRATE as Ht, BuildOptions as I, assertClusterUrl as In, tokenAccountOwnerAndMint as It, curveQuote as J, RATE_DENOMINATOR as Jt, cpmmPoolMatches as K, METADATA_SEED as Kt, GaboxTransactionMessage as L, clusterNamedBy as Ln, CONSTANT_CURVE_TAG as Lt, launchlabBuyAccounts as M, DEVNET_WS as Mn, decodeLaunchlabGlobalConfig as Mt, launchlabBuyExactInAccounts as N, GaboxClient as Nn, decodeLaunchlabPlatformConfig as Nt, CpmmTradeAccountsInput as O, CLUSTER_ENDPOINTS as On, LaunchlabPlatformConfig as Ot, launchlabSellAccounts as P, GaboxRpc as Pn, decodeLaunchlabPool as Pt, newCurveReserves as Q, compareAddresses as Qt, buildMessage as R, createClient as Rn, CPMM_SEEDS as Rt, CreatorFees as S, RaydiumClusterIds as Sn, CpmmAmmConfig as St, fetchCreatorFees as T, VenueAccountSpec as Tn, LAUNCHLAB_PLATFORM_CONFIG_HEAD_SIZE as Tt, ResolveVenueOptions as U, LAUNCHLAB_STATUS_TRADE as Ut, FindCpmmPoolOptions as V, LAUNCHLAB_STATUS_FUND as Vt, ResolvedVenue as W, LAUNCH_DECIMALS as Wt, findCpmmPool as X, RaydiumIds as Xt, fetchCurveSettings as Y, RAYDIUM_IDS as Yt, newCurveBuyCost as Z, SHARE_FEE_RATE as Zt, platformFeeVaultAddress as _, METAPLEX_PROGRAM_ADDRESS as _n, totalCurveFeeRate as _t, cpmmAuthority as a, CPMM_SWAP_BASE_INPUT as an, CurveReserves as at, ClaimCreatorFeeInput as b, RAYDIUM_MAINNET_IDS as bn, CPMM_POOL_STATE_HEAD_SIZE as bt, creatorFeeVaultAddress as c, LAUNCHLAB_BUY_EXACT_OUT as cn, ceilDivRate as ct, launchlabEventAuthority as d, LAUNCHLAB_INITIALIZE as dn, curveBuyExactIn as dt, sortedMints as en, sellQuote as et, launchlabGlobalConfig as f, LAUNCHLAB_PLATFORM_CONFIG_DISCRIMINATOR as fn, curveBuyExactOut as ft, metadataAddress as g, LAUNCH_TOTAL_BASE_SELL as gn, remainingBase as gt, launchlabVaultAddress as h, LAUNCH_SUPPLY as hn, preFeeAmount as ht, ata as i, CPMM_POOL_STATE_DISCRIMINATOR as in, CurveFeeRates as it, cpmmSellAccounts as j, DEVNET_HTTP as jn, decodeCpmmPool as jt, LaunchlabTradeAccountsInput as k, ClientConfig as kn, LaunchlabPoolState as kt, creatorFeeVaultAuthority as l, LAUNCHLAB_CLAIM_CREATOR_FEE as ln, cpmmSwapBaseInput as lt, launchlabPoolAddress as m, LAUNCHLAB_SELL_EXACT_IN as mn, initialCurve as mt, CurveBuyExactInInput as n, CPMM_AMM_CONFIG_DISCRIMINATOR as nn, CpmmFeeRates as nt, cpmmCreatorFeeShare as o, CPMM_SWAP_BASE_OUTPUT as on, LaunchParams as ot, launchlabPlatformConfig as p, LAUNCHLAB_POOL_STATE_DISCRIMINATOR as pn, curveSellExactIn as pt, creatorFeeOnInput as q, MIGRATE_TO_CPMM as qt, getCurveBuyExactInInstruction as r, CPMM_COLLECT_CREATOR_FEE as rn, CpmmSwapSides as rt, cpmmPoolAddress as s, LAUNCHLAB_BUY_EXACT_IN as sn, ceilDiv as st, index_d_exports as t, ASSOCIATED_TOKEN_PROGRAM_ADDRESS as tn, wsolAccountFor as tt, launchlabAuthority as u, LAUNCHLAB_GLOBAL_CONFIG_DISCRIMINATOR as un, cpmmSwapBaseOutput as ut, LaunchInput as v, PLATFORM_ADMIN as vn, CPMM_AMM_CONFIG_HEAD_SIZE as vt, collectCreatorFee as w, TOKEN_PROGRAM_ADDRESS as wn, LAUNCHLAB_GLOBAL_CONFIG_HEAD_SIZE as wt, CollectCreatorFeeInput as x, RENT_SYSVAR_ADDRESS as xn, CPMM_POOL_STATE_SIZE as xt, getLaunchInstruction as y, RAYDIUM_DEVNET_IDS as yn, CPMM_POOL_OFFSETS as yt, withRemainingAccounts as z, websocketUrlFor as zn, CREATOR_FEE_ON_QUOTE as zt };
934
- //# sourceMappingURL=index-BDfGvmgF.d.ts.map
1184
+ export { QuoteBinding as $, assertClusterUrl as $n, CONSTANT_CURVE_TAG as $t, ClaimCreatorFeeInput as A, LAUNCHLAB_SELL_EXACT_IN as An, totalCurveFeeRate as At, cpmmBuyAccounts as B, TOKEN_2022_PROGRAM_ADDRESS as Bn, LaunchlabGlobalConfig as Bt, launchlabPlatformConfig as C, LAUNCHLAB_BUY_EXACT_IN as Cn, cpmmSwapBaseOutput as Ct, platformFeeVaultAddress as D, LAUNCHLAB_INITIALIZE as Dn, initialCurve as Dt, metadataAddress as E, LAUNCHLAB_GLOBAL_CONFIG_DISCRIMINATOR as En, curveSellExactIn as Et, fetchCreatorFees as F, RAYDIUM_DEVNET_IDS as Fn, CpmmAmmConfig as Ft, order as G, CLUSTER_ENDPOINTS as Gn, decodeLaunchlabGlobalConfig as Gt, launchlabBuyAccounts as H, VenueAccountSpec as Hn, LaunchlabPoolState as Ht, getClaimCreatorFeeInstructions as I, RAYDIUM_MAINNET_IDS as In, CpmmPoolState as It, buildMessage as J, DEVNET_HTTP as Jn, metaplexSymbol as Jt, BuildOptions as K, ClientConfig as Kn, decodeLaunchlabPlatformConfig as Kt, getCollectCreatorFeeInstructions as L, RENT_SYSVAR_ADDRESS as Ln, LAUNCHLAB_GLOBAL_CONFIG_HEAD_SIZE as Lt, CreatorFees as M, LAUNCH_TOTAL_BASE_SELL as Mn, CPMM_POOL_OFFSETS as Mt, claimCreatorFee as N, METAPLEX_PROGRAM_ADDRESS as Nn, CPMM_POOL_STATE_HEAD_SIZE as Nt, LaunchInput as O, LAUNCHLAB_PLATFORM_CONFIG_DISCRIMINATOR as On, preFeeAmount as Ot, collectCreatorFee as P, PLATFORM_ADMIN as Pn, CPMM_POOL_STATE_SIZE as Pt, MigratedCpmmPool as Q, GaboxRpcSubscriptions as Qn, tokenAccountOwnerAndMint as Qt, CpmmTradeAccountsInput as R, RaydiumClusterIds as Rn, LAUNCHLAB_PLATFORM_CONFIG_HEAD_SIZE as Rt, launchlabGlobalConfig as S, CPMM_SWAP_BASE_OUTPUT as Sn, cpmmSwapBaseInput as St, launchlabVaultAddress as T, LAUNCHLAB_CLAIM_CREATOR_FEE as Tn, curveBuyExactOut as Tt, launchlabBuyExactInAccounts as U, VenueInstructionAbi as Un, decodeCpmmAmmConfig as Ut, cpmmSellAccounts as V, TOKEN_PROGRAM_ADDRESS as Vn, LaunchlabPlatformConfig as Vt, launchlabSellAccounts as W, WSOL_MINT as Wn, decodeCpmmPool as Wt, CurveSettings as X, GaboxClient as Xn, token2022Symbol as Xt, withRemainingAccounts as Y, DEVNET_WS as Yn, mintDecimals as Yt, FindCpmmPoolOptions as Z, GaboxRpc as Zn, tokenAccountAmount as Zt, cpmmPoolAddress as _, ASSOCIATED_TOKEN_PROGRAM_ADDRESS as _n, CurveFeeRates as _t, decodeBase64 as a, LAUNCHLAB_STATUS_TRADE as an, RouteMode as ar, curveQuote as at, launchlabAuthority as b, CPMM_POOL_STATE_DISCRIMINATOR as bn, ceilDiv as bt, QuoteConfig as c, METADATA_SEED as cn, findCpmmPool as ct, fetchQuoteConfig as d, RAYDIUM_IDS as dn, quoteAccountFor as dt, CPMM_SEEDS as en, clusterNamedBy as er, ResolveVenueOptions as et, fetchQuoteDisplay as f, RaydiumIds as fn, resolveVenue as ft, cpmmCreatorFeeShare as g, sortedMints as gn, CpmmSwapSides as gt, cpmmAuthority as h, raydiumIds as hn, CpmmFeeRates as ht, MaybeAccount$1 as i, LAUNCHLAB_STATUS_MIGRATE as in, Route as ir, creatorFeeOnInput as it, CollectCreatorFeeInput as j, LAUNCH_SUPPLY as jn, CPMM_AMM_CONFIG_HEAD_SIZE as jt, getLaunchInstruction as k, LAUNCHLAB_POOL_STATE_DISCRIMINATOR as kn, remainingBase as kt, QuoteDisplay as l, MIGRATE_TO_CPMM as ln, newCurveBuyCost as lt, ata as m, compareAddresses as mn, wsolAccountFor as mt, CurveBuyExactInInput as n, LAUNCHLAB_SEEDS as nn, defaultRoute as nr, VenueKind as nt, readAccounts as o, LAUNCH_DECIMALS as on, RouteProvider as or, fetchCurveSettings as ot, isQuoteSupported as p, SHARE_FEE_RATE as pn, sellQuote as pt, GaboxTransactionMessage as q, Cluster as qn, decodeLaunchlabPool as qt, getCurveBuyExactInInstruction as r, LAUNCHLAB_STATUS_FUND as rn, websocketUrlFor as rr, cpmmPoolMatches as rt, QuoteAsset as s, METADATA_LIMITS as sn, fetchQuoteBinding as st, index_d_exports as t, CREATOR_FEE_ON_QUOTE as tn, createClient as tr, ResolvedVenue as tt, fetchQuoteAsset as u, RATE_DENOMINATOR as un, newCurveReserves as ut, creatorFeeVaultAddress as v, CPMM_AMM_CONFIG_DISCRIMINATOR as vn, CurveReserves as vt, launchlabPoolAddress as w, LAUNCHLAB_BUY_EXACT_OUT as wn, curveBuyExactIn as wt, launchlabEventAuthority as x, CPMM_SWAP_BASE_INPUT as xn, ceilDivRate as xt, creatorFeeVaultAuthority as y, CPMM_COLLECT_CREATOR_FEE as yn, LaunchParams as yt, LaunchlabTradeAccountsInput as z, SYSTEM_PROGRAM_ADDRESS as zn, LAUNCHLAB_POOL_STATE_HEAD_SIZE as zt };
1185
+ //# sourceMappingURL=index-CA0m7AKk.d.ts.map