3. Add assets and metadata
Last updated
Last updated
Stargaze's sg721 contract allows for off-chain metadata storage. We recommend using a decentralized storage solution such as IPFS.
In this guide, we will cover basic project structure as well as using or to upload your project to IPFS.
Add your NFT images and metadata .json
files to the respective images
and metadata
folders. Your project should be structured like this:
Files should be numbered sequentially and there should be a matching metadata file for each image.
Sample metadata files are available in /metadata
. Let's take a look at one of them.
After setting up your project, upload the files to IPFS using one of our guides:
After following the steps in the guides above, you'll receive a baseTokenUri
for your project. This way, the contract knows how to associate each token ID with an individual token URI without having to send the contract a list of URIs. All token URIs can be determined by appending the token ID to the base URL.
Be sure to update your config.js
with this baseTokenUri
.
Stargaze NFT metadata follows the .
(with script)