This repository contains the Rust implementation of the Solana PFP protocol.
The Solana PFP protocol allows Solana users to set a single Metaplex-standard NFT as a universal PFP for the Solana blockchain.
Program ID: 6UQLqKYWqErHqdsX6WtANQsMmvfKtWNuSSRj6ybg5in3
Program ID is the same on both mainnet and devnet deployments.
Instruction: 0 - Allows users to set a single Metaplex-standard NFT as their PFP
[signer]
The account of the person setting the NFT profile picture[writable]
NFT profile picture account (PDA)[]
NFT mint account[]
NFT token account[]
NFT Metaplex metadata account[]
Clock sysvar[]
System program
Instruction: 1 - Allows users to remove their PFP
[signer]
The account of the person removing the NFT profile picture[writable]
NFT profile picture account (PDA)
If you want to add new features to the protocol or improve existing ones, please follow the steps below.
- Install the latest Rust stable from https://rustup.rs/
- Install Solana v1.8.11 or later from https://docs.solana.com/cli/install-solana-cli-tools
- Install the
libudev
development package for your distribution (libudev-dev
on Debian-derived distros,libudev-devel
on Redhat-derived).
To compile the PFP rust code to the wasm binary, use:
cargo build-bpf
To deploy the compiled wasm binary, use:
solana program deploy ./target/deploy/solana_pfp_program.so