/{wallet}/nft is very slow sometimes

Calls for /{wallet}/nft (sometimes for the first page, sometimes for subsequent pages with a cursor) can take a few seconds (7) sometimes:

curl --request GET \
           --url 'https://deep-index.moralis.io/api/v2.2/0xFFA17Ef7e40430C19ADcb15fA7E20B52C205DEc6/nft?chain=polygon' \
           --header 'accept: application/json' \
           --header 'X-API-Key: <key>'

Most of the time itโ€™s faster like ~0.7s. Is there a way to make it faster, especially those 6-7 second ones? These calls are all made from the same server. We are careful to check for 429s and backoff.

Hi @hboon

Thanks for the report. The speed could be related to the number of NFTs or transactions that the wallet has.
Can you verify if that is the case?

Itโ€™s the wallet in the example (0xFFA17Ef7e40430C19ADcb15fA7E20B52C205DEc6). It has at least 300 (or more) tokens.

But apparently the first page was quite fast, then 2nd and 3rd are slow. But when I refetch with the same calls with the same wallet, itโ€™s significantly faster (maybe cached, rightfully).

This seems to be the case โ€” for a given wallet, even if a particular page is slow, some other pages (both before and after the slow page) could be fast.

Thanks for the details. Let me report to the devs๐Ÿ™Œ

1 Like