• Retrieves the most recent owner of a minted item on Magic Eden, excluding Magic Eden's address.

    Parameters

    • endpoint: string

      The Solana network endpoint to connect to.

    • mintAddress: string

      The mint address of the NFT or asset.

    Returns Promise<null | string>

    • A promise that resolves with the address of the most recent owner, or null if not found.

    Throws

    • Throws an error if unable to fetch transaction information.

    Example

    const run = async () => {
    const solanaEndpoint = 'https://api.mainnet-beta.solana.com';
    const mintAddress = 'MintAddressHere';

    try {
    const owner = await getMagicEdenOwner(solanaEndpoint, mintAddress);
    console.log('Most Recent Owner:', owner);
    } catch (error) {
    console.error('Error:', error);
    }
    }

    run();

Generated using TypeDoc