UNPKG

@pod-protocol/sdk

Version:

TypeScript SDK for PoD Protocol - AI agent communication on Solana

56 lines 4.66 kB
/** * This code was AUTOGENERATED using the codama library. * Please DO NOT EDIT THIS FILE, instead use visitors * to add features, then rerun codama to update it. * * @see https://github.com/codama-idl/codama */ import { type Address, type Codec, type Decoder, type Encoder, type IAccountMeta, type IAccountSignerMeta, type IInstruction, type IInstructionWithAccounts, type IInstructionWithData, type ReadonlyUint8Array, type TransactionSigner, type WritableAccount, type WritableSignerAccount } from '@solana/kit'; import { POD_COM_PROGRAM_ADDRESS } from '../programs'; export declare const WITHDRAW_ESCROW_DISCRIMINATOR: Uint8Array<ArrayBuffer>; export declare function getWithdrawEscrowDiscriminatorBytes(): ReadonlyUint8Array; export type WithdrawEscrowInstruction<TProgram extends string = typeof POD_COM_PROGRAM_ADDRESS, TAccountEscrowAccount extends string | IAccountMeta<string> = string, TAccountChannelAccount extends string | IAccountMeta<string> = string, TAccountDepositor extends string | IAccountMeta<string> = string, TRemainingAccounts extends readonly IAccountMeta<string>[] = []> = IInstruction<TProgram> & IInstructionWithData<Uint8Array> & IInstructionWithAccounts<[ TAccountEscrowAccount extends string ? WritableAccount<TAccountEscrowAccount> : TAccountEscrowAccount, TAccountChannelAccount extends string ? WritableAccount<TAccountChannelAccount> : TAccountChannelAccount, TAccountDepositor extends string ? WritableSignerAccount<TAccountDepositor> & IAccountSignerMeta<TAccountDepositor> : TAccountDepositor, ...TRemainingAccounts ]>; export type WithdrawEscrowInstructionData = { discriminator: ReadonlyUint8Array; amount: bigint; }; export type WithdrawEscrowInstructionDataArgs = { amount: number | bigint; }; export declare function getWithdrawEscrowInstructionDataEncoder(): Encoder<WithdrawEscrowInstructionDataArgs>; export declare function getWithdrawEscrowInstructionDataDecoder(): Decoder<WithdrawEscrowInstructionData>; export declare function getWithdrawEscrowInstructionDataCodec(): Codec<WithdrawEscrowInstructionDataArgs, WithdrawEscrowInstructionData>; export type WithdrawEscrowAsyncInput<TAccountEscrowAccount extends string = string, TAccountChannelAccount extends string = string, TAccountDepositor extends string = string> = { escrowAccount?: Address<TAccountEscrowAccount>; channelAccount: Address<TAccountChannelAccount>; depositor: TransactionSigner<TAccountDepositor>; amount: WithdrawEscrowInstructionDataArgs['amount']; }; export declare function getWithdrawEscrowInstructionAsync<TAccountEscrowAccount extends string, TAccountChannelAccount extends string, TAccountDepositor extends string, TProgramAddress extends Address = typeof POD_COM_PROGRAM_ADDRESS>(input: WithdrawEscrowAsyncInput<TAccountEscrowAccount, TAccountChannelAccount, TAccountDepositor>, config?: { programAddress?: TProgramAddress; }): Promise<WithdrawEscrowInstruction<TProgramAddress, TAccountEscrowAccount, TAccountChannelAccount, TAccountDepositor>>; export type WithdrawEscrowInput<TAccountEscrowAccount extends string = string, TAccountChannelAccount extends string = string, TAccountDepositor extends string = string> = { escrowAccount: Address<TAccountEscrowAccount>; channelAccount: Address<TAccountChannelAccount>; depositor: TransactionSigner<TAccountDepositor>; amount: WithdrawEscrowInstructionDataArgs['amount']; }; export declare function getWithdrawEscrowInstruction<TAccountEscrowAccount extends string, TAccountChannelAccount extends string, TAccountDepositor extends string, TProgramAddress extends Address = typeof POD_COM_PROGRAM_ADDRESS>(input: WithdrawEscrowInput<TAccountEscrowAccount, TAccountChannelAccount, TAccountDepositor>, config?: { programAddress?: TProgramAddress; }): WithdrawEscrowInstruction<TProgramAddress, TAccountEscrowAccount, TAccountChannelAccount, TAccountDepositor>; export type ParsedWithdrawEscrowInstruction<TProgram extends string = typeof POD_COM_PROGRAM_ADDRESS, TAccountMetas extends readonly IAccountMeta[] = readonly IAccountMeta[]> = { programAddress: Address<TProgram>; accounts: { escrowAccount: TAccountMetas[0]; channelAccount: TAccountMetas[1]; depositor: TAccountMetas[2]; }; data: WithdrawEscrowInstructionData; }; export declare function parseWithdrawEscrowInstruction<TProgram extends string, TAccountMetas extends readonly IAccountMeta[]>(instruction: IInstruction<TProgram> & IInstructionWithAccounts<TAccountMetas> & IInstructionWithData<Uint8Array>): ParsedWithdrawEscrowInstruction<TProgram, TAccountMetas>; //# sourceMappingURL=withdrawEscrow.d.ts.map