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

Provide an API for retrieving listing information

Open LookRain opened this issue 4 years ago • 16 comments

  • current listings(the result shown with the Buy Now filter on) image

I was quite surprised to find out that such information are not in the existing APIs. I would be happy even with just the number of listings, but that's sadly not available either...

LookRain avatar Apr 19 '22 16:04 LookRain

Just to clarify, you would want the "buy now" option to be a parameter when fetching listings?

esteban-OpenSea avatar Apr 19 '22 17:04 esteban-OpenSea

Just to clarify, you would want the "buy now" option to be a parameter when fetching listings?

Right. The main problem now is that there doesn't seen to be an API to fetch listings for a collection at all. The current API is only for fetching listings for a single asset(collection with an token_id).

LookRain avatar Apr 20 '22 02:04 LookRain

+1

Philigane avatar Apr 20 '22 07:04 Philigane

+1

emorling avatar Apr 21 '22 21:04 emorling

Is there a query parameter that can implement status filtering? @esteban-OpenSea

aweiu avatar May 08 '22 15:05 aweiu

It's easy enough ti implement a scraper to full the listing off the page although it would be great if the api provided this info.

An option would to retrieve all items for a collection and count once retrieved.

krjii avatar May 08 '22 19:05 krjii

It's easy enough ti implement a scraper to full the listing off the page although it would be great if the api provided this info.

An option would to retrieve all items for a collection and count once retrieved.

Did you actually implement a scraper to do so?

I did some testing and it seems OS does a lot of detection for this kind of page visit. Using puppeteer headless mode would be detected and blocked, unless you change the user agent header manually, also OS would prompt CAPTCHA i guess

LookRain avatar May 12 '22 10:05 LookRain

It's easy enough ti implement a scraper to full the listing off the page although it would be great if the api provided this info. An option would to retrieve all items for a collection and count once retrieved.

Did you actually implement a scraper to do so?

I did some testing and it seems OS does a lot of detection for this kind of page visit. Using puppeteer headless mode would be detected and blocked, unless you change the user agent header manually, also OS would prompt CAPTCHA i guess

I use Selenium in both headless and normal modes. One of the main things is ensuring you are NOT sending requests to quickly. That's one of the main ways to get blocked. Load a page and wait a second or so the scraper seems like a human. Scraping should be slow as you have to mimic a human for many sights.

It is always good practice to change the headers if you use to avoid bot detection.

krjii avatar May 12 '22 16:05 krjii

Thank you everyone for your feedback! We will look into this and adding an option to filter by buy now. In the meantime, check this out for collections

  • Fetch Collections: https://docs.opensea.io/reference/retrieving-a-single-collection
  • Collection Stats: https://docs.opensea.io/reference/retrieving-collection-stats
  • Stream API: https://docs.opensea.io/reference/stream-api-overview

esteban-OpenSea avatar Jun 10 '22 02:06 esteban-OpenSea

Any update on this?

usmanashraf678 avatar Jun 26 '22 04:06 usmanashraf678

something new?

ahjohnwon avatar Jul 06 '22 15:07 ahjohnwon

@esteban-OpenSea is there a timeline for this?

usmanashraf678 avatar Jul 19 '22 13:07 usmanashraf678

@esteban-OpenSea i would like to test it but cannot get an API key. Tried several times but always no reply... someone can help me to get it??? Thanks

eriqferrari avatar Jan 08 '23 13:01 eriqferrari

Has this been implemented yet? Any updates?

SeanNFT avatar Jan 27 '23 19:01 SeanNFT

Hi @esteban-OpenSea any view to add listing data to the Collections endpoint? Thanks, Scott

Thank you everyone for your feedback! We will look into this and adding an option to filter by buy now. In the meantime, check this out for collections

  • Fetch Collections: https://docs.opensea.io/reference/retrieving-a-single-collection
  • Collection Stats: https://docs.opensea.io/reference/retrieving-collection-stats
  • Stream API: https://docs.opensea.io/reference/stream-api-overview

mekanoid55 avatar Mar 04 '23 01:03 mekanoid55

This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 14 days if no further activity occurs. Thank you for your contributions. If you believe this was a mistake, please comment.

github-actions[bot] avatar May 24 '23 04:05 github-actions[bot]