Huione Docs
White Paper
Developers
Developers
  • Learn
    • Introduction to Huione Chain
    • Getting started with Huione Chain
  • Architecture
    • What is a Huione Chain Cluster?
    • Clusters
      • Huione Chain Clusters
      • RPC Endpoints
      • Benchmark a Cluster
      • Performance Metrics
    • Consensus
      • Synchronization
      • Leader Rotation
      • Fork Generation
      • Managing Forks
      • Turbine Block Propagation
      • Commitment Status
      • Secure Vote Signing
      • Stake Delegation and Rewards
    • Validators
      • Overview
      • TPU
      • TVU
      • Blockstore
      • Gossip Service
      • The Runtime
    • Dex & Swap
      • Trade on dex
      • Trade on swap
  • CLI
    • Command-line Guide
    • Install the Huione Tool Suite
    • Command-line Wallets
      • Command Line Wallets
      • Paper Wallet
      • File System Wallet
      • Support / Troubleshooting
    • Using Huione Chain CLI
    • Connecting to a Cluster
    • Send and Receive Tokens
    • Staking
    • Deploy a Program
    • Offline Transaction Signing
    • Durable Transaction Nonces
    • CLI Usage Reference
  • Developers
    • Get Started
      • Hello World
      • Local development
      • Rust program
    • Core Concepts
      • Accounts
      • Transactions
        • Overview
        • Versioned Transactions
        • Address Lookup Tables
      • Programs
      • Rent
      • Calling between programs
      • Runtime
    • Clients
      • JSON RPC API -1
      • JSON RPC API -2
      • JSON RPC API -3
      • Web3 JavaScript API
      • Web3 API Reference
      • Rust API
    • Writing Programs
      • Overview
      • Developing with Rust
      • Deploying
      • Debugging
      • Program Examples
      • FAQ
    • Native Programs
      • Overview
      • Sysvar Cluster Data
    • Local Development
      • Huione Test Validator
    • Backward Compatibility Policy
    • Anchor Book
      • Introduction
        • What is Anchor
        • Anchor Documentation
        • Prerequisites
      • Getting Started
        • Installation
        • Hello, Anchor!
      • Anchor Programs In-Depth
        • Essentials
          • High-level Overview
          • The Accounts Struct
          • The Program Module
          • Errors
          • Milestone Project - Tic-Tac-Toe
        • Intermediate
          • Cross-Program Invocations
          • PDAs
          • Events
      • Anchor BTS
        • The Discriminator
      • Anchor References
        • Space Reference
        • Javascript Anchor Types Reference
        • CLI Reference
        • Code References
  • Validators
    • Running a Validator
    • Getting Started
      • Validator Requirements
    • Voting Setup
      • Starting a Validator
      • Vote Account Management
      • Staking
      • Monitoring a Validator
      • Publishing Validator Info
      • Failover Setup
      • Troubleshooting
    • Geyser
      • Geyser Plugins
  • Staking
    • Staking on Huione
    • Stake Account Structure
  • Integrations
    • Add Huione to Your Exchange
    • Retrying Transactions
  • Library
    • Introduction
    • Token Program
    • Associated Token Account Program
    • Memo Program
    • Name Service
    • Feature Proposal Program
    • NFT Program
      • Overview
      • Interface
      • Usage Guidelines
        • Create a new NFT-Mint
        • Cast NFT
        • Transfer an NFT
        • Change account status
        • Permission settings
        • Query Interface
        • Continuous casting
        • Change the Mint attribute
      • Operation Overview
        • Create a new NFT-Mint
        • Transfer NFT
        • Destroy
        • Freeze NFT accounts
        • Update
    • Huione multi-sign program
      • Overview
      • Interface
      • Usage Guidelines
        • Create a multi-signature account
        • Create a proposal account
        • Vote proposal
        • Verify Proposal
        • Add-singer
        • Remove-signer
      • Operation Overview
        • Create a multi-signature account
        • Create a proposal account
        • Vote
        • Verify
        • Add-singer
        • Remove-signer
Powered by GitBook
On this page

Was this helpful?

  1. Library
  2. NFT Program
  3. Usage Guidelines

Transfer an NFT

The transfer instruction transfers the ownership of one NFT to another address.

$ hpl-nft transfer --from /root/.config/huione/id2.json –nft
62Tt6NNUxQbBYx6x5P1s42t7KWQdDamn9ATb6Ls5HYVv --recipient 
DySd8hi7Z4jrV3ixAk5dT1kPJQzKMiUyyCF38DiJypLY
	
program_id An2DRyUtGBKYioLhHJEQ3nPcGgzzRJQ8vgdhyjdtC14H
recipient:  DySd8hi7Z4jrV3ixAk5dT1kPJQzKMiUyyCF38DiJypLY
nft:  62Tt6NNUxQbBYx6x5P1s42t7KWQdDamn9ATb6Ls5HYVv

Signature: 5yVM4LKkUfF7ybRoM97kP7Sf3bqCTrjg8Shud2zfKDe8QSogPwdXmS9WYRStKigvvUEKo6iUKHHRagcrsmRNiPFC

The transfer parameter must be the private key of the NFT.

After the transfer transaction is completed on the chain, the owner of the NFT will change and the sender will not have the right to operate the NFT.

$ hpl-nft nft-info 62Tt6NNUxQbBYx6x5P1s42t7KWQdDamn9ATb6Ls5HYVv

Mint : 2ZYMxZojdocSbwcGg4W92H3hVE9qgMBo7XQg9aug6uKs
Owner: DySd8hi7Z4jrV3ixAk5dT1kPJQzKMiUyyCF38DiJypLY
State: Initialized
Token id: 1
Token url: http://my.asset.uri.path
Close authority: None

You can see that Owner has changed from the original 97pqCNMq4NUBVa6DSabNiRPQAbtM8ixEDvXYWQCPLxBi to DySd8hi7Z4jrV3ixAk5dT1kPJQzKMiUyyCF38DiJypLY.

PreviousCast NFTNextChange account status

Last updated 7 months ago

Was this helpful?