Resync token uri of NFT's in ETHNFTOWNERS table

is there any fix for this, i’m constantly updating the token uri on my nft’s cause they’re dynamically generated and stored on IPFS, is there a way to force moralis to resync?

Hey @xavierx

I don’t understand a little, but why are you updating token uri? If you pinned a file on IPFS, doesn’t the link to it remain constant?

On what chain are you doing that? From what I know there is a 24 hours period when Moralis will try to do a resync for the NFTs that were accessed. But it could take longer if there are lots of NFTs waiting to be processed.

The NFT metadata is generated dynamically cause it requires User input as i allow users set a name for their NFTs. So i have to update the metadata url of the tokens after every few nfts. Even though i updated the token uri on the contract, the ETHNFTOWNERS table still has the old token-uri. Is there a way to force resync

Yeah i heard it takes 24 hours, but i need it to update often. I wonder if i delete the ETHNFTOWNERS tables, if it will resync?

I don’t think that it would help if you delete that table.

Seems to be over 24 hours yet Moralis hasn’t resync’d @Yomoo

Some misunderstanding here
The server doesn’t resync

The SDK will get fresh data after 24h if you use this function to request metadata https://docs.moralis.io/moralis-server/web3-sdk/token#gettokenidmetadata

You need to use SDK to update server NFT metadata it won’t do it itself

We will add in the future that server also does it

I would suggest to make tokenURI pointing to deterministic URL for each token.

https://your-backend/tokenAddress/tokenId

Then metadata returning by this URL can be dynamically generated.

I assume in that case, getTokenIdMetadata would return fresh data each time?

Also I wonder, if we can make tokenURI pointing directly to moralis database? @ivan

This is how you get token metadata via API/SDK: https://docs.moralis.io/moralis-server/web3-sdk/token#gettokenidmetadata

That data is cached for 24h as 99% of NFTs dont change metadata

If you need real time changes in metadata - we dont have that yet, maybe we will add in the future :raised_hands: