1

I understand what a mint account is. For example, I know that USDC has a single mint address on mainnet.

I know what associated token accounts are. For example, I know that my personal store of USDC is a token account inside by wallet.

enter image description here

However what I don't understand is the documentation from Metaplex:

/**
 * This model captures all the relevant information about an NFT
 * in the Solana blockchain. That includes the NFT's metadata account,
 * its mint account, its edition account and its off-chain JSON metadata.
 *
 * @group Models
 */
export type Nft = Omit<Metadata, 'model' | 'address' | 'mintAddress'> & {
    /** A model identifier to distinguish models in the SDK. */
    readonly model: 'nft';
    /** The mint address of the NFT. */
    readonly address: PublicKey;
    /** The metadata address of the NFT. */
    readonly metadataAddress: Pda;
    /** The mint account of the NFT. */
    readonly mint: Mint;
    /**
     * Defines whether the NFT is an original edition or a
     * printed edition and provides additional information accordingly.
     */
    readonly edition: NftEdition;
};

Metaplex says:

  • address is 'the mint address of the NFT'
  • metadataAddress is 'the metadata address of the NFT'
  • mint is 'the mint account of the NFT'

My problem: 'the mint address of the NFT' and 'the mint account of the NFT' seem like the same thing. What is the difference between them?

1 Answer 1

2

Although the TypeScript document describes mint as mint account, mint is an actually an object that gives you the data stored on the mint account such as decimals, supply, etc.

/**
 * This model represents a mint account.
 *
 * @group Models
 */
export type Mint = {
    /** A model identifier to distinguish models in the SDK. */
    readonly model: 'mint';
    /** The address of the mint account. */
    readonly address: PublicKey;
    /**
     * The address of the authority that is allowed
     * to mint new tokens to token accounts.
     *
     * When `null`, no authority is ever allowed to mint new tokens.
     */
    readonly mintAuthorityAddress: Option<PublicKey>;
    /**
     * The address of the authority that is allowed
     * to freeze token accounts.
     *
     * When `null`, no authority is ever allowed to freeze token accounts.
     */
    readonly freezeAuthorityAddress: Option<PublicKey>;
    /**
     * The number of decimal points used to define token amounts.
     */
    readonly decimals: number;
    /**
     * The current supply of tokens across all token accounts.
     */
    readonly supply: SplTokenAmount;
    /**
     * Helper boolean to determine whether this mint account is the
     * mint account that wraps SOL as an SPL token.
     */
    readonly isWrappedSol: boolean;
    /**
     * A currency object that can be used to create amounts
     * representing the tokens of this mint account.
     *
     * For instance, here's how you can transform an amount of token
     * in basis points into an `Amount` object.
     *
     * ```ts
     * const tokenBasisPoints = 1000;
     * const tokensAsAmount = amount(tokenBasisPoints, mint.currency);
     * ```
     */
    readonly currency: SplTokenCurrency;
};

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.