• Fetch and decode a token mint.

    Automatically detects Token vs Token-2022 and applies the appropriate decoder.

    Parameters

    Returns Promise<FetchedMint | null>

    Decoded mint, or null if not found.

    const mint = await fetchMint(transport, mintPubkey);
    if (mint) console.log(`Supply: ${mint.decoded.supply}, Decimals: ${mint.decoded.decimals}`);

    1.1.0