Source Code
Overview
ETH Balance
0 ETH
Eth Value
$0.00Latest 25 from a total of 64 transactions
| Transaction Hash |
Method
|
Block
|
From
|
|
To
|
||||
|---|---|---|---|---|---|---|---|---|---|
| Settle | 23384093 | 64 days ago | IN | 0 ETH | 0.00022354 | ||||
| Settle | 23384088 | 64 days ago | IN | 0 ETH | 0.00014673 | ||||
| Bid | 23383847 | 64 days ago | IN | 12 ETH | 0.00006464 | ||||
| Bid | 23383727 | 64 days ago | IN | 0.025 ETH | 0.0000462 | ||||
| Bid | 23383721 | 64 days ago | IN | 0.028 ETH | 0.00004556 | ||||
| Bid | 23383718 | 64 days ago | IN | 0.028 ETH | 0.00003998 | ||||
| Bid | 23383701 | 64 days ago | IN | 0.05 ETH | 0.00006471 | ||||
| Bid | 23383690 | 64 days ago | IN | 0.001 ETH | 0.00006667 | ||||
| Bid | 23383671 | 64 days ago | IN | 0.0019 ETH | 0.00004329 | ||||
| Bid | 23383622 | 64 days ago | IN | 0.001 ETH | 0.00003704 | ||||
| Bid | 23383618 | 64 days ago | IN | 0.001 ETH | 0.00003489 | ||||
| Bid | 23383555 | 64 days ago | IN | 0.0013 ETH | 0.00002452 | ||||
| Bid | 23383552 | 64 days ago | IN | 0.00112 ETH | 0.00002428 | ||||
| Bid | 23383540 | 64 days ago | IN | 0.0012 ETH | 0.00002813 | ||||
| Bid | 23383536 | 64 days ago | IN | 0.001 ETH | 0.0000289 | ||||
| Bid | 23383534 | 64 days ago | IN | 0.001 ETH | 0.00002913 | ||||
| Bid | 23383532 | 64 days ago | IN | 0.001 ETH | 0.00002719 | ||||
| Bid | 23383529 | 64 days ago | IN | 0.001 ETH | 0.00002991 | ||||
| Bid | 23383497 | 64 days ago | IN | 0.001 ETH | 0.00006557 | ||||
| Bid | 23383434 | 64 days ago | IN | 0.0012 ETH | 0.00006225 | ||||
| Bid | 23383251 | 64 days ago | IN | 0.001 ETH | 0.00003747 | ||||
| Bid | 23383186 | 64 days ago | IN | 0.2 ETH | 0.00002521 | ||||
| Bid | 23383179 | 64 days ago | IN | 0.001 ETH | 0.00002516 | ||||
| Bid | 23383177 | 64 days ago | IN | 0.001 ETH | 0.00002606 | ||||
| Bid | 23383049 | 64 days ago | IN | 0.001 ETH | 0.00002158 |
Latest 25 internal transactions (View All)
Advanced mode:
| Parent Transaction Hash | Method | Block |
From
|
|
To
|
||
|---|---|---|---|---|---|---|---|
| Transfer | 23384093 | 64 days ago | 11.11 ETH | ||||
| Transfer | 23384088 | 64 days ago | 0.0011 ETH | ||||
| Transfer | 23377434 | 64 days ago | 9.99 ETH | ||||
| Transfer | 23377359 | 64 days ago | 8.88 ETH | ||||
| Transfer | 23377001 | 65 days ago | 6.9 ETH | ||||
| Transfer | 23376953 | 65 days ago | 6.269 ETH | ||||
| Transfer | 23376950 | 65 days ago | 5.69 ETH | ||||
| Transfer | 23376924 | 65 days ago | 4.7 ETH | ||||
| Transfer | 23376904 | 65 days ago | 4.2 ETH | ||||
| Transfer | 23376899 | 65 days ago | 3.33 ETH | ||||
| Transfer | 23376805 | 65 days ago | 2.9282 ETH | ||||
| Transfer | 23376784 | 65 days ago | 2.662 ETH | ||||
| Transfer | 23376782 | 65 days ago | 2.42 ETH | ||||
| Transfer | 23376751 | 65 days ago | 2.2 ETH | ||||
| Transfer | 23376742 | 65 days ago | 2 ETH | ||||
| Transfer | 23376730 | 65 days ago | 1.562 ETH | ||||
| Transfer | 23376729 | 65 days ago | 1.42 ETH | ||||
| Transfer | 23376717 | 65 days ago | 1.23 ETH | ||||
| Transfer | 23376713 | 65 days ago | 1 ETH | ||||
| Transfer | 23376690 | 65 days ago | 0.69 ETH | ||||
| Transfer | 23376687 | 65 days ago | 0.25 ETH | ||||
| Transfer | 23376687 | 65 days ago | 0.0011 ETH | ||||
| Transfer | 23376686 | 65 days ago | 0.001 ETH | ||||
| Transfer | 23376273 | 65 days ago | 0.001 ETH | ||||
| 0x61010060 | 21286420 | 357 days ago | Contract Creation | 0 ETH |
Loading...
Loading
Cross-Chain Transactions
Loading...
Loading
Contract Source Code Verified (Exact Match)
Contract Name:
Auctions
Compiler Version
v0.8.24+commit.e11b9ed9
Optimization Enabled:
Yes with 100000 runs
Other Settings:
paris EvmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: MIT
pragma solidity 0.8.24;
import "@openzeppelin/contracts/token/ERC1155/IERC1155.sol";
import "@openzeppelin/contracts/token/ERC1155/utils/ERC1155Holder.sol";
import "@openzeppelin/contracts/token/ERC721/IERC721.sol";
import "@openzeppelin/contracts/token/ERC721/utils/ERC721Holder.sol";
///̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶//
// //
// ┌───────────────┐ ┌────────────────┐ //
// │ │ │ │ //
// │ │ safeTransfer │ │ //
// │ NFT │ ──────────────────► │ AUCTIONS │ //
// │ │ │ │ //
// │ │ │ │ //
// └───────────────┘ └────────────────┘ //
// //
// ─────────────────────────────────────────────────────────────── //
// //
// 24 Hour Auction //
// 5 Minute Grace Period //
// min(+10%, 1 Ether) Bid Increase //
// //
///̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶/̶//
/// @notice You are free to transact.
/// @author Visualize Value
contract Auctions is ERC721Holder, ERC1155Holder {
/// @notice The data struct for a given auction.
struct Auction {
address tokenContract;
uint256 tokenId;
uint80 tokenAmount;
uint16 tokenStandard;
uint40 endTimestamp;
bool settled;
uint112 latestBid;
address latestBidder;
address payable beneficiary;
}
/// @notice The auctions are all one day (+ variable bid grace period increments).
uint40 public immutable AUCTION_DURATION = 24 hours;
/// @notice Minimum auction duration after a bid in seconds (5 minutes).
uint40 public immutable BIDDING_GRACE_PERIOD = 5 minutes;
/// @notice Each bid has to increase by at least 10%
uint256 public immutable BID_PERCENTAGE_INCREASE = 10;
/// @notice Mininum bid increases should be capped at 1 Ether.
uint256 public immutable MAX_BID_INCREASE = 1 ether;
/// @notice The next auction ID
uint256 public auctionId;
/// @dev Each auction is identified by an ID
mapping(uint256 => Auction) public auctions;
/// @dev When the automatic refunds of previous bids fail, they are stored in here
mapping(address => uint256) public balances;
/// @dev Emitted when an NFT is sent to the contract.
event AuctionInitialised(
uint256 indexed auctionId,
address indexed tokenContract,
uint256 indexed tokenId,
uint16 tokenERCStandard,
uint40 endTimestamp,
address beneficiary
);
/// @dev Emitted when a new bid is entered.
event Bid(uint256 indexed auctionId, uint256 indexed bid, address indexed from);
/// @dev Emitted when a new bid is entered within the BIDDING_GRACE_PERIOD.
event AuctionExtended(uint256 indexed auctionId, uint256 indexed endTimestamp);
/// @dev Emitted when an auction is settled, the NFT is sent
// to the winner and the funds sent to the beneficiary.
event AuctionSettled(
uint256 indexed auctionId,
address indexed winner,
address indexed beneficiary,
uint256 amount
);
error AuctionNotActive();
error AuctionAlreadySettled();
error AuctionDoesNotExist();
error AuctionNotComplete();
error FailedWithdrawal();
error MinimumBidNotMet();
error NoBalanceToWithdraw();
error TooManyTokens();
/// @dev Hook for `safeTransferFrom` of ERC721 tokens to this contract
/// @param from The address which previously owned the token
/// @param tokenId The ID of the token being transferred
/// @param data The auction parameters encoded as: address beneficiary (20 bytes)
function onERC721Received(
address, // The (approved) address which initiated the transfer
address from,
uint256 tokenId,
bytes memory data
) public override returns (bytes4) {
address tokenContract = msg.sender;
_initializeAuction(
tokenContract,
tokenId,
721,
1,
_getBeneficiary(data, from)
);
return this.onERC721Received.selector;
}
/// @dev Hook for `safeTransferFrom` of ERC1155 tokens to this contract
/// @param from The address which previously owned the token
/// @param id The ID of the token being transferred
/// @param value The amount of tokens being transferred
/// @param data The auction parameters encoded as: address beneficiary (20 bytes)
function onERC1155Received(
address, // The (approved) address which initiated the transfer
address from,
uint256 id,
uint256 value,
bytes memory data
) public override returns (bytes4) {
if (value >= type(uint80).max) revert TooManyTokens();
address tokenContract = msg.sender;
_initializeAuction(
tokenContract,
id,
1155,
uint80(value),
_getBeneficiary(data, from)
);
return this.onERC1155Received.selector;
}
/// @dev The minimum value of the next bid for an auction.
function currentBidPrice(uint256 id) external view returns (uint256) {
return _currentBidPrice(auctions[id]);
}
/// @dev Enter a new bid
/// @param id The Auction ID to bid on
function bid(uint256 id) external payable {
Auction storage auction = auctions[id];
address previousBidder = auction.latestBidder;
uint256 previousValue = auction.latestBid;
address bidder = msg.sender;
uint256 value = msg.value;
if (value < _currentBidPrice(auction)) revert MinimumBidNotMet();
if (block.timestamp > auction.endTimestamp) revert AuctionNotActive();
_maybeExtendTime(id, auction);
// Store the bid
auction.latestBid = uint112(value);
auction.latestBidder = bidder;
// Pay back previous bidder
if (_hasBid(auction)) {
(bool success,) = payable(previousBidder).call{value: previousValue, gas: 60_000}("");
if (!success) {
balances[previousBidder] += previousValue;
}
}
emit Bid(id, value, bidder);
}
/// @dev Settles an auction
/// @param id The Auction ID to claim.
function settle(uint256 id) external {
Auction storage auction = auctions[id];
if (auction.settled) revert AuctionAlreadySettled();
if (auction.endTimestamp == 0) revert AuctionDoesNotExist();
if (block.timestamp <= auction.endTimestamp) revert AuctionNotComplete();
bool hasBid = _hasBid(auction);
address winner = hasBid ? auction.latestBidder : auction.beneficiary;
// Mark the auction as settled.
auction.settled = true;
// Send the funds to the beneficiary if there was a bid
if (hasBid) {
(bool success,) = auction.beneficiary.call{value: auction.latestBid, gas: 60_000}("");
if (!success) {
balances[auction.beneficiary] += auction.latestBid;
}
}
// Transfer the NFT to the winner
if (auction.tokenStandard == 721) {
IERC721(auction.tokenContract).safeTransferFrom(
address(this),
winner,
auction.tokenId,
""
);
} else if (auction.tokenStandard == 1155) {
IERC1155(auction.tokenContract).safeTransferFrom(
address(this),
winner,
auction.tokenId,
auction.tokenAmount,
""
);
}
emit AuctionSettled(id, winner, auction.beneficiary, auction.latestBid);
}
/// @dev Withdraw user balance in case automatic refund in bid failed.
function withdraw() external {
uint256 amount = balances[msg.sender];
if (amount == 0) revert NoBalanceToWithdraw();
// Set balance to zero because it could be called again in receive before call returns
balances[msg.sender] = 0;
(bool success,) = payable(msg.sender).call{value: amount}("");
if (!success) revert FailedWithdrawal();
}
/// @dev Decode auction parameters from token transfer data
/// @param data Encoded auction parameters: address beneficiary (20 bytes)
function _getBeneficiary(bytes memory data, address defaultBeneficiary) internal pure returns (address payable) {
if (data.length == 32) {
address beneficiary = abi.decode(data, (address));
if (beneficiary != address(0)) {
return payable(beneficiary);
}
}
return payable(defaultBeneficiary);
}
/// @dev Initializes an auction
function _initializeAuction(
address tokenContract,
uint256 tokenId,
uint16 tokenStandard,
uint80 tokenAmount,
address payable beneficiary
) internal {
auctionId++;
uint40 endTimestamp = uint40(block.timestamp + AUCTION_DURATION);
Auction storage auction = auctions[auctionId];
auction.tokenContract = tokenContract;
auction.tokenId = tokenId;
auction.tokenAmount = tokenAmount;
auction.tokenStandard = tokenStandard;
auction.endTimestamp = endTimestamp;
auction.beneficiary = beneficiary;
emit AuctionInitialised(
auctionId,
tokenContract,
tokenId,
tokenStandard,
endTimestamp,
beneficiary
);
}
/// @dev Extends the end time of an auction if we are within the grace period.
function _maybeExtendTime(uint256 id, Auction storage auction) internal {
uint40 gracePeriodStart = auction.endTimestamp - BIDDING_GRACE_PERIOD;
uint40 _now = uint40(block.timestamp);
if (_now > gracePeriodStart) {
auction.endTimestamp = _now + BIDDING_GRACE_PERIOD;
emit AuctionExtended(id, auction.endTimestamp);
}
}
/// @dev Calculates the minimum price for the next bid
function _currentBidPrice(Auction memory auction) internal view returns (uint256) {
if (!_hasBid(auction)) return _getMinimumBid();
uint256 latestBid = uint256(auction.latestBid);
uint256 percentageIncrease = latestBid * BID_PERCENTAGE_INCREASE / 100;
uint256 increase = percentageIncrease < MAX_BID_INCREASE
? percentageIncrease
: MAX_BID_INCREASE;
return latestBid + increase;
}
/// @dev Whether an auction has an existing bid
function _hasBid(Auction memory auction) internal pure returns (bool) {
return auction.latestBid > 0;
}
/// @dev Calculate the minimum bid based on current network conditions (based on VV Mint prices)
function _getMinimumBid() internal view returns (uint256) {
return block.basefee * 60_000;
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.1.0) (token/ERC1155/IERC1155.sol)
pragma solidity ^0.8.20;
import {IERC165} from "../../utils/introspection/IERC165.sol";
/**
* @dev Required interface of an ERC-1155 compliant contract, as defined in the
* https://eips.ethereum.org/EIPS/eip-1155[ERC].
*/
interface IERC1155 is IERC165 {
/**
* @dev Emitted when `value` amount of tokens of type `id` are transferred from `from` to `to` by `operator`.
*/
event TransferSingle(address indexed operator, address indexed from, address indexed to, uint256 id, uint256 value);
/**
* @dev Equivalent to multiple {TransferSingle} events, where `operator`, `from` and `to` are the same for all
* transfers.
*/
event TransferBatch(
address indexed operator,
address indexed from,
address indexed to,
uint256[] ids,
uint256[] values
);
/**
* @dev Emitted when `account` grants or revokes permission to `operator` to transfer their tokens, according to
* `approved`.
*/
event ApprovalForAll(address indexed account, address indexed operator, bool approved);
/**
* @dev Emitted when the URI for token type `id` changes to `value`, if it is a non-programmatic URI.
*
* If an {URI} event was emitted for `id`, the standard
* https://eips.ethereum.org/EIPS/eip-1155#metadata-extensions[guarantees] that `value` will equal the value
* returned by {IERC1155MetadataURI-uri}.
*/
event URI(string value, uint256 indexed id);
/**
* @dev Returns the value of tokens of token type `id` owned by `account`.
*/
function balanceOf(address account, uint256 id) external view returns (uint256);
/**
* @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {balanceOf}.
*
* Requirements:
*
* - `accounts` and `ids` must have the same length.
*/
function balanceOfBatch(
address[] calldata accounts,
uint256[] calldata ids
) external view returns (uint256[] memory);
/**
* @dev Grants or revokes permission to `operator` to transfer the caller's tokens, according to `approved`,
*
* Emits an {ApprovalForAll} event.
*
* Requirements:
*
* - `operator` cannot be the zero address.
*/
function setApprovalForAll(address operator, bool approved) external;
/**
* @dev Returns true if `operator` is approved to transfer ``account``'s tokens.
*
* See {setApprovalForAll}.
*/
function isApprovedForAll(address account, address operator) external view returns (bool);
/**
* @dev Transfers a `value` amount of tokens of type `id` from `from` to `to`.
*
* WARNING: This function can potentially allow a reentrancy attack when transferring tokens
* to an untrusted contract, when invoking {onERC1155Received} on the receiver.
* Ensure to follow the checks-effects-interactions pattern and consider employing
* reentrancy guards when interacting with untrusted contracts.
*
* Emits a {TransferSingle} event.
*
* Requirements:
*
* - `to` cannot be the zero address.
* - If the caller is not `from`, it must have been approved to spend ``from``'s tokens via {setApprovalForAll}.
* - `from` must have a balance of tokens of type `id` of at least `value` amount.
* - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155Received} and return the
* acceptance magic value.
*/
function safeTransferFrom(address from, address to, uint256 id, uint256 value, bytes calldata data) external;
/**
* @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {safeTransferFrom}.
*
* WARNING: This function can potentially allow a reentrancy attack when transferring tokens
* to an untrusted contract, when invoking {onERC1155BatchReceived} on the receiver.
* Ensure to follow the checks-effects-interactions pattern and consider employing
* reentrancy guards when interacting with untrusted contracts.
*
* Emits either a {TransferSingle} or a {TransferBatch} event, depending on the length of the array arguments.
*
* Requirements:
*
* - `ids` and `values` must have the same length.
* - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155BatchReceived} and return the
* acceptance magic value.
*/
function safeBatchTransferFrom(
address from,
address to,
uint256[] calldata ids,
uint256[] calldata values,
bytes calldata data
) external;
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.1.0) (token/ERC1155/IERC1155Receiver.sol)
pragma solidity ^0.8.20;
import {IERC165} from "../../utils/introspection/IERC165.sol";
/**
* @dev Interface that must be implemented by smart contracts in order to receive
* ERC-1155 token transfers.
*/
interface IERC1155Receiver is IERC165 {
/**
* @dev Handles the receipt of a single ERC-1155 token type. This function is
* called at the end of a `safeTransferFrom` after the balance has been updated.
*
* NOTE: To accept the transfer, this must return
* `bytes4(keccak256("onERC1155Received(address,address,uint256,uint256,bytes)"))`
* (i.e. 0xf23a6e61, or its own function selector).
*
* @param operator The address which initiated the transfer (i.e. msg.sender)
* @param from The address which previously owned the token
* @param id The ID of the token being transferred
* @param value The amount of tokens being transferred
* @param data Additional data with no specified format
* @return `bytes4(keccak256("onERC1155Received(address,address,uint256,uint256,bytes)"))` if transfer is allowed
*/
function onERC1155Received(
address operator,
address from,
uint256 id,
uint256 value,
bytes calldata data
) external returns (bytes4);
/**
* @dev Handles the receipt of a multiple ERC-1155 token types. This function
* is called at the end of a `safeBatchTransferFrom` after the balances have
* been updated.
*
* NOTE: To accept the transfer(s), this must return
* `bytes4(keccak256("onERC1155BatchReceived(address,address,uint256[],uint256[],bytes)"))`
* (i.e. 0xbc197c81, or its own function selector).
*
* @param operator The address which initiated the batch transfer (i.e. msg.sender)
* @param from The address which previously owned the token
* @param ids An array containing ids of each token being transferred (order and length must match values array)
* @param values An array containing amounts of each token being transferred (order and length must match ids array)
* @param data Additional data with no specified format
* @return `bytes4(keccak256("onERC1155BatchReceived(address,address,uint256[],uint256[],bytes)"))` if transfer is allowed
*/
function onERC1155BatchReceived(
address operator,
address from,
uint256[] calldata ids,
uint256[] calldata values,
bytes calldata data
) external returns (bytes4);
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.1.0) (token/ERC1155/utils/ERC1155Holder.sol)
pragma solidity ^0.8.20;
import {IERC165, ERC165} from "../../../utils/introspection/ERC165.sol";
import {IERC1155Receiver} from "../IERC1155Receiver.sol";
/**
* @dev Simple implementation of `IERC1155Receiver` that will allow a contract to hold ERC-1155 tokens.
*
* IMPORTANT: When inheriting this contract, you must include a way to use the received tokens, otherwise they will be
* stuck.
*/
abstract contract ERC1155Holder is ERC165, IERC1155Receiver {
/**
* @dev See {IERC165-supportsInterface}.
*/
function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) {
return interfaceId == type(IERC1155Receiver).interfaceId || super.supportsInterface(interfaceId);
}
function onERC1155Received(
address,
address,
uint256,
uint256,
bytes memory
) public virtual override returns (bytes4) {
return this.onERC1155Received.selector;
}
function onERC1155BatchReceived(
address,
address,
uint256[] memory,
uint256[] memory,
bytes memory
) public virtual override returns (bytes4) {
return this.onERC1155BatchReceived.selector;
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.1.0) (token/ERC721/IERC721.sol)
pragma solidity ^0.8.20;
import {IERC165} from "../../utils/introspection/IERC165.sol";
/**
* @dev Required interface of an ERC-721 compliant contract.
*/
interface IERC721 is IERC165 {
/**
* @dev Emitted when `tokenId` token is transferred from `from` to `to`.
*/
event Transfer(address indexed from, address indexed to, uint256 indexed tokenId);
/**
* @dev Emitted when `owner` enables `approved` to manage the `tokenId` token.
*/
event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId);
/**
* @dev Emitted when `owner` enables or disables (`approved`) `operator` to manage all of its assets.
*/
event ApprovalForAll(address indexed owner, address indexed operator, bool approved);
/**
* @dev Returns the number of tokens in ``owner``'s account.
*/
function balanceOf(address owner) external view returns (uint256 balance);
/**
* @dev Returns the owner of the `tokenId` token.
*
* Requirements:
*
* - `tokenId` must exist.
*/
function ownerOf(uint256 tokenId) external view returns (address owner);
/**
* @dev Safely transfers `tokenId` token from `from` to `to`.
*
* Requirements:
*
* - `from` cannot be the zero address.
* - `to` cannot be the zero address.
* - `tokenId` token must exist and be owned by `from`.
* - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}.
* - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon
* a safe transfer.
*
* Emits a {Transfer} event.
*/
function safeTransferFrom(address from, address to, uint256 tokenId, bytes calldata data) external;
/**
* @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients
* are aware of the ERC-721 protocol to prevent tokens from being forever locked.
*
* Requirements:
*
* - `from` cannot be the zero address.
* - `to` cannot be the zero address.
* - `tokenId` token must exist and be owned by `from`.
* - If the caller is not `from`, it must have been allowed to move this token by either {approve} or
* {setApprovalForAll}.
* - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon
* a safe transfer.
*
* Emits a {Transfer} event.
*/
function safeTransferFrom(address from, address to, uint256 tokenId) external;
/**
* @dev Transfers `tokenId` token from `from` to `to`.
*
* WARNING: Note that the caller is responsible to confirm that the recipient is capable of receiving ERC-721
* or else they may be permanently lost. Usage of {safeTransferFrom} prevents loss, though the caller must
* understand this adds an external call which potentially creates a reentrancy vulnerability.
*
* Requirements:
*
* - `from` cannot be the zero address.
* - `to` cannot be the zero address.
* - `tokenId` token must be owned by `from`.
* - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}.
*
* Emits a {Transfer} event.
*/
function transferFrom(address from, address to, uint256 tokenId) external;
/**
* @dev Gives permission to `to` to transfer `tokenId` token to another account.
* The approval is cleared when the token is transferred.
*
* Only a single account can be approved at a time, so approving the zero address clears previous approvals.
*
* Requirements:
*
* - The caller must own the token or be an approved operator.
* - `tokenId` must exist.
*
* Emits an {Approval} event.
*/
function approve(address to, uint256 tokenId) external;
/**
* @dev Approve or remove `operator` as an operator for the caller.
* Operators can call {transferFrom} or {safeTransferFrom} for any token owned by the caller.
*
* Requirements:
*
* - The `operator` cannot be the address zero.
*
* Emits an {ApprovalForAll} event.
*/
function setApprovalForAll(address operator, bool approved) external;
/**
* @dev Returns the account approved for `tokenId` token.
*
* Requirements:
*
* - `tokenId` must exist.
*/
function getApproved(uint256 tokenId) external view returns (address operator);
/**
* @dev Returns if the `operator` is allowed to manage all of the assets of `owner`.
*
* See {setApprovalForAll}
*/
function isApprovedForAll(address owner, address operator) external view returns (bool);
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.1.0) (token/ERC721/IERC721Receiver.sol)
pragma solidity ^0.8.20;
/**
* @title ERC-721 token receiver interface
* @dev Interface for any contract that wants to support safeTransfers
* from ERC-721 asset contracts.
*/
interface IERC721Receiver {
/**
* @dev Whenever an {IERC721} `tokenId` token is transferred to this contract via {IERC721-safeTransferFrom}
* by `operator` from `from`, this function is called.
*
* It must return its Solidity selector to confirm the token transfer.
* If any other value is returned or the interface is not implemented by the recipient, the transfer will be
* reverted.
*
* The selector can be obtained in Solidity with `IERC721Receiver.onERC721Received.selector`.
*/
function onERC721Received(
address operator,
address from,
uint256 tokenId,
bytes calldata data
) external returns (bytes4);
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.0.0) (token/ERC721/utils/ERC721Holder.sol)
pragma solidity ^0.8.20;
import {IERC721Receiver} from "../IERC721Receiver.sol";
/**
* @dev Implementation of the {IERC721Receiver} interface.
*
* Accepts all token transfers.
* Make sure the contract is able to use its token with {IERC721-safeTransferFrom}, {IERC721-approve} or
* {IERC721-setApprovalForAll}.
*/
abstract contract ERC721Holder is IERC721Receiver {
/**
* @dev See {IERC721Receiver-onERC721Received}.
*
* Always returns `IERC721Receiver.onERC721Received.selector`.
*/
function onERC721Received(address, address, uint256, bytes memory) public virtual returns (bytes4) {
return this.onERC721Received.selector;
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.1.0) (utils/introspection/ERC165.sol)
pragma solidity ^0.8.20;
import {IERC165} from "./IERC165.sol";
/**
* @dev Implementation of the {IERC165} interface.
*
* Contracts that want to implement ERC-165 should inherit from this contract and override {supportsInterface} to check
* for the additional interface id that will be supported. For example:
*
* ```solidity
* function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
* return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId);
* }
* ```
*/
abstract contract ERC165 is IERC165 {
/**
* @dev See {IERC165-supportsInterface}.
*/
function supportsInterface(bytes4 interfaceId) public view virtual returns (bool) {
return interfaceId == type(IERC165).interfaceId;
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.1.0) (utils/introspection/IERC165.sol)
pragma solidity ^0.8.20;
/**
* @dev Interface of the ERC-165 standard, as defined in the
* https://eips.ethereum.org/EIPS/eip-165[ERC].
*
* Implementers can declare support of contract interfaces, which can then be
* queried by others ({ERC165Checker}).
*
* For an implementation, see {ERC165}.
*/
interface IERC165 {
/**
* @dev Returns true if this contract implements the interface defined by
* `interfaceId`. See the corresponding
* https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[ERC section]
* to learn more about how these ids are created.
*
* This function call must use less than 30 000 gas.
*/
function supportsInterface(bytes4 interfaceId) external view returns (bool);
}{
"optimizer": {
"enabled": true,
"runs": 100000
},
"evmVersion": "paris",
"outputSelection": {
"*": {
"*": [
"evm.bytecode",
"evm.deployedBytecode",
"devdoc",
"userdoc",
"metadata",
"abi"
]
}
}
}Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
Contract ABI
API[{"inputs":[],"name":"AuctionAlreadySettled","type":"error"},{"inputs":[],"name":"AuctionDoesNotExist","type":"error"},{"inputs":[],"name":"AuctionNotActive","type":"error"},{"inputs":[],"name":"AuctionNotComplete","type":"error"},{"inputs":[],"name":"FailedWithdrawal","type":"error"},{"inputs":[],"name":"MinimumBidNotMet","type":"error"},{"inputs":[],"name":"NoBalanceToWithdraw","type":"error"},{"inputs":[],"name":"TooManyTokens","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"auctionId","type":"uint256"},{"indexed":true,"internalType":"uint256","name":"endTimestamp","type":"uint256"}],"name":"AuctionExtended","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"auctionId","type":"uint256"},{"indexed":true,"internalType":"address","name":"tokenContract","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint16","name":"tokenERCStandard","type":"uint16"},{"indexed":false,"internalType":"uint40","name":"endTimestamp","type":"uint40"},{"indexed":false,"internalType":"address","name":"beneficiary","type":"address"}],"name":"AuctionInitialised","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"auctionId","type":"uint256"},{"indexed":true,"internalType":"address","name":"winner","type":"address"},{"indexed":true,"internalType":"address","name":"beneficiary","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"AuctionSettled","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"auctionId","type":"uint256"},{"indexed":true,"internalType":"uint256","name":"bid","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"}],"name":"Bid","type":"event"},{"inputs":[],"name":"AUCTION_DURATION","outputs":[{"internalType":"uint40","name":"","type":"uint40"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BIDDING_GRACE_PERIOD","outputs":[{"internalType":"uint40","name":"","type":"uint40"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BID_PERCENTAGE_INCREASE","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAX_BID_INCREASE","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"auctionId","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"auctions","outputs":[{"internalType":"address","name":"tokenContract","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint80","name":"tokenAmount","type":"uint80"},{"internalType":"uint16","name":"tokenStandard","type":"uint16"},{"internalType":"uint40","name":"endTimestamp","type":"uint40"},{"internalType":"bool","name":"settled","type":"bool"},{"internalType":"uint112","name":"latestBid","type":"uint112"},{"internalType":"address","name":"latestBidder","type":"address"},{"internalType":"address payable","name":"beneficiary","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"balances","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"bid","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"currentBidPrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"","type":"address"},{"internalType":"uint256[]","name":"","type":"uint256[]"},{"internalType":"uint256[]","name":"","type":"uint256[]"},{"internalType":"bytes","name":"","type":"bytes"}],"name":"onERC1155BatchReceived","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"from","type":"address"},{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint256","name":"value","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onERC1155Received","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"from","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onERC721Received","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"settle","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"}]Contract Creation Code
6101006040526201518060805261012c60a052600a60c052670de0b6b3a764000060e05234801561002f57600080fd5b5060805160a05160c05160e051611aa86100936000396000818161040701528181611414015261143b01526000818161036901526113df0152600081816104a00152818161148401526114da0152600081816103bd015261121d0152611aa86000f3fe6080604052600436106100e85760003560e01c806374c025981161008a578063bc197c8111610059578063bc197c8114610429578063cb0fc56d1461046e578063e75429e11461048e578063f23a6e61146104c257600080fd5b806374c02598146103575780638df828001461038b578063a271e525146103ab578063b5a13e4c146103f557600080fd5b806327e235e3116100c657806327e235e3146101975780633ccfd60b146101c4578063454a2ab3146101db578063571a26a0146101ee57600080fd5b806301ffc9a7146100ed57806310782f8f14610122578063150b7a0214610146575b600080fd5b3480156100f957600080fd5b5061010d610108366004611593565b6104e2565b60405190151581526020015b60405180910390f35b34801561012e57600080fd5b5061013860005481565b604051908152602001610119565b34801561015257600080fd5b5061016661016136600461170d565b61057b565b6040517fffffffff000000000000000000000000000000000000000000000000000000009091168152602001610119565b3480156101a357600080fd5b506101386101b2366004611779565b60026020526000908152604090205481565b3480156101d057600080fd5b506101d96105c2565b005b6101d96101e9366004611796565b6106a1565b3480156101fa57600080fd5b506102cd610209366004611796565b60016020819052600091825260409091208054918101546002820154600383015460049093015473ffffffffffffffffffffffffffffffffffffffff94851694929369ffffffffffffffffffff8316936a0100000000000000000000840461ffff16936c01000000000000000000000000810464ffffffffff169371010000000000000000000000000000000000820460ff169372010000000000000000000000000000000000009092046dffffffffffffffffffffffffffff1692918216911689565b6040805173ffffffffffffffffffffffffffffffffffffffff9a8b168152602081019990995269ffffffffffffffffffff9097169688019690965261ffff909416606087015264ffffffffff9092166080860152151560a08501526dffffffffffffffffffffffffffff1660c0840152831660e08301529190911661010082015261012001610119565b34801561036357600080fd5b506101387f000000000000000000000000000000000000000000000000000000000000000081565b34801561039757600080fd5b506101d96103a6366004611796565b610a7a565b3480156103b757600080fd5b506103df7f000000000000000000000000000000000000000000000000000000000000000081565b60405164ffffffffff9091168152602001610119565b34801561040157600080fd5b506101387f000000000000000000000000000000000000000000000000000000000000000081565b34801561043557600080fd5b5061016661044436600461182f565b7fbc197c810000000000000000000000000000000000000000000000000000000095945050505050565b34801561047a57600080fd5b50610138610489366004611796565b61102e565b34801561049a57600080fd5b506103df7f000000000000000000000000000000000000000000000000000000000000000081565b3480156104ce57600080fd5b506101666104dd3660046118dd565b611128565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f4e2312e000000000000000000000000000000000000000000000000000000000148061057557507f01ffc9a7000000000000000000000000000000000000000000000000000000007fffffffff000000000000000000000000000000000000000000000000000000008316145b92915050565b60003361059781856102d16001610592888b6111ad565b6111fb565b507f150b7a020000000000000000000000000000000000000000000000000000000095945050505050565b336000908152600260205260408120549081900361060c576040517fbbd8170800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000818152600260205260408082208290555190919083908381818185875af1925050503d806000811461065d576040519150601f19603f3d011682016040523d82523d6000602084013e610662565b606091505b505090508061069d576040517fa124823500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5050565b60008181526001602081815260409283902060038101546002820154855161012081018752835473ffffffffffffffffffffffffffffffffffffffff9081168252958401549481019490945269ffffffffffffffffffff8116958401959095526a0100000000000000000000850461ffff1660608401526c01000000000000000000000000850464ffffffffff16608084015271010000000000000000000000000000000000850460ff16151560a084015272010000000000000000000000000000000000009094046dffffffffffffffffffffffffffff1660c0830181905293831660e0830181905260048201549093166101008301529290339034906107a890611396565b8110156107e1576040517f4285416300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60028501546c01000000000000000000000000900464ffffffffff16421115610836576040517f69b8d0fe00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6108408686611476565b6002850180546dffffffffffffffffffffffffffff838116720100000000000000000000000000000000000090810271ffffffffffffffffffffffffffffffffffff841681179485905560038a01805473ffffffffffffffffffffffffffffffffffffffff8981167fffffffffffffffffffffffff0000000000000000000000000000000000000000909216821790925560408051610120810182528d548416815260018e0154602082015269ffffffffffffffffffff94851694909716939093179286019290925261ffff6a0100000000000000000000870416606086015264ffffffffff6c01000000000000000000000000870416608086015260ff71010000000000000000000000000000000000870416151560a08601529190940490911660c0830181905260e08301939093526004880154166101009091015215610a2d5760008473ffffffffffffffffffffffffffffffffffffffff168461ea6090604051600060405180830381858888f193505050503d80600081146109e2576040519150601f19603f3d011682016040523d82523d6000602084013e6109e7565b606091505b5050905080610a2b5773ffffffffffffffffffffffffffffffffffffffff851660009081526002602052604081208054869290610a25908490611975565b90915550505b505b8173ffffffffffffffffffffffffffffffffffffffff1681877ffd7cfbd219ff1e7365436fb2930a026fa6704a1e0bb39ad104f0485c8c01124d60405160405180910390a4505050505050565b6000818152600160205260409020600281015471010000000000000000000000000000000000900460ff1615610adc576040517f4f4fee1700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60028101546c01000000000000000000000000900464ffffffffff16600003610b31576040517fe6759c6700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60028101546c01000000000000000000000000900464ffffffffff164211610b85576040517f9510b0d600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805161012081018252825473ffffffffffffffffffffffffffffffffffffffff908116825260018401546020830152600284015469ffffffffffffffffffff8116938301939093526a0100000000000000000000830461ffff1660608301526c01000000000000000000000000830464ffffffffff16608083015271010000000000000000000000000000000000830460ff16151560a083015272010000000000000000000000000000000000009092046dffffffffffffffffffffffffffff1660c082018190526003840154831660e08301526004840154909216610100909101521515600081610c9357600483015473ffffffffffffffffffffffffffffffffffffffff16610caf565b600383015473ffffffffffffffffffffffffffffffffffffffff165b6002840180547fffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffff167101000000000000000000000000000000000017905590508115610e03576004830154600284015460405160009273ffffffffffffffffffffffffffffffffffffffff169161ea609172010000000000000000000000000000000000009091046dffffffffffffffffffffffffffff1690600060405180830381858888f193505050503d8060008114610d86576040519150601f19603f3d011682016040523d82523d6000602084013e610d8b565b606091505b5050905080610e0157600284810154600486015473ffffffffffffffffffffffffffffffffffffffff16600090815260209290925260408220805472010000000000000000000000000000000000009092046dffffffffffffffffffffffffffff16929091610dfb908490611975565b90915550505b505b60028301546a0100000000000000000000900461ffff166102d103610ecb57825460018401546040517fb88d4fde00000000000000000000000000000000000000000000000000000000815230600482015273ffffffffffffffffffffffffffffffffffffffff84811660248301526044820192909252608060648201526000608482015291169063b88d4fde9060a401600060405180830381600087803b158015610eae57600080fd5b505af1158015610ec2573d6000803e3d6000fd5b50505050610fa7565b60028301546a0100000000000000000000900461ffff1661048303610fa7578254600184015460028501546040517ff242432a00000000000000000000000000000000000000000000000000000000815230600482015273ffffffffffffffffffffffffffffffffffffffff8581166024830152604482019390935269ffffffffffffffffffff909116606482015260a06084820152600060a482015291169063f242432a9060c401600060405180830381600087803b158015610f8e57600080fd5b505af1158015610fa2573d6000803e3d6000fd5b505050505b6004830154600284015460405172010000000000000000000000000000000000009091046dffffffffffffffffffffffffffff16815273ffffffffffffffffffffffffffffffffffffffff9182169183169086907f3e25c3675d003af5184b628dd8bd4775b9b3abc7351c3574c90870ca25b55f119060200160405180910390a450505050565b6000818152600160208181526040808420815161012081018352815473ffffffffffffffffffffffffffffffffffffffff90811682529482015493810193909352600281015469ffffffffffffffffffff8116928401929092526a0100000000000000000000820461ffff1660608401526c01000000000000000000000000820464ffffffffff16608084015271010000000000000000000000000000000000820460ff16151560a084015272010000000000000000000000000000000000009091046dffffffffffffffffffffffffffff1660c08301526003810154831660e08301526004015490911661010082015261057590611396565b600069ffffffffffffffffffff831061116d576040517f748e67b200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b33611181818661048387610592888c6111ad565b507ff23a6e61000000000000000000000000000000000000000000000000000000009695505050505050565b600082516020036111f5576000838060200190518101906111ce9190611988565b905073ffffffffffffffffffffffffffffffffffffffff8116156111f3579050610575565b505b50919050565b60008054908061120a836119a5565b909155506000905061124364ffffffffff7f00000000000000000000000000000000000000000000000000000000000000001642611975565b60008054815260016020818152604080842080547fffffffffffffffffffffffff000000000000000000000000000000000000000090811673ffffffffffffffffffffffffffffffffffffffff8e811691821784559583018d905560028301805469ffffffffffffffffffff8d167fffffffffffffffffffffffffffffffffffffffff000000000000000000000000909116176a010000000000000000000061ffff8f16908102919091177fffffffffffffffffffffffffffffff0000000000ffffffffffffffffffffffff166c0100000000000000000000000064ffffffffff8c1690810291909117909255600485018054909416978c169788179093559654845192835294820196909652918201939093529394509092889291907fcb1b0405c5d24f2840cd78fac5deecd67b4778ee67c494933cd568cbadbd81da9060600160405180910390a450505050505050565b60006113b58260c001516dffffffffffffffffffffffffffff16151590565b6113c157610575611580565b60c08201516dffffffffffffffffffffffffffff16600060646114047f0000000000000000000000000000000000000000000000000000000000000000846119dd565b61140e91906119f4565b905060007f0000000000000000000000000000000000000000000000000000000000000000821061145f577f0000000000000000000000000000000000000000000000000000000000000000611461565b815b905061146d8184611975565b95945050505050565b60028101546000906114c0907f0000000000000000000000000000000000000000000000000000000000000000906c01000000000000000000000000900464ffffffffff16611a2f565b90504264ffffffffff808316908216111561157a576114ff7f000000000000000000000000000000000000000000000000000000000000000082611a54565b6002840180547fffffffffffffffffffffffffffffff0000000000ffffffffffffffffffffffff166c0100000000000000000000000064ffffffffff9384168102919091179182905560405191049091169085907f6e912a3a9105bdd2af817ba5adc14e6c127c1035b5b648faa29ca0d58ab8ff4e90600090a35b50505050565b600061158e4861ea606119dd565b905090565b6000602082840312156115a557600080fd5b81357fffffffff00000000000000000000000000000000000000000000000000000000811681146115d557600080fd5b9392505050565b73ffffffffffffffffffffffffffffffffffffffff811681146115fe57600080fd5b50565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff8111828210171561167757611677611601565b604052919050565b600082601f83011261169057600080fd5b813567ffffffffffffffff8111156116aa576116aa611601565b6116db60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601611630565b8181528460208386010111156116f057600080fd5b816020850160208301376000918101602001919091529392505050565b6000806000806080858703121561172357600080fd5b843561172e816115dc565b9350602085013561173e816115dc565b925060408501359150606085013567ffffffffffffffff81111561176157600080fd5b61176d8782880161167f565b91505092959194509250565b60006020828403121561178b57600080fd5b81356115d5816115dc565b6000602082840312156117a857600080fd5b5035919050565b600082601f8301126117c057600080fd5b8135602067ffffffffffffffff8211156117dc576117dc611601565b8160051b6117eb828201611630565b928352848101820192828101908785111561180557600080fd5b83870192505b848310156118245782358252918301919083019061180b565b979650505050505050565b600080600080600060a0868803121561184757600080fd5b8535611852816115dc565b94506020860135611862816115dc565b9350604086013567ffffffffffffffff8082111561187f57600080fd5b61188b89838a016117af565b945060608801359150808211156118a157600080fd5b6118ad89838a016117af565b935060808801359150808211156118c357600080fd5b506118d08882890161167f565b9150509295509295909350565b600080600080600060a086880312156118f557600080fd5b8535611900816115dc565b94506020860135611910816115dc565b93506040860135925060608601359150608086013567ffffffffffffffff81111561193a57600080fd5b6118d08882890161167f565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b8082018082111561057557610575611946565b60006020828403121561199a57600080fd5b81516115d5816115dc565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036119d6576119d6611946565b5060010190565b808202811582820484141761057557610575611946565b600082611a2a577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500490565b64ffffffffff828116828216039080821115611a4d57611a4d611946565b5092915050565b64ffffffffff818116838216019080821115611a4d57611a4d61194656fea2646970667358221220407cb206ba77d0ec967d1f4d8a45fc0476dc30e129531947324a2657893e6e2764736f6c63430008180033
Deployed Bytecode
0x6080604052600436106100e85760003560e01c806374c025981161008a578063bc197c8111610059578063bc197c8114610429578063cb0fc56d1461046e578063e75429e11461048e578063f23a6e61146104c257600080fd5b806374c02598146103575780638df828001461038b578063a271e525146103ab578063b5a13e4c146103f557600080fd5b806327e235e3116100c657806327e235e3146101975780633ccfd60b146101c4578063454a2ab3146101db578063571a26a0146101ee57600080fd5b806301ffc9a7146100ed57806310782f8f14610122578063150b7a0214610146575b600080fd5b3480156100f957600080fd5b5061010d610108366004611593565b6104e2565b60405190151581526020015b60405180910390f35b34801561012e57600080fd5b5061013860005481565b604051908152602001610119565b34801561015257600080fd5b5061016661016136600461170d565b61057b565b6040517fffffffff000000000000000000000000000000000000000000000000000000009091168152602001610119565b3480156101a357600080fd5b506101386101b2366004611779565b60026020526000908152604090205481565b3480156101d057600080fd5b506101d96105c2565b005b6101d96101e9366004611796565b6106a1565b3480156101fa57600080fd5b506102cd610209366004611796565b60016020819052600091825260409091208054918101546002820154600383015460049093015473ffffffffffffffffffffffffffffffffffffffff94851694929369ffffffffffffffffffff8316936a0100000000000000000000840461ffff16936c01000000000000000000000000810464ffffffffff169371010000000000000000000000000000000000820460ff169372010000000000000000000000000000000000009092046dffffffffffffffffffffffffffff1692918216911689565b6040805173ffffffffffffffffffffffffffffffffffffffff9a8b168152602081019990995269ffffffffffffffffffff9097169688019690965261ffff909416606087015264ffffffffff9092166080860152151560a08501526dffffffffffffffffffffffffffff1660c0840152831660e08301529190911661010082015261012001610119565b34801561036357600080fd5b506101387f000000000000000000000000000000000000000000000000000000000000000a81565b34801561039757600080fd5b506101d96103a6366004611796565b610a7a565b3480156103b757600080fd5b506103df7f000000000000000000000000000000000000000000000000000000000001518081565b60405164ffffffffff9091168152602001610119565b34801561040157600080fd5b506101387f0000000000000000000000000000000000000000000000000de0b6b3a764000081565b34801561043557600080fd5b5061016661044436600461182f565b7fbc197c810000000000000000000000000000000000000000000000000000000095945050505050565b34801561047a57600080fd5b50610138610489366004611796565b61102e565b34801561049a57600080fd5b506103df7f000000000000000000000000000000000000000000000000000000000000012c81565b3480156104ce57600080fd5b506101666104dd3660046118dd565b611128565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f4e2312e000000000000000000000000000000000000000000000000000000000148061057557507f01ffc9a7000000000000000000000000000000000000000000000000000000007fffffffff000000000000000000000000000000000000000000000000000000008316145b92915050565b60003361059781856102d16001610592888b6111ad565b6111fb565b507f150b7a020000000000000000000000000000000000000000000000000000000095945050505050565b336000908152600260205260408120549081900361060c576040517fbbd8170800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000818152600260205260408082208290555190919083908381818185875af1925050503d806000811461065d576040519150601f19603f3d011682016040523d82523d6000602084013e610662565b606091505b505090508061069d576040517fa124823500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5050565b60008181526001602081815260409283902060038101546002820154855161012081018752835473ffffffffffffffffffffffffffffffffffffffff9081168252958401549481019490945269ffffffffffffffffffff8116958401959095526a0100000000000000000000850461ffff1660608401526c01000000000000000000000000850464ffffffffff16608084015271010000000000000000000000000000000000850460ff16151560a084015272010000000000000000000000000000000000009094046dffffffffffffffffffffffffffff1660c0830181905293831660e0830181905260048201549093166101008301529290339034906107a890611396565b8110156107e1576040517f4285416300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60028501546c01000000000000000000000000900464ffffffffff16421115610836576040517f69b8d0fe00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6108408686611476565b6002850180546dffffffffffffffffffffffffffff838116720100000000000000000000000000000000000090810271ffffffffffffffffffffffffffffffffffff841681179485905560038a01805473ffffffffffffffffffffffffffffffffffffffff8981167fffffffffffffffffffffffff0000000000000000000000000000000000000000909216821790925560408051610120810182528d548416815260018e0154602082015269ffffffffffffffffffff94851694909716939093179286019290925261ffff6a0100000000000000000000870416606086015264ffffffffff6c01000000000000000000000000870416608086015260ff71010000000000000000000000000000000000870416151560a08601529190940490911660c0830181905260e08301939093526004880154166101009091015215610a2d5760008473ffffffffffffffffffffffffffffffffffffffff168461ea6090604051600060405180830381858888f193505050503d80600081146109e2576040519150601f19603f3d011682016040523d82523d6000602084013e6109e7565b606091505b5050905080610a2b5773ffffffffffffffffffffffffffffffffffffffff851660009081526002602052604081208054869290610a25908490611975565b90915550505b505b8173ffffffffffffffffffffffffffffffffffffffff1681877ffd7cfbd219ff1e7365436fb2930a026fa6704a1e0bb39ad104f0485c8c01124d60405160405180910390a4505050505050565b6000818152600160205260409020600281015471010000000000000000000000000000000000900460ff1615610adc576040517f4f4fee1700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60028101546c01000000000000000000000000900464ffffffffff16600003610b31576040517fe6759c6700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60028101546c01000000000000000000000000900464ffffffffff164211610b85576040517f9510b0d600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805161012081018252825473ffffffffffffffffffffffffffffffffffffffff908116825260018401546020830152600284015469ffffffffffffffffffff8116938301939093526a0100000000000000000000830461ffff1660608301526c01000000000000000000000000830464ffffffffff16608083015271010000000000000000000000000000000000830460ff16151560a083015272010000000000000000000000000000000000009092046dffffffffffffffffffffffffffff1660c082018190526003840154831660e08301526004840154909216610100909101521515600081610c9357600483015473ffffffffffffffffffffffffffffffffffffffff16610caf565b600383015473ffffffffffffffffffffffffffffffffffffffff165b6002840180547fffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffff167101000000000000000000000000000000000017905590508115610e03576004830154600284015460405160009273ffffffffffffffffffffffffffffffffffffffff169161ea609172010000000000000000000000000000000000009091046dffffffffffffffffffffffffffff1690600060405180830381858888f193505050503d8060008114610d86576040519150601f19603f3d011682016040523d82523d6000602084013e610d8b565b606091505b5050905080610e0157600284810154600486015473ffffffffffffffffffffffffffffffffffffffff16600090815260209290925260408220805472010000000000000000000000000000000000009092046dffffffffffffffffffffffffffff16929091610dfb908490611975565b90915550505b505b60028301546a0100000000000000000000900461ffff166102d103610ecb57825460018401546040517fb88d4fde00000000000000000000000000000000000000000000000000000000815230600482015273ffffffffffffffffffffffffffffffffffffffff84811660248301526044820192909252608060648201526000608482015291169063b88d4fde9060a401600060405180830381600087803b158015610eae57600080fd5b505af1158015610ec2573d6000803e3d6000fd5b50505050610fa7565b60028301546a0100000000000000000000900461ffff1661048303610fa7578254600184015460028501546040517ff242432a00000000000000000000000000000000000000000000000000000000815230600482015273ffffffffffffffffffffffffffffffffffffffff8581166024830152604482019390935269ffffffffffffffffffff909116606482015260a06084820152600060a482015291169063f242432a9060c401600060405180830381600087803b158015610f8e57600080fd5b505af1158015610fa2573d6000803e3d6000fd5b505050505b6004830154600284015460405172010000000000000000000000000000000000009091046dffffffffffffffffffffffffffff16815273ffffffffffffffffffffffffffffffffffffffff9182169183169086907f3e25c3675d003af5184b628dd8bd4775b9b3abc7351c3574c90870ca25b55f119060200160405180910390a450505050565b6000818152600160208181526040808420815161012081018352815473ffffffffffffffffffffffffffffffffffffffff90811682529482015493810193909352600281015469ffffffffffffffffffff8116928401929092526a0100000000000000000000820461ffff1660608401526c01000000000000000000000000820464ffffffffff16608084015271010000000000000000000000000000000000820460ff16151560a084015272010000000000000000000000000000000000009091046dffffffffffffffffffffffffffff1660c08301526003810154831660e08301526004015490911661010082015261057590611396565b600069ffffffffffffffffffff831061116d576040517f748e67b200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b33611181818661048387610592888c6111ad565b507ff23a6e61000000000000000000000000000000000000000000000000000000009695505050505050565b600082516020036111f5576000838060200190518101906111ce9190611988565b905073ffffffffffffffffffffffffffffffffffffffff8116156111f3579050610575565b505b50919050565b60008054908061120a836119a5565b909155506000905061124364ffffffffff7f00000000000000000000000000000000000000000000000000000000000151801642611975565b60008054815260016020818152604080842080547fffffffffffffffffffffffff000000000000000000000000000000000000000090811673ffffffffffffffffffffffffffffffffffffffff8e811691821784559583018d905560028301805469ffffffffffffffffffff8d167fffffffffffffffffffffffffffffffffffffffff000000000000000000000000909116176a010000000000000000000061ffff8f16908102919091177fffffffffffffffffffffffffffffff0000000000ffffffffffffffffffffffff166c0100000000000000000000000064ffffffffff8c1690810291909117909255600485018054909416978c169788179093559654845192835294820196909652918201939093529394509092889291907fcb1b0405c5d24f2840cd78fac5deecd67b4778ee67c494933cd568cbadbd81da9060600160405180910390a450505050505050565b60006113b58260c001516dffffffffffffffffffffffffffff16151590565b6113c157610575611580565b60c08201516dffffffffffffffffffffffffffff16600060646114047f000000000000000000000000000000000000000000000000000000000000000a846119dd565b61140e91906119f4565b905060007f0000000000000000000000000000000000000000000000000de0b6b3a7640000821061145f577f0000000000000000000000000000000000000000000000000de0b6b3a7640000611461565b815b905061146d8184611975565b95945050505050565b60028101546000906114c0907f000000000000000000000000000000000000000000000000000000000000012c906c01000000000000000000000000900464ffffffffff16611a2f565b90504264ffffffffff808316908216111561157a576114ff7f000000000000000000000000000000000000000000000000000000000000012c82611a54565b6002840180547fffffffffffffffffffffffffffffff0000000000ffffffffffffffffffffffff166c0100000000000000000000000064ffffffffff9384168102919091179182905560405191049091169085907f6e912a3a9105bdd2af817ba5adc14e6c127c1035b5b648faa29ca0d58ab8ff4e90600090a35b50505050565b600061158e4861ea606119dd565b905090565b6000602082840312156115a557600080fd5b81357fffffffff00000000000000000000000000000000000000000000000000000000811681146115d557600080fd5b9392505050565b73ffffffffffffffffffffffffffffffffffffffff811681146115fe57600080fd5b50565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff8111828210171561167757611677611601565b604052919050565b600082601f83011261169057600080fd5b813567ffffffffffffffff8111156116aa576116aa611601565b6116db60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601611630565b8181528460208386010111156116f057600080fd5b816020850160208301376000918101602001919091529392505050565b6000806000806080858703121561172357600080fd5b843561172e816115dc565b9350602085013561173e816115dc565b925060408501359150606085013567ffffffffffffffff81111561176157600080fd5b61176d8782880161167f565b91505092959194509250565b60006020828403121561178b57600080fd5b81356115d5816115dc565b6000602082840312156117a857600080fd5b5035919050565b600082601f8301126117c057600080fd5b8135602067ffffffffffffffff8211156117dc576117dc611601565b8160051b6117eb828201611630565b928352848101820192828101908785111561180557600080fd5b83870192505b848310156118245782358252918301919083019061180b565b979650505050505050565b600080600080600060a0868803121561184757600080fd5b8535611852816115dc565b94506020860135611862816115dc565b9350604086013567ffffffffffffffff8082111561187f57600080fd5b61188b89838a016117af565b945060608801359150808211156118a157600080fd5b6118ad89838a016117af565b935060808801359150808211156118c357600080fd5b506118d08882890161167f565b9150509295509295909350565b600080600080600060a086880312156118f557600080fd5b8535611900816115dc565b94506020860135611910816115dc565b93506040860135925060608601359150608086013567ffffffffffffffff81111561193a57600080fd5b6118d08882890161167f565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b8082018082111561057557610575611946565b60006020828403121561199a57600080fd5b81516115d5816115dc565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036119d6576119d6611946565b5060010190565b808202811582820484141761057557610575611946565b600082611a2a577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500490565b64ffffffffff828116828216039080821115611a4d57611a4d611946565b5092915050565b64ffffffffff818116838216019080821115611a4d57611a4d61194656fea2646970667358221220407cb206ba77d0ec967d1f4d8a45fc0476dc30e129531947324a2657893e6e2764736f6c63430008180033
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 34 Chains
| Chain | Token | Portfolio % | Price | Amount | Value |
|---|
Loading...
Loading
Loading...
Loading
Loading...
Loading
[ Download: CSV Export ]
[ Download: CSV Export ]
A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.