SoLibrary
  • Solana
  • The Meme Coin Problem and Solution
  • Developing on Solana
  • From Rust To Deployment
  • Solana Blockchain Explorer
  • Building a Solana dAPP
  • Deploying a Solana dApp
  • Deploying a Solana Memecoin using CLI
  • Solana Smart Contracts
  • Send Solana via javascript functions
  • Candy Machine
  • Pump fun APIs
  • Metaplex
  • Metaplex Program Library
  • Solana Program Library
  • UMI Framework
  • Umi and Web3js Differences
  • Fetching Accounts
  • UMI Helpers
  • HTTP Requests
  • Umi's Interfaces
  • Interface implementations
  • Kinobi
  • UMI Plugins
  • Registering Programs
  • Public keys and Signers
  • Connecting RPCS
  • Serializer
  • Storage
  • Transactions
  • Web 3.JS Adapters
  • Metaplex Umi Plugins
  • Core JS SDK v1.0
  • Local Validator
  • SolScriptions
  • FAQ
  • Initialize
  • Write Inscription Data
  • Fetch
  • Clear
  • Close
  • Authority
  • Sharding
  • Getting Started using JavaScript
  • Getting started using the Inscriptions CLI
  • Core Candy Machine
  • Getting Started using JavaScript
  • Candy Guard
  • Assets
  • Creating a Core Candy Machine
  • Inserting Items
  • Updating The Core Candy Machine
  • Guard Groups
  • Special Guard Instructions
  • Fetching a Core Candy Machine
  • Minting
  • Withdrawing a Core Candy Machine
  • Address Gate Guard
  • Allocation
  • Allowlist Guard
  • Asset Burn Guard
  • Asset Burn Multi
  • Asset Payment Guard
  • Asset Payment Multi
  • Asset Mint Limit
  • Bot Tax Guard
  • End Date Guard
  • Edition
  • Freeze Sol Payment guard
  • Freeze Token Payment Guard
  • Gatekeeper Guard
  • Mint Limit Guard
  • NFT Burn Guard
  • NFT Gate Guard
  • NFT Mint Limit Guard
  • NFT Payment Guard
  • Program Gate Guard
  • Redeemed Amount Guard
  • Sol Fixed Fee Guard
  • Sol Payment Guard
  • Start Date Guard
  • Third Party Signer Guard
  • Token Burn Guard
  • Token Gate Guard
  • Token Payment Guard
  • Token2022 Payment Guard
  • Generating Custom Guard Client for Core Candy Machine
Powered by GitBook
On this page
  • Download the NFTs
  • Estimate cost (Optional)
  • Trim JSON fields (Optional)
  • Compress Images (Optional)
  • Inscribe!

Getting started using the Inscriptions CLI

Set up your workspace

PreviousGetting Started using JavaScriptNextCore Candy Machine

Last updated 10 months ago

Clone the .

git clone https://github.com/metaplex-foundation/mpl-inscription.git

The CLI lives in the repo in the clients/cli subdirectory. The dependencies must first be installed before it can be run.

pnpm install

After that bulk Inscribing can be invoked using the following commands. Commands that are optional are indicated

Download the NFTs

This command is used for initializing the assets that will be inscribed. The Download process will create a cache folder in the running directory and store the JSON (.json) and Media (.png, .jpg, .jpeg) files associated with the NFT there, along with a .metadata file which stores data for other CLI commands. The name of each file will be the mint address of the NFT being inscribed.

If you wish to manually override any of the JSON or media files being inscribed, replace the relevant file in the cache directory with the file you'd like to inscribe instead.

Download your NFT assets.

Bash (Hashlist)

pnpm cli download hashlist -r <RPC_URL> -k <KEYPAIR_FILE> -h <HASHLIST_FILE>

Estimate cost (Optional)

The total cost of inscribing an NFT can be determined using this command. It calculates the SOL rent costs for inscribing NFTs based on the account overhead and the file sizes in the cache directory.

Estimate total NFT Inscription cost.

Bash (Hashlist)

pnpm cli cost hashlist -h <HASHLIST_FILE>

Trim JSON fields (Optional)

This command can be used to trim JSON fields from the .json file associated with an NFT. Oftentimes NFT JSON data includes deprecated fields that can be removed for cost savings during the Inscription process. For example the 'seller_fee_basis_points', 'creators', and 'collection' fields are all deprecated in the JSON data and can be removed to save on rent cost. Additionally, the description field is often long and creators may want to remove this for cost savings. The default fields to be removed if the --remove option isn't provided are 'symbol', 'description', 'seller_fee_basis_points', and 'collection'.

Trim JSON fields.

Bash (Hashlist)

pnpm cli compress json --fields symbol

Compress Images (Optional)

The CLI also offers the ability to compress images before inscribing, to further save on rent cost. They can be compressed on three metrics:

  • Quality (number 1-100, default: 80) (only applicable for jpegs) which reduces the overall clarity and colors available in the image.

  • Size (number 1-100, default: 100) - Reducing the total image size with lower numbers being smaller images.

  • Extension (png or jpg, default: jpg) - Change the image to the specified file type, with jpegs typically being smaller (but lossier) than pngs.

Compress Images.

Bash (Hashlist)

pnpm cli compress images -q <QUALITY> -s <SIZE> -e <EXTENSION>

Inscribe!

Download your NFT assets.

Bash (Hashlist)

pnpm cli inscribe hashlist -r <RPC_URL> -k <KEYPAIR_FILE> -h <HASHLIST_FILE>
mpl-inscription repo