Skip to content

Add token metadata support to ticket_nft contract (name, symbol, URI) #25

@manoahLinks

Description

@manoahLinks

Description

The ticket_nft contract has no metadata support. Ticket NFTs need a name, symbol, and per-token URI (e.g., for QR codes or event artwork) to be useful in wallets and marketplaces.

Missing Fields

  • Contract-level: name, symbol, base_uri
  • Per-token: token_uri(token_id) -> String mapping

Expected Implementation

  • Store name and symbol in constructor
  • Add DataKey::TokenUri(u128) for per-token metadata
  • Add set_token_uri(token_id, uri) (minter-only)
  • Add name(), symbol(), token_uri(token_id) view functions

Files

  • soroban-contract/contracts/ticket_nft/src/lib.rs

Acceptance Criteria

  • name() and symbol() getters
  • Per-token URI storage and retrieval
  • URI set during mint or via separate minter-only function
  • Tests for metadata functions

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions