ListingERC20
Supports bids in ETH/ERC20s and supports Listing Fee.
note
All deployed addresses can be found on the Auctions introduction page.
Check out the Key Considerations 🔑 section before getting started.
#
Auction Structureseller
: The address of the sellerreservePrice
: The reserve price to start the auctionsellerFundsRecipient
: The address where funds are sent after the auctionhighestBid
: The highest bid of the auctionhighestBidder
: The address of the highest bidderduration
: The length of time that the auction runs after the first bid is placedstartTime
: The time that the first bid can be placedfirstBidTime
: The time that the first bid is placedcurrency
: The address of the ERC-20 token, oraddress(0)
for ETH, required for a bidlistingFeeRecipient
: The address that listed the auctionlistingFeeBps
: The fee that is sent to the lister of the auction
struct Auction { address seller; uint96 reservePrice; address sellerFundsRecipient; uint96 highestBid; address highestBidder; uint96 startTime; uint80 duration; uint96 firstBidTime; address currency; address listingFeeRecipient; uint16 listingFeeBps;}
#
Functions#
supportsInterfaceImplements EIP-165 for standard interface detection.
function supportsInterface(bytes4 _interfaceId) returns (bool)
#
Functions#
createAuctionCreates an auction for a given ERC-721 NFT. There can only be one auction at a time for a given NFT.
function createAuction( address _tokenContract, uint256 _tokenId, uint256 _duration, uint256 _reservePrice, address _sellerFundsRecipient, uint256 _startTime, address _bidCurrency, uint256 _listingFeeBps, address _listingFeeRecipient)
#
setAuctionReservePriceUpdates the auction reserve price for a given NFT
function setAuctionReservePrice( address _tokenContract, uint256 _tokenId, uint256 _reservePrice)
#
cancelAuctionCancels the auction for a given NFT.
function cancelAuction(address _tokenContract, uint256 _tokenId)
#
createBidPlaces a bid on the auction for a given NFT. The bid percentage difference must be greater than or equal to 10% of the previous bid.
function createBid( address _tokenContract, uint256 _tokenId, uint256 _amount)
#
settleAuctionEnds the auction for a given NFT by sending the NFT to the highest bidder and the funds to the seller. Note, that this module honors royalty payouts.
function settleAuction(address _tokenContract, uint256 _tokenId)