Appearance
Solidity API
PropsMetadataTokenBased
This contract manages token-based metadata for Props tokens. It inherits from PropsBaseFacet, PropsMetadataTokenBasedInternal, and implements IPropsMetadataTokenBased.
uri
solidity
function uri(uint256 _tokenId) public view returns (string)Returns the metadata URI for a given token ID.
Parameters
| Name | Type | Description |
|---|---|---|
| _tokenId | uint256 | The ID of the token to query. |
Return Values
| Name | Type | Description |
|---|---|---|
| [0] | string | A string containing the metadata URI. |
setTokenMetadata
solidity
function setTokenMetadata(uint256 _tokenId, string _metadata) publicOnly accounts with METADATA_MANAGER_ROLE or the diamond owner can call this function. Emits a TokenMetadataUpdated event.
Sets the metadata for a specific token.
Parameters
| Name | Type | Description |
|---|---|---|
| _tokenId | uint256 | The ID of the token to update. |
| _metadata | string | The new metadata string to set for the token. |