IFixedPriceBatch
Inherits: IBatchAuction
Interface for fixed price batch auctions
Functions
getBid
Returns the Bid
and EncryptedBid
data for a given lot and bid ID
function getBid(uint96 lotId_, uint64 bidId_) external view returns (Bid memory bid);
Parameters
Name | Type | Description |
---|---|---|
lotId_ | uint96 | The lot ID |
bidId_ | uint64 | The bid ID |
Returns
Name | Type | Description |
---|---|---|
bid | Bid | The Bid data |
getAuctionData
Returns the AuctionData
data for an auction lot
function getAuctionData(uint96 lotId_) external view returns (AuctionData memory auctionData_);
Parameters
Name | Type | Description |
---|---|---|
lotId_ | uint96 | The lot ID |
Returns
Name | Type | Description |
---|---|---|
auctionData_ | AuctionData | The AuctionData |
getPartialFill
Returns the PartialFill
data for an auction lot
function getPartialFill(
uint96 lotId_
) external view returns (bool hasPartialFill, PartialFill memory partialFill);
Parameters
Name | Type | Description |
---|---|---|
lotId_ | uint96 | The lot ID |
Returns
Name | Type | Description |
---|---|---|
hasPartialFill | bool | True if a partial fill exists |
partialFill | PartialFill | The PartialFill data |
Errors
Auction_WrongState
error Auction_WrongState(uint96 lotId);
Bid_WrongState
error Bid_WrongState(uint96 lotId, uint64 bidId);
NotPermitted
error NotPermitted(address caller);
Structs
AuctionDataParams
Parameters for a fixed price auction
struct AuctionDataParams {
uint256 price;
uint24 minFillPercent;
}
Properties
Name | Type | Description |
---|---|---|
price | uint256 | The fixed price of the lot |
minFillPercent | uint24 | The minimum percentage of the lot that must be filled in order to settle (100% = 100e2 = 1e4) |
AuctionData
Core data for an auction lot
struct AuctionData {
uint256 price;
LotStatus status;
uint64 nextBidId;
bool settlementCleared;
uint256 totalBidAmount;
uint256 minFilled;
}
Properties
Name | Type | Description |
---|---|---|
price | uint256 | The price of the lot |
status | LotStatus | The status of the lot |
nextBidId | uint64 | The ID of the next bid |
settlementCleared | bool | True if the settlement has been cleared |
totalBidAmount | uint256 | The total amount of all bids |
minFilled | uint256 | The minimum amount of the lot that must be filled in order to settle |
Bid
Core data for a bid
struct Bid {
address bidder;
uint96 amount;
address referrer;
BidStatus status;
}
Properties
Name | Type | Description |
---|---|---|
bidder | address | The address of the bidder |
amount | uint96 | The amount of the bid |
referrer | address | The address of the referrer |
status | BidStatus | The status of the bid |
PartialFill
Struct containing partial fill data for a lot
struct PartialFill {
uint64 bidId;
uint96 refund;
uint256 payout;
}
Properties
Name | Type | Description |
---|---|---|
bidId | uint64 | The ID of the bid |
refund | uint96 | The amount to refund to the bidder |
payout | uint256 | The amount to payout to the bidder |
Enums
LotStatus
The status of an auction lot
enum LotStatus {
Created,
Settled
}
BidStatus
The status of a bid
Bid status will also be set to claimed if the bid is cancelled/refunded
enum BidStatus {
Submitted,
Claimed
}