You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The contract name and address (0x0b2a3299cc857e29, TopShot)
The NFT token ID (1234)
The Owner address (0x01)
Determine:
NFT metadata using metadata views
Problem
In the below example the CollectionPublicPath might not exists in the contract.
let collection = account
.getCapability(ExampleNFT.CollectionPublicPath)
.borrow<&{MetadataViews.ResolverCollection}>()
?? panic("Could not borrow a reference to the collection")
Example TopShot uses a different name for that variable.
Steps to Reproduce
Acceptance Criteria
Context
Also, the NFT Catalog does not have a simple way to fetch the metadata of a single NFT when only the data above is known.
The text was updated successfully, but these errors were encountered:
Thanks for sharing! So when we originally created the NFT standard, it wasn't possible to have paths as variables, so we weren't able to include a path requirement in the NonFungibleToken.Vault definition. As you probably know, upgrades are difficult in that we can't add paths to existing types, so adding these requirements on their own isn't really possible.
Additionally, the metadata views have a view to get the paths in the NFTCollectionData view, so projects can decide how they would like to store them and they can use the standard view to share them.
I do acknowledge that is is difficult to get metadata about an NFT without the paths though, but I'm not sure what we could do to have a standard for this in the short term since we can't add a path field requirement to the NFT standard without breaking every contract.
We do have a change that addresses this in the NFT standard V2 though, which will include breaking changes and will come later this year assuming we get enough buy-in from the community.
I'd recommend reading through those changes and leaving feedback, because we definitely could use the help. 🙂
Besides that, is there another option that you think we could do to make this easier?
Instructions
Given:
0x0b2a3299cc857e29
,TopShot
)1234
)0x01
)Determine:
Problem
In the below example the
CollectionPublicPath
might not exists in the contract.Example
TopShot
uses a different name for that variable.Steps to Reproduce
Acceptance Criteria
Context
Also, the NFT Catalog does not have a simple way to fetch the metadata of a single NFT when only the data above is known.
The text was updated successfully, but these errors were encountered: