0

I am following the the Metaplex Examples Repository recommended by the metaplex docs:

const getNFT = async () => {
  const nft = await metaplex
    .nfts()
    .findByMint(testIdentityTokenIssuer.publicKey);

  console.log(json.stringify(nft));
}

Returns:

{
  status: "pending",
  children: [],
  context: {},
  eventEmitter: {
    _events: {},
    _eventsCount: 0,
  },
}

This kind of looks like an unresolved promise, but I'm awaiting the result so it would have resolved at this point. How can I see the NFTs when using findByMint()?

1 Answer 1

1

Answering own question to help others:

My code is missing .run() - this is needed to execute the transaction:

const nft = await metaplex
    .nfts()
    .findByMint(testIdentityTokenIssuer.publicKey)
    .run();

The example in the docs is also missing the run() - I've raised an issue about this.

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.