import { BN } from "@coral-xyz/anchor"; import { Connection, PublicKey, TransactionInstruction, TransactionSignature, VersionedTransaction } from "@solana/web3.js"; import { BaseClient, BaseTxBuilder, type ProtocolPolicyClient, type ProtocolPolicyTxBuilder, TokenAccount, type TxOptions } from "./base"; import { PriceClient } from "./price"; import { MintIdlModel, RequestType, StateAccountType } from "../models"; import { MintPolicy } from "../deser/integrationPolicies"; import { UpdateStateParams } from "./state"; export type InitMintParams = { accountType: StateAccountType; name: number[]; symbol: string; uri: string; baseAssetMint: PublicKey; decimals?: number; } & Partial; export type UpdateMintParams = { permanentDelegate?: PublicKey; defaultAccountStateFrozen?: boolean; lockupPeriod?: number; maxCap?: BN; minSubscription?: BN; minRedemption?: BN; allowlist?: PublicKey[]; blocklist?: PublicKey[]; }; /** * Resolves the list config + wallet entry pairs needed for permissionless thaw. * Returns empty array if Token ACL is not enabled or no matching pairs found. */ export declare function resolveThawAccounts(connection: Connection, mintPda: PublicKey, wallet: PublicKey): Promise<{ listConfig: PublicKey; walletEntry: PublicKey; }[]>; /** * Builds a permissionless thaw instruction for the Token ACL program. * Standalone version of TxBuilder.thawPermissionlessIx for use outside * the MintClient context (e.g., in invest.ts). */ export declare function buildThawPermissionlessIx(mintPda: PublicKey, wallet: PublicKey, listAndWalletPairs: { listConfig: PublicKey; walletEntry: PublicKey; }[], signer: PublicKey): TransactionInstruction; declare class TxBuilder extends BaseTxBuilder implements ProtocolPolicyTxBuilder { setTokenAccountsStatesIx(tokenAccounts: PublicKey[], frozen: boolean, glamSigner: PublicKey): Promise; setTokenAccountsStatesTx(tokenAccounts: PublicKey[], frozen: boolean, txOptions?: TxOptions): Promise; createTokenAccountIxs(owner: PublicKey, setFrozen: boolean, glamSigner: PublicKey): Promise; createTokenAccountTx(owner: PublicKey, setFrozen?: boolean, txOptions?: TxOptions): Promise; mintIxs(recipient: PublicKey, amount: BN, forceThaw: boolean | undefined, glamSigner: PublicKey): Promise; mintTx(recipient: PublicKey, amount: BN, forceThaw?: boolean, txOptions?: TxOptions): Promise; burnIxs(from: PublicKey, amount: BN, forceThaw: boolean, glamSigner: PublicKey): Promise; burnTx(from: PublicKey, amount: BN, forceThaw?: boolean, txOptions?: TxOptions): Promise; forceTransferIxs(from: PublicKey, to: PublicKey, amount: BN, forceThaw: boolean, glamSigner: PublicKey): Promise; forceTransferTx(from: PublicKey, to: PublicKey, amount: BN, forceThaw?: boolean, txOptions?: TxOptions): Promise; initializeIxs(initMintParams: InitMintParams, stateParams: UpdateStateParams | null, glamSigner: PublicKey): Promise<[TransactionInstruction[], PublicKey]>; initializeTx(initMintParams: InitMintParams, stateParams: UpdateStateParams | null, txOptions?: TxOptions): Promise<[VersionedTransaction, PublicKey]>; crystallizeFeesIxs(glamSigner: PublicKey): Promise; updateIx(mintModel: Partial, glamSigner: PublicKey): Promise; updateTx(mintModel: Partial, txOptions?: TxOptions): Promise; emergencyUpdateIx(requestType: RequestType, setPaused: boolean, glamSigner: PublicKey): Promise; pauseSubscriptionTx(txOptions?: TxOptions): Promise; unpauseSubscriptionTx(txOptions?: TxOptions): Promise; pauseRedemptionTx(txOptions?: TxOptions): Promise; unpauseRedemptionTx(txOptions?: TxOptions): Promise; closeMintIx(signer?: PublicKey): Promise; closeMintTx(txOptions?: TxOptions): Promise; enableTokenAclIx(gatingProgram: PublicKey | undefined, glamSigner: PublicKey): Promise; enableTokenAclTx(gatingProgram: PublicKey | undefined, txOptions?: TxOptions): Promise; aclGateCreateListIx(seed: Buffer, mode: number, glamSigner: PublicKey): Promise; aclGateCreateListTx(seed: Buffer, mode: number, txOptions?: TxOptions): Promise; aclGateAddWalletIx(listConfig: PublicKey, wallet: PublicKey, glamSigner: PublicKey): Promise; aclGateAddWalletTx(listConfig: PublicKey, wallet: PublicKey, txOptions?: TxOptions): Promise; aclGateRemoveWalletIx(listConfig: PublicKey, walletEntry: PublicKey, glamSigner: PublicKey): Promise; aclGateRemoveWalletTx(listConfig: PublicKey, walletEntry: PublicKey, txOptions?: TxOptions): Promise; aclGateDeleteListIx(listConfig: PublicKey, glamSigner: PublicKey): Promise; aclGateDeleteListTx(listConfig: PublicKey, txOptions?: TxOptions): Promise; aclGateSetupExtraMetasIx(listConfigs: PublicKey[], glamSigner: PublicKey): Promise; aclGateSetupExtraMetasTx(listConfigs: PublicKey[], txOptions?: TxOptions): Promise; tokenAclFreezeIx(tokenAccounts: PublicKey[], glamSigner: PublicKey): Promise; tokenAclFreezeTx(tokenAccounts: PublicKey[], txOptions?: TxOptions): Promise; tokenAclThawIx(tokenAccounts: PublicKey[], glamSigner: PublicKey): Promise; tokenAclThawTx(tokenAccounts: PublicKey[], txOptions?: TxOptions): Promise; thawPermissionlessIx(wallet: PublicKey, listAndWalletPairs: { listConfig: PublicKey; walletEntry: PublicKey; }[], signer: PublicKey): TransactionInstruction; thawPermissionlessTx(wallet: PublicKey, listAndWalletPairs: { listConfig: PublicKey; walletEntry: PublicKey; }[], txOptions?: TxOptions): Promise; setPolicyIx(policy: MintPolicy, signer?: PublicKey): Promise; setMintPolicyIx(policy: MintPolicy, signer?: PublicKey): Promise; setPolicyTx(policy: MintPolicy, txOptions?: TxOptions): Promise; setMintPolicyTx(policy: MintPolicy, txOptions?: TxOptions): Promise; clearPolicyIx(signer?: PublicKey): Promise; clearMintPolicyIx(signer?: PublicKey): Promise; clearPolicyTx(txOptions?: TxOptions): Promise; clearMintPolicyTx(txOptions?: TxOptions): Promise; } export declare class MintClient implements ProtocolPolicyClient { readonly base: BaseClient; private readonly getPrice?; readonly txBuilder: TxBuilder; constructor(base: BaseClient, getPrice?: (() => PriceClient) | undefined); get price(): PriceClient; fetchPolicy(): Promise; fetchMintPolicy(): Promise; setPolicy(policy: MintPolicy, txOptions?: TxOptions): Promise; setMintPolicy(policy: MintPolicy, txOptions?: TxOptions): Promise; clearPolicy(txOptions?: TxOptions): Promise; clearMintPolicy(txOptions?: TxOptions): Promise; /** * Fetches token holders of the GLAM mint using helius RPC. Falls back to * getHolders if helius API key is not provided or cluster is not mainnet. */ fetchTokenHolders(showZeroBalance?: boolean): Promise; getHolders(showZeroBalance?: boolean): Promise; initialize(initMintParams: InitMintParams, txOptions?: TxOptions): Promise; initializeWithStateParams(initMintParams: InitMintParams, stateParams: UpdateStateParams, txOptions?: TxOptions): Promise; update(mintModel: Partial, txOptions?: TxOptions): Promise; pauseSubscription(txOptions?: TxOptions): Promise; unpauseSubscription(txOptions?: TxOptions): Promise; pauseRedemption(txOptions?: TxOptions): Promise; unpauseRedemption(txOptions?: TxOptions): Promise; close(txOptions?: TxOptions): Promise; mint(to: PublicKey, amount: BN | number, unfreeze?: boolean, txOptions?: TxOptions): Promise; burn(from: PublicKey, amount: BN | number, unfreeze?: boolean, txOptions?: TxOptions): Promise; createTokenAccount(owner: PublicKey, setFrozen: boolean, txOptions?: TxOptions): Promise; setTokenAccountsStates(tokenAccounts: PublicKey[], frozen: boolean, txOptions?: TxOptions): Promise; enableTokenAcl(gatingProgram?: PublicKey, txOptions?: TxOptions): Promise; forceTransfer(from: PublicKey, to: PublicKey, amount: BN | number, unfreeze?: boolean, txOptions?: TxOptions): Promise; tokenAclFreeze(tokenAccounts: PublicKey[], txOptions?: TxOptions): Promise; tokenAclThaw(tokenAccounts: PublicKey[], txOptions?: TxOptions): Promise; aclGateCreateList(seed: Buffer, mode?: number, txOptions?: TxOptions): Promise; aclGateAddWallet(listConfig: PublicKey, wallet: PublicKey, txOptions?: TxOptions): Promise; aclGateRemoveWallet(listConfig: PublicKey, walletEntry: PublicKey, txOptions?: TxOptions): Promise; aclGateDeleteList(listConfig: PublicKey, txOptions?: TxOptions): Promise; aclGateSetupExtraMetas(listConfigs: PublicKey[], txOptions?: TxOptions): Promise; thawPermissionless(wallet: PublicKey, listAndWalletPairs: { listConfig: PublicKey; walletEntry: PublicKey; }[], txOptions?: TxOptions): Promise; } export {};