Contract 9971ce9aa0bdc232ecc4ac3ce5c34855f5e2c0b9a4973efd0f7c6b218c966f5b

← Back to Index 📥 Download WASM

Meta

rssdkver 23.0.2#a97daf8b07cdf24e9bd45e344db51a21b9ea77d3
rsver 1.89.0

Instances

  • CAMOZBTH6VE2VYIAZXYKRMSVTZHFVGK5A323PRMCZS2IALIU6NPHN67X

Interface

Initialize the contract with signer public key and metadata.

Arguments

  • signer_pub_key - 32-byte Ed25519 public key for voucher verification
fn __constructor(env: soroban_sdk::Env, signer_pub_key: soroban_sdk::BytesN<32>)

Mint an NFT using a signed voucher from the backend.

Arguments

  • recipient - Address to receive the NFT (must authorize)
  • nonce - Unique nonce to prevent replay attacks
  • signature - 64-byte Ed25519 signature from backend

Returns

The token ID of the newly minted NFT

fn mint_with_voucher(
    env: soroban_sdk::Env,
    slug: soroban_sdk::String,
    name: soroban_sdk::String,
    recipient: soroban_sdk::Address,
    nonce: u64,
    signature: soroban_sdk::BytesN<64>,
) -> u32

Check if a nonce has been used

fn is_nonce_used(
    env: soroban_sdk::Env,
    nonce: u64,
    name: soroban_sdk::String,
    slug: soroban_sdk::String,
) -> bool

Get the signer public key

fn get_signer(env: soroban_sdk::Env) -> soroban_sdk::BytesN<32>
fn balance(env: soroban_sdk::Env, account: soroban_sdk::Address) -> u32
fn owner_of(env: soroban_sdk::Env, token_id: u32) -> soroban_sdk::Address
fn transfer(
    env: soroban_sdk::Env,
    from: soroban_sdk::Address,
    to: soroban_sdk::Address,
    token_id: u32,
)
fn transfer_from(
    env: soroban_sdk::Env,
    spender: soroban_sdk::Address,
    from: soroban_sdk::Address,
    to: soroban_sdk::Address,
    token_id: u32,
)
fn approve(
    env: soroban_sdk::Env,
    approver: soroban_sdk::Address,
    approved: soroban_sdk::Address,
    token_id: u32,
    live_until_ledger: u32,
)
fn approve_for_all(
    env: soroban_sdk::Env,
    owner: soroban_sdk::Address,
    operator: soroban_sdk::Address,
    live_until_ledger: u32,
)
fn get_approved(env: soroban_sdk::Env, token_id: u32) -> Option
fn is_approved_for_all(
    env: soroban_sdk::Env,
    owner: soroban_sdk::Address,
    operator: soroban_sdk::Address,
) -> bool
fn token_uri(env: soroban_sdk::Env, token_id: u32) -> soroban_sdk::String
fn name(env: soroban_sdk::Env) -> soroban_sdk::String
fn symbol(env: soroban_sdk::Env) -> soroban_sdk::String
fn burn(env: soroban_sdk::Env, from: soroban_sdk::Address, token_id: u32)
fn burn_from(
    env: soroban_sdk::Env,
    spender: soroban_sdk::Address,
    from: soroban_sdk::Address,
    token_id: u32,
)

Imports

WebAssembly Text (WAT) ▶