Open John-44 opened 1 year ago
@micieslak just speaking to @dlipicar , we might need to Infura or Alchamy API for this. @dlipicar can help/do/advise on the backend here
@benjthayer depending on what @dlipicar discovers is possible via whatever NFT search API(s) we choose to use, we might need to slightly update this design. Nothing to do for now though, the API research needs to be completed first.
Initial findings:
If we have some certainty that what the user entered is some specific piece of information (contract address, collection slug), we can make a search using specific endpoints in any of our providers. For example: https://docs.opensea.io/reference/retrieve-nfts-by-contract https://docs.opensea.io/reference/retrieve-nfts-by-collection https://docs.infura.io/infura-expansion-apis/nft-api/rest-apis/api-reference/collections#get-all-nfts-with-metadata-in-a-specific-collection https://docs.alchemy.com/reference/getnftsforcontract-v3
If we want to throw whatever the user enters to an API Endpoint and see if it matches any some field in the NFT metadata (For example enter "bored" and get the Bored Apes collection)
So, we could get contract address/collection slug search support using
And text-based search support using
Probably a good idea to make some tests before making any decision.
thanks for looking at this @dlipicar
Agree that it would be a good idea to do some tests before making any decision.
For 'Contract address/collection slug search' using either: OpenSea with Infura as a fallback OR just Infura, both work from a product POV.
For 'text-based search', using either: Infura with Alchemy as a fallback OR just Infura, both work from a product POV.
Update: Infura's shutting down their NFT API
Hey 👋
We are writing to let you know that we will soon be sunsetting our NFT API + SDK. Infura’s mission is to provide web3 developers with reliable and cost-effective tools to make it easier to build web3 products and this strategic realignment will allow us to reprioritize our focus to develop products and services that we are uniquely positioned to create, and that we do better than anyone else.
We will be sunsetting these services in two phases:
Phase 1: September 1
The "search NFT" endpoint will no longer be valid
When getting transfers within a block range using the fromBlock/toBlock query parameters, the total field will no longer be returned
Phase 2: November 1
All other NFT endpoints will be sunset, along with the SDK
To ensure a seamless transition and uninterrupted NFT services, we recommend migrating to Moralis, a reliable and feature-rich platform for NFT operations. Moralis (https://moralis.io/) provides a comprehensive set of tools and services, and their team is dedicated to delivering an exceptional user experience that we trust at MetaMask.
We apologize for any inconvenience this may cause and are here to support you during this transition. If you have any questions or need assistance, please don't hesitate to reach out to our support team at [support@infura.io.](mailto:support@infura.io)
To help with onboarding onto Moralis, Nicolai Melniciuc ([nicolai@moralis.io](mailto:nicolai@moralis.io)) from Moralis can help with all of your questions.
Thank you for your continued support. We are excited about the new opportunities this strategic shift will bring and look forward to serving you in new and innovative ways.
Best regards,
The Infura Team
@dlipicar @alaibe Can we use Moralis instead as recommended by infura in their message above?
Additional note: Rarible seems to have something we could use, though they only support Ethereum (mainnet + testnet) https://multichain.redoc.ly/testnet/tag/item-controller#operation/searchItems
Additional note: First search with alchemy: https://docs.alchemy.com/reference/searchcontractmetadata-v3 Then Rarible: https://docs.rarible.org/reference/searchitems
Summary of capabilities for the available providers:
Alchemy:
Results cannot be sorted in any special way, and there's no clear indication of how they're ordered by default, so there's a lot of contracts deployed by random people mixed with "big/known" collections from reputable orgs.
If we want to get individual items from each of these collections, then we need to call a separate API. There's no way to search individual items from a given collection.
Rarible:
As things are, Rarible's API is the only really useful one. I've sent Alchemy support a message about making they're API more similar to Rarible's, hopefully they'll take notice.
So yeah, for now text-based search only makes sense using Rarible. I'll be on the lookout for improvements to Alchemy's endpoint.
We could somehow integrate specifying contract address and (when desired) tokenID into our designs, which is the best way of knowing if you're hitting the "real" collection instead of a forgery.
Ugh... Rarible's API has a case-sensitive text field, so searching for lilpudgys
returns a completely different list than Lilpudgys
🤦
Asked their support if we can get case-sensitivity disabled or at least configurable
Iterating over the designs with Ben
Iterated on with Dario and pending review with @John-44 and design team... https://www.figma.com/file/qHfFm7C9LwtXpfdbxssCK3/Kuba%E2%8E%9CDesktop---Communities?type=design&node-id=53449-148202&mode=design&t=sYCpMDPq54tgNmF8-4
cc @dlipicar
I'm guessing the priority for this is now quite low, won't resume work on it until further notice
I'm guessing the priority for this is now quite low, won't resume work on it until further notice
We do need a way for users to create permissions tied to any arbitrary NFT, not just NFTs minted in status. How much work is remaining to complete the implementation of this, could anybody else pick this up?
@John-44 oh sorry, I thought this was considered a "new messenger feature" and had been de-prioritized. My bad!
The backend is mostly done, the UI is mostly not. I can finish the few missing pieces from the backend and see if somebody from the UI team can work on the rest. Do we want this in for 2.29?
Do we want this in for 2.29?
If possible, yes cc'ing @noeliaSD
@dlipicar designs are now signed off an folded into main permissions flows in Figma :) https://www.figma.com/file/qHfFm7C9LwtXpfdbxssCK3/Kuba%E2%8E%9CDesktop---Communities?type=design&node-id=53874-101256&mode=design&t=dVuLDOqra39yKahC-4
Do we want this in for 2.29?
If possible, yes cc'ing @noeliaSD
Hey @John-44 we cannot make it for 2.29
but we can work on it for 2.30
. Is it ok?
Hey @John-44 we cannot make it for
2.29
but we can work on it for2.30
. Is it ok?
This is fine, thanks for the heads up :-)
See designs here: https://www.figma.com/design/qHfFm7C9LwtXpfdbxssCK3/Kuba%E2%8E%9CDesktop---Communities?node-id=53874-101256&t=hLXAVLh0o0CsZKWE-0
When creating or editing permission, it should be possible for the user to reference any collectable listed on OpenSea in the permission. Or we might want to consider using the Infura NFT API for this search, as it might have better functionality than the OpenSea API and be more reliable. Someone from the wallet team might be able to advise here, cc'ing @alaibe
After the user drills into 'All collectables':
cc'ing @jrainville @iurimatias
Sub-tasks