Skip to content

Conversation

@drichar
Copy link
Contributor

@drichar drichar commented Mar 10, 2025

Description

This PR adds convenience methods to the NfdClient class to simplify common NFD search operations. These methods make it easier for integrators to perform common queries without having to construct complex search parameters.

Details

  • Added resolveAddress method to find the NFD associated with a specific wallet address
  • Added searchByOwner method to search for all NFDs owned by a specific wallet address
  • Added searchForSale method to search for all NFDs that are currently for sale
  • Set a reasonable default limit of 20 results for search methods
  • Added clear documentation with @remarks tags explaining the default limits
  • Ensured methods handle both string and Address object parameters consistently

drichar added 2 commits March 10, 2025 13:22
Add methods to simplify common NFD search operations:
- `resolveAddress`: Find NFD for a specific wallet address
- `searchByOwner`: Search for NFDs owned by a wallet address
- `searchForSale`: Search for NFDs currently for sale
Restores the behavior of resetting the `signer` after `mint` operations complete,
which was inadvertently removed during the addition of new search methods.
This ensures the `mint` method continues to work as expected and passes tests.
@drichar drichar merged commit 9b6d1d1 into main Mar 10, 2025
1 check passed
@drichar drichar deleted the feat/nfd-client-search-methods branch March 10, 2025 17:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants