Skip to main content

Marketplace.getAllListings() method

Get all the listings

Example

const listings = await contract.getAllListings();
const priceOfFirstListing = listings[0].price;

Signature:

getAllListings(filter?: MarketplaceFilter): Promise<(AuctionListing | DirectListing)[]>;

Parameters

ParameterTypeDescription
filterMarketplaceFilter(Optional) optional filter parameters

Returns:

Promise<(AuctionListing | DirectListing)[]>

Remarks

Fetch all the listings from this marketplace contract, including sold ones.