Skip to main content

MarketplaceAuction.getWinner() method

Get Auction Winner

Example

// The listing ID of the auction that closed
const listingId = 0;

contract.auction.
.getWinner(listingId)
.then((auctionWinner) => console.log(auctionWinner))
.catch((err) => console.error(err));

Signature:

getWinner(listingId: BigNumberish): Promise<string>;

Parameters

ParameterTypeDescription
listingIdBigNumberish

Returns:

Promise<string>

Remarks

Get the winner of the auction after an auction ends.