@metaplex-foundation/mpl-toolbox
Version:
Auto-generated essential Solana and Metaplex programs
34 lines (33 loc) • 1.58 kB
TypeScript
/**
* This code was AUTOGENERATED using the kinobi library.
* Please DO NOT EDIT THIS FILE, instead use visitors
* to add features, then rerun kinobi to update it.
*
* @see https://github.com/metaplex-foundation/kinobi
*/
import { Context, Pda, PublicKey, Signer, TransactionBuilder } from '@metaplex-foundation/umi';
import { Serializer } from '@metaplex-foundation/umi/serializers';
export type CreateTokenIfMissingInstructionAccounts = {
/** The account paying for the token account creation if needed */
payer?: Signer;
/** The token account that may or may not exist */
token?: PublicKey | Pda;
/** The mint account of the provided token account */
mint: PublicKey | Pda;
/** The owner of the provided token account */
owner?: PublicKey | Pda;
/** The associated token account which may be the same as the token account */
ata?: PublicKey | Pda;
/** System program */
systemProgram?: PublicKey | Pda;
/** Token program */
tokenProgram?: PublicKey | Pda;
/** Associated Token program */
ataProgram?: PublicKey | Pda;
};
export type CreateTokenIfMissingInstructionData = {
discriminator: number;
};
export type CreateTokenIfMissingInstructionDataArgs = {};
export declare function getCreateTokenIfMissingInstructionDataSerializer(): Serializer<CreateTokenIfMissingInstructionDataArgs, CreateTokenIfMissingInstructionData>;
export declare function createTokenIfMissing(context: Pick<Context, 'eddsa' | 'identity' | 'payer' | 'programs'>, input: CreateTokenIfMissingInstructionAccounts): TransactionBuilder;