Skip to main content

Avatar Passport

An Avatar Passport links a user identity, avatar NFT, metadata, and optional Stellar release into one portable identity record.

It lets a wallet prove:

  • this is my profile;
  • this NFT is my selected avatar;
  • I hold the avatar token;
  • the avatar metadata is valid;
  • the avatar may come from a collaborative Stellar release.

Current Programs

The avatar stack lives in:

/Users/wotori/git/ekza/solana-avatars

It has two Anchor programs:

ProgramPurpose
user_profileStores profile data and selected avatar mint.
avatar_nft_minterPublishes avatar collections and mints avatar NFTs.

Profile PDA

Seed:

["profile", owner]

Fields:

FieldMeaning
ownerWallet that controls the profile.
usernameFixed 32-byte username.
descriptionFixed 128-byte description.
avatar_mintSelected avatar NFT mint.
created_atCreation timestamp.

Profile creation and avatar updates require proof that the owner holds the selected avatar mint in a token account.

Avatar Minter Accounts

AccountPurpose
AvatarRegistryStores next_index for avatar collection data.
AvatarDataStores creator, IPFS hash policy, supply, fee, and fee state.
EscrowPDA that holds mint fees until creator claim.
StellarAvatarLinkLinks avatar data to a Stellar release.
StellarReleaseLinkReverse lookup from Stellar release to avatar data.

Important seeds:

PDASeeds
Registry["avatar_registry"]
Avatar data["avatar_v1", next_index_le]
Escrow["avatar_escrow", index_le]
Stellar avatar link["stellar_avatar_link", avatar_data]
Stellar release link["stellar_release_link", stellar_release]

Main Instructions

user_profile:

  • initialize_profile
  • update_profile
  • update_avatar_mint
  • delete_profile

avatar_nft_minter:

  • initialize_avatar
  • initialize_avatar_from_stellar
  • mint_nft
  • claim_fee

Mainnet Security Standard

The current protocol follows these production-oriented rules:

  • NFT mints use decimals = 0.
  • Mint authority and freeze authority are revoked after minting.
  • Metadata must use the canonical Metaplex PDA.
  • Mint URI must match the avatar hash policy stored in AvatarData.
  • Mint fees are transferred atomically and tracked with checked arithmetic.
  • Only the creator can claim escrowed fees.
  • Profiles can only attach an avatar mint after ownership proof.
  • Mutable state uses deterministic PDAs and signer constraints.

Stellar Release Integration

initialize_avatar_from_stellar lets a finalized Stellar release become an avatar collection.

The flow:

  1. A collaborative asset is finalized in solana-stellar.
  2. The release has a vault and contributor share distribution.
  3. The avatar minter initializes AvatarData from that release.
  4. Mints can generate revenue.
  5. Revenue can be linked back to the release accounting model.

This makes avatars useful proof of a real production asset, not only a profile image or isolated collectible.

Avatar Passport Document

{
"schema": "ekza.avatar.passport.v1",
"profile": "PUBLIC_KEY",
"owner": "PUBLIC_KEY",
"avatarMint": "PUBLIC_KEY",
"avatarData": "PUBLIC_KEY",
"metadataUri": "ipfs://bafy.../avatar.json",
"stellarRelease": "PUBLIC_KEY",
"model": "ipfs://bafy.../avatar.glb",
"rig": "humanoid",
"compatibility": ["web", "bevy", "unity"]
}