hedera上的minting nfts返回max_nfts_in_price_regime_have_have_been_minted
我一直在尝试使用本机 tokenmintTransaction()函数来造成NFT,但是它一直返回max_nfts_in_in_price_rice_regime_have_have_been_been_minted错误。由于文档很糟糕,因此我很难找出错误的实际含义。
我使用了与他们的文档中解释的完全相同的代码:( https://docs.hedera.com/guides/getting-started/try-examples/create-and-transfer-your-first-nft )
let nftCreate = await new TokenCreateTransaction()
.setTokenName("diploma")
.setTokenSymbol("GRAD")
.setTokenType(TokenType.NonFungibleUnique)
.setDecimals(0)
.setInitialSupply(0)
.setTreasuryAccountId(treasuryId)
.setSupplyType(TokenSupplyType.Finite)
.setMaxSupply(250)
.setSupplyKey(supplyKey)
.freezeWith(client);
let nftCreateTxSign = await nftCreate.sign(treasuryKey);
let nftCreateSubmit = await nftCreateTxSign.execute(client);
let nftCreateRx = await nftCreateSubmit.getReceipt(client);
let tokenId = nftCreateRx.tokenId;
CID = ["**********************************************"];
let mintTx = await new TokenMintTransaction()
.setTokenId(tokenId)
.setMetadata([Buffer.from(CID)])
.freezeWith(client);
let mintTxSign = await mintTx.sign(supplyKey);
let mintTxSubmit = await mintTxSign.execute(client);
let mintRx = await mintTxSubmit.getReceipt(client);
所以我在这里做错了什么?
I have been trying to mint an NFT using the native TokenMintTransaction() function, but it keeps returning the MAX_NFTS_IN_PRICE_REGIME_HAVE_BEEN_MINTED error. Since the documentation is terrible I have a hard time finding out what the error actually means.
I used the exact same code as explained in their docs:(https://docs.hedera.com/guides/getting-started/try-examples/create-and-transfer-your-first-nft)
let nftCreate = await new TokenCreateTransaction()
.setTokenName("diploma")
.setTokenSymbol("GRAD")
.setTokenType(TokenType.NonFungibleUnique)
.setDecimals(0)
.setInitialSupply(0)
.setTreasuryAccountId(treasuryId)
.setSupplyType(TokenSupplyType.Finite)
.setMaxSupply(250)
.setSupplyKey(supplyKey)
.freezeWith(client);
let nftCreateTxSign = await nftCreate.sign(treasuryKey);
let nftCreateSubmit = await nftCreateTxSign.execute(client);
let nftCreateRx = await nftCreateSubmit.getReceipt(client);
let tokenId = nftCreateRx.tokenId;
CID = ["**********************************************"];
let mintTx = await new TokenMintTransaction()
.setTokenId(tokenId)
.setMetadata([Buffer.from(CID)])
.freezeWith(client);
let mintTxSign = await mintTx.sign(supplyKey);
let mintTxSubmit = await mintTxSign.execute(client);
let mintRx = await mintTxSubmit.getReceipt(client);
So what am I doing wrong here?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我似乎找到了一个答案。 TestNet已达到可铸造的最大NFT量(500万)。开发人员目前正在研究增加此限制的方法。
I seem to have found an answer. Testnet has reached the maximum amount of NFTs that can be minted (5 million). The devs are currently looking into ways to increase this limit.