Skip to main content

NFT market is in your hands.

Project description

nft-market

PyPI version test

What is it?

nft-market is a Python library by which current market information of NFTs on several famous NFT markets (OpenSea, Tofu, PancakeSwap, etc) can be obtained.

Main features

nft-market provides simple APIs that return market information just by your giving the following arguments.

  • The marketplace (from nft_market.Market)
  • the ID of a specific NFT (See the below in detail.)
from nft_market import Market, Retriever

r = Retriever()
print(r.fetch(Market.OpenSea, 'boredapeyachtclub'))  # Bored Ape Yacht Club

# [Output]
# type: nft_market.NFTInfo
# NFTInfo(name='boredapeyachtclub', num_items_all=None, num_listing=10000, num_owners=6400, floor=110.0, volume=487100.0)

Currently supported marketplaces

At this moment, the following marketplaces are supported in nft-market.

Other marketplaces will be added into the list in the future. You can, off course, request them in issues if needed immediately. Either PRs or issues are always welcome!

How to get the ID of a NFT?

Although it depends on which marketplace you use, you can basically find it in the URL.

Example 1: OpenSea

When you want to retrieve the information of the NFT of Bored Ape Yacht Club , the URL looks like https://opensea.io/collection/boredapeyachtclub . In this URL, what differs according to a NFT is the part of boredapeyachtclub, which is all you need to use ** nft-market**.

Example 2: Tofu

URLs look like https://tofunft.com/collection/astardegens/items. In this case, what nft-market requires is only the part of astardegens.

Other examples

We have several examples of the usage in samples.py for references.

Available information

What you can retrieve may change by a marketplace you specify, as follows.

Market Name # Items # Listing # Owners Floor Volume
OpenSea
Entrepot
Tofu
PancakeSwap
Rarible
GhostMarket

Other information may be provided in the future!

Installation

You can install nft-market by pip.

$ pip install nft-market

Also, as nft-market depends on Firefox and its driver, you need to install them.

[mac]
$ brew install firefox

[ubuntu]
$ sudo apt install firefox

Besides, all Python dependencies are listed up in requirements.txt. Please install them by $ pip install -r requirements.txt if you install nft-market not by pip but by cloning from GitHub.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

nft_market-1.2-py3-none-any.whl (6.3 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page