ITRACE

Git Source

Author: transientlabs.xyz

Interface for TRACE

Interface id = 0xcfec4f64

Functions

mint

Function to mint a single token

Requires owner or admin

function mint(address recipient, string calldata uri) external;

Parameters

NameTypeDescription
recipientaddressThe recipient of the token - assumed as able to receive 721 tokens
uristringThe token uri to mint

mint

Function to mint a single token with specific token royalty

Requires owner or admin

function mint(address recipient, string calldata uri, address royaltyAddress, uint256 royaltyPercent) external;

Parameters

NameTypeDescription
recipientaddressThe recipient of the token - assumed as able to receive 721 tokens
uristringThe token uri to mint
royaltyAddressaddressRoyalty payout address for this new token
royaltyPercentuint256Royalty percentage for this new token

airdrop

Function to airdrop tokens to addresses

Requires owner or admin

Utilizes batch mint token uri values to save some gas but still ultimately mints individual tokens to people

The baseUri folder should have the same number of json files in it as addresses in addresses

The baseUri folder should have files named without any file extension

function airdrop(address[] calldata addresses, string calldata baseUri) external;

Parameters

NameTypeDescription
addressesaddress[]Dynamic array of addresses to mint to
baseUristringThe base uri for the batch, expecting json to be in order, starting at file name 0, and SHOULD NOT have a trailing /

externalMint

Function to allow an approved mint contract to mint

Requires the caller to be an approved mint contract

function externalMint(address recipient, string calldata uri) external;

Parameters

NameTypeDescription
recipientaddressThe recipient of the token - assumed as able to receive 721 tokens
uristringThe token uri to mint

transferToken

Function to transfer token to another wallet

Callable only by owner or admin

Useful if a chip fails or an alteration damages a chip in some way

function transferToken(address from, address to, uint256 tokenId) external;

Parameters

NameTypeDescription
fromaddressThe current owner of the token
toaddressThe recipient of the token
tokenIduint256The token to transfer

setTracersRegistry

Function to set a new TRACERS registry

Callable only by owner or admin

function setTracersRegistry(address newTracersRegistry) external;

Parameters

NameTypeDescription
newTracersRegistryaddressThe new TRACERS Registry

addVerifiedStory

Function to write stories for tokens

Requires that the passed signature is signed by the token owner, which is the ARX Halo Chip (physical)

Uses EIP-712 for the signature

function addVerifiedStory(uint256[] calldata tokenIds, string[] calldata stories, bytes[] calldata signatures)
    external;

Parameters

NameTypeDescription
tokenIdsuint256[]The tokens to add a stories to
storiesstring[]The story text
signaturesbytes[]The signtatures from the chip to verify physical presence

setTokenUri

Function to update a token uri for a specific token

Requires owner or admin

function setTokenUri(uint256 tokenId, string calldata newUri) external;

Parameters

NameTypeDescription
tokenIduint256The token to propose new metadata for
newUristringThe new token uri proposed

Events

TRACERSRegistryUpdated

event TRACERSRegistryUpdated(
    address indexed sender, address indexed oldTracersRegistry, address indexed newTracersRegistry
);