-
Notifications
You must be signed in to change notification settings - Fork 9
/
Copy pathIKoansAuctionHouse.sol
71 lines (45 loc) · 2.29 KB
/
IKoansAuctionHouse.sol
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
// SPDX-License-Identifier: Beta Software
pragma solidity ^0.8;
interface IKoansAuctionHouse {
struct Auction {
// ID for the Koan (ERC721 token ID)
uint256 koanId;
// The current highest bid amount
uint256 amount;
// The time that the auction started
uint256 startTime;
// The time that the auction is scheduled to end
uint256 endTime;
// The address of the current highest bid
address payable bidder;
// Whether or not the auction has been settled
bool settled;
// The address to payout a portion of the auction's proceeds to.
address payable payoutAddress;
}
event AuctionCreated(uint256 indexed koanId, uint256 startTime, uint256 endTime);
event AuctionBid(uint256 indexed koanId, address sender, uint256 value, bool extended);
event AuctionExtended(uint256 indexed koanId, uint256 endTime);
event AuctionSettled(uint256 indexed koanId, address winner, uint256 amount);
event AuctionTimeBufferUpdated(uint256 timeBuffer);
event AuctionReservePriceUpdated(uint256 reservePrice);
event AuctionMinBidIncrementPercentageUpdated(uint256 minBidIncrementPercentage);
event PayoutRewardBPUpdated(uint256 artistRewardBP);
event AuctionDurationUpdated(uint256 duration);
function reservePrice() external view returns (uint256);
function minBidIncrementPercentage() external view returns (uint8);
function auction() external view returns (uint256, uint256, uint256, uint256, address payable, bool, address payable);
function settleCurrentAndCreateNewAuction() external;
function settleAuction() external;
function createBid(uint256 koanId) external payable;
function addOffer(string memory _uri, address _payoutAddress) external;
function pause() external;
function unpause() external;
function paused() external view returns (bool);
function setTimeBuffer(uint256 _timeBuffer) external;
function setReservePrice(uint256 _reservePrice) external;
function setMinBidIncrementPercentage(uint8 _minBidIncrementPercentage) external;
function setPayoutRewardBP(uint256 _payoutRewardBP) external;
function setDuration(uint256 _duration) external;
function setOfferAddress(address _koanOfferAddress) external;
}