Skip to main content

NFT Commands

Commands

chia_getNFTs

Requests a full or paginated list of NFTs.

ParameterTypeDescription
walletIdsnumber[]NFT wallet ids.
numnumberNumber of NFTs to fetch.
startIndexnumberIndex to start from in the list.

Output data

The output is an object of type Record<string, NFTInfo[]>, where the keys are wallet ids.

chia_getNFTInfo

Gets information about a specific NFT.

ParameterTypeDescription
coinIdstringNFT launcher id.

Output Data

The output is an object of type NftInfo.

chia_mintNFT

ParameterTypeDescription
walletIdnumberNFT wallet id.
royaltyAddress (optional)string | nullAddress royalty is sent to.
royaltyPercentage (optional)number | nullCreator royalty percent. (1000 = 1%)
targetAddress (optional)string | nullAddress NFT is sent to upon mint.
urisstring[]List of NFT content URIs.
hashstringHash of the NFT content.
metaUrisstring[]List of metadata URIs.
metaHash (optional)string | nullHash of the metadata.
licenseUrisstring[]List of the license URIs.
licenseHash (optional)string | nullHash of the license.
editionNumber (optional)number | nullNumber of the current NFT in edition.
editionTotal (optional)number | nullHow many NFTs in the current edition.
didId (optional)string | nullThe DID used during an NFT mint.
fee (optional)number | nullTransaction fee in mojos.

Output Data

ParameterTypeDescription
nftIdstringThe NFT id.
spendBundleSpendBundleCreated spend bundle.
successbooleanBackend success status.
walletIdnumberNFT wallet id.

chia_transferNFT

ParameterTypeDescription
walletIdnumberNFT wallet id.
launcherIdstringNFT launcher id.
nftCoinIdsstring[]NFT coin ids.
targetAddressstringBech32m encoded address to transfer to.
feenumberTransaction fee in mojos.

Output Data

ParameterTypeDescription
walletIdnumber | number[]NFT wallet id(s).
spendBundleSpendBundleCreated spend bundle.
txNum? (optional)numberTransaction number.

chia_getNFTsCount

ParameterTypeDescription
walletIdsnumber[]NFT wallet ids.

Output Data

The output is an object of type Record<string, number>, where the keys are wallet ids. It has the following additional key:

ParameterTypeDescription
totalnumberTotal number of NFTs.

chia_setNFTDID

Sets the owner DID associated with a given NFT.

ParameterTypeDescription
walletIdnumberWallet id.
nftLauncherIdstringNFT launcher id.
nftCoinIdsstring[]NFT coin ids.
didstringBech32m encoded DID address.
feenumberTransaction fee in mojos.

Output Data

ParameterTypeDescription
walletIdnumberWallet id.
spendBundleSpendBundleCreated spend bundle.
successbooleanBackend success status.

Types

NFTInfo

ParameterTypeDescription
nftIdstringThe NFT id.
launcherIdstringThe launcher id.
nftCoinIdstringThe current coin id.
nftCoinConfirmationHeightnumberCurrent NFT coin confirmation height
ownerDidstring | nullThe owner DID.
royaltyPercentagenumber | nullCreator royalty percent. (1000 = 1%)
royaltyPuzzleHashstring | nullPuzzle hash royalty is sent to.
royaltyAddressstringAddress royalty is sent to.
targetAddressstringAddress NFT is sent to upon mint.
urisstring[]List of NFT content URIs.
hashstringHash of the NFT content.
metaUrisstring[]List of metadata URIs.
metaHashstringHash of the metadata.
licenseUrisstring[]List of the license URIs.
licenseHashstringHash of the license.
editionTotalnumberHow many NFTs in the current edition.
editionNumbernumberNumber of the current NFT in edition.
updaterPuzhashstringPuzzle hash of the metadata updater.
chainInfostringInformation saved on the chain.
mintHeightnumberBlock height when the NFT was minted.
supportsDidbooleanWhether the inner puzzle supports DID.
p2AddressstringThe innermost puzzle hash of the NFT.
pendingTransactionbooleanWhether the NFT is pending for a tx.
didIdstring | nullThe DID used during an NFT mint.
minterDidstring | nullThe minter DID.
launcherPuzhashstringSingleton launcher puzzle hash.
offChainMetadatastring | nullSerialized off-chain metadata.