Create Tokens on Solana

In this tutorial, we will focus on an agile and efficient approach to the ideation, creation and deployment of tokens on Solana, known as SPL tokens.

Instructions

  1. Create a new project folder

  2. Navigate to it in command line

  3. Prepare your development environment:

    1. Install @solana/web3.js: npm install @solana/web3.js

    2. Install @solana/spl-token: npm install @solana/spl-token

    3. Install @metaplex-foundation/js: npm install @metaplex-foundation/js

    4. Install @metaplex-foundation/mpl-token-metadata: npm install @metaplex-foundation/mpl-token-metadata

  4. Install MetaBoss

    1. cargo install metaboss

  5. Switch to Devnet - solana config set --url https://api.devnet.solana.com

  6. Create Keypair File - solana-keygen new --outfile C:Path\To\Keypair\File

  7. Get 1 SOL in Config Wallet - solana airdrop 1

  8. Create an OFF_CHAIN_DATA_JSON file

    Example:

    { "name":"Tunak Tunak Tun", "symbol":"TUNAK", "description": "TUNAK TUNAK TUN TUNAK TUNAK TUN TUNAK TUNAK TUN TAN TAN TAN", "image":"https://arweave.net/lkD2dSYcZG1XZCaj93QflHJZqdtPCeDxJ52bM1xmSm0", "attributes":[], "properties":{ "files":[ {"uri":"https://arweave.net/lkD2dSYcZG1XZCaj93QflHJZqdtPCeDxJ52bM1xmSm0", "type":"image/png"} ] } }

  9. Upload the token symbol to Arweave using Akord

  10. Add the image URI to the ”image” value and the ”files” value

  11. Upload the OFF_CHAIN_DATA_JSON to Arweave using Akord and get a URI

  12. Create an ON_CHAIN_DATA_JSON file

    Example:

    { "name": "Tunak Tunak Tun", "symbol": "TUNAK", "uri": "https://arweave.net/--_ohDuhkakw1qQka_vaqhvDq-R61wYxXq9CwVKol0s", "seller_fee_basis_points": 0 }

  13. Add the OFF_CHAIN_DATA_JSON URI to the ON_CHAIN_DATA_JSON

  14. Use MetaBoss to create the token

    1. metaboss create fungible -d 6 -m token_metadata/tunak_onchain.json

Last updated

Was this helpful?