HomeAPI ReferenceTokensCreate Token from Template
POST/tokenization/deploy

Create Token from Template

Outcome - Deploys a token from a contract template. Pick the standard and the template, then give the template its config. The owner is an address (ownerAddress) or one of your clients (ownerClientId): give exactly one. Send JSON, or multipart/form-data to attach an image. The token comes back with status PENDING; it can be operated once DEPLOYED.

Body Parameters

standardnumber | stringrequired

Token standard, as its number or its name: 1 = ERC20, 2 = ERC3643, 5 = ERC721.

templatestringrequired

Template of the standard: erc20-v1 (ERC20), erc721-v1 (ERC721), erc3643-v1 or title-fraction-v1 (ERC3643). Any other pair returns 422.

configobjectrequired

The template's settings. Each template takes only its own fields, listed below.

Show child parameters (9)
canMintbooleanerc20-v1: required

erc20-v1: allow MINT after creation. A capability set to false can never be used.

canBurnbooleanerc20-v1, erc721-v1: required

erc20-v1 and erc721-v1: allow BURN.

canPausebooleanerc20-v1, erc721-v1: required

erc20-v1 and erc721-v1: allow PAUSE and UNPAUSE.

documentstringmax(20000)

erc20-v1 and erc721-v1: legal or descriptive text stored with the token.

identityRegistryAddressstringerc3643-v1, title-fraction-v1: required

erc3643-v1 and title-fraction-v1: your ERC-3643 identity registry. Only addresses verified in it can receive the token.

complianceAddressstringerc3643-v1: required

erc3643-v1: your compliance contract. It must not be bound to another token yet.

onchainIdAddressstring

erc3643-v1: the token's own ONCHAINID.

escrowAddressstringtitle-fraction-v1: required

title-fraction-v1: the TradeTrust title escrow that holds the title. It must be active and hold the title.

depositorAddressstringtitle-fraction-v1: required

title-fraction-v1: the title's current beneficiary. The fractions are minted to this address, and it can cancel before fractionalizing.

networkIdnumberrequired

EVM network to deploy on. See Get Token Supported Networks.

namestringrequiredmin(2)max(255)

Token name.

symbolstringrequiredmin(2)max(45)

Token symbol.

decimalsnumber0 to 18

Decimals. ERC20 and ERC3643: required, 0 to 18 (title-fraction-v1: exactly 0). ERC721: not accepted.

initialSupplystringdigits only

erc20-v1 only: whole tokens minted at creation, digits only. Required above 0 when canMint is false. ERC3643 and ERC721 refuse it: their supply comes from later operations.

ownerAddressstring

Address that will own the contract. Give ownerAddress or ownerClientId.

ownerClientIdstring

Your client id (externalId): the client's wallet on this network owns the contract. Give ownerAddress or ownerClientId.

recipientAddressstring

erc20-v1: address that receives initialSupply. Defaults to the owner.

payerPublicAddressstring

A wallet of this vault on this network that pays the deployment fee, instead of the gas station.

imagefile

Token image. Only with multipart/form-data.

idempotencyKeystring

Your unique key for this creation. Repeating it returns the first token instead of creating another.

Responses

Response attributes

messagestring

Success message

dataobject

The token, with status PENDING until the contract is deployed

Show child attributes (32)
idnumber

Token ID. Use it in the token routes (Get Token by ID, Get Token Roles, Token Operations).

networkIdnumber

Network the contract is deployed on

deployingWalletIdstring

ID of the vault wallet that sent the deployment

templateVersionstring | null

Contract template: erc20-v1, erc721-v1, erc3643-v1 or title-fraction-v1. null for Solana tokens.

namestring

Token name

symbolstring

Token symbol

decimalsnumber

Decimals of the token. Amounts in the API are in whole units with up to this many decimals.

feesstring | null

Deployment fee paid, in the network's coin. null until deployed.

contractAddressstring | null

Contract address. null until deployed.

assetIdnumber | null

Asset created for the token once deployed: wallets of this asset hold the token. null until deployed.

vaultIdnumber

Vault that created the token

internalOwnerTypestring | null

CLIENT when the owner is a client's wallet, MASTER when it is a master wallet of the vault, null when the owner is outside RoxCustody

internalOwnerTargetIdnumber | null

The RoxCustody client ID when internalOwnerType is CLIENT

ownerAddressstring

Owner of the contract (the OWNER role)

recipientAddressstring

Address that received the initial supply (equal to ownerAddress when none was given)

configobject

The config sent at creation (template settings). Solana and v1 tokens also carry metadataUrl and additional here.

verificationMessagestring | null

The block explorer's answer to the source-code verification

verificationStatusstring

Source-code verification on the block explorer: PENDING, VERIFIED, REJECTED, LimitReached or UNEXPECTED_ERROR

imagestring | null

Image URL, when an image was uploaded

isCollectionboolean

true for an NFT collection

parentIdnumber | null

For an NFT, its collection

parentobject | null

For an NFT, its collection

childrenCountnumber

For a collection, number of NFTs in it

networkobject

The network

Show child attributes (12)
idnumber

Network ID

namestring

Network name

symbolstring

Symbol of the network's coin

createdAtstring

Creation date

updatedAtstring

Last update date

typestring

PUBLIC or PRIVATE

statusstring

Network status, for example ACTIVE

logostring

Network logo URL

isSwappableboolean

Whether swaps are available on this network

categorystring

Network family, for example EVM or Solana

chainobject

Chain details: id, name, nativeCurrency, rpcUrls, blockExplorers and testnet

addressFormatobject

Address format: prefixes and lengthRange

createdAtstring

Creation date

updatedAtstring

Last update date

typestring

Asset type of the token: ERC20 for every fungible EVM token (ERC-20 and ERC-3643 alike), NFT_COLLECTION for an ERC-721 collection, TOKEN or NFT on Solana

standardstring | null

Token standard: ERC20, ERC3643, ERC721, SPL_TOKEN or SOLANA_NFT

statusstring

Deployment status: PENDING, DEPLOYED, REVERTED, INSUFFICIENT_GAS, ERROR or NONCE_TOO_LOW

tokenExplorerUrlstring | null

Link to the contract on the block explorer. null until deployed.

initialSupplystring

Supply minted at creation, in whole units. "0" for ERC-3643 and ERC-721, whose supply comes from later operations.

vaultobject

The vault that created the token: id, name, category, vaultType, gasStationCategoryId (set when fees are gasless) and its other settings

statusnumber

HTTP status code

Was this page helpful?