opensea-js icon indicating copy to clipboard operation
opensea-js copied to clipboard

ERROR on createFactorySellOrders

Open aleandro-coppola opened this issue 5 years ago • 17 comments

When I launch initial_sale i have this error:

Error: API Error 429: Message: {"detail":"Request was throttled. Expected available in 1 second."} at OpenSeaAPI. (/Users/aleandrocoppola/Desktop/projects/nft/opensea-creatures/node_modules/opensea-js/src/api.ts:418:11) at step (/Users/aleandrocoppola/Desktop/projects/nft/opensea-creatures/node_modules/opensea-js/lib/api.js:40:23) at Object.next (/Users/aleandrocoppola/Desktop/projects/nft/opensea-creatures/node_modules/opensea-js/lib/api.js:21:53) at fulfilled (/Users/aleandrocoppola/Desktop/projects/nft/opensea-creatures/node_modules/opensea-js/lib/api.js:12:58) at processTicksAndRejections (internal/process/task_queues.js:97:5)

aleandro-coppola avatar Mar 31 '21 19:03 aleandro-coppola

Hey Coppola. You need an API key which you can request from OpenSea. https://docs.opensea.io/reference#request-an-api-key

elliottrisby avatar Mar 31 '21 22:03 elliottrisby

@elliottrisby I haven't received the API KEY yet, it is possible to do something?

aleandro-coppola avatar Apr 06 '21 11:04 aleandro-coppola

Hey! I don't actually work at Opensea but i suggest hitting up Hamish (or one of the opensea admins) via discord. That did the trick for me.

elliottrisby avatar Apr 06 '21 13:04 elliottrisby

And you could limit your requests to a second each while you wait for them to respond! :)

elliottrisby avatar Apr 06 '21 13:04 elliottrisby

Thank you so much @elliottrisby !

aleandro-coppola avatar Apr 06 '21 13:04 aleandro-coppola

And you could limit your requests to a second each while you wait for them to respond! :)

I have the same issue. How can i limit the requests?

RobinBosch avatar Sep 02 '21 08:09 RobinBosch

And you could limit your requests to a second each while you wait for them to respond! :)

Same here! how to avoid 429 when using internal opensea-js functions? there is no method to add delay or limit requests

ubudragon avatar Oct 11 '21 13:10 ubudragon

Same, same @ubudragon @RobinBosch @Coppola-Aleandro @elliottrisby Was anyone able to find a fix?

For example, setting offset to anything above 1400, pops out either a Error 429 or a Server Error 500 url = "https://api.opensea.io/api/v1/assets?order_by=sale_date&order_direction=desc&offset=1600&limit=50"

I even have an API key and still isn't working.

Orescout avatar Nov 24 '21 15:11 Orescout

I have the api key yet am getting this error

version0chiro avatar Dec 17 '21 05:12 version0chiro

Same here @version0chiro

nikolaiwaerpen avatar Dec 25 '21 20:12 nikolaiwaerpen

Same here

stefdelec avatar Jan 07 '22 09:01 stefdelec

same issue here

ngmi

  const openSeaResponse = await fetch(
    `https://api.opensea.io/api/v1/assets?owner=${address}&limit=50&order_by=sale_price`,
    {
      method: 'GET',
      headers: {
        'X-API-KEY': process.env.OPENSEA_API_KEY,
      },
    }
  );

for now, im fetching without any headers

peduarte avatar Jan 08 '22 16:01 peduarte

Same @ubudragon @RobinBosch @Coppola-Aleandro @elliottrisby @peduarte until five days ago all worked . (i have API KEY)

cmenzani avatar Jan 17 '22 15:01 cmenzani

Hi, I'm getting the same error but on testnets.opensea.io. I'm using the API key that comes by default on this page: https://docs.opensea.io/reference/retrieving-orders-testnets-1

ebertbm avatar Jan 25 '22 22:01 ebertbm

This thread has been hijacked by another API issue. OP was reporting on SDK api issue.

If you are not commenting on the SDK createFactorySellOrders function, then you are in the wrong issue.

It appears that API keys are now required for functions that were optional with rate limits and this is generating a lot of traffic around throttle errors.

Again, if you are not commenting on the SDK createFactorySellOrders function, then you are in the wrong issue.

Joseph-Cardwell avatar Feb 15 '22 12:02 Joseph-Cardwell

Usually 429 errors happen when you don't have an api key or you are reaching the rate limit. The testnets api key is a different one than the main network api key. That being said, the original request was about createFactorySellOrders errors. Is anyone still getting this error? Please let me know!

esteban-OpenSea avatar Mar 24 '22 17:03 esteban-OpenSea

How can I get the testnets api key?

tiger-525 avatar Jun 06 '23 05:06 tiger-525