Skip to content

Add NFT events to docs/events.md #405

Description

@Levi-Ojukwu

Description:

The NFT module in contracts/invoice_liquidity/src/nft.rs emits three events that represent the lifecycle of invoice NFTs. These events are not documented in docs/events.md:

  1. invoice_nft_minted — Emitted when an NFT is created for a new invoice. Contains invoice_id, owner, amount, due_date.

  2. invoice_nft_transferred — Emitted when an NFT is transferred between addresses (e.g., freelancer to LP when invoice is funded). Contains invoice_id, from, to.

  3. invoice_nft_burned — Emitted when an NFT is destroyed (e.g., when invoice is marked as paid). Contains invoice_id, owner.

These events are emitted using env.events().publish_event() at lines 101-107, 152-157, and 195-199 of nft.rs. Note: the current implementation uses the deprecated publish_event method — see Issue #26 for the migration.

Why it matters: NFT events enable indexers to track invoice ownership changes and build NFT marketplace features. Without documentation, developers cannot subscribe to or parse these events.

Acceptance Criteria:

Relevant Files: docs/events.md, contracts/invoice_liquidity/src/nft.rs:100-200


Metadata

Metadata

Assignees

No one assigned

    Labels

    GrantFox OSSIssue tracked in GrantFox OSSMaybe RewardedIssue may be eligible for a GrantFox rewardOfficial Campaign | FWC26Campaign: Official Campaign | FWC26Stellar WaveIssues in the Stellar wave program

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions