简体   繁体   English

如何在OPENSEA上获取某个集合的上线NFT

[英]How to get the listed NFT of a collection on OPENSEA

Hey Im trying to get the listed nfts of a collection on opensea but its not working im using the API but for some reason all im getting a cloudflare block is there a way to bypass this is or be able to get the collection stats of a nft collection of every listed nft in python. I have tried a cloudflare bypass module but that sometimes is iffy.嘿,我试图在 opensea 上获取一个集合的列出的 nfts,但它不能使用 API 即时通讯,但出于某种原因,所有我都得到一个 cloudflare 块,有没有办法绕过它,或者能够获取 nft 的集合统计信息python 中每个列出的 nft 的集合。我已经尝试过 cloudflare 绕过模块,但有时它是不确定的。

import requests

url = "https://opensea.io/collection/clonex?tab=activity&search[isSingleCollection]=true&search[eventTypes][0]=AUCTION_CREATED"

headers = {
    "Accept": "application/json",
    "X-API-KEY": ""
}

response = requests.request("GET", url, headers=headers)

print(response.text)

https://docs.opensea.io/reference/getting-assets https://docs.opensea.io/reference/getting-assets

Firstly, it should be "api.opensea.io" rather than "opensea.io".首先,它应该是“api.opensea.io”而不是“opensea.io”。

Secondly, the name of the collection should be added as a parameter rather than being used directly.其次,集合的名称应该作为参数添加,而不是直接使用。

You can try on the link above with your desired parameters.您可以使用您想要的参数尝试上面的链接。

In your case, for example, it should probably be something like this:例如,在您的情况下,它可能应该是这样的:

https://api.opensea.io/api/v1/assets?collection_slug=clonex&order_direction=desc&limit=20&include_orders=false

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM