Trades

The NFT Trades table aggregates ERC721 and ERC1155 token sales from popular NFT marketplaces and protocols on Base.

Our current NFT trades model supports single-currency trades (trades involving either one ERC20 token or ETH alone), which constitute most of the current NFT trades.

Marketplace and Protocol Coverage:

ProtocolMarketplace

seaport

alienswap, opensea, mint.fun, unlabeled, okx

element

element

zonic

zonic

sudoswap_v2

sudoswap

Sample Query

Query daily marketplace volume and unique buyers on Polygon in the last 30 days.

 select
    date(block_timestamp) as date, 
    marketplace,
    count(distinct buyer_address) as buyers,
    sum(usd_price) as usd_volume
from base.nfts.trades 
where current_date - date(block_timestamp) < 30
group by 1,2 
order by 1 desc 

Table Columns

Column NameDescriptionExample

marketplace

Marketplace of the nft trade. The list of marketplaces supported can be found at the end of this table.

opensea

protocol

The protocol of the marketplace determined by the smart contract used.

seaport

order_match_type

Type of sales. Registered as BUY for direct purchase and ACCEPT_BID for bids accepted.

BUY

trade_type

Type of trade. SINGLE_TRADE for single token sales or BUNDLE_TRADE when more than 1 token is sold in a transaction.

SINGLE_TRADE

buyer_address

Address of the buyer.

0xb7f9837ec16e1af85e0fb4edf144d97f255c1fa0

seller_address

Address of the seller.

0x00000000e8c9360a402ea4b02efd312d3d196e3f

token_standard

Type of token traded in the transaction. Either an ERC721 or ERC1155 token.

ERC721

token_address

Token contract of the NFT in the trade.

0xea2a41c02fa86a4901826615f9796e603c6a4491

token_name

Name of the token traded.

Bridge to Base

token_symbol

Symbol of the token traded.

BRIDGETOBASE

token_id

Token id of the NFT traded.

41785115

item_quantity

Quantity of the item traded. For ERC721 tokens, the value is null. While for ERC1155 tokens, the value can be more than 1.

1

currency_address

Token address of the currency used for this trade. Native ETH is represented as 0x0000000000000000000000000000000000000000 Note: Multi-currency trades will be represented as 'MULTI'. These constitute a small fraction of all trades in seaport protocol. It is also associated with phishing transactions. Prices of such trades are represented as NULL. For more details refer to our write-up on multi-currency trades.

0x0000000000000000000000000000000000000000

currency_symbol

Token symbol of the currency used for the trade.

ETH

raw_price

Raw price of the NFT trade. (Unnormalised)

1000000000000

price

Price of the NFT.

0.000001

usd_price

USD value of the trade. The USD value of the trade is calculated by multiplying the hourly exchange rate of the currency (e.g. ETH) with the price oracle data source from exchanges. 3,750.91

0.00178322

agg_fees

Sum of the fees paid by the NFT buyer and the seller.

{ "creator": null, "platform": 2.500000000000000e-08, "raw_creator": null, "raw_platform": "25000000000", "raw_total": "25000000000", "total": 2.500000000000000e-08, "usd_creator": null, "usd_platform": 4.458050000000000e-05, "usd_total": 4.458050000000000e-05 }

buyer_fees

Fees paid by the NFT buyer.

It might be "unimplemented" if we haven't parse the fees for that protocol yet. Otherwise, it will be a json with 9 columns. "creator" fees are the ones paid to the nft creator (royalties); "platform" fees are paid to the marketplace; "total" fees are the sum of both fees

Use this syntax to access a specific fee:buyer_fees['usd_total']::double. And don't worry about the unimplemented ones, they will become null

{ "creator": null, "platform": 2.500000000000000e-08, "raw_creator": null, "raw_platform": "25000000000", "raw_total": "25000000000", "total": 2.500000000000000e-08, "usd_creator": null, "usd_platform": 4.458050000000000e-05, "usd_total": 4.458050000000000e-05 }

seller_fees

Fees paid by the NFT seller. Note: usually no fees are paid by the seller.

{ "creator": null, "platform": null, "raw_creator": null, "raw_platform": null, "raw_total": null, "total": null, "usd_creator": null, "usd_platform": null, "usd_total": null }

aggregator_name

Name of the aggregator use for the trade. Will be empty is the trade did not involve the use of aggregators.

Coinbase

aggregator_address

Contract address of the aggregator used for the trade.

0x00000000000000adc04c56bf30ac9d3c0aaf14dc

transaction_hash

Transaction hash that this trade.

0x93f916d29d92716569142dcbb25417ccb6e2ed686b642fa7d8629dbc33c5786c

block_timestamp

The timestamp of the block that the corresponding transaction of this trade.

2023-10-25 06:40:45

block_number

The block number that the corresponding transaction of this trade belongs to.

5,713,349

block_hash

The block hash that the corresponding transaction of this trade belongs to.

0x4423538260f983319e40a88a5ff1888b43d9b3a07bd5489e1ae87b26360b2714

unique_id

Unique id generated for this trade.

opensea-transaction_hash-0x93f916d29d92716569142dcbb25417ccb6e2ed686b642fa7d8629dbc33c5786c_log_index-28_token_address-0xea2a41c02fa86a4901826615f9796e603c6a4491_token_id-41785115_index-1_buyer_address-0xb7f9837ec16e1af85e0fb4edf144d97f255c1fa0_seller_address-0x00000000e8c9360a402ea4b02efd312d3d196e3f

_updated_at

Timestamp of entry update.

2023-10-25 08:11:20.853 +0000

_helper_nft_tokens__updated_at

Timestamp of token info update.

_changed_since_full_refresh

Flag for change since full refresh.

TRUE

Last updated