@0dotxyz/p0-ts-sdk 2.3.0-alpha.3 → 2.3.0-alpha.5
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/index.cjs +6344 -375
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +38 -63
- package/dist/index.d.ts +38 -63
- package/dist/index.js +6344 -375
- package/dist/index.js.map +1 -1
- package/dist/vendor.cjs +6423 -284
- package/dist/vendor.cjs.map +1 -1
- package/dist/vendor.d.cts +1014 -110
- package/dist/vendor.d.ts +1014 -110
- package/dist/vendor.js +6413 -285
- package/dist/vendor.js.map +1 -1
- package/package.json +1 -1
package/dist/vendor.d.ts
CHANGED
|
@@ -27206,11 +27206,11 @@ interface TitanSwapQuoteResult {
|
|
|
27206
27206
|
timeTaken?: number;
|
|
27207
27207
|
}
|
|
27208
27208
|
declare function buildSwapQuoteResult(route: {
|
|
27209
|
-
inAmount: number;
|
|
27210
|
-
outAmount: number;
|
|
27209
|
+
inAmount: number | bigint;
|
|
27210
|
+
outAmount: number | bigint;
|
|
27211
27211
|
slippageBps: number;
|
|
27212
27212
|
platformFee?: {
|
|
27213
|
-
amount: number;
|
|
27213
|
+
amount: number | bigint;
|
|
27214
27214
|
fee_bps: number;
|
|
27215
27215
|
};
|
|
27216
27216
|
contextSlot?: number;
|
|
@@ -27613,6 +27613,221 @@ interface ExponentStripContext {
|
|
|
27613
27613
|
computeStrippedPtNative(syInNative: bigint): bigint;
|
|
27614
27614
|
}
|
|
27615
27615
|
|
|
27616
|
+
/**
|
|
27617
|
+
* Accounts required by `wrapper_merge` — the core instruction that merges PT **and**
|
|
27618
|
+
* redeems the resulting SY into the underlying **base** token in one go (so the buy leg can
|
|
27619
|
+
* swap a normal token, not the un-swappable SY). The 16 fixed accounts mirror the IDL's
|
|
27620
|
+
* `WrapperMerge` struct (same vault-side fields as `merge`, minus the SY destination order);
|
|
27621
|
+
* `remainingAccounts` is the assembled `[...redeem, ...cpi]` list and `redeemSyAccountsUntil`
|
|
27622
|
+
* marks the boundary between them.
|
|
27623
|
+
*/
|
|
27624
|
+
interface ExponentWrapperMergeAccounts {
|
|
27625
|
+
/** Position owner / signer (the marginfi account authority). */
|
|
27626
|
+
owner: PublicKey;
|
|
27627
|
+
/** Owner's SY token account (intermediate; the redeem consumes it). */
|
|
27628
|
+
syAta: PublicKey;
|
|
27629
|
+
/** The maturity vault address. */
|
|
27630
|
+
vault: PublicKey;
|
|
27631
|
+
/** `Vault.escrow_sy`. */
|
|
27632
|
+
escrowSy: PublicKey;
|
|
27633
|
+
/** Owner's YT token account (source; empty/0 after maturity). */
|
|
27634
|
+
ytAta: PublicKey;
|
|
27635
|
+
/** Owner's PT token account (source; holds the withdrawn PT). */
|
|
27636
|
+
ptAta: PublicKey;
|
|
27637
|
+
/** `Vault.mint_yt`. */
|
|
27638
|
+
mintYt: PublicKey;
|
|
27639
|
+
/** `Vault.mint_pt`. */
|
|
27640
|
+
mintPt: PublicKey;
|
|
27641
|
+
/** `Vault.authority`. */
|
|
27642
|
+
authority: PublicKey;
|
|
27643
|
+
/** `Vault.address_lookup_table`. */
|
|
27644
|
+
addressLookupTable: PublicKey;
|
|
27645
|
+
/** `Vault.yield_position` (the vault robot yield position). */
|
|
27646
|
+
yieldPosition: PublicKey;
|
|
27647
|
+
/** `Vault.sy_program`. */
|
|
27648
|
+
syProgram: PublicKey;
|
|
27649
|
+
/** SPL token program for the PT/YT/SY mints (defaults to classic Token). */
|
|
27650
|
+
tokenProgram?: PublicKey;
|
|
27651
|
+
/**
|
|
27652
|
+
* Assembled SY-program remaining accounts: the flavor's `redeem_sy` accounts first
|
|
27653
|
+
* (count = `redeemSyAccountsUntil`), then the vault's deduped `withdraw_sy ++ get_sy_state`
|
|
27654
|
+
* CPI accounts. The redeem's first account is the owner and keeps its signer flag.
|
|
27655
|
+
*/
|
|
27656
|
+
remainingAccounts: AccountMeta$1[];
|
|
27657
|
+
/** Number of leading `remainingAccounts` that are the flavor redeem accounts. */
|
|
27658
|
+
redeemSyAccountsUntil: number;
|
|
27659
|
+
}
|
|
27660
|
+
interface ResolveExponentWrapperMergeContextParams {
|
|
27661
|
+
connection: Connection;
|
|
27662
|
+
/** Position owner / signer (the marginfi account authority). */
|
|
27663
|
+
owner: PublicKey;
|
|
27664
|
+
/** The maturity vault, or… */
|
|
27665
|
+
vault?: PublicKey;
|
|
27666
|
+
/** …the `MarketTwo` address (its `vault` is read). One of `vault`/`market` is required. */
|
|
27667
|
+
market?: PublicKey;
|
|
27668
|
+
/**
|
|
27669
|
+
* The flavor's underlying **base** token (e.g. bulkSOL). Required — it isn't on the
|
|
27670
|
+
* vault; the caller supplies it (config). The redeem unwraps SY into this token.
|
|
27671
|
+
*/
|
|
27672
|
+
baseMint: PublicKey;
|
|
27673
|
+
/** Token program for the base mint (defaults to classic Token). */
|
|
27674
|
+
baseTokenProgram?: PublicKey;
|
|
27675
|
+
/** Token program for the PT/YT mints (Exponent uses classic Token). */
|
|
27676
|
+
ptYtTokenProgram?: PublicKey;
|
|
27677
|
+
/** Token program for the SY mint (may be token-2022). Defaults to classic Token. */
|
|
27678
|
+
syTokenProgram?: PublicKey;
|
|
27679
|
+
}
|
|
27680
|
+
/**
|
|
27681
|
+
* Resolved inputs for the roll's redeem leg: the `wrapper_merge` accounts, the SPL
|
|
27682
|
+
* stake-pool refresh that must run before it (so the SY↔base rate is current), the base
|
|
27683
|
+
* token the swap leg consumes, and a helper to size the redeemed base from the vault rates.
|
|
27684
|
+
*/
|
|
27685
|
+
interface ExponentWrapperMergeContext {
|
|
27686
|
+
vaultAddress: PublicKey;
|
|
27687
|
+
vault: ExponentVault;
|
|
27688
|
+
wrapperMergeAccounts: ExponentWrapperMergeAccounts;
|
|
27689
|
+
/**
|
|
27690
|
+
* Instruction(s) the flavor requires *before* `wrapper_merge` (for an SPL-stake-pool LST
|
|
27691
|
+
* like bulkSOL, the stake pool's `UpdateStakePoolBalance` refresh). Empty for flavors that
|
|
27692
|
+
* need none.
|
|
27693
|
+
*/
|
|
27694
|
+
preInstructions: TransactionInstruction[];
|
|
27695
|
+
/** The vault's address lookup table — add it to the transaction's lookup tables. */
|
|
27696
|
+
addressLookupTable: AddressLookupTableAccount;
|
|
27697
|
+
/** The redeemed underlying base token (swap-leg input). */
|
|
27698
|
+
baseToken: {
|
|
27699
|
+
mint: PublicKey;
|
|
27700
|
+
decimals: number;
|
|
27701
|
+
tokenProgram: PublicKey;
|
|
27702
|
+
};
|
|
27703
|
+
/** ATAs the bundle touches and must create idempotently (sy, pt, yt, base). */
|
|
27704
|
+
setupMints: {
|
|
27705
|
+
mint: PublicKey;
|
|
27706
|
+
tokenProgram: PublicKey;
|
|
27707
|
+
}[];
|
|
27708
|
+
/**
|
|
27709
|
+
* Native base the wrapper yields for a native PT amount: `merge` gives
|
|
27710
|
+
* `sy = floor(pt × sy_for_pt / pt_supply)`, then the redeem gives
|
|
27711
|
+
* `base = floor(sy × sy_exchange_rate)`. Feed into the swap-engine input sizing.
|
|
27712
|
+
*/
|
|
27713
|
+
computeRedeemedBaseNative(ptAmountNative: bigint): bigint;
|
|
27714
|
+
}
|
|
27715
|
+
|
|
27716
|
+
/**
|
|
27717
|
+
* The SY-program CPI account lists a CLMM `trade_pt` appends as remaining accounts.
|
|
27718
|
+
* Order (from the SDK's `ixTradePt`): `getSyState` ++ `getPositionState` ++ `depositSy`
|
|
27719
|
+
* ++ `withdrawSy`, then de-duplicated. Each is referenced by an index into the market's
|
|
27720
|
+
* address lookup table.
|
|
27721
|
+
*/
|
|
27722
|
+
interface ExponentMarketThreeCpiAccounts {
|
|
27723
|
+
getSyState: ExponentCpiInterfaceContext[];
|
|
27724
|
+
getPositionState: ExponentCpiInterfaceContext[];
|
|
27725
|
+
depositSy: ExponentCpiInterfaceContext[];
|
|
27726
|
+
withdrawSy: ExponentCpiInterfaceContext[];
|
|
27727
|
+
}
|
|
27728
|
+
/** The subset of an Exponent `MarketThree` (CLMM) pool account that `trade_pt` needs. */
|
|
27729
|
+
interface ExponentMarketThree {
|
|
27730
|
+
/** The pool's own address (`self_address` / the account key). */
|
|
27731
|
+
selfAddress: PublicKey;
|
|
27732
|
+
mintPt: PublicKey;
|
|
27733
|
+
mintSy: PublicKey;
|
|
27734
|
+
vault: PublicKey;
|
|
27735
|
+
/** The single `ticks` account holding the pool's tick tree (not per-tick-array accounts). */
|
|
27736
|
+
ticks: PublicKey;
|
|
27737
|
+
/** Pool PT liquidity escrow (`token_pt_escrow`). */
|
|
27738
|
+
tokenPtEscrow: PublicKey;
|
|
27739
|
+
/** Pool SY liquidity escrow (`token_sy_escrow`). */
|
|
27740
|
+
tokenSyEscrow: PublicKey;
|
|
27741
|
+
/** SY account holding treasury fees (`token_fee_treasury_sy`). */
|
|
27742
|
+
tokenFeeTreasurySy: PublicKey;
|
|
27743
|
+
/** PT account holding treasury fees (`token_fee_treasury_pt`). */
|
|
27744
|
+
tokenFeeTreasuryPt: PublicKey;
|
|
27745
|
+
addressLookupTable: PublicKey;
|
|
27746
|
+
syProgram: PublicKey;
|
|
27747
|
+
statusFlags: number;
|
|
27748
|
+
/** SY-program CPI account lists, referenced by ALT index. */
|
|
27749
|
+
cpiAccounts: ExponentMarketThreeCpiAccounts;
|
|
27750
|
+
}
|
|
27751
|
+
/**
|
|
27752
|
+
* `SwapDirection` arg of the CLMM `trade_pt` instruction (a `u8`). `SyToPt` buys PT with
|
|
27753
|
+
* SY (the roll's buy leg); `PtToSy` sells PT for SY.
|
|
27754
|
+
*/
|
|
27755
|
+
declare enum ExponentSwapDirection {
|
|
27756
|
+
PtToSy = 0,
|
|
27757
|
+
SyToPt = 1
|
|
27758
|
+
}
|
|
27759
|
+
/**
|
|
27760
|
+
* Accounts required by the CLMM `trade_pt`. The first 14 are the fixed
|
|
27761
|
+
* `#[derive(Accounts)]` accounts; `remainingAccounts` are the SY-program CPI accounts
|
|
27762
|
+
* (already resolved from the market ALT and de-duplicated).
|
|
27763
|
+
*/
|
|
27764
|
+
interface ExponentClmmTradePtAccounts {
|
|
27765
|
+
/** Trader / signer (the marginfi account authority). */
|
|
27766
|
+
trader: PublicKey;
|
|
27767
|
+
/** The `MarketThree` (CLMM pool) address. */
|
|
27768
|
+
market: PublicKey;
|
|
27769
|
+
/** The pool's `ticks` account. */
|
|
27770
|
+
ticks: PublicKey;
|
|
27771
|
+
/** Trader's SY token account (source of the SY spent buying PT). */
|
|
27772
|
+
tokenSyTrader: PublicKey;
|
|
27773
|
+
/** Trader's PT token account (destination of the bought PT). */
|
|
27774
|
+
tokenPtTrader: PublicKey;
|
|
27775
|
+
/** `MarketThree.token_sy_escrow`. */
|
|
27776
|
+
tokenSyEscrow: PublicKey;
|
|
27777
|
+
/** `MarketThree.token_pt_escrow`. */
|
|
27778
|
+
tokenPtEscrow: PublicKey;
|
|
27779
|
+
/** `MarketThree.address_lookup_table`. */
|
|
27780
|
+
addressLookupTable: PublicKey;
|
|
27781
|
+
/** `MarketThree.sy_program`. */
|
|
27782
|
+
syProgram: PublicKey;
|
|
27783
|
+
/** `MarketThree.token_fee_treasury_sy`. */
|
|
27784
|
+
tokenFeeTreasurySy: PublicKey;
|
|
27785
|
+
/** `MarketThree.token_fee_treasury_pt`. */
|
|
27786
|
+
tokenFeeTreasuryPt: PublicKey;
|
|
27787
|
+
/** SPL token program for the PT/SY mints (defaults to the classic Token program). */
|
|
27788
|
+
tokenProgram?: PublicKey;
|
|
27789
|
+
/**
|
|
27790
|
+
* SY-program CPI accounts (`getSyState` ++ `getPositionState` ++ `depositSy` ++
|
|
27791
|
+
* `withdrawSy`, de-duplicated), pubkeys already resolved from the market ALT. Appended
|
|
27792
|
+
* after the 14 fixed accounts.
|
|
27793
|
+
*/
|
|
27794
|
+
remainingAccounts: AccountMeta$1[];
|
|
27795
|
+
}
|
|
27796
|
+
interface ResolveExponentClmmTradePtContextParams {
|
|
27797
|
+
connection: Connection;
|
|
27798
|
+
/** Trader / signer (the marginfi account authority). */
|
|
27799
|
+
owner: PublicKey;
|
|
27800
|
+
/** The successor maturity's `MarketThree` (CLMM pool) where the new PT trades. */
|
|
27801
|
+
market: PublicKey;
|
|
27802
|
+
/** Token program for the PT mint (Exponent uses the classic Token program). */
|
|
27803
|
+
ptTokenProgram?: PublicKey;
|
|
27804
|
+
/** Token program for the SY mint. Defaults to classic Token. */
|
|
27805
|
+
syTokenProgram?: PublicKey;
|
|
27806
|
+
}
|
|
27807
|
+
/**
|
|
27808
|
+
* Resolved inputs for a native CLMM `trade_pt` (SY → PT) on an Exponent `MarketThree`:
|
|
27809
|
+
* the fully-resolved `trade_pt` accounts (including the ALT-derived SY-CPI remaining
|
|
27810
|
+
* accounts), the market ALT to add to the transaction's lookup tables, and the SY/PT
|
|
27811
|
+
* token info. Feed `tradePtAccounts` + `addressLookupTable` into the roll's buy leg.
|
|
27812
|
+
*/
|
|
27813
|
+
interface ExponentClmmTradePtContext {
|
|
27814
|
+
marketAddress: PublicKey;
|
|
27815
|
+
market: ExponentMarketThree;
|
|
27816
|
+
tradePtAccounts: ExponentClmmTradePtAccounts;
|
|
27817
|
+
/** The market's address lookup table account — must be carried by the transaction. */
|
|
27818
|
+
addressLookupTable: AddressLookupTableAccount;
|
|
27819
|
+
sy: {
|
|
27820
|
+
mint: PublicKey;
|
|
27821
|
+
decimals: number;
|
|
27822
|
+
tokenProgram: PublicKey;
|
|
27823
|
+
};
|
|
27824
|
+
pt: {
|
|
27825
|
+
mint: PublicKey;
|
|
27826
|
+
decimals: number;
|
|
27827
|
+
tokenProgram: PublicKey;
|
|
27828
|
+
};
|
|
27829
|
+
}
|
|
27830
|
+
|
|
27616
27831
|
/**
|
|
27617
27832
|
* Exponent Finance program IDs (mainnet), taken from the official SDK's
|
|
27618
27833
|
* `@exponent-labs/exponent-sdk` `environment.js`.
|
|
@@ -28219,113 +28434,802 @@ declare const EXPONENT_CORE_IDL: {
|
|
|
28219
28434
|
docs?: undefined;
|
|
28220
28435
|
})[];
|
|
28221
28436
|
};
|
|
28222
|
-
|
|
28223
|
-
/**
|
|
28224
|
-
* Exponent's high-precision `Number` is a little-endian U256 (`[u64; 4]`) scaled by 1e12
|
|
28225
|
-
* (`precise_number::ONE`). See exponent-core `libraries/precise_number`.
|
|
28226
|
-
*/
|
|
28227
|
-
declare const EXPONENT_NUMBER_DENOM: BigNumber;
|
|
28228
|
-
/** Convert a decoded Exponent `Number` (LE `[u64; 4]` U256) to a scaled BigNumber. */
|
|
28229
|
-
declare function exponentNumberToBigNumber(raw: unknown): BigNumber;
|
|
28230
|
-
/** Decode a raw `Vault` account buffer into {@link ExponentVault}. */
|
|
28231
|
-
declare function decodeExponentVault(data: Buffer): ExponentVault;
|
|
28232
|
-
/** Decode a `MarketTwo` account and return its `vault` address. */
|
|
28233
|
-
declare function decodeExponentMarketVault(data: Buffer): PublicKey;
|
|
28234
|
-
/** Decode a raw `MarketTwo` account buffer into {@link ExponentMarketTwo}. */
|
|
28235
|
-
declare function decodeExponentMarketTwo(data: Buffer): ExponentMarketTwo;
|
|
28236
|
-
/** Fetch + decode an Exponent `MarketTwo` account. */
|
|
28237
|
-
declare function fetchExponentMarketTwo(connection: Connection, market: PublicKey): Promise<ExponentMarketTwo>;
|
|
28238
|
-
/** Fetch + decode an Exponent `Vault` account. */
|
|
28239
|
-
declare function fetchExponentVault(connection: Connection, vault: PublicKey): Promise<ExponentVault>;
|
|
28240
|
-
/** Fetch a `MarketTwo` account and resolve + fetch its `Vault`. */
|
|
28241
|
-
declare function fetchExponentVaultFromMarket(connection: Connection, market: PublicKey): Promise<{
|
|
28242
|
-
vault: PublicKey;
|
|
28243
|
-
account: ExponentVault;
|
|
28244
|
-
}>;
|
|
28245
|
-
/** Read an SPL mint's decimals (classic + token-2022 share the offset-44 layout). */
|
|
28246
|
-
declare function getMintDecimals(connection: Connection, mint: PublicKey): Promise<number>;
|
|
28247
|
-
|
|
28248
|
-
/** Derive the Anchor event-CPI authority PDA for the Exponent core program. */
|
|
28249
|
-
declare function deriveExponentEventAuthority(): PublicKey;
|
|
28250
|
-
|
|
28251
|
-
/**
|
|
28252
|
-
* Resolve everything `makeRollPtTx` needs for an Exponent PT roll by decoding the maturity
|
|
28253
|
-
* `Vault` (every vault-side `merge` account is a `has_one` field on it), deriving the
|
|
28254
|
-
* owner's PT/YT/SY token accounts, and resolving the SY-program CPI remaining accounts
|
|
28255
|
-
* (`get_sy_state ++ withdraw_sy`) from the vault's address lookup table.
|
|
28256
|
-
*/
|
|
28257
|
-
declare function resolveExponentMergeContext(params: ResolveExponentMergeContextParams): Promise<ExponentMergeContext>;
|
|
28258
|
-
/**
|
|
28259
|
-
* Resolve everything `makeRollPtTx` needs to buy the successor PT natively (SY → PT,
|
|
28260
|
-
* no unwrap, no external aggregator) by trading on the successor maturity's `MarketTwo`.
|
|
28261
|
-
*
|
|
28262
|
-
* Decodes the market, resolves the SY-program CPI accounts from the market's address
|
|
28263
|
-
* lookup table (every `CpiInterfaceContext` is an ALT index), and derives the owner's
|
|
28264
|
-
* SY/PT token accounts. The returned {@link ExponentTradePtContext.addressLookupTable}
|
|
28265
|
-
* must be added to the transaction's lookup tables.
|
|
28266
|
-
*/
|
|
28267
|
-
declare function resolveExponentTradePtContext(params: ResolveExponentTradePtContextParams): Promise<ExponentTradePtContext>;
|
|
28268
|
-
/**
|
|
28269
|
-
* Resolve everything needed to `strip` SY → PT + YT on an Exponent vault (the buy leg that
|
|
28270
|
-
* *mints* the successor PT, unbounded by AMM depth). Decodes the vault, derives the owner's
|
|
28271
|
-
* SY/PT/YT token accounts, resolves the `deposit_sy` CPI remaining accounts from the vault's
|
|
28272
|
-
* address lookup table, and exposes the last-seen SY exchange rate for sizing the minted PT.
|
|
28273
|
-
*/
|
|
28274
|
-
declare function resolveExponentStripContext(params: ResolveExponentStripContextParams): Promise<ExponentStripContext>;
|
|
28275
|
-
|
|
28276
|
-
/**
|
|
28277
|
-
* Build the Exponent `merge(amount)` instruction — redeems `amount` PT (post-maturity,
|
|
28278
|
-
* 1:1, no AMM/slippage) into SY at `sySrcDstAta`.
|
|
28279
|
-
*
|
|
28280
|
-
* @param accounts resolved merge accounts (see {@link ExponentMergeAccounts})
|
|
28281
|
-
* @param amountNative PT amount to redeem, in native units (u64)
|
|
28282
|
-
*/
|
|
28283
|
-
declare function makeExponentMergeIx(accounts: ExponentMergeAccounts, amountNative: bigint): TransactionInstruction;
|
|
28284
|
-
/**
|
|
28285
|
-
* Signed `trade_pt` args for **buying** PT with SY (the roll's buy leg).
|
|
28286
|
-
*
|
|
28287
|
-
* The program's convention is signed-from-the-trader's-perspective: a buy makes PT flow
|
|
28288
|
-
* *to* the trader (`net_trader_pt > 0`) and SY flow *away* (`sy_constraint < 0`, the most
|
|
28289
|
-
* negative SY balance change the trader will tolerate — i.e. the max SY spent).
|
|
28290
|
-
*
|
|
28291
|
-
* @param ptOutNative exact PT the trader receives (native u64). Set to a conservative
|
|
28292
|
-
* floor; the trade gives exactly this many PT.
|
|
28293
|
-
* @param maxSyInNative max SY the trader is willing to spend (native u64).
|
|
28294
|
-
*/
|
|
28295
|
-
declare function exponentBuyPtArgs({ ptOutNative, maxSyInNative, }: {
|
|
28296
|
-
ptOutNative: bigint;
|
|
28297
|
-
maxSyInNative: bigint;
|
|
28298
|
-
}): {
|
|
28299
|
-
netTraderPt: bigint;
|
|
28300
|
-
syConstraint: bigint;
|
|
28301
|
-
};
|
|
28302
|
-
/**
|
|
28303
|
-
* Build the Exponent `trade_pt(net_trader_pt, sy_constraint)` instruction — an
|
|
28304
|
-
* implied-APY AMM trade of SY ↔ PT on a `MarketTwo`. For a buy use {@link exponentBuyPtArgs}.
|
|
28305
|
-
*
|
|
28306
|
-
* Pricing PT reads the SY exchange rate on-chain, so `accounts.remainingAccounts` (the
|
|
28307
|
-
* flavor's SY-program CPI accounts, resolved from the market ALT) are appended after the
|
|
28308
|
-
* 12 fixed accounts, and the transaction must carry the market's address lookup table.
|
|
28309
|
-
*
|
|
28310
|
-
* @param accounts resolved trade accounts (see {@link ExponentTradePtAccounts})
|
|
28311
|
-
* @param args signed `net_trader_pt` / `sy_constraint` (i64 LE)
|
|
28312
|
-
*/
|
|
28313
|
-
declare function makeExponentTradePtIx(accounts: ExponentTradePtAccounts, args: {
|
|
28314
|
-
netTraderPt: bigint;
|
|
28315
|
-
syConstraint: bigint;
|
|
28316
|
-
}): TransactionInstruction;
|
|
28317
28437
|
/**
|
|
28318
|
-
*
|
|
28319
|
-
*
|
|
28320
|
-
*
|
|
28321
|
-
*
|
|
28322
|
-
* Pricing PT/YT reads the SY rate on-chain, so `accounts.remainingAccounts` (the flavor's
|
|
28323
|
-
* `deposit_sy` CPI accounts, resolved from the vault ALT) are appended after the 15 fixed
|
|
28324
|
-
* accounts, and the transaction must carry the vault's address lookup table.
|
|
28325
|
-
*
|
|
28326
|
-
* @param accounts resolved strip accounts (see {@link ExponentStripAccounts})
|
|
28327
|
-
* @param amountNative SY amount to strip, in native units (u64)
|
|
28438
|
+
* Raw Exponent CLMM IDL (`@exponent-labs/exponent-clmm-idl`, program `XPC1MM…` /
|
|
28439
|
+
* "MarketThree"). Used to Borsh-decode the `MarketThree` pool account; its `address`
|
|
28440
|
+
* field is the live CLMM program id. The matured-PT roll buys the successor PT directly
|
|
28441
|
+
* on this PT/SY CLMM via `trade_pt` (SY → PT), with no base round-trip or aggregator.
|
|
28328
28442
|
*/
|
|
28329
|
-
declare
|
|
28443
|
+
declare const EXPONENT_CLMM_IDL: {
|
|
28444
|
+
address: string;
|
|
28445
|
+
metadata: {
|
|
28446
|
+
name: string;
|
|
28447
|
+
version: string;
|
|
28448
|
+
spec: string;
|
|
28449
|
+
description: string;
|
|
28450
|
+
};
|
|
28451
|
+
instructions: ({
|
|
28452
|
+
name: string;
|
|
28453
|
+
discriminator: number[];
|
|
28454
|
+
accounts: ({
|
|
28455
|
+
name: string;
|
|
28456
|
+
writable: boolean;
|
|
28457
|
+
signer?: undefined;
|
|
28458
|
+
} | {
|
|
28459
|
+
name: string;
|
|
28460
|
+
signer: boolean;
|
|
28461
|
+
writable?: undefined;
|
|
28462
|
+
} | {
|
|
28463
|
+
name: string;
|
|
28464
|
+
writable: boolean;
|
|
28465
|
+
signer: boolean;
|
|
28466
|
+
} | {
|
|
28467
|
+
name: string;
|
|
28468
|
+
writable?: undefined;
|
|
28469
|
+
signer?: undefined;
|
|
28470
|
+
})[];
|
|
28471
|
+
args: {
|
|
28472
|
+
name: string;
|
|
28473
|
+
type: string;
|
|
28474
|
+
}[];
|
|
28475
|
+
returns: {
|
|
28476
|
+
defined: {
|
|
28477
|
+
name: string;
|
|
28478
|
+
};
|
|
28479
|
+
};
|
|
28480
|
+
docs?: undefined;
|
|
28481
|
+
} | {
|
|
28482
|
+
name: string;
|
|
28483
|
+
discriminator: number[];
|
|
28484
|
+
accounts: ({
|
|
28485
|
+
name: string;
|
|
28486
|
+
writable: boolean;
|
|
28487
|
+
signer: boolean;
|
|
28488
|
+
docs?: undefined;
|
|
28489
|
+
} | {
|
|
28490
|
+
name: string;
|
|
28491
|
+
writable: boolean;
|
|
28492
|
+
signer?: undefined;
|
|
28493
|
+
docs?: undefined;
|
|
28494
|
+
} | {
|
|
28495
|
+
name: string;
|
|
28496
|
+
docs: string[];
|
|
28497
|
+
writable?: undefined;
|
|
28498
|
+
signer?: undefined;
|
|
28499
|
+
} | {
|
|
28500
|
+
name: string;
|
|
28501
|
+
writable?: undefined;
|
|
28502
|
+
signer?: undefined;
|
|
28503
|
+
docs?: undefined;
|
|
28504
|
+
})[];
|
|
28505
|
+
args: ({
|
|
28506
|
+
name: string;
|
|
28507
|
+
type: string;
|
|
28508
|
+
} | {
|
|
28509
|
+
name: string;
|
|
28510
|
+
type: {
|
|
28511
|
+
option: string;
|
|
28512
|
+
};
|
|
28513
|
+
})[];
|
|
28514
|
+
returns: {
|
|
28515
|
+
defined: {
|
|
28516
|
+
name: string;
|
|
28517
|
+
};
|
|
28518
|
+
};
|
|
28519
|
+
docs?: undefined;
|
|
28520
|
+
} | {
|
|
28521
|
+
name: string;
|
|
28522
|
+
discriminator: number[];
|
|
28523
|
+
accounts: ({
|
|
28524
|
+
name: string;
|
|
28525
|
+
writable: boolean;
|
|
28526
|
+
signer?: undefined;
|
|
28527
|
+
} | {
|
|
28528
|
+
name: string;
|
|
28529
|
+
signer: boolean;
|
|
28530
|
+
writable?: undefined;
|
|
28531
|
+
} | {
|
|
28532
|
+
name: string;
|
|
28533
|
+
writable: boolean;
|
|
28534
|
+
signer: boolean;
|
|
28535
|
+
} | {
|
|
28536
|
+
name: string;
|
|
28537
|
+
writable?: undefined;
|
|
28538
|
+
signer?: undefined;
|
|
28539
|
+
})[];
|
|
28540
|
+
args: {
|
|
28541
|
+
name: string;
|
|
28542
|
+
type: {
|
|
28543
|
+
defined: {
|
|
28544
|
+
name: string;
|
|
28545
|
+
};
|
|
28546
|
+
};
|
|
28547
|
+
}[];
|
|
28548
|
+
returns?: undefined;
|
|
28549
|
+
docs?: undefined;
|
|
28550
|
+
} | {
|
|
28551
|
+
name: string;
|
|
28552
|
+
discriminator: number[];
|
|
28553
|
+
accounts: ({
|
|
28554
|
+
name: string;
|
|
28555
|
+
writable: boolean;
|
|
28556
|
+
signer: boolean;
|
|
28557
|
+
} | {
|
|
28558
|
+
name: string;
|
|
28559
|
+
writable: boolean;
|
|
28560
|
+
signer?: undefined;
|
|
28561
|
+
} | {
|
|
28562
|
+
name: string;
|
|
28563
|
+
writable?: undefined;
|
|
28564
|
+
signer?: undefined;
|
|
28565
|
+
})[];
|
|
28566
|
+
args: ({
|
|
28567
|
+
name: string;
|
|
28568
|
+
type: string;
|
|
28569
|
+
} | {
|
|
28570
|
+
name: string;
|
|
28571
|
+
type: {
|
|
28572
|
+
option: string;
|
|
28573
|
+
};
|
|
28574
|
+
})[];
|
|
28575
|
+
returns?: undefined;
|
|
28576
|
+
docs?: undefined;
|
|
28577
|
+
} | {
|
|
28578
|
+
name: string;
|
|
28579
|
+
docs: string[];
|
|
28580
|
+
discriminator: number[];
|
|
28581
|
+
accounts: ({
|
|
28582
|
+
name: string;
|
|
28583
|
+
writable: boolean;
|
|
28584
|
+
signer: boolean;
|
|
28585
|
+
docs?: undefined;
|
|
28586
|
+
} | {
|
|
28587
|
+
name: string;
|
|
28588
|
+
signer: boolean;
|
|
28589
|
+
writable?: undefined;
|
|
28590
|
+
docs?: undefined;
|
|
28591
|
+
} | {
|
|
28592
|
+
name: string;
|
|
28593
|
+
writable?: undefined;
|
|
28594
|
+
signer?: undefined;
|
|
28595
|
+
docs?: undefined;
|
|
28596
|
+
} | {
|
|
28597
|
+
name: string;
|
|
28598
|
+
docs: string[];
|
|
28599
|
+
writable: boolean;
|
|
28600
|
+
signer?: undefined;
|
|
28601
|
+
} | {
|
|
28602
|
+
name: string;
|
|
28603
|
+
writable: boolean;
|
|
28604
|
+
signer?: undefined;
|
|
28605
|
+
docs?: undefined;
|
|
28606
|
+
} | {
|
|
28607
|
+
name: string;
|
|
28608
|
+
docs: string[];
|
|
28609
|
+
writable?: undefined;
|
|
28610
|
+
signer?: undefined;
|
|
28611
|
+
})[];
|
|
28612
|
+
args: ({
|
|
28613
|
+
name: string;
|
|
28614
|
+
type: string;
|
|
28615
|
+
} | {
|
|
28616
|
+
name: string;
|
|
28617
|
+
type: {
|
|
28618
|
+
defined: {
|
|
28619
|
+
name: string;
|
|
28620
|
+
};
|
|
28621
|
+
};
|
|
28622
|
+
})[];
|
|
28623
|
+
returns: {
|
|
28624
|
+
defined: {
|
|
28625
|
+
name: string;
|
|
28626
|
+
};
|
|
28627
|
+
};
|
|
28628
|
+
} | {
|
|
28629
|
+
name: string;
|
|
28630
|
+
discriminator: number[];
|
|
28631
|
+
accounts: ({
|
|
28632
|
+
name: string;
|
|
28633
|
+
writable: boolean;
|
|
28634
|
+
signer: boolean;
|
|
28635
|
+
docs?: undefined;
|
|
28636
|
+
} | {
|
|
28637
|
+
name: string;
|
|
28638
|
+
writable: boolean;
|
|
28639
|
+
signer?: undefined;
|
|
28640
|
+
docs?: undefined;
|
|
28641
|
+
} | {
|
|
28642
|
+
name: string;
|
|
28643
|
+
docs: string[];
|
|
28644
|
+
writable: boolean;
|
|
28645
|
+
signer?: undefined;
|
|
28646
|
+
} | {
|
|
28647
|
+
name: string;
|
|
28648
|
+
writable?: undefined;
|
|
28649
|
+
signer?: undefined;
|
|
28650
|
+
docs?: undefined;
|
|
28651
|
+
})[];
|
|
28652
|
+
args: ({
|
|
28653
|
+
name: string;
|
|
28654
|
+
type: string;
|
|
28655
|
+
} | {
|
|
28656
|
+
name: string;
|
|
28657
|
+
type: {
|
|
28658
|
+
defined: {
|
|
28659
|
+
name: string;
|
|
28660
|
+
};
|
|
28661
|
+
option?: undefined;
|
|
28662
|
+
};
|
|
28663
|
+
} | {
|
|
28664
|
+
name: string;
|
|
28665
|
+
type: {
|
|
28666
|
+
option: string;
|
|
28667
|
+
defined?: undefined;
|
|
28668
|
+
};
|
|
28669
|
+
})[];
|
|
28670
|
+
returns: {
|
|
28671
|
+
defined: {
|
|
28672
|
+
name: string;
|
|
28673
|
+
};
|
|
28674
|
+
};
|
|
28675
|
+
docs?: undefined;
|
|
28676
|
+
} | {
|
|
28677
|
+
name: string;
|
|
28678
|
+
discriminator: number[];
|
|
28679
|
+
accounts: ({
|
|
28680
|
+
name: string;
|
|
28681
|
+
writable: boolean;
|
|
28682
|
+
signer: boolean;
|
|
28683
|
+
docs?: undefined;
|
|
28684
|
+
} | {
|
|
28685
|
+
name: string;
|
|
28686
|
+
writable: boolean;
|
|
28687
|
+
signer?: undefined;
|
|
28688
|
+
docs?: undefined;
|
|
28689
|
+
} | {
|
|
28690
|
+
name: string;
|
|
28691
|
+
docs: string[];
|
|
28692
|
+
writable: boolean;
|
|
28693
|
+
signer?: undefined;
|
|
28694
|
+
} | {
|
|
28695
|
+
name: string;
|
|
28696
|
+
docs: string[];
|
|
28697
|
+
writable?: undefined;
|
|
28698
|
+
signer?: undefined;
|
|
28699
|
+
} | {
|
|
28700
|
+
name: string;
|
|
28701
|
+
writable?: undefined;
|
|
28702
|
+
signer?: undefined;
|
|
28703
|
+
docs?: undefined;
|
|
28704
|
+
})[];
|
|
28705
|
+
args: {
|
|
28706
|
+
name: string;
|
|
28707
|
+
type: string;
|
|
28708
|
+
}[];
|
|
28709
|
+
returns: {
|
|
28710
|
+
defined: {
|
|
28711
|
+
name: string;
|
|
28712
|
+
};
|
|
28713
|
+
};
|
|
28714
|
+
docs?: undefined;
|
|
28715
|
+
} | {
|
|
28716
|
+
name: string;
|
|
28717
|
+
discriminator: number[];
|
|
28718
|
+
accounts: ({
|
|
28719
|
+
name: string;
|
|
28720
|
+
writable: boolean;
|
|
28721
|
+
signer: boolean;
|
|
28722
|
+
docs?: undefined;
|
|
28723
|
+
} | {
|
|
28724
|
+
name: string;
|
|
28725
|
+
writable: boolean;
|
|
28726
|
+
signer?: undefined;
|
|
28727
|
+
docs?: undefined;
|
|
28728
|
+
} | {
|
|
28729
|
+
name: string;
|
|
28730
|
+
docs: string[];
|
|
28731
|
+
writable: boolean;
|
|
28732
|
+
signer?: undefined;
|
|
28733
|
+
} | {
|
|
28734
|
+
name: string;
|
|
28735
|
+
writable?: undefined;
|
|
28736
|
+
signer?: undefined;
|
|
28737
|
+
docs?: undefined;
|
|
28738
|
+
})[];
|
|
28739
|
+
args: {
|
|
28740
|
+
name: string;
|
|
28741
|
+
type: string;
|
|
28742
|
+
}[];
|
|
28743
|
+
returns?: undefined;
|
|
28744
|
+
docs?: undefined;
|
|
28745
|
+
})[];
|
|
28746
|
+
accounts: {
|
|
28747
|
+
name: string;
|
|
28748
|
+
discriminator: number[];
|
|
28749
|
+
}[];
|
|
28750
|
+
events: {
|
|
28751
|
+
name: string;
|
|
28752
|
+
discriminator: number[];
|
|
28753
|
+
}[];
|
|
28754
|
+
errors: {
|
|
28755
|
+
code: number;
|
|
28756
|
+
name: string;
|
|
28757
|
+
msg: string;
|
|
28758
|
+
}[];
|
|
28759
|
+
types: ({
|
|
28760
|
+
name: string;
|
|
28761
|
+
type: {
|
|
28762
|
+
kind: string;
|
|
28763
|
+
fields: ({
|
|
28764
|
+
name: string;
|
|
28765
|
+
type: string;
|
|
28766
|
+
} | {
|
|
28767
|
+
name: string;
|
|
28768
|
+
type: {
|
|
28769
|
+
option: string;
|
|
28770
|
+
defined?: undefined;
|
|
28771
|
+
};
|
|
28772
|
+
} | {
|
|
28773
|
+
name: string;
|
|
28774
|
+
type: {
|
|
28775
|
+
defined: {
|
|
28776
|
+
name: string;
|
|
28777
|
+
};
|
|
28778
|
+
option?: undefined;
|
|
28779
|
+
};
|
|
28780
|
+
})[];
|
|
28781
|
+
variants?: undefined;
|
|
28782
|
+
};
|
|
28783
|
+
docs?: undefined;
|
|
28784
|
+
repr?: undefined;
|
|
28785
|
+
} | {
|
|
28786
|
+
name: string;
|
|
28787
|
+
type: {
|
|
28788
|
+
kind: string;
|
|
28789
|
+
variants: ({
|
|
28790
|
+
name: string;
|
|
28791
|
+
fields?: undefined;
|
|
28792
|
+
} | {
|
|
28793
|
+
name: string;
|
|
28794
|
+
fields: string[];
|
|
28795
|
+
})[];
|
|
28796
|
+
fields?: undefined;
|
|
28797
|
+
};
|
|
28798
|
+
docs?: undefined;
|
|
28799
|
+
repr?: undefined;
|
|
28800
|
+
} | {
|
|
28801
|
+
name: string;
|
|
28802
|
+
type: {
|
|
28803
|
+
kind: string;
|
|
28804
|
+
fields: ({
|
|
28805
|
+
name: string;
|
|
28806
|
+
docs: string[];
|
|
28807
|
+
type: string;
|
|
28808
|
+
} | {
|
|
28809
|
+
name: string;
|
|
28810
|
+
type: string;
|
|
28811
|
+
docs?: undefined;
|
|
28812
|
+
} | {
|
|
28813
|
+
name: string;
|
|
28814
|
+
type: {
|
|
28815
|
+
array: (string | number)[];
|
|
28816
|
+
};
|
|
28817
|
+
docs?: undefined;
|
|
28818
|
+
})[];
|
|
28819
|
+
variants?: undefined;
|
|
28820
|
+
};
|
|
28821
|
+
docs?: undefined;
|
|
28822
|
+
repr?: undefined;
|
|
28823
|
+
} | {
|
|
28824
|
+
name: string;
|
|
28825
|
+
docs: string[];
|
|
28826
|
+
type: {
|
|
28827
|
+
kind: string;
|
|
28828
|
+
fields: ({
|
|
28829
|
+
name: string;
|
|
28830
|
+
docs: string[];
|
|
28831
|
+
type: {
|
|
28832
|
+
vec: {
|
|
28833
|
+
defined: {
|
|
28834
|
+
name: string;
|
|
28835
|
+
};
|
|
28836
|
+
vec?: undefined;
|
|
28837
|
+
};
|
|
28838
|
+
};
|
|
28839
|
+
} | {
|
|
28840
|
+
name: string;
|
|
28841
|
+
docs: string[];
|
|
28842
|
+
type: {
|
|
28843
|
+
vec: {
|
|
28844
|
+
vec: {
|
|
28845
|
+
defined: {
|
|
28846
|
+
name: string;
|
|
28847
|
+
};
|
|
28848
|
+
};
|
|
28849
|
+
defined?: undefined;
|
|
28850
|
+
};
|
|
28851
|
+
};
|
|
28852
|
+
})[];
|
|
28853
|
+
variants?: undefined;
|
|
28854
|
+
};
|
|
28855
|
+
repr?: undefined;
|
|
28856
|
+
} | {
|
|
28857
|
+
name: string;
|
|
28858
|
+
docs: string[];
|
|
28859
|
+
type: {
|
|
28860
|
+
kind: string;
|
|
28861
|
+
fields: ({
|
|
28862
|
+
name: string;
|
|
28863
|
+
docs: string[];
|
|
28864
|
+
type: string;
|
|
28865
|
+
} | {
|
|
28866
|
+
name: string;
|
|
28867
|
+
type: string;
|
|
28868
|
+
docs?: undefined;
|
|
28869
|
+
} | {
|
|
28870
|
+
name: string;
|
|
28871
|
+
type: {
|
|
28872
|
+
defined: {
|
|
28873
|
+
name: string;
|
|
28874
|
+
};
|
|
28875
|
+
};
|
|
28876
|
+
docs?: undefined;
|
|
28877
|
+
})[];
|
|
28878
|
+
variants?: undefined;
|
|
28879
|
+
};
|
|
28880
|
+
repr?: undefined;
|
|
28881
|
+
} | {
|
|
28882
|
+
name: string;
|
|
28883
|
+
type: {
|
|
28884
|
+
kind: string;
|
|
28885
|
+
variants: ({
|
|
28886
|
+
name: string;
|
|
28887
|
+
fields: string[];
|
|
28888
|
+
} | {
|
|
28889
|
+
name: string;
|
|
28890
|
+
fields: {
|
|
28891
|
+
name: string;
|
|
28892
|
+
type: {
|
|
28893
|
+
defined: {
|
|
28894
|
+
name: string;
|
|
28895
|
+
};
|
|
28896
|
+
};
|
|
28897
|
+
}[];
|
|
28898
|
+
} | {
|
|
28899
|
+
name: string;
|
|
28900
|
+
fields: {
|
|
28901
|
+
name: string;
|
|
28902
|
+
type: string;
|
|
28903
|
+
}[];
|
|
28904
|
+
})[];
|
|
28905
|
+
fields?: undefined;
|
|
28906
|
+
};
|
|
28907
|
+
docs?: undefined;
|
|
28908
|
+
repr?: undefined;
|
|
28909
|
+
} | {
|
|
28910
|
+
name: string;
|
|
28911
|
+
docs: string[];
|
|
28912
|
+
repr: {
|
|
28913
|
+
kind: string;
|
|
28914
|
+
};
|
|
28915
|
+
type: {
|
|
28916
|
+
kind: string;
|
|
28917
|
+
fields: {
|
|
28918
|
+
array: (string | number)[];
|
|
28919
|
+
}[];
|
|
28920
|
+
variants?: undefined;
|
|
28921
|
+
};
|
|
28922
|
+
} | {
|
|
28923
|
+
name: string;
|
|
28924
|
+
docs: string[];
|
|
28925
|
+
type: {
|
|
28926
|
+
kind: string;
|
|
28927
|
+
fields: ({
|
|
28928
|
+
name: string;
|
|
28929
|
+
docs: string[];
|
|
28930
|
+
type: string;
|
|
28931
|
+
} | {
|
|
28932
|
+
name: string;
|
|
28933
|
+
docs: string[];
|
|
28934
|
+
type: {
|
|
28935
|
+
defined: {
|
|
28936
|
+
name: string;
|
|
28937
|
+
};
|
|
28938
|
+
};
|
|
28939
|
+
} | {
|
|
28940
|
+
name: string;
|
|
28941
|
+
type: {
|
|
28942
|
+
defined: {
|
|
28943
|
+
name: string;
|
|
28944
|
+
};
|
|
28945
|
+
};
|
|
28946
|
+
docs?: undefined;
|
|
28947
|
+
})[];
|
|
28948
|
+
variants?: undefined;
|
|
28949
|
+
};
|
|
28950
|
+
repr?: undefined;
|
|
28951
|
+
} | {
|
|
28952
|
+
name: string;
|
|
28953
|
+
type: {
|
|
28954
|
+
kind: string;
|
|
28955
|
+
fields: {
|
|
28956
|
+
name: string;
|
|
28957
|
+
type: {
|
|
28958
|
+
vec: string;
|
|
28959
|
+
};
|
|
28960
|
+
}[];
|
|
28961
|
+
variants?: undefined;
|
|
28962
|
+
};
|
|
28963
|
+
docs?: undefined;
|
|
28964
|
+
repr?: undefined;
|
|
28965
|
+
} | {
|
|
28966
|
+
name: string;
|
|
28967
|
+
type: {
|
|
28968
|
+
kind: string;
|
|
28969
|
+
fields: ({
|
|
28970
|
+
name: string;
|
|
28971
|
+
docs: string[];
|
|
28972
|
+
type: string;
|
|
28973
|
+
} | {
|
|
28974
|
+
name: string;
|
|
28975
|
+
docs: string[];
|
|
28976
|
+
type: {
|
|
28977
|
+
array: (string | number)[];
|
|
28978
|
+
defined?: undefined;
|
|
28979
|
+
vec?: undefined;
|
|
28980
|
+
};
|
|
28981
|
+
} | {
|
|
28982
|
+
name: string;
|
|
28983
|
+
docs: string[];
|
|
28984
|
+
type: {
|
|
28985
|
+
defined: {
|
|
28986
|
+
name: string;
|
|
28987
|
+
};
|
|
28988
|
+
array?: undefined;
|
|
28989
|
+
vec?: undefined;
|
|
28990
|
+
};
|
|
28991
|
+
} | {
|
|
28992
|
+
name: string;
|
|
28993
|
+
type: string;
|
|
28994
|
+
docs?: undefined;
|
|
28995
|
+
} | {
|
|
28996
|
+
name: string;
|
|
28997
|
+
type: {
|
|
28998
|
+
vec: {
|
|
28999
|
+
defined: {
|
|
29000
|
+
name: string;
|
|
29001
|
+
};
|
|
29002
|
+
};
|
|
29003
|
+
array?: undefined;
|
|
29004
|
+
defined?: undefined;
|
|
29005
|
+
};
|
|
29006
|
+
docs?: undefined;
|
|
29007
|
+
} | {
|
|
29008
|
+
name: string;
|
|
29009
|
+
type: {
|
|
29010
|
+
defined: {
|
|
29011
|
+
name: string;
|
|
29012
|
+
};
|
|
29013
|
+
array?: undefined;
|
|
29014
|
+
vec?: undefined;
|
|
29015
|
+
};
|
|
29016
|
+
docs?: undefined;
|
|
29017
|
+
})[];
|
|
29018
|
+
variants?: undefined;
|
|
29019
|
+
};
|
|
29020
|
+
docs?: undefined;
|
|
29021
|
+
repr?: undefined;
|
|
29022
|
+
})[];
|
|
29023
|
+
};
|
|
29024
|
+
|
|
29025
|
+
/**
|
|
29026
|
+
* Exponent's high-precision `Number` is a little-endian U256 (`[u64; 4]`) scaled by 1e12
|
|
29027
|
+
* (`precise_number::ONE`). See exponent-core `libraries/precise_number`.
|
|
29028
|
+
*/
|
|
29029
|
+
declare const EXPONENT_NUMBER_DENOM: BigNumber;
|
|
29030
|
+
/** Convert a decoded Exponent `Number` (LE `[u64; 4]` U256) to a scaled BigNumber. */
|
|
29031
|
+
declare function exponentNumberToBigNumber(raw: unknown): BigNumber;
|
|
29032
|
+
/** Decode a raw `Vault` account buffer into {@link ExponentVault}. */
|
|
29033
|
+
declare function decodeExponentVault(data: Buffer): ExponentVault;
|
|
29034
|
+
/** Decode a `MarketTwo` account and return its `vault` address. */
|
|
29035
|
+
declare function decodeExponentMarketVault(data: Buffer): PublicKey;
|
|
29036
|
+
/** Decode a raw `MarketTwo` account buffer into {@link ExponentMarketTwo}. */
|
|
29037
|
+
declare function decodeExponentMarketTwo(data: Buffer): ExponentMarketTwo;
|
|
29038
|
+
/** Fetch + decode an Exponent `MarketTwo` account. */
|
|
29039
|
+
declare function fetchExponentMarketTwo(connection: Connection, market: PublicKey): Promise<ExponentMarketTwo>;
|
|
29040
|
+
/** Decode a raw `MarketThree` (CLMM) pool account buffer into {@link ExponentMarketThree}. */
|
|
29041
|
+
declare function decodeExponentMarketThree(data: Buffer): ExponentMarketThree;
|
|
29042
|
+
/** Fetch + decode an Exponent `MarketThree` (CLMM) pool account. */
|
|
29043
|
+
declare function fetchExponentMarketThree(connection: Connection, market: PublicKey): Promise<ExponentMarketThree>;
|
|
29044
|
+
/** Fetch + decode an Exponent `Vault` account. */
|
|
29045
|
+
declare function fetchExponentVault(connection: Connection, vault: PublicKey): Promise<ExponentVault>;
|
|
29046
|
+
/** Fetch a `MarketTwo` account and resolve + fetch its `Vault`. */
|
|
29047
|
+
declare function fetchExponentVaultFromMarket(connection: Connection, market: PublicKey): Promise<{
|
|
29048
|
+
vault: PublicKey;
|
|
29049
|
+
account: ExponentVault;
|
|
29050
|
+
}>;
|
|
29051
|
+
/** Read an SPL mint's decimals (classic + token-2022 share the offset-44 layout). */
|
|
29052
|
+
declare function getMintDecimals(connection: Connection, mint: PublicKey): Promise<number>;
|
|
29053
|
+
|
|
29054
|
+
/** Derive the Anchor event-CPI authority PDA for the Exponent core program. */
|
|
29055
|
+
declare function deriveExponentEventAuthority(): PublicKey;
|
|
29056
|
+
/** Derive the Anchor event-CPI authority PDA for the Exponent CLMM (`MarketThree`) program. */
|
|
29057
|
+
declare function deriveExponentClmmEventAuthority(): PublicKey;
|
|
29058
|
+
|
|
29059
|
+
/**
|
|
29060
|
+
* Resolve everything `makeRollPtTx` needs for an Exponent PT roll by decoding the maturity
|
|
29061
|
+
* `Vault` (every vault-side `merge` account is a `has_one` field on it), deriving the
|
|
29062
|
+
* owner's PT/YT/SY token accounts, and resolving the SY-program CPI remaining accounts
|
|
29063
|
+
* (`get_sy_state ++ withdraw_sy`) from the vault's address lookup table.
|
|
29064
|
+
*/
|
|
29065
|
+
declare function resolveExponentMergeContext(params: ResolveExponentMergeContextParams): Promise<ExponentMergeContext>;
|
|
29066
|
+
/**
|
|
29067
|
+
* Resolve everything `makeRollPtTx` needs to buy the successor PT natively (SY → PT,
|
|
29068
|
+
* no unwrap, no external aggregator) by trading on the successor maturity's `MarketTwo`.
|
|
29069
|
+
*
|
|
29070
|
+
* Decodes the market, resolves the SY-program CPI accounts from the market's address
|
|
29071
|
+
* lookup table (every `CpiInterfaceContext` is an ALT index), and derives the owner's
|
|
29072
|
+
* SY/PT token accounts. The returned {@link ExponentTradePtContext.addressLookupTable}
|
|
29073
|
+
* must be added to the transaction's lookup tables.
|
|
29074
|
+
*/
|
|
29075
|
+
declare function resolveExponentTradePtContext(params: ResolveExponentTradePtContextParams): Promise<ExponentTradePtContext>;
|
|
29076
|
+
/**
|
|
29077
|
+
* Resolve everything the roll needs to buy the successor PT natively on its **CLMM**
|
|
29078
|
+
* (`MarketThree`) pool — SY → PT in one on-chain trade, no base unwrap and no external
|
|
29079
|
+
* aggregator. The newer maturities (e.g. October bulkSOL) only list a CLMM PT/SY pool (no
|
|
29080
|
+
* `MarketTwo`, no order book), so this is the direct buy leg.
|
|
29081
|
+
*
|
|
29082
|
+
* Decodes the pool, resolves its SY-program CPI accounts from the pool's address lookup
|
|
29083
|
+
* table (each `CpiInterfaceContext` is an ALT index), de-duplicates them, and derives the
|
|
29084
|
+
* owner's SY/PT token accounts. The returned {@link ExponentClmmTradePtContext.addressLookupTable}
|
|
29085
|
+
* must be added to the transaction's lookup tables. The pool uses a single `ticks` account,
|
|
29086
|
+
* so the resolved account set is fixed regardless of trade size.
|
|
29087
|
+
*/
|
|
29088
|
+
declare function resolveExponentClmmTradePtContext(params: ResolveExponentClmmTradePtContextParams): Promise<ExponentClmmTradePtContext>;
|
|
29089
|
+
/**
|
|
29090
|
+
* Resolve everything needed to `strip` SY → PT + YT on an Exponent vault (the buy leg that
|
|
29091
|
+
* *mints* the successor PT, unbounded by AMM depth). Decodes the vault, derives the owner's
|
|
29092
|
+
* SY/PT/YT token accounts, resolves the `deposit_sy` CPI remaining accounts from the vault's
|
|
29093
|
+
* address lookup table, and exposes the last-seen SY exchange rate for sizing the minted PT.
|
|
29094
|
+
*/
|
|
29095
|
+
declare function resolveExponentStripContext(params: ResolveExponentStripContextParams): Promise<ExponentStripContext>;
|
|
29096
|
+
/**
|
|
29097
|
+
* Resolve everything the roll's redeem leg needs to turn matured PT into the underlying
|
|
29098
|
+
* **base** token via `wrapper_merge` (merge PT → SY, then CPI-redeem SY → base, in one ix) —
|
|
29099
|
+
* so the buy leg swaps a normal token, not the un-swappable SY.
|
|
29100
|
+
*
|
|
29101
|
+
* Decodes the maturity `Vault`, derives the owner's SY/PT/YT/base token accounts, assembles
|
|
29102
|
+
* the flavor redeem accounts (all derivable: the generic SY state is `get_sy_state[0]`, the
|
|
29103
|
+
* SPL stake pool is `get_sy_state[3]`, the base escrow is `ATA(syState, baseMint)`), appends
|
|
29104
|
+
* the vault's `withdraw_sy ++ get_sy_state` CPI accounts, and builds the stake-pool refresh
|
|
29105
|
+
* that must run first. Validated byte-for-byte against the Exponent SDK's `ixMergeToBase`.
|
|
29106
|
+
*/
|
|
29107
|
+
declare function resolveExponentWrapperMergeContext(params: ResolveExponentWrapperMergeContextParams): Promise<ExponentWrapperMergeContext>;
|
|
29108
|
+
|
|
29109
|
+
/**
|
|
29110
|
+
* Build the Exponent `merge(amount)` instruction — redeems `amount` PT (post-maturity,
|
|
29111
|
+
* 1:1, no AMM/slippage) into SY at `sySrcDstAta`.
|
|
29112
|
+
*
|
|
29113
|
+
* @param accounts resolved merge accounts (see {@link ExponentMergeAccounts})
|
|
29114
|
+
* @param amountNative PT amount to redeem, in native units (u64)
|
|
29115
|
+
*/
|
|
29116
|
+
declare function makeExponentMergeIx(accounts: ExponentMergeAccounts, amountNative: bigint): TransactionInstruction;
|
|
29117
|
+
/**
|
|
29118
|
+
* Signed `trade_pt` args for **buying** PT with SY (the roll's buy leg).
|
|
29119
|
+
*
|
|
29120
|
+
* The program's convention is signed-from-the-trader's-perspective: a buy makes PT flow
|
|
29121
|
+
* *to* the trader (`net_trader_pt > 0`) and SY flow *away* (`sy_constraint < 0`, the most
|
|
29122
|
+
* negative SY balance change the trader will tolerate — i.e. the max SY spent).
|
|
29123
|
+
*
|
|
29124
|
+
* @param ptOutNative exact PT the trader receives (native u64). Set to a conservative
|
|
29125
|
+
* floor; the trade gives exactly this many PT.
|
|
29126
|
+
* @param maxSyInNative max SY the trader is willing to spend (native u64).
|
|
29127
|
+
*/
|
|
29128
|
+
declare function exponentBuyPtArgs({ ptOutNative, maxSyInNative, }: {
|
|
29129
|
+
ptOutNative: bigint;
|
|
29130
|
+
maxSyInNative: bigint;
|
|
29131
|
+
}): {
|
|
29132
|
+
netTraderPt: bigint;
|
|
29133
|
+
syConstraint: bigint;
|
|
29134
|
+
};
|
|
29135
|
+
/**
|
|
29136
|
+
* Build the Exponent `trade_pt(net_trader_pt, sy_constraint)` instruction — an
|
|
29137
|
+
* implied-APY AMM trade of SY ↔ PT on a `MarketTwo`. For a buy use {@link exponentBuyPtArgs}.
|
|
29138
|
+
*
|
|
29139
|
+
* Pricing PT reads the SY exchange rate on-chain, so `accounts.remainingAccounts` (the
|
|
29140
|
+
* flavor's SY-program CPI accounts, resolved from the market ALT) are appended after the
|
|
29141
|
+
* 12 fixed accounts, and the transaction must carry the market's address lookup table.
|
|
29142
|
+
*
|
|
29143
|
+
* @param accounts resolved trade accounts (see {@link ExponentTradePtAccounts})
|
|
29144
|
+
* @param args signed `net_trader_pt` / `sy_constraint` (i64 LE)
|
|
29145
|
+
*/
|
|
29146
|
+
declare function makeExponentTradePtIx(accounts: ExponentTradePtAccounts, args: {
|
|
29147
|
+
netTraderPt: bigint;
|
|
29148
|
+
syConstraint: bigint;
|
|
29149
|
+
}): TransactionInstruction;
|
|
29150
|
+
/**
|
|
29151
|
+
* Build the Exponent `strip(amount)` instruction — splits `amount` SY into PT + YT on an
|
|
29152
|
+
* active vault. The minted PT lands in `ptDst`, the YT in `ytDst`. Because PT is minted (not
|
|
29153
|
+
* swapped), this is the buy leg for rolling more PT than a thin AMM pool could provide.
|
|
29154
|
+
*
|
|
29155
|
+
* Pricing PT/YT reads the SY rate on-chain, so `accounts.remainingAccounts` (the flavor's
|
|
29156
|
+
* `deposit_sy` CPI accounts, resolved from the vault ALT) are appended after the 15 fixed
|
|
29157
|
+
* accounts, and the transaction must carry the vault's address lookup table.
|
|
29158
|
+
*
|
|
29159
|
+
* @param accounts resolved strip accounts (see {@link ExponentStripAccounts})
|
|
29160
|
+
* @param amountNative SY amount to strip, in native units (u64)
|
|
29161
|
+
*/
|
|
29162
|
+
declare function makeExponentStripIx(accounts: ExponentStripAccounts, amountNative: bigint): TransactionInstruction;
|
|
29163
|
+
/**
|
|
29164
|
+
* Build the Exponent `wrapper_merge(amount_py, redeem_sy_accounts_until)` instruction —
|
|
29165
|
+
* redeems `amountPyNative` PT into the underlying base token at the owner's base ATA.
|
|
29166
|
+
*
|
|
29167
|
+
* The remaining accounts are `[...flavor redeem accounts, ...vault SY-CPI accounts]`;
|
|
29168
|
+
* `redeemSyAccountsUntil` tells the program where the redeem accounts end. The redeem's first
|
|
29169
|
+
* account is the owner and keeps its signer flag (the SY-CPI accounts are forced non-signer,
|
|
29170
|
+
* resolved upstream). The transaction must carry the vault's address lookup table.
|
|
29171
|
+
*
|
|
29172
|
+
* @param accounts resolved wrapper-merge accounts (see {@link ExponentWrapperMergeAccounts})
|
|
29173
|
+
* @param args `amountPyNative` (u64) PT to redeem + `redeemSyAccountsUntil` (u8)
|
|
29174
|
+
*/
|
|
29175
|
+
declare function makeExponentWrapperMergeIx(accounts: ExponentWrapperMergeAccounts, args: {
|
|
29176
|
+
amountPyNative: bigint;
|
|
29177
|
+
redeemSyAccountsUntil: number;
|
|
29178
|
+
}): TransactionInstruction;
|
|
29179
|
+
/**
|
|
29180
|
+
* Build the SPL Stake Pool `UpdateStakePoolBalance` instruction — refreshes a stake pool's
|
|
29181
|
+
* total-lamports / pool-token-supply so the pool↔token exchange rate is current for the
|
|
29182
|
+
* epoch. An SPL-stake-pool SY flavor (e.g. bulkSOL) requires this immediately before
|
|
29183
|
+
* `wrapper_merge`, otherwise the redeem reads a stale SY↔base rate.
|
|
29184
|
+
*
|
|
29185
|
+
* Account order matches the SPL Stake Pool program's `UpdateStakePoolBalance`.
|
|
29186
|
+
*/
|
|
29187
|
+
declare function makeSplStakePoolUpdateBalanceIx(accounts: {
|
|
29188
|
+
stakePoolProgram: PublicKey;
|
|
29189
|
+
stakePool: PublicKey;
|
|
29190
|
+
withdrawAuthority: PublicKey;
|
|
29191
|
+
validatorList: PublicKey;
|
|
29192
|
+
reserveStake: PublicKey;
|
|
29193
|
+
managerFeeAccount: PublicKey;
|
|
29194
|
+
poolMint: PublicKey;
|
|
29195
|
+
tokenProgram?: PublicKey;
|
|
29196
|
+
}): TransactionInstruction;
|
|
29197
|
+
/**
|
|
29198
|
+
* Signed `trade_pt` args for **buying** PT with SY on the CLMM (the roll's buy leg).
|
|
29199
|
+
*
|
|
29200
|
+
* `amountIn` is the exact SY spent; `swapDirection` is `SyToPt`; `amountOutConstraint` is
|
|
29201
|
+
* the minimum PT out (slippage floor); `priceSpotLimit` (ln-implied-APY limit) is left unset.
|
|
29202
|
+
*
|
|
29203
|
+
* @param amountInSyNative SY to spend (native u64).
|
|
29204
|
+
* @param minPtOutNative minimum PT to receive (native u64) — the swap reverts below this.
|
|
29205
|
+
*/
|
|
29206
|
+
declare function exponentClmmBuyPtArgs({ amountInSyNative, minPtOutNative, }: {
|
|
29207
|
+
amountInSyNative: bigint;
|
|
29208
|
+
minPtOutNative: bigint;
|
|
29209
|
+
}): {
|
|
29210
|
+
amountIn: bigint;
|
|
29211
|
+
swapDirection: ExponentSwapDirection;
|
|
29212
|
+
amountOutConstraint: bigint | null;
|
|
29213
|
+
priceSpotLimit: null;
|
|
29214
|
+
};
|
|
29215
|
+
/**
|
|
29216
|
+
* Build the CLMM `trade_pt(amount_in, swap_direction, amount_out_constraint, price_spot_limit)`
|
|
29217
|
+
* instruction — an implied-APY AMM trade of SY ↔ PT on a `MarketThree` pool. For a buy use
|
|
29218
|
+
* {@link exponentClmmBuyPtArgs}.
|
|
29219
|
+
*
|
|
29220
|
+
* Pricing PT reads the SY exchange rate on-chain, so `accounts.remainingAccounts` (the SY-CPI
|
|
29221
|
+
* accounts resolved from the market ALT) are appended after the 14 fixed accounts, and the
|
|
29222
|
+
* transaction must carry the market's address lookup table.
|
|
29223
|
+
*
|
|
29224
|
+
* @param accounts resolved trade accounts (see {@link ExponentClmmTradePtAccounts})
|
|
29225
|
+
* @param args `amountIn` (u64) + `swapDirection` (u8) + `amountOutConstraint` (Option<u64>)
|
|
29226
|
+
* + `priceSpotLimit` (Option<f64>, always `null` here)
|
|
29227
|
+
*/
|
|
29228
|
+
declare function makeExponentClmmTradePtIx(accounts: ExponentClmmTradePtAccounts, args: {
|
|
29229
|
+
amountIn: bigint;
|
|
29230
|
+
swapDirection: ExponentSwapDirection;
|
|
29231
|
+
amountOutConstraint: bigint | null;
|
|
29232
|
+
priceSpotLimit: null;
|
|
29233
|
+
}): TransactionInstruction;
|
|
28330
29234
|
|
|
28331
|
-
export { ACCOUNT_SIZE, ACCOUNT_TYPE_SIZE, ASSOCIATED_TOKEN_PROGRAM_ID, type Account, AccountLayout, type AccountMeta, AccountState, AccountType, type ApproveInstructionData, type Base, type ClientRequest, type CloseAccountInstructionData, ConnectionClosed, CorpAction, CurvePointFields, DEFAULT_RECENT_SLOT_DURATION_MS, DRIFT_IDL, DRIFT_PROGRAM_ID, type DriftIdlType, type DriftInterestRateCurvePoint, DriftRewards, DriftRewardsJSON, DriftSpotBalanceType, DriftSpotMarket, DriftSpotMarketJSON, type DriftSpotMarketRaw, type DriftState, type DriftStateJSON, DriftUser, DriftUserJSON, type DriftUserRaw, DriftUserStats, DriftUserStatsJSON, EXPONENT_CLMM_PROGRAM_ID, EXPONENT_CORE_IDL, EXPONENT_CORE_PROGRAM_ID, EXPONENT_EVENT_AUTHORITY_SEED, EXPONENT_GENERIC_SY_PROGRAM_ID, EXPONENT_JITO_RESTAKING_SY_PROGRAM_ID, EXPONENT_KAMINO_SY_PROGRAM_ID, EXPONENT_MARGINFI_SY_PROGRAM_ID, EXPONENT_NUMBER_DENOM, EXPONENT_ORDERBOOK_PROGRAM_ID, EXPONENT_PERENA_SY_PROGRAM_ID, EXPONENT_VAULTS_PROGRAM_ID, type Ema, ErrorResponse, type ExponentCpiInterfaceContext, type ExponentMarketTwo, type ExponentMarketTwoCpiAccounts, type ExponentMergeAccounts, type ExponentMergeContext, type ExponentStripAccounts, type ExponentStripContext, type ExponentTradePtAccounts, type ExponentTradePtContext, type ExponentVault, ExtensionType, FARMS_PROGRAM_ID, FarmStateJSON, FarmStateRaw, FeeStructure, FeeStructureJSON, HistoricalIndexData, HistoricalOracleData, type InitializeAccountInstructionData, type Instruction, InsuranceFund, JUP_EXCHANGE_PRICES_PRECISION, JUP_LEND_IDL, JUP_LEND_PROGRAM_ID, JUP_LIQUIDITY_IDL, JUP_LIQUIDITY_PROGRAM_ID, JUP_MAX_REWARDS_RATE, JUP_REWARDS_PROGRAM_ID, JUP_SECONDS_PER_YEAR, type JupLendIdlType, type JupLendInterestRateCurvePoint, type JupLendRewardsResult, JupLendingRewardsRateModel, JupLendingRewardsRateModelJSON, type JupLendingRewardsRateModelRaw, JupLendingState, JupLendingStateJSON, type JupLendingStateRaw, type JupLiquidityIdlType, JupRateModel, JupRateModelJSON, type JupRateModelRaw, JupTokenReserve, JupTokenReserveJSON, type JupTokenReserveRaw, KFARMS_IDL, KLEND_ACCOUNT_CODER, KLEND_IDL, KLEND_PROGRAM_ID, type KaminoReserveCurveData, type KfarmsIdlType, type KlendIdlType, type KlendInterestRateCurvePoint, LENGTH_SIZE, MAX_SLOT_DIFFERENCE, MEMO_PROGRAM_ID, MINT_SIZE, MULTISIG_SIZE, type Mint, MintLayout, type Multisig, MultisigLayout, NATIVE_MINT, ONE, ONE_HUNDRED_PCT_IN_BPS, ONE_YEAR, ObligationJSON, ObligationRaw, OracleGuardRails, OracleGuardRailsJSON, PERCENTAGE_PRECISION, PERCENTAGE_PRECISION_EXP, type PlatformFee, PoolBalance, type Price, type PriceComponent, type PriceData, PriceStatus, PriceType, type Pubkey, type QuoteSwapStreamResponse, type QuoteUpdateParams, REFRESH_OBLIGATION_DISCRIMINATOR, type RawAccount, type RawMint, type RawMultisig, type RefreshObligationAccounts, type RequestData, ReserveJSON, ReserveRaw, type ResolveExponentMergeContextParams, type ResolveExponentStripContextParams, type ResolveExponentTradePtContextParams, type ResponseData, type ResponseError, type ResponseSuccess, type ResponseWithStream, RewardInfoFields, type RoutePlanStep, SEED_BASE_REFERRER_STATE, SEED_BASE_REFERRER_TOKEN_STATE, SEED_BASE_SHORT_URL, SEED_BASE_USER_METADATA, SEED_DRIFT_SIGNER, SEED_DRIFT_STATE, SEED_FEE_RECEIVER, SEED_F_TOKEN_MINT, SEED_LENDING, SEED_LENDING_ADMIN, SEED_LENDING_MARKET_AUTH, SEED_LENDING_REWARDS_RATE_MODEL, SEED_LIQUIDITY, SEED_RATE_MODEL, SEED_RESERVE, SEED_RESERVE_COLL_MINT, SEED_RESERVE_COLL_SUPPLY, SEED_RESERVE_LIQ_SUPPLY, SEED_SPOT_MARKET, SEED_SPOT_MARKET_VAULT, SEED_USER, SEED_USER_CLAIM, SEED_USER_STATE, SEED_USER_STATS, SEED_USER_SUPPLY_POSITION, SLOTS_PER_DAY, SLOTS_PER_HOUR, SLOTS_PER_MINUTE, SLOTS_PER_SECOND, SLOTS_PER_YEAR, SPOT_MARKET_RATE_PRECISION, SPOT_MARKET_RATE_PRECISION_EXP, SPOT_MARKET_UTILIZATION_PRECISION, SPOT_MARKET_UTILIZATION_PRECISION_EXP, type SerializedInstruction, type SerializedSwapRoute, type ServerMessage, SinglePoolInstruction, SplAccountType, SpotPosition, type StakeAccount, type StopStreamRequest, type StopStreamResponse, type StreamData, type StreamDataPayload, type StreamEnd, StreamError, type StreamStart, SwapMode, type SwapParams, type SwapQuoteRequest, type SwapQuotes, type SwapRoute, SwapVersion, type SyncNativeInstructionData, TEN, TOKEN_2022_PROGRAM_ID, TOKEN_PROGRAM_ID, TYPE_SIZE, type TitanGatewayQuoteParams, type TitanGatewayQuoteResponse, type TitanProxyExactOutResponse, type TitanProxySwapQuoteResponse, type TitanSwapQuoteResult, type TitanTemplateLut, type TitanTransactionTemplate, TokenAccountNotFoundError, TokenError, TokenInstruction, TokenInvalidAccountError, TokenInvalidAccountOwnerError, TokenInvalidAccountSizeError, TokenInvalidInstructionDataError, TokenInvalidInstructionKeysError, TokenInvalidInstructionProgramError, TokenInvalidInstructionTypeError, TokenInvalidMintError, TokenInvalidOwnerError, TokenOwnerOffCurveError, TokenUnsupportedInstructionError, type TransactionParams, type TransactionTemplate, type TransactionTemplateLut, type TransferCheckedInstructionData, type Uint64, V1Client, ZERO, addSigners, approveInstructionData, buildSwapQuoteResult, buildTitanTemplate, calculateAPYFromAPR, calculateDriftBorrowAPR, calculateDriftBorrowAPY, calculateDriftBorrowRate, calculateDriftDepositRate, calculateDriftInterestRate, calculateDriftLendingAPR, calculateDriftLendingAPY, calculateDriftUtilization, calculateJupLendBorrowRate, calculateJupLendLiquiditySupplyRate, calculateJupLendNewExchangePrice, calculateJupLendRewardsRate, calculateJupLendRewardsRateForExchangePrice, calculateJupLendSupplyAPY, calculateJupLendSupplyRate, calculateJupLendTotalAssets, calculateKaminoEstimatedBorrowRate, calculateKaminoEstimatedSupplyRate, calculateKaminoSupplyAPY, calculateRewardApy, calculateSlotAdjustmentFactor, calculateUtilizationRatio, closeAccountInstructionData, createAccountIx, createApproveInstruction, createAssociatedTokenAccountIdempotentInstruction, createAssociatedTokenAccountInstruction, createCloseAccountInstruction, createInitializeAccountInstruction, createMemoInstruction, createPoolOnrampIx, createSyncNativeInstruction, createTransferCheckedInstruction, decodeDriftSpotMarketData, decodeDriftStateData, decodeDriftUserData, decodeDriftUserStatsData, decodeExponentMarketTwo, decodeExponentMarketVault, decodeExponentVault, decodeFarmDataRaw, decodeJupLendingRewardsRateModelData, decodeJupLendingStateData, decodeJupRateModelData, decodeJupTokenReserveData, decodeKlendObligationData, decodeKlendReserveData, deriveBaseObligation, deriveDriftSigner, deriveDriftSpotMarket, deriveDriftSpotMarketVault, deriveDriftState, deriveDriftUser, deriveDriftUserStats, deriveExponentEventAuthority, deriveFeeReceiver, deriveJupLendClaimAccount, deriveJupLendFTokenMint, deriveJupLendLending, deriveJupLendLendingAdmin, deriveJupLendLendingPdas, deriveJupLendLendingRewardsRateModel, deriveJupLendLiquidity, deriveJupLendLiquiditySupplyPositionPda, deriveJupLendLiquidityVaultAta, deriveJupLendRateModel, deriveJupLendTokenReserve, deriveLendingMarketAuthority, deriveObligation, deriveReferrerState, deriveReferrerTokenState, deriveReserveCollateralMint, deriveReserveCollateralSupply, deriveReserveLiquiditySupply, deriveShortUrl, deriveUserMetadata, deriveUserState, deserializeSerializedInstruction, deserializeTitanWireInstruction, driftRewardsRawToDto, driftSpotMarketRawToDto, driftStateRawToDto, driftUserRawToDto, driftUserStatsRawToDto, dtoToDriftRewardsRaw, dtoToDriftSpotMarketRaw, dtoToDriftStateRaw, dtoToDriftUserRaw, dtoToDriftUserStatsRaw, dtoToFarmRaw, dtoToJupLendingRewardsRateModelRaw, dtoToJupLendingStateRaw, dtoToJupRateModelRaw, dtoToJupTokenReserveRaw, dtoToObligationRaw, dtoToReserveRaw, encodeTitanTemplate, exponentBuyPtArgs, exponentNumberToBigNumber, farmRawToDto, fetchExponentMarketTwo, fetchExponentVault, fetchExponentVaultFromMarket, fetchTitanQuoteSwapV3, findMplMetadataAddress, findPoolAddress, findPoolMintAddress, findPoolMintAddressByVoteAccount, findPoolMintAuthorityAddress, findPoolMplAuthorityAddress, findPoolOnRampAddress, findPoolStakeAddress, findPoolStakeAuthorityAddress, generateDriftReserveCurve, generateJupLendSupplyCurve, generateKaminoReserveCurve, getAccount, getAccountLen, getAllDerivedDriftAccounts, getAllDerivedJupLendAccounts, getAllDerivedKaminoAccounts, getAllRequiredMarkets, getAssociatedTokenAddressSync, getDriftRewards, getDriftTokenAmount, getFixedHostInterestRate, getJupLendRewards, getKaminoBorrowRate, getKaminoTotalSupply, getMinimumBalanceForRentExemptAccount, getMinimumBalanceForRentExemptAccountWithExtensions, getMint, getMintDecimals, getMultipleAccounts, getProtocolTakeRatePct, getReserveRewardsApy, getRewardPerTimeUnitSecond, getStakeAccount, initializeAccountInstructionData, initializeStakedPoolIxs, initializeStakedPoolTx, instructionToTitanWire, interpolateLinear, jupLendingRewardsRateModelRawToDto, jupLendingStateRawToDto, jupRateModelRawToDto, jupTokenReserveRawToDto, layout, lutToTitanWire, makeExponentMergeIx, makeExponentStripIx, makeExponentTradePtIx, makeRefreshObligationIx, makeRefreshReservesBatchIx, makeRefreshingIxs, makeUpdateJupLendRate, makeUpdateJupLendRateIx, makeUpdateSpotMarketCumulativeInterestIx, makeUpdateSpotMarketIx, obligationRawToDto, parsePriceData, parsePriceInfo, replenishPoolIx, reserveRawToDto, resolveExponentMergeContext, resolveExponentStripContext, resolveExponentTradePtContext, resolveLookupTables, scaledSupplies, selectBestRoute, selectGatewayRoute, slotAdjustmentFactor, syncNativeInstructionData, transferCheckedInstructionData, truncateBorrowCurve, unpackAccount };
|
|
29235
|
+
export { ACCOUNT_SIZE, ACCOUNT_TYPE_SIZE, ASSOCIATED_TOKEN_PROGRAM_ID, type Account, AccountLayout, type AccountMeta, AccountState, AccountType, type ApproveInstructionData, type Base, type ClientRequest, type CloseAccountInstructionData, ConnectionClosed, CorpAction, CurvePointFields, DEFAULT_RECENT_SLOT_DURATION_MS, DRIFT_IDL, DRIFT_PROGRAM_ID, type DriftIdlType, type DriftInterestRateCurvePoint, DriftRewards, DriftRewardsJSON, DriftSpotBalanceType, DriftSpotMarket, DriftSpotMarketJSON, type DriftSpotMarketRaw, type DriftState, type DriftStateJSON, DriftUser, DriftUserJSON, type DriftUserRaw, DriftUserStats, DriftUserStatsJSON, EXPONENT_CLMM_IDL, EXPONENT_CLMM_PROGRAM_ID, EXPONENT_CORE_IDL, EXPONENT_CORE_PROGRAM_ID, EXPONENT_EVENT_AUTHORITY_SEED, EXPONENT_GENERIC_SY_PROGRAM_ID, EXPONENT_JITO_RESTAKING_SY_PROGRAM_ID, EXPONENT_KAMINO_SY_PROGRAM_ID, EXPONENT_MARGINFI_SY_PROGRAM_ID, EXPONENT_NUMBER_DENOM, EXPONENT_ORDERBOOK_PROGRAM_ID, EXPONENT_PERENA_SY_PROGRAM_ID, EXPONENT_VAULTS_PROGRAM_ID, type Ema, ErrorResponse, type ExponentClmmTradePtAccounts, type ExponentClmmTradePtContext, type ExponentCpiInterfaceContext, type ExponentMarketThree, type ExponentMarketThreeCpiAccounts, type ExponentMarketTwo, type ExponentMarketTwoCpiAccounts, type ExponentMergeAccounts, type ExponentMergeContext, type ExponentStripAccounts, type ExponentStripContext, ExponentSwapDirection, type ExponentTradePtAccounts, type ExponentTradePtContext, type ExponentVault, type ExponentWrapperMergeAccounts, type ExponentWrapperMergeContext, ExtensionType, FARMS_PROGRAM_ID, FarmStateJSON, FarmStateRaw, FeeStructure, FeeStructureJSON, HistoricalIndexData, HistoricalOracleData, type InitializeAccountInstructionData, type Instruction, InsuranceFund, JUP_EXCHANGE_PRICES_PRECISION, JUP_LEND_IDL, JUP_LEND_PROGRAM_ID, JUP_LIQUIDITY_IDL, JUP_LIQUIDITY_PROGRAM_ID, JUP_MAX_REWARDS_RATE, JUP_REWARDS_PROGRAM_ID, JUP_SECONDS_PER_YEAR, type JupLendIdlType, type JupLendInterestRateCurvePoint, type JupLendRewardsResult, JupLendingRewardsRateModel, JupLendingRewardsRateModelJSON, type JupLendingRewardsRateModelRaw, JupLendingState, JupLendingStateJSON, type JupLendingStateRaw, type JupLiquidityIdlType, JupRateModel, JupRateModelJSON, type JupRateModelRaw, JupTokenReserve, JupTokenReserveJSON, type JupTokenReserveRaw, KFARMS_IDL, KLEND_ACCOUNT_CODER, KLEND_IDL, KLEND_PROGRAM_ID, type KaminoReserveCurveData, type KfarmsIdlType, type KlendIdlType, type KlendInterestRateCurvePoint, LENGTH_SIZE, MAX_SLOT_DIFFERENCE, MEMO_PROGRAM_ID, MINT_SIZE, MULTISIG_SIZE, type Mint, MintLayout, type Multisig, MultisigLayout, NATIVE_MINT, ONE, ONE_HUNDRED_PCT_IN_BPS, ONE_YEAR, ObligationJSON, ObligationRaw, OracleGuardRails, OracleGuardRailsJSON, PERCENTAGE_PRECISION, PERCENTAGE_PRECISION_EXP, type PlatformFee, PoolBalance, type Price, type PriceComponent, type PriceData, PriceStatus, PriceType, type Pubkey, type QuoteSwapStreamResponse, type QuoteUpdateParams, REFRESH_OBLIGATION_DISCRIMINATOR, type RawAccount, type RawMint, type RawMultisig, type RefreshObligationAccounts, type RequestData, ReserveJSON, ReserveRaw, type ResolveExponentClmmTradePtContextParams, type ResolveExponentMergeContextParams, type ResolveExponentStripContextParams, type ResolveExponentTradePtContextParams, type ResolveExponentWrapperMergeContextParams, type ResponseData, type ResponseError, type ResponseSuccess, type ResponseWithStream, RewardInfoFields, type RoutePlanStep, SEED_BASE_REFERRER_STATE, SEED_BASE_REFERRER_TOKEN_STATE, SEED_BASE_SHORT_URL, SEED_BASE_USER_METADATA, SEED_DRIFT_SIGNER, SEED_DRIFT_STATE, SEED_FEE_RECEIVER, SEED_F_TOKEN_MINT, SEED_LENDING, SEED_LENDING_ADMIN, SEED_LENDING_MARKET_AUTH, SEED_LENDING_REWARDS_RATE_MODEL, SEED_LIQUIDITY, SEED_RATE_MODEL, SEED_RESERVE, SEED_RESERVE_COLL_MINT, SEED_RESERVE_COLL_SUPPLY, SEED_RESERVE_LIQ_SUPPLY, SEED_SPOT_MARKET, SEED_SPOT_MARKET_VAULT, SEED_USER, SEED_USER_CLAIM, SEED_USER_STATE, SEED_USER_STATS, SEED_USER_SUPPLY_POSITION, SLOTS_PER_DAY, SLOTS_PER_HOUR, SLOTS_PER_MINUTE, SLOTS_PER_SECOND, SLOTS_PER_YEAR, SPOT_MARKET_RATE_PRECISION, SPOT_MARKET_RATE_PRECISION_EXP, SPOT_MARKET_UTILIZATION_PRECISION, SPOT_MARKET_UTILIZATION_PRECISION_EXP, type SerializedInstruction, type SerializedSwapRoute, type ServerMessage, SinglePoolInstruction, SplAccountType, SpotPosition, type StakeAccount, type StopStreamRequest, type StopStreamResponse, type StreamData, type StreamDataPayload, type StreamEnd, StreamError, type StreamStart, SwapMode, type SwapParams, type SwapQuoteRequest, type SwapQuotes, type SwapRoute, SwapVersion, type SyncNativeInstructionData, TEN, TOKEN_2022_PROGRAM_ID, TOKEN_PROGRAM_ID, TYPE_SIZE, type TitanGatewayQuoteParams, type TitanGatewayQuoteResponse, type TitanProxyExactOutResponse, type TitanProxySwapQuoteResponse, type TitanSwapQuoteResult, type TitanTemplateLut, type TitanTransactionTemplate, TokenAccountNotFoundError, TokenError, TokenInstruction, TokenInvalidAccountError, TokenInvalidAccountOwnerError, TokenInvalidAccountSizeError, TokenInvalidInstructionDataError, TokenInvalidInstructionKeysError, TokenInvalidInstructionProgramError, TokenInvalidInstructionTypeError, TokenInvalidMintError, TokenInvalidOwnerError, TokenOwnerOffCurveError, TokenUnsupportedInstructionError, type TransactionParams, type TransactionTemplate, type TransactionTemplateLut, type TransferCheckedInstructionData, type Uint64, V1Client, ZERO, addSigners, approveInstructionData, buildSwapQuoteResult, buildTitanTemplate, calculateAPYFromAPR, calculateDriftBorrowAPR, calculateDriftBorrowAPY, calculateDriftBorrowRate, calculateDriftDepositRate, calculateDriftInterestRate, calculateDriftLendingAPR, calculateDriftLendingAPY, calculateDriftUtilization, calculateJupLendBorrowRate, calculateJupLendLiquiditySupplyRate, calculateJupLendNewExchangePrice, calculateJupLendRewardsRate, calculateJupLendRewardsRateForExchangePrice, calculateJupLendSupplyAPY, calculateJupLendSupplyRate, calculateJupLendTotalAssets, calculateKaminoEstimatedBorrowRate, calculateKaminoEstimatedSupplyRate, calculateKaminoSupplyAPY, calculateRewardApy, calculateSlotAdjustmentFactor, calculateUtilizationRatio, closeAccountInstructionData, createAccountIx, createApproveInstruction, createAssociatedTokenAccountIdempotentInstruction, createAssociatedTokenAccountInstruction, createCloseAccountInstruction, createInitializeAccountInstruction, createMemoInstruction, createPoolOnrampIx, createSyncNativeInstruction, createTransferCheckedInstruction, decodeDriftSpotMarketData, decodeDriftStateData, decodeDriftUserData, decodeDriftUserStatsData, decodeExponentMarketThree, decodeExponentMarketTwo, decodeExponentMarketVault, decodeExponentVault, decodeFarmDataRaw, decodeJupLendingRewardsRateModelData, decodeJupLendingStateData, decodeJupRateModelData, decodeJupTokenReserveData, decodeKlendObligationData, decodeKlendReserveData, deriveBaseObligation, deriveDriftSigner, deriveDriftSpotMarket, deriveDriftSpotMarketVault, deriveDriftState, deriveDriftUser, deriveDriftUserStats, deriveExponentClmmEventAuthority, deriveExponentEventAuthority, deriveFeeReceiver, deriveJupLendClaimAccount, deriveJupLendFTokenMint, deriveJupLendLending, deriveJupLendLendingAdmin, deriveJupLendLendingPdas, deriveJupLendLendingRewardsRateModel, deriveJupLendLiquidity, deriveJupLendLiquiditySupplyPositionPda, deriveJupLendLiquidityVaultAta, deriveJupLendRateModel, deriveJupLendTokenReserve, deriveLendingMarketAuthority, deriveObligation, deriveReferrerState, deriveReferrerTokenState, deriveReserveCollateralMint, deriveReserveCollateralSupply, deriveReserveLiquiditySupply, deriveShortUrl, deriveUserMetadata, deriveUserState, deserializeSerializedInstruction, deserializeTitanWireInstruction, driftRewardsRawToDto, driftSpotMarketRawToDto, driftStateRawToDto, driftUserRawToDto, driftUserStatsRawToDto, dtoToDriftRewardsRaw, dtoToDriftSpotMarketRaw, dtoToDriftStateRaw, dtoToDriftUserRaw, dtoToDriftUserStatsRaw, dtoToFarmRaw, dtoToJupLendingRewardsRateModelRaw, dtoToJupLendingStateRaw, dtoToJupRateModelRaw, dtoToJupTokenReserveRaw, dtoToObligationRaw, dtoToReserveRaw, encodeTitanTemplate, exponentBuyPtArgs, exponentClmmBuyPtArgs, exponentNumberToBigNumber, farmRawToDto, fetchExponentMarketThree, fetchExponentMarketTwo, fetchExponentVault, fetchExponentVaultFromMarket, fetchTitanQuoteSwapV3, findMplMetadataAddress, findPoolAddress, findPoolMintAddress, findPoolMintAddressByVoteAccount, findPoolMintAuthorityAddress, findPoolMplAuthorityAddress, findPoolOnRampAddress, findPoolStakeAddress, findPoolStakeAuthorityAddress, generateDriftReserveCurve, generateJupLendSupplyCurve, generateKaminoReserveCurve, getAccount, getAccountLen, getAllDerivedDriftAccounts, getAllDerivedJupLendAccounts, getAllDerivedKaminoAccounts, getAllRequiredMarkets, getAssociatedTokenAddressSync, getDriftRewards, getDriftTokenAmount, getFixedHostInterestRate, getJupLendRewards, getKaminoBorrowRate, getKaminoTotalSupply, getMinimumBalanceForRentExemptAccount, getMinimumBalanceForRentExemptAccountWithExtensions, getMint, getMintDecimals, getMultipleAccounts, getProtocolTakeRatePct, getReserveRewardsApy, getRewardPerTimeUnitSecond, getStakeAccount, initializeAccountInstructionData, initializeStakedPoolIxs, initializeStakedPoolTx, instructionToTitanWire, interpolateLinear, jupLendingRewardsRateModelRawToDto, jupLendingStateRawToDto, jupRateModelRawToDto, jupTokenReserveRawToDto, layout, lutToTitanWire, makeExponentClmmTradePtIx, makeExponentMergeIx, makeExponentStripIx, makeExponentTradePtIx, makeExponentWrapperMergeIx, makeRefreshObligationIx, makeRefreshReservesBatchIx, makeRefreshingIxs, makeSplStakePoolUpdateBalanceIx, makeUpdateJupLendRate, makeUpdateJupLendRateIx, makeUpdateSpotMarketCumulativeInterestIx, makeUpdateSpotMarketIx, obligationRawToDto, parsePriceData, parsePriceInfo, replenishPoolIx, reserveRawToDto, resolveExponentClmmTradePtContext, resolveExponentMergeContext, resolveExponentStripContext, resolveExponentTradePtContext, resolveExponentWrapperMergeContext, resolveLookupTables, scaledSupplies, selectBestRoute, selectGatewayRoute, slotAdjustmentFactor, syncNativeInstructionData, transferCheckedInstructionData, truncateBorrowCurve, unpackAccount };
|