Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

222
Visualizações
Metadata.getMinimumBalanceForRentExemption seems to return wrong value. | mpl-token-metadata from Metaplex

I have a question for the createCreateMetadataAccountV2Instruction. I'm trying to calculate the fee with Metadata.getMinimumBalanceForRentExemption But seems it returns wrong value. I'm getting this error from the transaction.

Transfer: insufficient lamports 2491680, need 5616720

The function returns 1600800 but should be higher.

const metadataFee = await Metadata.getMinimumBalanceForRentExemption(
        {
          key: Key.MetadataV1,
          updateAuthority: mintAuthority,
          mint: form.mintAccount?.pubkey,
          data: tokenMetadata,
          primarySaleHappened: true,
          isMutable: true,
          tokenStandard: TokenStandard.Fungible,
          uses: null,
          collection: null,
          editionNonce: 255,
        },
        connection.current
      )

Please tell me if the args seem wrong.

Also I tried the Metadata.biteSize and it returned 102 but it's actually 679.

https://explorer.solana.com/address/R747jBxHo56wfb7FqVymdQWYpeny16Po6WwmXiiQ9g6?cluster=devnet

How to know the true rent fee? Please let me know if you know something about this.

Thank you always. Have a good day!

about 4 years ago · Juan Pablo Isaza
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda