APE Price: $1.12 (-2.10%)

Contract

0x737C1E397FEEeF1CA7DfB960295D6C85E1b50f3d

Overview

APE Balance

Apechain LogoApechain LogoApechain Logo0 APE

APE Value

$0.00

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To
Update Aggregato...46100412024-11-18 21:00:1118 hrs ago1731963611IN
0x737C1E39...5E1b50f3d
0 APE0.0025086625.42069
0x6080604046100022024-11-18 20:59:4118 hrs ago1731963581IN
 Create: ChainlinkSourcesRegistry
0 APE0.009984225.42069

Parent Transaction Hash Block From To
View All Internal Transactions

Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
ChainlinkSourcesRegistry

Compiler Version
v0.6.12+commit.27d51765

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion
File 1 of 3 : ChainlinkSourcesRegistry.sol
// SPDX-License-Identifier: MIT
pragma solidity 0.6.12;

import {Ownable} from '../dependencies/openzeppelin/contracts/Ownable.sol';

contract ChainlinkSourcesRegistry is Ownable {
  /// @dev Mapping of current stored asset => underlying Chainlink aggregator
  mapping (address => address) public aggregatorsOfAssets;
  
  event AggregatorUpdated(address token, address aggregator);

    
  function updateAggregators(address[] memory assets, address[] memory aggregators) external onlyOwner {    
    for(uint256 i = 0; i < assets.length; i++) {
      aggregatorsOfAssets[assets[i]] = aggregators[i];
      emit AggregatorUpdated(assets[i], aggregators[i]);
    }
  }
}

File 2 of 3 : Context.sol
// SPDX-License-Identifier: MIT
pragma solidity 0.6.12;

/*
 * @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 GSN 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 payable) {
    return msg.sender;
  }

  function _msgData() internal view virtual returns (bytes memory) {
    this; // silence state mutability warning without generating bytecode - see https://github.com/ethereum/solidity/issues/2691
    return msg.data;
  }
}

File 3 of 3 : Ownable.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.6.0;

import './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.
 */
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() internal {
    address msgSender = _msgSender();
    _owner = msgSender;
    emit OwnershipTransferred(address(0), msgSender);
  }

  /**
   * @dev Returns the address of the current owner.
   */
  function owner() public view returns (address) {
    return _owner;
  }

  /**
   * @dev Throws if called by any account other than the owner.
   */
  modifier onlyOwner() {
    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 {
    emit OwnershipTransferred(_owner, address(0));
    _owner = 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');
    emit OwnershipTransferred(_owner, newOwner);
    _owner = newOwner;
  }
}

Settings
{
  "optimizer": {
    "enabled": true,
    "runs": 200
  },
  "outputSelection": {
    "*": {
      "*": [
        "evm.bytecode",
        "evm.deployedBytecode",
        "devdoc",
        "userdoc",
        "metadata",
        "abi"
      ]
    }
  },
  "libraries": {}
}

Contract Security Audit

Contract ABI

[{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"token","type":"address"},{"indexed":false,"internalType":"address","name":"aggregator","type":"address"}],"name":"AggregatorUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"aggregatorsOfAssets","outputs":[{"internalType":"address","name":"","type":"address"}],"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":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"assets","type":"address[]"},{"internalType":"address[]","name":"aggregators","type":"address[]"}],"name":"updateAggregators","outputs":[],"stateMutability":"nonpayable","type":"function"}]

608060405234801561001057600080fd5b50600061001b61006a565b600080546001600160a01b0319166001600160a01b0383169081178255604051929350917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908290a35061006e565b3390565b6105af8061007d6000396000f3fe608060405234801561001057600080fd5b50600436106100575760003560e01c8063246d7a651461005c578063403f136e1461009e578063715018a6146101c75780638da5cb5b146101cf578063f2fde38b146101d7575b600080fd5b6100826004803603602081101561007257600080fd5b50356001600160a01b03166101fd565b604080516001600160a01b039092168252519081900360200190f35b6101c5600480360360408110156100b457600080fd5b8101906020810181356401000000008111156100cf57600080fd5b8201836020820111156100e157600080fd5b8035906020019184602083028401116401000000008311171561010357600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929594936020810193503591505064010000000081111561015357600080fd5b82018360208201111561016557600080fd5b8035906020019184602083028401116401000000008311171561018757600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550610218945050505050565b005b6101c5610382565b610082610436565b6101c5600480360360208110156101ed57600080fd5b50356001600160a01b0316610445565b6001602052600090815260409020546001600160a01b031681565b61022061054f565b6000546001600160a01b03908116911614610282576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b60005b825181101561037d5781818151811061029a57fe5b6020026020010151600160008584815181106102b257fe5b60200260200101516001600160a01b03166001600160a01b0316815260200190815260200160002060006101000a8154816001600160a01b0302191690836001600160a01b031602179055507f89baabef7dfd0683c0ac16fd2a8431c51b49fbe654c3f7b5ef19763e2ccd88f283828151811061032b57fe5b602002602001015183838151811061033f57fe5b602002602001015160405180836001600160a01b03168152602001826001600160a01b031681526020019250505060405180910390a1600101610285565b505050565b61038a61054f565b6000546001600160a01b039081169116146103ec576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b600080546040516001600160a01b03909116907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600080546001600160a01b0319169055565b6000546001600160a01b031690565b61044d61054f565b6000546001600160a01b039081169116146104af576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b0381166104f45760405162461bcd60e51b81526004018080602001828103825260268152602001806105546026913960400191505060405180910390fd5b600080546040516001600160a01b03808516939216917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a3600080546001600160a01b0319166001600160a01b0392909216919091179055565b339056fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f2061646472657373a26469706673582212209004aec8a5fa07d71ffbc20251265cb13953a6826ae3c4a81da3a2ac9df52ae864736f6c634300060c0033

Deployed Bytecode

0x608060405234801561001057600080fd5b50600436106100575760003560e01c8063246d7a651461005c578063403f136e1461009e578063715018a6146101c75780638da5cb5b146101cf578063f2fde38b146101d7575b600080fd5b6100826004803603602081101561007257600080fd5b50356001600160a01b03166101fd565b604080516001600160a01b039092168252519081900360200190f35b6101c5600480360360408110156100b457600080fd5b8101906020810181356401000000008111156100cf57600080fd5b8201836020820111156100e157600080fd5b8035906020019184602083028401116401000000008311171561010357600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929594936020810193503591505064010000000081111561015357600080fd5b82018360208201111561016557600080fd5b8035906020019184602083028401116401000000008311171561018757600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550610218945050505050565b005b6101c5610382565b610082610436565b6101c5600480360360208110156101ed57600080fd5b50356001600160a01b0316610445565b6001602052600090815260409020546001600160a01b031681565b61022061054f565b6000546001600160a01b03908116911614610282576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b60005b825181101561037d5781818151811061029a57fe5b6020026020010151600160008584815181106102b257fe5b60200260200101516001600160a01b03166001600160a01b0316815260200190815260200160002060006101000a8154816001600160a01b0302191690836001600160a01b031602179055507f89baabef7dfd0683c0ac16fd2a8431c51b49fbe654c3f7b5ef19763e2ccd88f283828151811061032b57fe5b602002602001015183838151811061033f57fe5b602002602001015160405180836001600160a01b03168152602001826001600160a01b031681526020019250505060405180910390a1600101610285565b505050565b61038a61054f565b6000546001600160a01b039081169116146103ec576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b600080546040516001600160a01b03909116907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600080546001600160a01b0319169055565b6000546001600160a01b031690565b61044d61054f565b6000546001600160a01b039081169116146104af576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b0381166104f45760405162461bcd60e51b81526004018080602001828103825260268152602001806105546026913960400191505060405180910390fd5b600080546040516001600160a01b03808516939216917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a3600080546001600160a01b0319166001600160a01b0392909216919091179055565b339056fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f2061646472657373a26469706673582212209004aec8a5fa07d71ffbc20251265cb13953a6826ae3c4a81da3a2ac9df52ae864736f6c634300060c0033

Block Transaction Difficulty Gas Used Reward
View All Blocks Produced

Block Uncle Number Difficulty Gas Used Reward
View All Uncles
Loading...
Loading
Loading...
Loading

Validator Index Block Amount
View All Withdrawals

Transaction Hash Block Value Eth2 PubKey Valid
View All Deposits
[ 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.