UNPKG

@cobaltx/sdk-v2

Version:

An SDK for building applications on top of CobaltX.

39 lines (36 loc) 1.63 kB
import { NetworkName } from '../config.js'; import { AccountMeta, PublicKey } from '@solana/web3.js'; interface AccountMetaProps { pubkey: PublicKey; isSigner?: boolean; isWritable?: boolean; } declare function accountMeta({ pubkey, isSigner, isWritable }: AccountMetaProps): AccountMeta; declare const commonSystemAccountMeta: AccountMeta[]; type PublicKeyish = PublicKey | string; declare function validateAndParsePublicKey({ publicKey: orgPubKey, transformSol, network, }: { publicKey: PublicKeyish; transformSol?: boolean; network?: NetworkName; }): PublicKey; declare function tryParsePublicKey(v: string): PublicKey | string; declare const MEMO_PROGRAM_ID: PublicKey; declare const MEMO_PROGRAM_ID2: PublicKey; declare const RENT_PROGRAM_ID: PublicKey; declare const CLOCK_PROGRAM_ID: PublicKey; declare const METADATA_PROGRAM_ID: PublicKey; declare const INSTRUCTION_PROGRAM_ID: PublicKey; declare const SYSTEM_PROGRAM_ID: PublicKey; declare const SOLMint: PublicKey; declare function getMintAddresses(network: NetworkName): { USDCMint: PublicKey; USDTMint: PublicKey; WSOLMint: PublicKey; ETHMint: PublicKey; BONK_Mint: PublicKey; SOL_Mint: PublicKey; INPUT_MINT: PublicKey; OUTPUT_MINT: PublicKey; }; declare function solToWSol(mint: PublicKeyish, network: NetworkName): PublicKey; export { CLOCK_PROGRAM_ID, INSTRUCTION_PROGRAM_ID, MEMO_PROGRAM_ID, MEMO_PROGRAM_ID2, METADATA_PROGRAM_ID, PublicKeyish, RENT_PROGRAM_ID, SOLMint, SYSTEM_PROGRAM_ID, accountMeta, commonSystemAccountMeta, getMintAddresses, solToWSol, tryParsePublicKey, validateAndParsePublicKey };