Contract 0x6cb7d5bd21664e0201347bd93d66ce18bc48a807 1

 
Txn Hash Method
Block
From
To
Value [Txn Fee]
0x5207f95fded4498e88a9448a675d3cd020dbabaa4e789a3bdb6fad3ab331f7140x6080604048444282022-01-21 3:04:18608 days 4 hrs ago0xde485812e28824e542b9c2270b6b8ed9232b7d0b IN  Create: GohmPriceOracle0 ETH0.005628263054 ETH1.318829168
[ Download CSV Export 
Latest 25 internal transaction
Parent Txn Hash Block From To Value
0x1cac68331aeb12d55c0e2ec65129d9dcaf778ecfd047a18ac4b5d45313d0db97707359732023-03-17 11:53:46187 days 19 hrs ago Dopex: gOHM Price Oracle 0x761aaebf021f19f198d325d7979965d0c7c9e53b0 ETH
0x1cac68331aeb12d55c0e2ec65129d9dcaf778ecfd047a18ac4b5d45313d0db97707359732023-03-17 11:53:46187 days 19 hrs ago Dopex: gOHM Price Oracle 0x48c4721354a3b29d80ef03c65e6644a37338a0b10 ETH
0x1cac68331aeb12d55c0e2ec65129d9dcaf778ecfd047a18ac4b5d45313d0db97707359732023-03-17 11:53:46187 days 19 hrs ago 0x7d3bb7a1d5ec0378ca3a2beb4f2423ecf5f41570 Dopex: gOHM Price Oracle0 ETH
0x1cac68331aeb12d55c0e2ec65129d9dcaf778ecfd047a18ac4b5d45313d0db97707359732023-03-17 11:53:46187 days 19 hrs ago Dopex: gOHM Price Oracle 0x761aaebf021f19f198d325d7979965d0c7c9e53b0 ETH
0x1cac68331aeb12d55c0e2ec65129d9dcaf778ecfd047a18ac4b5d45313d0db97707359732023-03-17 11:53:46187 days 19 hrs ago Dopex: gOHM Price Oracle 0x48c4721354a3b29d80ef03c65e6644a37338a0b10 ETH
0x1cac68331aeb12d55c0e2ec65129d9dcaf778ecfd047a18ac4b5d45313d0db97707359732023-03-17 11:53:46187 days 19 hrs ago 0x7d3bb7a1d5ec0378ca3a2beb4f2423ecf5f41570 Dopex: gOHM Price Oracle0 ETH
0x94ea0ab14ed34141c1d8910856ad7e4f0c39fad6adf4ff4182044d8cf80627aa707328592023-03-17 11:40:55187 days 20 hrs ago Dopex: gOHM Price Oracle 0x761aaebf021f19f198d325d7979965d0c7c9e53b0 ETH
0x94ea0ab14ed34141c1d8910856ad7e4f0c39fad6adf4ff4182044d8cf80627aa707328592023-03-17 11:40:55187 days 20 hrs ago Dopex: gOHM Price Oracle 0x48c4721354a3b29d80ef03c65e6644a37338a0b10 ETH
0x94ea0ab14ed34141c1d8910856ad7e4f0c39fad6adf4ff4182044d8cf80627aa707328592023-03-17 11:40:55187 days 20 hrs ago 0x2ba83da46846ccf633db9d30209163c627aaf1a7 Dopex: gOHM Price Oracle0 ETH
0x94ea0ab14ed34141c1d8910856ad7e4f0c39fad6adf4ff4182044d8cf80627aa707328592023-03-17 11:40:55187 days 20 hrs ago Dopex: gOHM Price Oracle 0x761aaebf021f19f198d325d7979965d0c7c9e53b0 ETH
0x94ea0ab14ed34141c1d8910856ad7e4f0c39fad6adf4ff4182044d8cf80627aa707328592023-03-17 11:40:55187 days 20 hrs ago Dopex: gOHM Price Oracle 0x48c4721354a3b29d80ef03c65e6644a37338a0b10 ETH
0x94ea0ab14ed34141c1d8910856ad7e4f0c39fad6adf4ff4182044d8cf80627aa707328592023-03-17 11:40:55187 days 20 hrs ago 0x2ba83da46846ccf633db9d30209163c627aaf1a7 Dopex: gOHM Price Oracle0 ETH
0xb9188408ba4362b1115761ac52bd2b67474b9bbe32f40bf874ac77fff90c9462706794422023-03-17 8:00:29187 days 23 hrs ago Dopex: gOHM Price Oracle 0x761aaebf021f19f198d325d7979965d0c7c9e53b0 ETH
0xb9188408ba4362b1115761ac52bd2b67474b9bbe32f40bf874ac77fff90c9462706794422023-03-17 8:00:29187 days 23 hrs ago Dopex: gOHM Price Oracle 0x48c4721354a3b29d80ef03c65e6644a37338a0b10 ETH
0xb9188408ba4362b1115761ac52bd2b67474b9bbe32f40bf874ac77fff90c9462706794422023-03-17 8:00:29187 days 23 hrs ago 0x2ba83da46846ccf633db9d30209163c627aaf1a7 Dopex: gOHM Price Oracle0 ETH
0xb9188408ba4362b1115761ac52bd2b67474b9bbe32f40bf874ac77fff90c9462706794422023-03-17 8:00:29187 days 23 hrs ago Dopex: gOHM Price Oracle 0x761aaebf021f19f198d325d7979965d0c7c9e53b0 ETH
0xb9188408ba4362b1115761ac52bd2b67474b9bbe32f40bf874ac77fff90c9462706794422023-03-17 8:00:29187 days 23 hrs ago Dopex: gOHM Price Oracle 0x48c4721354a3b29d80ef03c65e6644a37338a0b10 ETH
0xb9188408ba4362b1115761ac52bd2b67474b9bbe32f40bf874ac77fff90c9462706794422023-03-17 8:00:29187 days 23 hrs ago 0x2ba83da46846ccf633db9d30209163c627aaf1a7 Dopex: gOHM Price Oracle0 ETH
0xb9188408ba4362b1115761ac52bd2b67474b9bbe32f40bf874ac77fff90c9462706794422023-03-17 8:00:29187 days 23 hrs ago Dopex: gOHM Price Oracle 0x761aaebf021f19f198d325d7979965d0c7c9e53b0 ETH
0xb9188408ba4362b1115761ac52bd2b67474b9bbe32f40bf874ac77fff90c9462706794422023-03-17 8:00:29187 days 23 hrs ago Dopex: gOHM Price Oracle 0x48c4721354a3b29d80ef03c65e6644a37338a0b10 ETH
0xb9188408ba4362b1115761ac52bd2b67474b9bbe32f40bf874ac77fff90c9462706794422023-03-17 8:00:29187 days 23 hrs ago 0x2ba83da46846ccf633db9d30209163c627aaf1a7 Dopex: gOHM Price Oracle0 ETH
0x759d53ac592236dc4b89266df48839367b0603f48705077c668ae7eda7efe530706794002023-03-17 8:00:18187 days 23 hrs ago Dopex: gOHM Price Oracle 0x761aaebf021f19f198d325d7979965d0c7c9e53b0 ETH
0x759d53ac592236dc4b89266df48839367b0603f48705077c668ae7eda7efe530706794002023-03-17 8:00:18187 days 23 hrs ago Dopex: gOHM Price Oracle 0x48c4721354a3b29d80ef03c65e6644a37338a0b10 ETH
0x759d53ac592236dc4b89266df48839367b0603f48705077c668ae7eda7efe530706794002023-03-17 8:00:18187 days 23 hrs ago 0x7d3bb7a1d5ec0378ca3a2beb4f2423ecf5f41570 Dopex: gOHM Price Oracle0 ETH
0x4bf978439b21012bda362b81a24c9056be01e8e2e1de458a3bb3795ce71853d0691365502023-03-12 12:38:22192 days 19 hrs ago Dopex: gOHM Price Oracle 0x761aaebf021f19f198d325d7979965d0c7c9e53b0 ETH
[ Download CSV Export 
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
GohmPriceOracle

Compiler Version
v0.8.9+commit.e5eed63a

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion, Unlicense license
File 1 of 2 : IChainlinkV3Aggregator.sol
// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.8.0;

interface IChainlinkV3Aggregator {
  function decimals() external view returns (uint8);

  function latestRoundData()
    external
    view
    returns (
      uint80 roundId,
      int256 answer,
      uint256 startedAt,
      uint256 updatedAt,
      uint80 answeredInRound
    );
}

File 2 of 2 : GohmPriceOracle.sol
// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.8.0;

// Interfaces
import {IChainlinkV3Aggregator} from '../external/interfaces/IChainlinkV3Aggregator.sol';

contract GohmPriceOracle {
    /*==== PUBLIC VARS ====*/

    address public constant OHMv2_CHAINLINK_AGGREGATOR =
        0x761aaeBf021F19F198D325D7979965D0c7C9e53b;

    address public constant OHM_INDEX_CHAINLINK_AGGREGATOR =
        0x48C4721354A3B29D80EF03C65E6644A37338a0B1;

    /*==== VIEWS ====*/

    /// @notice Gets the price of gOHM in USD
    /// @return price of gOHM in USD in 1e8 precision
    function getPriceInUSD() external view returns (uint256) {
        return (getOHMv2PriceInUSD() * getOHMIndex()) / 1e9;
    }

    /// @notice Gets the price of OHM (v2) in USD
    /// @return the price of OHM (v2) in USD in 1e8 precision
    function getOHMv2PriceInUSD() public view returns (uint256) {
        (, int256 price, , , ) = IChainlinkV3Aggregator(
            OHMv2_CHAINLINK_AGGREGATOR
        ).latestRoundData();

        return uint256(price);
    }

    /// @notice Gets the current index of OHM
    /// @return the current index of OHM in 1e9 precision
    function getOHMIndex() public view returns (uint256) {
        (, int256 index, , , ) = IChainlinkV3Aggregator(
            OHM_INDEX_CHAINLINK_AGGREGATOR
        ).latestRoundData();

        return uint256(index);
    }
}

Settings
{
  "evmVersion": "london",
  "libraries": {},
  "metadata": {
    "bytecodeHash": "ipfs",
    "useLiteralContent": true
  },
  "optimizer": {
    "enabled": true,
    "runs": 200
  },
  "remappings": [],
  "outputSelection": {
    "*": {
      "*": [
        "evm.bytecode",
        "evm.deployedBytecode",
        "abi"
      ]
    }
  }
}

Contract ABI

[{"inputs":[],"name":"OHM_INDEX_CHAINLINK_AGGREGATOR","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"OHMv2_CHAINLINK_AGGREGATOR","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getOHMIndex","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getOHMv2PriceInUSD","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getPriceInUSD","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"}]

608060405234801561001057600080fd5b506102dc806100206000396000f3fe608060405234801561001057600080fd5b50600436106100575760003560e01c80630bb32b021461005c5780635b3eb0d9146100775780639baa6040146100aa578063d6d7551d146100c5578063e1aa6036146100cd575b600080fd5b6100646100d5565b6040519081526020015b60405180910390f35b6100927348c4721354a3b29d80ef03c65e6644a37338a0b181565b6040516001600160a01b03909116815260200161006e565b61009273761aaebf021f19f198d325d7979965d0c7c9e53b81565b610064610168565b6100646101b8565b60008073761aaebf021f19f198d325d7979965d0c7c9e53b6001600160a01b031663feaf968c6040518163ffffffff1660e01b815260040160a06040518083038186803b15801561012557600080fd5b505afa158015610139573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061015d9190610207565b509195945050505050565b6000807348c4721354a3b29d80ef03c65e6644a37338a0b16001600160a01b031663feaf968c6040518163ffffffff1660e01b815260040160a06040518083038186803b15801561012557600080fd5b6000633b9aca006101c7610168565b6101cf6100d5565b6101d99190610257565b6101e39190610284565b905090565b805169ffffffffffffffffffff8116811461020257600080fd5b919050565b600080600080600060a0868803121561021f57600080fd5b610228866101e8565b945060208601519350604086015192506060860151915061024b608087016101e8565b90509295509295909350565b600081600019048311821515161561027f57634e487b7160e01b600052601160045260246000fd5b500290565b6000826102a157634e487b7160e01b600052601260045260246000fd5b50049056fea264697066735822122068a56b5bb018a31e9ca00934ffd480ffb502491c94d2e94e519ae5712ff1ed2a64736f6c63430008090033

Block Transaction Gas Used Reward
Age Block Fee Address BC Fee Address Voting Power Jailed Incoming
Block Uncle Number Difficulty Gas Used Reward
Loading
Make sure to use the "Vote Down" button for any spammy posts, and the "Vote Up" for interesting conversations.