Source Code
Overview
CELO Balance
More Info
ContractCreator
Multichain Info
N/A
Latest 13 from a total of 13 transactions
Transaction Hash |
Method
|
Block
|
From
|
To
|
|||||
---|---|---|---|---|---|---|---|---|---|
Set Answer | 40786662 | 5 days ago | IN | 0 CELO | 0.00071572 | ||||
Set Answer | 40786603 | 5 days ago | IN | 0 CELO | 0.00064572 | ||||
Set Answer | 40786513 | 5 days ago | IN | 0 CELO | 0.00064572 | ||||
Set Answer | 40786470 | 5 days ago | IN | 0 CELO | 0.00071572 | ||||
Set Answer | 40786325 | 5 days ago | IN | 0 CELO | 0.00064572 | ||||
Set Answer | 40786201 | 5 days ago | IN | 0 CELO | 0.00071572 | ||||
Set Answer | 37997408 | 37 days ago | IN | 0 CELO | 0.00071572 | ||||
Set Answer | 37983396 | 37 days ago | IN | 0 CELO | 0.00071572 | ||||
Set Answer | 28653385 | 145 days ago | IN | 0 CELO | 0.00071572 | ||||
Set Answer | 27708438 | 156 days ago | IN | 0 CELO | 0.00071572 | ||||
Set Answer | 25872774 | 201 days ago | IN | 0 CELO | 0.0012914 | ||||
Set Answer | 25868432 | 202 days ago | IN | 0 CELO | 0.0014314 | ||||
Set Answer | 25867110 | 202 days ago | IN | 0 CELO | 0.0022864 |
Latest 25 internal transactions (View All)
Parent Transaction Hash | Block | From | To | |||
---|---|---|---|---|---|---|
41255212 | 28 secs ago | 0 CELO | ||||
41255212 | 28 secs ago | 0 CELO | ||||
41255207 | 33 secs ago | 0 CELO | ||||
41255207 | 33 secs ago | 0 CELO | ||||
41255149 | 1 min ago | 0 CELO | ||||
41255149 | 1 min ago | 0 CELO | ||||
41255147 | 1 min ago | 0 CELO | ||||
41255147 | 1 min ago | 0 CELO | ||||
41255097 | 2 mins ago | 0 CELO | ||||
41255097 | 2 mins ago | 0 CELO | ||||
41255087 | 2 mins ago | 0 CELO | ||||
41255087 | 2 mins ago | 0 CELO | ||||
41255027 | 3 mins ago | 0 CELO | ||||
41255027 | 3 mins ago | 0 CELO | ||||
41255026 | 3 mins ago | 0 CELO | ||||
41255026 | 3 mins ago | 0 CELO | ||||
41254967 | 4 mins ago | 0 CELO | ||||
41254967 | 4 mins ago | 0 CELO | ||||
41254966 | 4 mins ago | 0 CELO | ||||
41254966 | 4 mins ago | 0 CELO | ||||
41254907 | 5 mins ago | 0 CELO | ||||
41254907 | 5 mins ago | 0 CELO | ||||
41254906 | 5 mins ago | 0 CELO | ||||
41254906 | 5 mins ago | 0 CELO | ||||
41254846 | 6 mins ago | 0 CELO |
Loading...
Loading
This contract contains unverified libraries: AddressLinkedList, AddressSortedLinkedListWithMedian
Contract Name:
MockChainlinkAggregator
Compiler Version
v0.8.18+commit.87f61d96
Optimization Enabled:
Yes with 10000 runs
Other Settings:
paris EvmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: GPL-3.0-or-later pragma solidity 0.8.18; import { Ownable } from "openzeppelin-contracts-next/contracts/access/Ownable.sol"; contract MockChainlinkAggregator is Ownable { int256 public savedAnswer; string public description; constructor(string memory _description) { description = _description; } function decimals() external pure returns (uint8) { return 8; } function setAnswer(int256 _answer) external onlyOwner { savedAnswer = _answer; } // Always look like the answer is revent to avoid timestamp spread issues function latestRoundData() external view returns (uint80 roundId, int256 answer, uint256 startedAt, uint256 updatedAt, uint80 answeredInRound) { return (uint80(0), savedAnswer, uint256(0), block.timestamp, uint80(0)); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/Context.sol) pragma solidity ^0.8.0; /** * @dev Provides information about the current execution context, including the * sender of the transaction and its data. While these are generally available * via msg.sender and msg.data, they should not be accessed in such a direct * manner, since when dealing with meta-transactions the account sending and * paying for execution may not be the actual sender (as far as an application * is concerned). * * This contract is only required for intermediate, library-like contracts. */ abstract contract Context { function _msgSender() internal view virtual returns (address) { return msg.sender; } function _msgData() internal view virtual returns (bytes calldata) { return msg.data; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (access/Ownable.sol) pragma solidity ^0.8.0; import "../utils/Context.sol"; /** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. * * This module is used through inheritance. It will make available the modifier * `onlyOwner`, which can be applied to your functions to restrict their use to * the owner. */ abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor() { _transferOwnership(_msgSender()); } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { _checkOwner(); _; } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { return _owner; } /** * @dev Throws if the sender is not the owner. */ function _checkOwner() internal view virtual { require(owner() == _msgSender(), "Ownable: caller is not the owner"); } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions anymore. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby removing any functionality that is only available to the owner. */ function renounceOwnership() public virtual onlyOwner { _transferOwnership(address(0)); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */ function transferOwnership(address newOwner) public virtual onlyOwner { require(newOwner != address(0), "Ownable: new owner is the zero address"); _transferOwnership(newOwner); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Internal function without access restriction. */ function _transferOwnership(address newOwner) internal virtual { address oldOwner = _owner; _owner = newOwner; emit OwnershipTransferred(oldOwner, newOwner); } }
{ "viaIR": true, "metadata": { "appendCBOR": true, "bytecodeHash": "none", "useLiteralContent": true }, "optimizer": { "enabled": true, "runs": 10000 }, "evmVersion": "paris", "remappings": [ ":@chainlink/contracts/=lib/mento-core-2.5.0/lib/foundry-chainlink-toolkit/lib/chainlink-brownie-contracts/contracts/src/", ":@openzeppelin/=lib/mento-core-2.5.0/lib/foundry-chainlink-toolkit/lib/openzeppelin-contracts/", ":@prb/test/=lib/mento-core-2.5.0/lib/prb-math/lib/prb-test/src/", ":celo-foundry/=lib/celo-foundry/src/", ":chainlink-brownie-contracts/=lib/mento-core-2.5.0/lib/foundry-chainlink-toolkit/lib/chainlink-brownie-contracts/contracts/src/v0.6/vendor/@arbitrum/nitro-contracts/src/", ":contracts/=contracts/", ":ds-test/=lib/celo-foundry/lib/forge-std/lib/ds-test/src/", ":forge-std-next/=lib/forge-std-next/src/", ":forge-std/=lib/celo-foundry/lib/forge-std/src/", ":foundry-chainlink-toolkit/=lib/mento-core-2.5.0/lib/foundry-chainlink-toolkit/", ":mento-core-2.0.0/=lib/mento-core-2.0.0/contracts/", ":mento-core-2.1.0/=lib/mento-core-2.1.0/contracts/", ":mento-core-2.2.0/=lib/mento-core-2.2.0/contracts/", ":mento-core-2.3.1/=lib/mento-core-2.3.1/contracts/", ":mento-core-2.5.0/=lib/mento-core-2.5.0/contracts/", ":openzeppelin-contracts-next/=lib/mento-core-2.3.1/lib/openzeppelin-contracts-next/", ":openzeppelin-contracts-upgradeable/=lib/mento-core-2.3.1/lib/openzeppelin-contracts-upgradeable/", ":openzeppelin-contracts/=lib/mento-core-2.0.0/lib/openzeppelin-contracts/contracts/", ":openzeppelin-solidity/=lib/mento-core-2.0.0/lib/openzeppelin-contracts/", ":prb-math/=lib/mento-core-2.5.0/lib/prb-math/src/", ":prb-test/=lib/mento-core-2.5.0/lib/prb-math/lib/prb-test/src/", ":prb/math/=lib/mento-core-2.5.0/lib/prb-math/src/", ":safe-contracts/=lib/mento-core-2.3.1/lib/safe-contracts/", ":src/=lib/mento-core-2.5.0/lib/prb-math/src/", ":test/=lib/mento-core-2.0.0/test/" ], "libraries": { "lib/mento-core-2.0.0/contracts/common/linkedlists/AddressLinkedList.sol": { "AddressLinkedList": "0x2f0f7686fffefc3c266403ad600035581deaedff" }, "lib/mento-core-2.0.0/contracts/common/linkedlists/AddressSortedLinkedListWithMedian.sol": { "AddressSortedLinkedListWithMedian": "0x29b1b5e05217c751038861af2c77494eab10a257" } }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } } }
Contract ABI
API[{"inputs":[{"internalType":"string","name":"_description","type":"string"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"inputs":[],"name":"decimals","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"description","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"latestRoundData","outputs":[{"internalType":"uint80","name":"roundId","type":"uint80"},{"internalType":"int256","name":"answer","type":"int256"},{"internalType":"uint256","name":"startedAt","type":"uint256"},{"internalType":"uint256","name":"updatedAt","type":"uint256"},{"internalType":"uint80","name":"answeredInRound","type":"uint80"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"savedAnswer","outputs":[{"internalType":"int256","name":"","type":"int256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"int256","name":"_answer","type":"int256"}],"name":"setAnswer","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"}]
Contract Creation Code
60806040523461023c576107a98038038061001981610241565b9283398101906020808284031261023c5781516001600160401b039283821161023c570192601f9080828601121561023c57845184811161021257601f199561006782850188168601610241565b9282845285838301011161023c57849060005b8381106102285750506000918301018190528054336001600160a01b0319821681178355916001600160a01b03909116907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09080a3805193841161021257600254926001938481811c91168015610208575b828210146101f2578381116101ab575b508092851160011461014557508394509083929160009461013a575b50501b916000199060031b1c1916176002555b60405161054290816102678239f35b015192503880610118565b929484908116600260005284600020946000905b888383106101915750505010610178575b505050811b0160025561012b565b015160001960f88460031b161c1916905538808061016a565b858701518855909601959485019487935090810190610159565b6002600052816000208480880160051c8201928489106101e9575b0160051c019085905b8281106101dd5750506100fc565b600081550185906101cf565b925081926101c6565b634e487b7160e01b600052602260045260246000fd5b90607f16906100ec565b634e487b7160e01b600052604160045260246000fd5b81810183015185820184015286920161007a565b600080fd5b6040519190601f01601f191682016001600160401b038111838210176102125760405256fe608060408181526004918236101561001657600080fd5b600092833560e01c918263313ce5671461049b57508163715018a61461041a5781637284e4161461024b5781638da5cb5b1461021857816399213cd8146101f6578163e1e244d8146101d7578163f2fde38b146100b4575063feaf968c1461007d57600080fd5b346100b057816003193601126100b0578160a0926001549280519382855260208501528301524260608301526080820152f35b5080fd5b919050346101d35760206003193601126101d35781359173ffffffffffffffffffffffffffffffffffffffff918284168094036101cf576100f36104b6565b831561014c5750508254827fffffffffffffffffffffffff00000000000000000000000000000000000000008216178455167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e08380a380f35b90602060849251917f08c379a0000000000000000000000000000000000000000000000000000000008352820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f64647265737300000000000000000000000000000000000000000000000000006064820152fd5b8480fd5b8280fd5b5050346100b057816003193601126100b0576020906001549051908152f35b8390346100b05760206003193601126100b0576102116104b6565b3560015580f35b5050346100b057816003193601126100b05773ffffffffffffffffffffffffffffffffffffffff60209254169051908152f35b919050346101d357826003193601126101d35780518360025460019581871c878316978815610410575b6020938483108a146103e457848798999a84895291826000146103a9575050600114610355575b5050601f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe095869203011683019583871067ffffffffffffffff881117610329575085929391838652818452845191828186015281955b8387106103115750508394508582601f949501015201168101030190f35b868101820151898801890152958101958895506102f3565b8260416024927f4e487b7100000000000000000000000000000000000000000000000000000000835252fd5b600285528492507f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ace5b8284106103935750505083018101388061029c565b805488850186015287965092840192810161037e565b915093507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0091501682860152151560051b840101388061029c565b60248660228b7f4e487b7100000000000000000000000000000000000000000000000000000000835252fd5b90607f1690610275565b83346104985780600319360112610498576104336104b6565b8073ffffffffffffffffffffffffffffffffffffffff81547fffffffffffffffffffffffff000000000000000000000000000000000000000081168355167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e08280a380f35b80fd5b8490346100b057816003193601126100b05780600860209252f35b73ffffffffffffffffffffffffffffffffffffffff6000541633036104d757565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602060248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152fdfea164736f6c6343000812000a000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000065048505553440000000000000000000000000000000000000000000000000000
Deployed Bytecode
0x608060408181526004918236101561001657600080fd5b600092833560e01c918263313ce5671461049b57508163715018a61461041a5781637284e4161461024b5781638da5cb5b1461021857816399213cd8146101f6578163e1e244d8146101d7578163f2fde38b146100b4575063feaf968c1461007d57600080fd5b346100b057816003193601126100b0578160a0926001549280519382855260208501528301524260608301526080820152f35b5080fd5b919050346101d35760206003193601126101d35781359173ffffffffffffffffffffffffffffffffffffffff918284168094036101cf576100f36104b6565b831561014c5750508254827fffffffffffffffffffffffff00000000000000000000000000000000000000008216178455167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e08380a380f35b90602060849251917f08c379a0000000000000000000000000000000000000000000000000000000008352820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f64647265737300000000000000000000000000000000000000000000000000006064820152fd5b8480fd5b8280fd5b5050346100b057816003193601126100b0576020906001549051908152f35b8390346100b05760206003193601126100b0576102116104b6565b3560015580f35b5050346100b057816003193601126100b05773ffffffffffffffffffffffffffffffffffffffff60209254169051908152f35b919050346101d357826003193601126101d35780518360025460019581871c878316978815610410575b6020938483108a146103e457848798999a84895291826000146103a9575050600114610355575b5050601f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe095869203011683019583871067ffffffffffffffff881117610329575085929391838652818452845191828186015281955b8387106103115750508394508582601f949501015201168101030190f35b868101820151898801890152958101958895506102f3565b8260416024927f4e487b7100000000000000000000000000000000000000000000000000000000835252fd5b600285528492507f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ace5b8284106103935750505083018101388061029c565b805488850186015287965092840192810161037e565b915093507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0091501682860152151560051b840101388061029c565b60248660228b7f4e487b7100000000000000000000000000000000000000000000000000000000835252fd5b90607f1690610275565b83346104985780600319360112610498576104336104b6565b8073ffffffffffffffffffffffffffffffffffffffff81547fffffffffffffffffffffffff000000000000000000000000000000000000000081168355167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e08280a380f35b80fd5b8490346100b057816003193601126100b05780600860209252f35b73ffffffffffffffffffffffffffffffffffffffff6000541633036104d757565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602060248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152fdfea164736f6c6343000812000a
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000065048505553440000000000000000000000000000000000000000000000000000
-----Decoded View---------------
Arg [0] : _description (string): PHPUSD
-----Encoded View---------------
3 Constructor Arguments found :
Arg [0] : 0000000000000000000000000000000000000000000000000000000000000020
Arg [1] : 0000000000000000000000000000000000000000000000000000000000000006
Arg [2] : 5048505553440000000000000000000000000000000000000000000000000000
Loading...
Loading
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.