{
  "contractName": "WitnetRequestTemplateConsumer",
  "abi": [
    {
      "anonymous": false,
      "inputs": [
        {
          "indexed": false,
          "internalType": "uint256",
          "name": "id",
          "type": "uint256"
        },
        {
          "indexed": false,
          "internalType": "uint256",
          "name": "evmReward",
          "type": "uint256"
        },
        {
          "components": [
            {
              "internalType": "uint8",
              "name": "committeeSize",
              "type": "uint8"
            },
            {
              "internalType": "uint64",
              "name": "witnessingFeeNanoWit",
              "type": "uint64"
            }
          ],
          "indexed": false,
          "internalType": "struct WitnetV2.RadonSLA",
          "name": "witnetSLA",
          "type": "tuple"
        }
      ],
      "name": "WitnetQuery",
      "type": "event"
    },
    {
      "anonymous": false,
      "inputs": [
        {
          "indexed": false,
          "internalType": "uint256",
          "name": "id",
          "type": "uint256"
        },
        {
          "indexed": false,
          "internalType": "uint256",
          "name": "evmGasPrice",
          "type": "uint256"
        }
      ],
      "name": "WitnetQueryResponse",
      "type": "event"
    },
    {
      "anonymous": false,
      "inputs": [
        {
          "indexed": false,
          "internalType": "uint256",
          "name": "id",
          "type": "uint256"
        },
        {
          "indexed": false,
          "internalType": "uint256",
          "name": "evmGasPrice",
          "type": "uint256"
        },
        {
          "indexed": false,
          "internalType": "uint256",
          "name": "evmCallbackGas",
          "type": "uint256"
        }
      ],
      "name": "WitnetQueryResponseDelivered",
      "type": "event"
    },
    {
      "anonymous": false,
      "inputs": [
        {
          "indexed": false,
          "internalType": "uint256",
          "name": "id",
          "type": "uint256"
        },
        {
          "indexed": false,
          "internalType": "bytes",
          "name": "resultCborBytes",
          "type": "bytes"
        },
        {
          "indexed": false,
          "internalType": "uint256",
          "name": "evmGasPrice",
          "type": "uint256"
        },
        {
          "indexed": false,
          "internalType": "uint256",
          "name": "evmCallbackActualGas",
          "type": "uint256"
        },
        {
          "indexed": false,
          "internalType": "string",
          "name": "evmCallbackRevertReason",
          "type": "string"
        }
      ],
      "name": "WitnetQueryResponseDeliveryFailed",
      "type": "event"
    },
    {
      "anonymous": false,
      "inputs": [
        {
          "indexed": false,
          "internalType": "uint256",
          "name": "id",
          "type": "uint256"
        },
        {
          "indexed": false,
          "internalType": "uint256",
          "name": "evmReward",
          "type": "uint256"
        }
      ],
      "name": "WitnetQueryRewardUpgraded",
      "type": "event"
    },
    {
      "inputs": [],
      "name": "dataRequestTemplate",
      "outputs": [
        {
          "internalType": "contract WitnetRequestTemplate",
          "name": "",
          "type": "address"
        }
      ],
      "stateMutability": "view",
      "type": "function"
    },
    {
      "inputs": [
        {
          "internalType": "uint256",
          "name": "witnetQueryId",
          "type": "uint256"
        },
        {
          "internalType": "uint64",
          "name": "witnetResultTimestamp",
          "type": "uint64"
        },
        {
          "internalType": "bytes32",
          "name": "witnetResultTallyHash",
          "type": "bytes32"
        },
        {
          "internalType": "uint256",
          "name": "witnetEvmFinalityBlock",
          "type": "uint256"
        },
        {
          "internalType": "enum Witnet.ResultErrorCodes",
          "name": "errorCode",
          "type": "uint8"
        },
        {
          "components": [
            {
              "components": [
                {
                  "internalType": "bytes",
                  "name": "data",
                  "type": "bytes"
                },
                {
                  "internalType": "uint256",
                  "name": "cursor",
                  "type": "uint256"
                }
              ],
              "internalType": "struct WitnetBuffer.Buffer",
              "name": "buffer",
              "type": "tuple"
            },
            {
              "internalType": "uint8",
              "name": "initialByte",
              "type": "uint8"
            },
            {
              "internalType": "uint8",
              "name": "majorType",
              "type": "uint8"
            },
            {
              "internalType": "uint8",
              "name": "additionalInformation",
              "type": "uint8"
            },
            {
              "internalType": "uint64",
              "name": "len",
              "type": "uint64"
            },
            {
              "internalType": "uint64",
              "name": "tag",
              "type": "uint64"
            }
          ],
          "internalType": "struct WitnetCBOR.CBOR",
          "name": "errorArgs",
          "type": "tuple"
        }
      ],
      "name": "reportWitnetQueryError",
      "outputs": [],
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "inputs": [
        {
          "internalType": "uint256",
          "name": "witnetQueryId",
          "type": "uint256"
        },
        {
          "internalType": "uint64",
          "name": "witnetResultTimestamp",
          "type": "uint64"
        },
        {
          "internalType": "bytes32",
          "name": "witnetResultTallyHash",
          "type": "bytes32"
        },
        {
          "internalType": "uint256",
          "name": "witnetEvmFinalityBlock",
          "type": "uint256"
        },
        {
          "components": [
            {
              "components": [
                {
                  "internalType": "bytes",
                  "name": "data",
                  "type": "bytes"
                },
                {
                  "internalType": "uint256",
                  "name": "cursor",
                  "type": "uint256"
                }
              ],
              "internalType": "struct WitnetBuffer.Buffer",
              "name": "buffer",
              "type": "tuple"
            },
            {
              "internalType": "uint8",
              "name": "initialByte",
              "type": "uint8"
            },
            {
              "internalType": "uint8",
              "name": "majorType",
              "type": "uint8"
            },
            {
              "internalType": "uint8",
              "name": "additionalInformation",
              "type": "uint8"
            },
            {
              "internalType": "uint64",
              "name": "len",
              "type": "uint64"
            },
            {
              "internalType": "uint64",
              "name": "tag",
              "type": "uint64"
            }
          ],
          "internalType": "struct WitnetCBOR.CBOR",
          "name": "witnetResultCborValue",
          "type": "tuple"
        }
      ],
      "name": "reportWitnetQueryResult",
      "outputs": [],
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "inputs": [
        {
          "internalType": "address",
          "name": "_from",
          "type": "address"
        }
      ],
      "name": "reportableFrom",
      "outputs": [
        {
          "internalType": "bool",
          "name": "",
          "type": "bool"
        }
      ],
      "stateMutability": "view",
      "type": "function"
    },
    {
      "inputs": [],
      "name": "witnet",
      "outputs": [
        {
          "internalType": "contract WitnetOracle",
          "name": "",
          "type": "address"
        }
      ],
      "stateMutability": "view",
      "type": "function"
    }
  ],
  "metadata": "{\"compiler\":{\"version\":\"0.8.25+commit.b61c2a91\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"evmReward\",\"type\":\"uint256\"},{\"components\":[{\"internalType\":\"uint8\",\"name\":\"committeeSize\",\"type\":\"uint8\"},{\"internalType\":\"uint64\",\"name\":\"witnessingFeeNanoWit\",\"type\":\"uint64\"}],\"indexed\":false,\"internalType\":\"struct WitnetV2.RadonSLA\",\"name\":\"witnetSLA\",\"type\":\"tuple\"}],\"name\":\"WitnetQuery\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"evmGasPrice\",\"type\":\"uint256\"}],\"name\":\"WitnetQueryResponse\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"evmGasPrice\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"evmCallbackGas\",\"type\":\"uint256\"}],\"name\":\"WitnetQueryResponseDelivered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"resultCborBytes\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"evmGasPrice\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"evmCallbackActualGas\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"string\",\"name\":\"evmCallbackRevertReason\",\"type\":\"string\"}],\"name\":\"WitnetQueryResponseDeliveryFailed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"evmReward\",\"type\":\"uint256\"}],\"name\":\"WitnetQueryRewardUpgraded\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"dataRequestTemplate\",\"outputs\":[{\"internalType\":\"contract WitnetRequestTemplate\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"witnetQueryId\",\"type\":\"uint256\"},{\"internalType\":\"uint64\",\"name\":\"witnetResultTimestamp\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"witnetResultTallyHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"witnetEvmFinalityBlock\",\"type\":\"uint256\"},{\"internalType\":\"enum Witnet.ResultErrorCodes\",\"name\":\"errorCode\",\"type\":\"uint8\"},{\"components\":[{\"components\":[{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"cursor\",\"type\":\"uint256\"}],\"internalType\":\"struct WitnetBuffer.Buffer\",\"name\":\"buffer\",\"type\":\"tuple\"},{\"internalType\":\"uint8\",\"name\":\"initialByte\",\"type\":\"uint8\"},{\"internalType\":\"uint8\",\"name\":\"majorType\",\"type\":\"uint8\"},{\"internalType\":\"uint8\",\"name\":\"additionalInformation\",\"type\":\"uint8\"},{\"internalType\":\"uint64\",\"name\":\"len\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"tag\",\"type\":\"uint64\"}],\"internalType\":\"struct WitnetCBOR.CBOR\",\"name\":\"errorArgs\",\"type\":\"tuple\"}],\"name\":\"reportWitnetQueryError\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"witnetQueryId\",\"type\":\"uint256\"},{\"internalType\":\"uint64\",\"name\":\"witnetResultTimestamp\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"witnetResultTallyHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"witnetEvmFinalityBlock\",\"type\":\"uint256\"},{\"components\":[{\"components\":[{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"cursor\",\"type\":\"uint256\"}],\"internalType\":\"struct WitnetBuffer.Buffer\",\"name\":\"buffer\",\"type\":\"tuple\"},{\"internalType\":\"uint8\",\"name\":\"initialByte\",\"type\":\"uint8\"},{\"internalType\":\"uint8\",\"name\":\"majorType\",\"type\":\"uint8\"},{\"internalType\":\"uint8\",\"name\":\"additionalInformation\",\"type\":\"uint8\"},{\"internalType\":\"uint64\",\"name\":\"len\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"tag\",\"type\":\"uint64\"}],\"internalType\":\"struct WitnetCBOR.CBOR\",\"name\":\"witnetResultCborValue\",\"type\":\"tuple\"}],\"name\":\"reportWitnetQueryResult\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_from\",\"type\":\"address\"}],\"name\":\"reportableFrom\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"witnet\",\"outputs\":[{\"internalType\":\"contract WitnetOracle\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"}],\"devdoc\":{\"kind\":\"dev\",\"methods\":{\"constructor\":{\"params\":{\"_baseFeeOverheadPercentage\":\"Percentage over base fee to pay as on every data request.\",\"_callbackGasLimit\":\"Maximum gas to be spent by the IWitnetConsumer's callback methods.\",\"_witnetRequestTemplate\":\"Address of the WitnetRequestTemplate from which actual data requests will get built.\"}},\"reportWitnetQueryError(uint256,uint64,bytes32,uint256,uint8,((bytes,uint256),uint8,uint8,uint8,uint64,uint64))\":{\"details\":\"It should revert if called from any other address different to the WitnetOracle being usedby the WitnetConsumer contract. \",\"params\":{\"errorArgs\":\"Error arguments, if any. An empty buffer is to be passed if no error arguments apply.\",\"errorCode\":\"The error code enum identifying the error produced during resolution on the Witnet blockchain.\",\"witnetEvmFinalityBlock\":\"EVM block at which the provided data can be considered to be final.\",\"witnetQueryId\":\"The unique identifier of the Witnet query being reported.\",\"witnetResultTallyHash\":\"Hash of the commit/reveal witnessing act that took place in the Witnet blockahin.\",\"witnetResultTimestamp\":\"Timestamp at which the reported value was captured by the Witnet blockchain. \"}},\"reportWitnetQueryResult(uint256,uint64,bytes32,uint256,((bytes,uint256),uint8,uint8,uint8,uint64,uint64))\":{\"details\":\"It should revert if called from any other address different to the WitnetOracle being usedby the WitnetConsumer contract. \",\"params\":{\"witnetEvmFinalityBlock\":\"EVM block at which the provided data can be considered to be final.\",\"witnetQueryId\":\"The unique identifier of the Witnet query being reported.\",\"witnetResultCborValue\":\"The CBOR-encoded resulting value of the Witnet query being reported.\",\"witnetResultTallyHash\":\"Hash of the commit/reveal witnessing act that took place in the Witnet blockahin.\",\"witnetResultTimestamp\":\"Timestamp at which the reported value was captured by the Witnet blockchain. \"}}},\"version\":1},\"userdoc\":{\"events\":{\"WitnetQuery(uint256,uint256,(uint8,uint64))\":{\"notice\":\"Emitted every time a new query containing some verified data request is posted to the WRB.\"},\"WitnetQueryResponse(uint256,uint256)\":{\"notice\":\"Emitted when a query with no callback gets reported into the WRB.\"},\"WitnetQueryResponseDelivered(uint256,uint256,uint256)\":{\"notice\":\"Emitted when a query with a callback gets successfully reported into the WRB.\"},\"WitnetQueryResponseDeliveryFailed(uint256,bytes,uint256,uint256,string)\":{\"notice\":\"Emitted when a query with a callback cannot get reported into the WRB.\"},\"WitnetQueryRewardUpgraded(uint256,uint256)\":{\"notice\":\"Emitted when the reward of some not-yet reported query is upgraded.\"}},\"kind\":\"user\",\"methods\":{\"reportWitnetQueryError(uint256,uint64,bytes32,uint256,uint8,((bytes,uint256),uint8,uint8,uint8,uint64,uint64))\":{\"notice\":\"Method to be called from the WitnetOracle contract as soon as the given Witnet `queryId`gets reported, if reported WITH errors.\"},\"reportWitnetQueryResult(uint256,uint64,bytes32,uint256,((bytes,uint256),uint8,uint8,uint8,uint64,uint64))\":{\"notice\":\"Method to be called from the WitnetOracle contract as soon as the given Witnet `queryId`gets reported, if reported with no errors.\"},\"reportableFrom(address)\":{\"notice\":\"=============================================================================================================== --- Base implementation of IWitnetConsumer --------------------------------------------------------------------\"}},\"version\":1}},\"settings\":{\"compilationTarget\":{\"project:/contracts/apps/WitnetRequestTemplateConsumer.sol\":\"WitnetRequestTemplateConsumer\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":true,\"runs\":200},\"remappings\":[]},\"sources\":{\"project:/contracts/WitnetOracle.sol\":{\"keccak256\":\"0x84ef8d2ebcba273e4bc23a5ee414a1213df55d1b4e496197a146031fea3a4874\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://c4a6e31964ed08c4c9dfe5279b4ffe9eeba6e759f15901e080e174e98e96a7f5\",\"dweb:/ipfs/QmTghzVFf2EHnfnHejgFGRBjanXYcstK9ftVaYmHWJfk8w\"]},\"project:/contracts/WitnetRequest.sol\":{\"keccak256\":\"0x5b5e8e9744de10fe86adf97826e3db5c5bcbf357d179a532ef4d7073c7c3af88\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://25bed2c86e46beb6f59024b731b9f3d1ab176312a28b090ad149ddea48841c32\",\"dweb:/ipfs/QmT3aAXfKQ2MTHo4dK1pCyhdvaLYf5TJtgcim5DfbWHjp4\"]},\"project:/contracts/WitnetRequestBytecodes.sol\":{\"keccak256\":\"0x2a79d919dd79c0e3f857e6bee08368ad0b463188aced4a52de29270ed0f5f3d2\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://290d6013ee9f75fedbbb7726527a637ea2ae7a5da0ad118ecc43b298846f0bb0\",\"dweb:/ipfs/QmU8AZtPyctrrvxdmH297p595ZMS6DgcD6djSFKNxAqYMs\"]},\"project:/contracts/WitnetRequestFactory.sol\":{\"keccak256\":\"0x3c66f27d7c1db0e662c37d98005c4cbd871ceb75e97079d7bf673fb75d59c858\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://52adb318b870d0825718125e94fdbdd0e968ced09926420e2543b0ca4c6eb579\",\"dweb:/ipfs/QmYack87Q2UTfQb8KLLEPFBrMJgN2o6PaPqPNSc95McPVH\"]},\"project:/contracts/WitnetRequestTemplate.sol\":{\"keccak256\":\"0x10084f4f493f87d0acd9937fa786bf9e92512bf3670ee0427445d43c2cae973e\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://2491b8a6ec8f01a53f35f6aa602df8630955000f3dc67e7dc8b61b0b25a71657\",\"dweb:/ipfs/QmXEuPy6pVnSQpbg8G1DuVMKQyVfbTdtsDUrPYCbZNHARD\"]},\"project:/contracts/apps/UsingWitnet.sol\":{\"keccak256\":\"0x3fe6f2f1162bd1c128fb6aad2db81eaa1fdf04b5d15a5eeadf3e44bc81e2d4ef\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://927de4c99298ede8a240305bfd8e9daa5c79a32ed68cef19ece9b7f5bb37860b\",\"dweb:/ipfs/QmeZEbXpCTHegD6H7cVDipyXLYHUE4e3C66XojzYk8CpE4\"]},\"project:/contracts/apps/UsingWitnetRequestTemplate.sol\":{\"keccak256\":\"0xcd05eef301092e6b16f9d60fb99a205d09a897c728f223b11393ab78e2089e73\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://2971b6571e08e6f5c17736a189299d570beb2aaece4742775f4ba3ecb5885ba7\",\"dweb:/ipfs/QmdGovKLyzg2PTFCVAXYBJVbkfD1Vr9nTB8BNYp7GgewAU\"]},\"project:/contracts/apps/WitnetConsumer.sol\":{\"keccak256\":\"0xf1bb9a975c8bae03b99feb014e0dfb95640a20cc4a5e5a3037374db687a1e339\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://6d6f1708356b2093c6b649f80e47c7a8ddaa07e66c31d32b4f439a8a6d07b209\",\"dweb:/ipfs/Qmd7fFXCaheGUqPfdZ6xv8dAVwUH7DzweE8squCRJ2NrAh\"]},\"project:/contracts/apps/WitnetRequestTemplateConsumer.sol\":{\"keccak256\":\"0x1739b4f1bef98328e4a9c8b4d4915a00d9024d5f79b23cff78b236fff9861181\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://24f592c70fb9a369522dcf912d0e203cc14265276291cdc29f77ab1d968dadf0\",\"dweb:/ipfs/QmTEd2vC8qiFC8gyMXsJZqoT97cmCDcA6hR1dhw6WJBs2o\"]},\"project:/contracts/interfaces/IWitnetConsumer.sol\":{\"keccak256\":\"0xf90fbcf0a59428c0ac13a3903214656060a95175adfdef8c11a7e16675b849e0\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://c2606640d3f343051ea18dfb8e136dfdb73ceecd8016c82ddb73d67ad39a30e0\",\"dweb:/ipfs/QmTADVW4M8pge6pGfenFAauEDk4yZEy78o5ksZiKGwP3DT\"]},\"project:/contracts/interfaces/IWitnetOracle.sol\":{\"keccak256\":\"0x5dbb04fce5e05675325232a735c46617378982b48dac2138aca0c6cc95e6e4d5\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://7447a70455478239500e16aebe5dce6676dc86307d22f662761d8e9f7c5d1276\",\"dweb:/ipfs/QmVkvA4Mt6G1JXxE8ebxKGAjT1WvNbp5QMKg9sUKdrJjhv\"]},\"project:/contracts/interfaces/IWitnetOracleEvents.sol\":{\"keccak256\":\"0x0442f474f253dc1f6bd6a4f153c3adb2abe5f6f0f24c76d1baf666185e61e659\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://535e8efcfc5693669d9bd2b6f62e6fc65aca19b7de355a27152e4362b410540d\",\"dweb:/ipfs/QmVZRXgku1cZewhoucebaiBKAyUjF2dmEzYrzGvjPzbwN9\"]},\"project:/contracts/interfaces/IWitnetRequestBytecodes.sol\":{\"keccak256\":\"0x8da168bee9a78442216965976b1f29087f760f37dcb09337283242599ed1cbca\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://e120623262ee0559913bdae56c0a7921147dfe08ada7ea81061b14e2fc38c5e1\",\"dweb:/ipfs/Qmbxe8XRrH6ZjJHiR6YYzcZV1jnSWwo9iBYz5r6GJ6To5G\"]},\"project:/contracts/interfaces/IWitnetRequestFactory.sol\":{\"keccak256\":\"0x3b19ec4a976745ba2646e7e1886d647ef30ad678460a712c93bbfb4405b57f1f\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://fa759ae15b7d4da622a81d50933474910959ac490d8b63ea2e7ed8608859a9c9\",\"dweb:/ipfs/QmRckCu7eBBP5fn9ff6djs7VbdhFc7sxYb2yqDr4go66jV\"]},\"project:/contracts/libs/Witnet.sol\":{\"keccak256\":\"0x65a87375dd79d63a83fb454b7199b6c999bd59c50b3b59d521c5c4d45a7d3cc3\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://ca865b681d810c2fc5c3672ea6343c3bdf6fd71764ab824d25994744dc85866b\",\"dweb:/ipfs/QmPGcP3xGTNZfsQ9GSKdujNLRVs8dWDdubyUko1rbQqJNv\"]},\"project:/contracts/libs/WitnetBuffer.sol\":{\"keccak256\":\"0xa14570492eb5a313ddbacae0185c850ec99c67211eb33989a5e21d31bf06a150\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://e83c11edb49cab6a767c0b685825bc22ece0d3d2897e0d54fe1923df5cc76ba5\",\"dweb:/ipfs/QmdLDgCc3tnKbgRrXwfNzsg6uUDirNmjvBB8V3iMmnD69a\"]},\"project:/contracts/libs/WitnetCBOR.sol\":{\"keccak256\":\"0xb346547ff731163beea2c657c52675cdf7936691d566a76a045577cf9c34ade0\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://6d4b5b6424a033584b41f1204d635db98fda9ca9bd2a614c9d82539a3e4e6529\",\"dweb:/ipfs/QmW6Qy3wWpzHSECYaCPaf9LWGfPqWDKVoP2kPSNNQu7LMQ\"]},\"project:/contracts/libs/WitnetV2.sol\":{\"keccak256\":\"0xb276a6da373bfbe9cd942dd7e59979cda898215d1e36ab3df95a6d6cc6ff770f\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://bc4890876b9bc64f501ccdd48408bb63724865cb2ce8d2057f6b318540adce7c\",\"dweb:/ipfs/QmPMHPdbCsKBavhiLcaDgQ9EjNSvwwzv8TKffotcCv1ctP\"]}},\"version\":1}",
  "bytecode": "0x",
  "deployedBytecode": "0x",
  "immutableReferences": {},
  "generatedSources": [],
  "deployedGeneratedSources": [],
  "sourceMap": "",
  "deployedSourceMap": "",
  "source": "// SPDX-License-Identifier: MIT\r\npragma solidity ^0.8.0;\r\n\r\nimport \"./UsingWitnetRequestTemplate.sol\";\r\nimport \"./WitnetConsumer.sol\";\r\n\r\nabstract contract WitnetRequestTemplateConsumer\r\n    is\r\n        UsingWitnetRequestTemplate,\r\n        WitnetConsumer\r\n{\r\n    using WitnetCBOR for WitnetCBOR.CBOR;\r\n    using WitnetCBOR for WitnetCBOR.CBOR[];\r\n    \r\n    /// @param _witnetRequestTemplate Address of the WitnetRequestTemplate from which actual data requests will get built.\r\n    /// @param _baseFeeOverheadPercentage Percentage over base fee to pay as on every data request.\r\n    /// @param _callbackGasLimit Maximum gas to be spent by the IWitnetConsumer's callback methods.\r\n    constructor(\r\n            WitnetRequestTemplate _witnetRequestTemplate, \r\n            uint16 _baseFeeOverheadPercentage,\r\n            uint24 _callbackGasLimit\r\n        )\r\n        UsingWitnetRequestTemplate(_witnetRequestTemplate, _baseFeeOverheadPercentage)\r\n        WitnetConsumer(_callbackGasLimit)\r\n    {}\r\n\r\n    function _witnetEstimateEvmReward()\r\n        virtual override(UsingWitnetRequestTemplate, WitnetConsumer)\r\n        internal view\r\n        returns (uint256)\r\n    {\r\n        return WitnetConsumer._witnetEstimateEvmReward(__witnetQueryResultMaxSize);\r\n    }\r\n\r\n    function _witnetEstimateEvmReward(uint16) \r\n        virtual override(UsingWitnet, WitnetConsumer) \r\n        internal view\r\n        returns (uint256)\r\n    {\r\n        return WitnetConsumer._witnetEstimateEvmReward();\r\n    } \r\n\r\n    function __witnetRequestData(\r\n            uint256 _witnetEvmReward,\r\n            string[][] memory _witnetRequestArgs,\r\n            WitnetV2.RadonSLA memory _witnetQuerySLA\r\n        )\r\n        virtual override\r\n        internal returns (uint256)\r\n    {\r\n        return __witnet.postRequestWithCallback{\r\n            value: _witnetEvmReward\r\n        }(\r\n            _witnetBuildRadHash(_witnetRequestArgs),\r\n            _witnetQuerySLA,\r\n            __witnetCallbackGasLimit\r\n        );\r\n    }\r\n\r\n}\r\n",
  "sourcePath": "C:\\Users\\guill\\github\\witnet\\witnet-solidity-bridge\\contracts\\apps\\WitnetRequestTemplateConsumer.sol",
  "ast": {
    "absolutePath": "project:/contracts/apps/WitnetRequestTemplateConsumer.sol",
    "exportedSymbols": {
      "IWitnetConsumer": [
        12829
      ],
      "IWitnetOracle": [
        13265
      ],
      "IWitnetOracleEvents": [
        13315
      ],
      "IWitnetRequestBytecodes": [
        13979
      ],
      "IWitnetRequestFactory": [
        14002
      ],
      "UsingWitnet": [
        1157
      ],
      "UsingWitnetRequestTemplate": [
        1453
      ],
      "Witnet": [
        17557
      ],
      "WitnetBuffer": [
        19191
      ],
      "WitnetCBOR": [
        20734
      ],
      "WitnetConsumer": [
        1566
      ],
      "WitnetOracle": [
        749
      ],
      "WitnetRequest": [
        826
      ],
      "WitnetRequestBytecodes": [
        849
      ],
      "WitnetRequestFactory": [
        880
      ],
      "WitnetRequestTemplate": [
        1005
      ],
      "WitnetRequestTemplateConsumer": [
        3316
      ],
      "WitnetV2": [
        23640
      ]
    },
    "id": 3317,
    "license": "MIT",
    "nodeType": "SourceUnit",
    "nodes": [
      {
        "id": 3225,
        "literals": [
          "solidity",
          "^",
          "0.8",
          ".0"
        ],
        "nodeType": "PragmaDirective",
        "src": "33:23:25"
      },
      {
        "absolutePath": "project:/contracts/apps/UsingWitnetRequestTemplate.sol",
        "file": "./UsingWitnetRequestTemplate.sol",
        "id": 3226,
        "nameLocation": "-1:-1:-1",
        "nodeType": "ImportDirective",
        "scope": 3317,
        "sourceUnit": 1454,
        "src": "60:42:25",
        "symbolAliases": [],
        "unitAlias": ""
      },
      {
        "absolutePath": "project:/contracts/apps/WitnetConsumer.sol",
        "file": "./WitnetConsumer.sol",
        "id": 3227,
        "nameLocation": "-1:-1:-1",
        "nodeType": "ImportDirective",
        "scope": 3317,
        "sourceUnit": 1567,
        "src": "104:30:25",
        "symbolAliases": [],
        "unitAlias": ""
      },
      {
        "abstract": true,
        "baseContracts": [
          {
            "baseName": {
              "id": 3228,
              "name": "UsingWitnetRequestTemplate",
              "nameLocations": [
                "203:26:25"
              ],
              "nodeType": "IdentifierPath",
              "referencedDeclaration": 1453,
              "src": "203:26:25"
            },
            "id": 3229,
            "nodeType": "InheritanceSpecifier",
            "src": "203:26:25"
          },
          {
            "baseName": {
              "id": 3230,
              "name": "WitnetConsumer",
              "nameLocations": [
                "240:14:25"
              ],
              "nodeType": "IdentifierPath",
              "referencedDeclaration": 1566,
              "src": "240:14:25"
            },
            "id": 3231,
            "nodeType": "InheritanceSpecifier",
            "src": "240:14:25"
          }
        ],
        "canonicalName": "WitnetRequestTemplateConsumer",
        "contractDependencies": [],
        "contractKind": "contract",
        "fullyImplemented": false,
        "id": 3316,
        "linearizedBaseContracts": [
          3316,
          1566,
          1453,
          1157,
          13315,
          12829
        ],
        "name": "WitnetRequestTemplateConsumer",
        "nameLocation": "156:29:25",
        "nodeType": "ContractDefinition",
        "nodes": [
          {
            "global": false,
            "id": 3235,
            "libraryName": {
              "id": 3232,
              "name": "WitnetCBOR",
              "nameLocations": [
                "269:10:25"
              ],
              "nodeType": "IdentifierPath",
              "referencedDeclaration": 20734,
              "src": "269:10:25"
            },
            "nodeType": "UsingForDirective",
            "src": "263:37:25",
            "typeName": {
              "id": 3234,
              "nodeType": "UserDefinedTypeName",
              "pathNode": {
                "id": 3233,
                "name": "WitnetCBOR.CBOR",
                "nameLocations": [
                  "284:10:25",
                  "295:4:25"
                ],
                "nodeType": "IdentifierPath",
                "referencedDeclaration": 19218,
                "src": "284:15:25"
              },
              "referencedDeclaration": 19218,
              "src": "284:15:25",
              "typeDescriptions": {
                "typeIdentifier": "t_struct$_CBOR_$19218_storage_ptr",
                "typeString": "struct WitnetCBOR.CBOR"
              }
            }
          },
          {
            "global": false,
            "id": 3240,
            "libraryName": {
              "id": 3236,
              "name": "WitnetCBOR",
              "nameLocations": [
                "312:10:25"
              ],
              "nodeType": "IdentifierPath",
              "referencedDeclaration": 20734,
              "src": "312:10:25"
            },
            "nodeType": "UsingForDirective",
            "src": "306:39:25",
            "typeName": {
              "baseType": {
                "id": 3238,
                "nodeType": "UserDefinedTypeName",
                "pathNode": {
                  "id": 3237,
                  "name": "WitnetCBOR.CBOR",
                  "nameLocations": [
                    "327:10:25",
                    "338:4:25"
                  ],
                  "nodeType": "IdentifierPath",
                  "referencedDeclaration": 19218,
                  "src": "327:15:25"
                },
                "referencedDeclaration": 19218,
                "src": "327:15:25",
                "typeDescriptions": {
                  "typeIdentifier": "t_struct$_CBOR_$19218_storage_ptr",
                  "typeString": "struct WitnetCBOR.CBOR"
                }
              },
              "id": 3239,
              "nodeType": "ArrayTypeName",
              "src": "327:17:25",
              "typeDescriptions": {
                "typeIdentifier": "t_array$_t_struct$_CBOR_$19218_storage_$dyn_storage_ptr",
                "typeString": "struct WitnetCBOR.CBOR[]"
              }
            }
          },
          {
            "body": {
              "id": 3258,
              "nodeType": "Block",
              "src": "989:2:25",
              "statements": []
            },
            "documentation": {
              "id": 3241,
              "nodeType": "StructuredDocumentation",
              "src": "357:320:25",
              "text": "@param _witnetRequestTemplate Address of the WitnetRequestTemplate from which actual data requests will get built.\n @param _baseFeeOverheadPercentage Percentage over base fee to pay as on every data request.\n @param _callbackGasLimit Maximum gas to be spent by the IWitnetConsumer's callback methods."
            },
            "id": 3259,
            "implemented": true,
            "kind": "constructor",
            "modifiers": [
              {
                "arguments": [
                  {
                    "id": 3251,
                    "name": "_witnetRequestTemplate",
                    "nodeType": "Identifier",
                    "overloadedDeclarations": [],
                    "referencedDeclaration": 3244,
                    "src": "889:22:25",
                    "typeDescriptions": {
                      "typeIdentifier": "t_contract$_WitnetRequestTemplate_$1005",
                      "typeString": "contract WitnetRequestTemplate"
                    }
                  },
                  {
                    "id": 3252,
                    "name": "_baseFeeOverheadPercentage",
                    "nodeType": "Identifier",
                    "overloadedDeclarations": [],
                    "referencedDeclaration": 3246,
                    "src": "913:26:25",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint16",
                      "typeString": "uint16"
                    }
                  }
                ],
                "id": 3253,
                "kind": "baseConstructorSpecifier",
                "modifierName": {
                  "id": 3250,
                  "name": "UsingWitnetRequestTemplate",
                  "nameLocations": [
                    "862:26:25"
                  ],
                  "nodeType": "IdentifierPath",
                  "referencedDeclaration": 1453,
                  "src": "862:26:25"
                },
                "nodeType": "ModifierInvocation",
                "src": "862:78:25"
              },
              {
                "arguments": [
                  {
                    "id": 3255,
                    "name": "_callbackGasLimit",
                    "nodeType": "Identifier",
                    "overloadedDeclarations": [],
                    "referencedDeclaration": 3248,
                    "src": "965:17:25",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint24",
                      "typeString": "uint24"
                    }
                  }
                ],
                "id": 3256,
                "kind": "baseConstructorSpecifier",
                "modifierName": {
                  "id": 3254,
                  "name": "WitnetConsumer",
                  "nameLocations": [
                    "950:14:25"
                  ],
                  "nodeType": "IdentifierPath",
                  "referencedDeclaration": 1566,
                  "src": "950:14:25"
                },
                "nodeType": "ModifierInvocation",
                "src": "950:33:25"
              }
            ],
            "name": "",
            "nameLocation": "-1:-1:-1",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 3249,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 3244,
                  "mutability": "mutable",
                  "name": "_witnetRequestTemplate",
                  "nameLocation": "731:22:25",
                  "nodeType": "VariableDeclaration",
                  "scope": 3259,
                  "src": "709:44:25",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_contract$_WitnetRequestTemplate_$1005",
                    "typeString": "contract WitnetRequestTemplate"
                  },
                  "typeName": {
                    "id": 3243,
                    "nodeType": "UserDefinedTypeName",
                    "pathNode": {
                      "id": 3242,
                      "name": "WitnetRequestTemplate",
                      "nameLocations": [
                        "709:21:25"
                      ],
                      "nodeType": "IdentifierPath",
                      "referencedDeclaration": 1005,
                      "src": "709:21:25"
                    },
                    "referencedDeclaration": 1005,
                    "src": "709:21:25",
                    "typeDescriptions": {
                      "typeIdentifier": "t_contract$_WitnetRequestTemplate_$1005",
                      "typeString": "contract WitnetRequestTemplate"
                    }
                  },
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 3246,
                  "mutability": "mutable",
                  "name": "_baseFeeOverheadPercentage",
                  "nameLocation": "776:26:25",
                  "nodeType": "VariableDeclaration",
                  "scope": 3259,
                  "src": "769:33:25",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint16",
                    "typeString": "uint16"
                  },
                  "typeName": {
                    "id": 3245,
                    "name": "uint16",
                    "nodeType": "ElementaryTypeName",
                    "src": "769:6:25",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint16",
                      "typeString": "uint16"
                    }
                  },
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 3248,
                  "mutability": "mutable",
                  "name": "_callbackGasLimit",
                  "nameLocation": "824:17:25",
                  "nodeType": "VariableDeclaration",
                  "scope": 3259,
                  "src": "817:24:25",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint24",
                    "typeString": "uint24"
                  },
                  "typeName": {
                    "id": 3247,
                    "name": "uint24",
                    "nodeType": "ElementaryTypeName",
                    "src": "817:6:25",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint24",
                      "typeString": "uint24"
                    }
                  },
                  "visibility": "internal"
                }
              ],
              "src": "694:158:25"
            },
            "returnParameters": {
              "id": 3257,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "989:0:25"
            },
            "scope": 3316,
            "src": "683:308:25",
            "stateMutability": "nonpayable",
            "virtual": false,
            "visibility": "internal"
          },
          {
            "baseFunctions": [
              1409,
              1529
            ],
            "body": {
              "id": 3272,
              "nodeType": "Block",
              "src": "1160:93:25",
              "statements": [
                {
                  "expression": {
                    "arguments": [
                      {
                        "id": 3269,
                        "name": "__witnetQueryResultMaxSize",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 1325,
                        "src": "1218:26:25",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint16",
                          "typeString": "uint16"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_uint16",
                          "typeString": "uint16"
                        }
                      ],
                      "expression": {
                        "id": 3267,
                        "name": "WitnetConsumer",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 1566,
                        "src": "1178:14:25",
                        "typeDescriptions": {
                          "typeIdentifier": "t_type$_t_contract$_WitnetConsumer_$1566_$",
                          "typeString": "type(contract WitnetConsumer)"
                        }
                      },
                      "id": 3268,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberLocation": "1193:24:25",
                      "memberName": "_witnetEstimateEvmReward",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 1541,
                      "src": "1178:39:25",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_internal_view$_t_uint16_$returns$_t_uint256_$",
                        "typeString": "function (uint16) view returns (uint256)"
                      }
                    },
                    "id": 3270,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "nameLocations": [],
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "1178:67:25",
                    "tryCall": false,
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "functionReturnParameters": 3266,
                  "id": 3271,
                  "nodeType": "Return",
                  "src": "1171:74:25"
                }
              ]
            },
            "id": 3273,
            "implemented": true,
            "kind": "function",
            "modifiers": [],
            "name": "_witnetEstimateEvmReward",
            "nameLocation": "1008:24:25",
            "nodeType": "FunctionDefinition",
            "overrides": {
              "id": 3263,
              "nodeType": "OverrideSpecifier",
              "overrides": [
                {
                  "id": 3261,
                  "name": "UsingWitnetRequestTemplate",
                  "nameLocations": [
                    "1061:26:25"
                  ],
                  "nodeType": "IdentifierPath",
                  "referencedDeclaration": 1453,
                  "src": "1061:26:25"
                },
                {
                  "id": 3262,
                  "name": "WitnetConsumer",
                  "nameLocations": [
                    "1089:14:25"
                  ],
                  "nodeType": "IdentifierPath",
                  "referencedDeclaration": 1566,
                  "src": "1089:14:25"
                }
              ],
              "src": "1052:52:25"
            },
            "parameters": {
              "id": 3260,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "1032:2:25"
            },
            "returnParameters": {
              "id": 3266,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 3265,
                  "mutability": "mutable",
                  "name": "",
                  "nameLocation": "-1:-1:-1",
                  "nodeType": "VariableDeclaration",
                  "scope": 3273,
                  "src": "1146:7:25",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 3264,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "1146:7:25",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "visibility": "internal"
                }
              ],
              "src": "1145:9:25"
            },
            "scope": 3316,
            "src": "999:254:25",
            "stateMutability": "view",
            "virtual": true,
            "visibility": "internal"
          },
          {
            "baseFunctions": [
              1128,
              1541
            ],
            "body": {
              "id": 3287,
              "nodeType": "Block",
              "src": "1415:67:25",
              "statements": [
                {
                  "expression": {
                    "arguments": [],
                    "expression": {
                      "argumentTypes": [],
                      "expression": {
                        "id": 3283,
                        "name": "WitnetConsumer",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 1566,
                        "src": "1433:14:25",
                        "typeDescriptions": {
                          "typeIdentifier": "t_type$_t_contract$_WitnetConsumer_$1566_$",
                          "typeString": "type(contract WitnetConsumer)"
                        }
                      },
                      "id": 3284,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberLocation": "1448:24:25",
                      "memberName": "_witnetEstimateEvmReward",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 1529,
                      "src": "1433:39:25",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_internal_view$__$returns$_t_uint256_$",
                        "typeString": "function () view returns (uint256)"
                      }
                    },
                    "id": 3285,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "nameLocations": [],
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "1433:41:25",
                    "tryCall": false,
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "functionReturnParameters": 3282,
                  "id": 3286,
                  "nodeType": "Return",
                  "src": "1426:48:25"
                }
              ]
            },
            "id": 3288,
            "implemented": true,
            "kind": "function",
            "modifiers": [],
            "name": "_witnetEstimateEvmReward",
            "nameLocation": "1270:24:25",
            "nodeType": "FunctionDefinition",
            "overrides": {
              "id": 3279,
              "nodeType": "OverrideSpecifier",
              "overrides": [
                {
                  "id": 3277,
                  "name": "UsingWitnet",
                  "nameLocations": [
                    "1330:11:25"
                  ],
                  "nodeType": "IdentifierPath",
                  "referencedDeclaration": 1157,
                  "src": "1330:11:25"
                },
                {
                  "id": 3278,
                  "name": "WitnetConsumer",
                  "nameLocations": [
                    "1343:14:25"
                  ],
                  "nodeType": "IdentifierPath",
                  "referencedDeclaration": 1566,
                  "src": "1343:14:25"
                }
              ],
              "src": "1321:37:25"
            },
            "parameters": {
              "id": 3276,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 3275,
                  "mutability": "mutable",
                  "name": "",
                  "nameLocation": "-1:-1:-1",
                  "nodeType": "VariableDeclaration",
                  "scope": 3288,
                  "src": "1295:6:25",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint16",
                    "typeString": "uint16"
                  },
                  "typeName": {
                    "id": 3274,
                    "name": "uint16",
                    "nodeType": "ElementaryTypeName",
                    "src": "1295:6:25",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint16",
                      "typeString": "uint16"
                    }
                  },
                  "visibility": "internal"
                }
              ],
              "src": "1294:8:25"
            },
            "returnParameters": {
              "id": 3282,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 3281,
                  "mutability": "mutable",
                  "name": "",
                  "nameLocation": "-1:-1:-1",
                  "nodeType": "VariableDeclaration",
                  "scope": 3288,
                  "src": "1401:7:25",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 3280,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "1401:7:25",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "visibility": "internal"
                }
              ],
              "src": "1400:9:25"
            },
            "scope": 3316,
            "src": "1261:221:25",
            "stateMutability": "view",
            "virtual": true,
            "visibility": "internal"
          },
          {
            "baseFunctions": [
              1452
            ],
            "body": {
              "id": 3314,
              "nodeType": "Block",
              "src": "1743:241:25",
              "statements": [
                {
                  "expression": {
                    "arguments": [
                      {
                        "arguments": [
                          {
                            "id": 3308,
                            "name": "_witnetRequestArgs",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 3294,
                            "src": "1877:18:25",
                            "typeDescriptions": {
                              "typeIdentifier": "t_array$_t_array$_t_string_memory_ptr_$dyn_memory_ptr_$dyn_memory_ptr",
                              "typeString": "string memory[] memory[] memory"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_array$_t_array$_t_string_memory_ptr_$dyn_memory_ptr_$dyn_memory_ptr",
                              "typeString": "string memory[] memory[] memory"
                            }
                          ],
                          "id": 3307,
                          "name": "_witnetBuildRadHash",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 1381,
                          "src": "1857:19:25",
                          "typeDescriptions": {
                            "typeIdentifier": "t_function_internal_nonpayable$_t_array$_t_array$_t_string_memory_ptr_$dyn_memory_ptr_$dyn_memory_ptr_$returns$_t_bytes32_$",
                            "typeString": "function (string memory[] memory[] memory) returns (bytes32)"
                          }
                        },
                        "id": 3309,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "functionCall",
                        "lValueRequested": false,
                        "nameLocations": [],
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "1857:39:25",
                        "tryCall": false,
                        "typeDescriptions": {
                          "typeIdentifier": "t_bytes32",
                          "typeString": "bytes32"
                        }
                      },
                      {
                        "id": 3310,
                        "name": "_witnetQuerySLA",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 3297,
                        "src": "1911:15:25",
                        "typeDescriptions": {
                          "typeIdentifier": "t_struct$_RadonSLA_$23503_memory_ptr",
                          "typeString": "struct WitnetV2.RadonSLA memory"
                        }
                      },
                      {
                        "id": 3311,
                        "name": "__witnetCallbackGasLimit",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 1464,
                        "src": "1941:24:25",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint24",
                          "typeString": "uint24"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_bytes32",
                          "typeString": "bytes32"
                        },
                        {
                          "typeIdentifier": "t_struct$_RadonSLA_$23503_memory_ptr",
                          "typeString": "struct WitnetV2.RadonSLA memory"
                        },
                        {
                          "typeIdentifier": "t_uint24",
                          "typeString": "uint24"
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_bytes32",
                            "typeString": "bytes32"
                          },
                          {
                            "typeIdentifier": "t_struct$_RadonSLA_$23503_memory_ptr",
                            "typeString": "struct WitnetV2.RadonSLA memory"
                          },
                          {
                            "typeIdentifier": "t_uint24",
                            "typeString": "uint24"
                          }
                        ],
                        "expression": {
                          "id": 3303,
                          "name": "__witnet",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 1016,
                          "src": "1761:8:25",
                          "typeDescriptions": {
                            "typeIdentifier": "t_contract$_WitnetOracle_$749",
                            "typeString": "contract WitnetOracle"
                          }
                        },
                        "id": 3304,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberLocation": "1770:23:25",
                        "memberName": "postRequestWithCallback",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": 13245,
                        "src": "1761:32:25",
                        "typeDescriptions": {
                          "typeIdentifier": "t_function_external_payable$_t_bytes32_$_t_struct$_RadonSLA_$23503_memory_ptr_$_t_uint24_$returns$_t_uint256_$",
                          "typeString": "function (bytes32,struct WitnetV2.RadonSLA memory,uint24) payable external returns (uint256)"
                        }
                      },
                      "id": 3306,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "names": [
                        "value"
                      ],
                      "nodeType": "FunctionCallOptions",
                      "options": [
                        {
                          "id": 3305,
                          "name": "_witnetEvmReward",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 3290,
                          "src": "1815:16:25",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        }
                      ],
                      "src": "1761:81:25",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_external_payable$_t_bytes32_$_t_struct$_RadonSLA_$23503_memory_ptr_$_t_uint24_$returns$_t_uint256_$value",
                        "typeString": "function (bytes32,struct WitnetV2.RadonSLA memory,uint24) payable external returns (uint256)"
                      }
                    },
                    "id": 3312,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "nameLocations": [],
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "1761:215:25",
                    "tryCall": false,
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "functionReturnParameters": 3302,
                  "id": 3313,
                  "nodeType": "Return",
                  "src": "1754:222:25"
                }
              ]
            },
            "id": 3315,
            "implemented": true,
            "kind": "function",
            "modifiers": [],
            "name": "__witnetRequestData",
            "nameLocation": "1500:19:25",
            "nodeType": "FunctionDefinition",
            "overrides": {
              "id": 3299,
              "nodeType": "OverrideSpecifier",
              "overrides": [],
              "src": "1693:8:25"
            },
            "parameters": {
              "id": 3298,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 3290,
                  "mutability": "mutable",
                  "name": "_witnetEvmReward",
                  "nameLocation": "1542:16:25",
                  "nodeType": "VariableDeclaration",
                  "scope": 3315,
                  "src": "1534:24:25",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 3289,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "1534:7:25",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 3294,
                  "mutability": "mutable",
                  "name": "_witnetRequestArgs",
                  "nameLocation": "1591:18:25",
                  "nodeType": "VariableDeclaration",
                  "scope": 3315,
                  "src": "1573:36:25",
                  "stateVariable": false,
                  "storageLocation": "memory",
                  "typeDescriptions": {
                    "typeIdentifier": "t_array$_t_array$_t_string_memory_ptr_$dyn_memory_ptr_$dyn_memory_ptr",
                    "typeString": "string[][]"
                  },
                  "typeName": {
                    "baseType": {
                      "baseType": {
                        "id": 3291,
                        "name": "string",
                        "nodeType": "ElementaryTypeName",
                        "src": "1573:6:25",
                        "typeDescriptions": {
                          "typeIdentifier": "t_string_storage_ptr",
                          "typeString": "string"
                        }
                      },
                      "id": 3292,
                      "nodeType": "ArrayTypeName",
                      "src": "1573:8:25",
                      "typeDescriptions": {
                        "typeIdentifier": "t_array$_t_string_storage_$dyn_storage_ptr",
                        "typeString": "string[]"
                      }
                    },
                    "id": 3293,
                    "nodeType": "ArrayTypeName",
                    "src": "1573:10:25",
                    "typeDescriptions": {
                      "typeIdentifier": "t_array$_t_array$_t_string_storage_$dyn_storage_$dyn_storage_ptr",
                      "typeString": "string[][]"
                    }
                  },
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 3297,
                  "mutability": "mutable",
                  "name": "_witnetQuerySLA",
                  "nameLocation": "1649:15:25",
                  "nodeType": "VariableDeclaration",
                  "scope": 3315,
                  "src": "1624:40:25",
                  "stateVariable": false,
                  "storageLocation": "memory",
                  "typeDescriptions": {
                    "typeIdentifier": "t_struct$_RadonSLA_$23503_memory_ptr",
                    "typeString": "struct WitnetV2.RadonSLA"
                  },
                  "typeName": {
                    "id": 3296,
                    "nodeType": "UserDefinedTypeName",
                    "pathNode": {
                      "id": 3295,
                      "name": "WitnetV2.RadonSLA",
                      "nameLocations": [
                        "1624:8:25",
                        "1633:8:25"
                      ],
                      "nodeType": "IdentifierPath",
                      "referencedDeclaration": 23503,
                      "src": "1624:17:25"
                    },
                    "referencedDeclaration": 23503,
                    "src": "1624:17:25",
                    "typeDescriptions": {
                      "typeIdentifier": "t_struct$_RadonSLA_$23503_storage_ptr",
                      "typeString": "struct WitnetV2.RadonSLA"
                    }
                  },
                  "visibility": "internal"
                }
              ],
              "src": "1519:156:25"
            },
            "returnParameters": {
              "id": 3302,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 3301,
                  "mutability": "mutable",
                  "name": "",
                  "nameLocation": "-1:-1:-1",
                  "nodeType": "VariableDeclaration",
                  "scope": 3315,
                  "src": "1729:7:25",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 3300,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "1729:7:25",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "visibility": "internal"
                }
              ],
              "src": "1728:9:25"
            },
            "scope": 3316,
            "src": "1491:493:25",
            "stateMutability": "nonpayable",
            "virtual": true,
            "visibility": "internal"
          }
        ],
        "scope": 3317,
        "src": "138:1851:25",
        "usedErrors": [],
        "usedEvents": [
          13278,
          13285,
          13294,
          13307,
          13314
        ]
      }
    ],
    "src": "33:1958:25"
  },
  "compiler": {
    "name": "solc",
    "version": "0.8.25+commit.b61c2a91.Emscripten.clang"
  },
  "networks": {},
  "schemaVersion": "3.4.16",
  "updatedAt": "2024-12-05T09:36:04.203Z",
  "devdoc": {
    "kind": "dev",
    "methods": {
      "constructor": {
        "params": {
          "_baseFeeOverheadPercentage": "Percentage over base fee to pay as on every data request.",
          "_callbackGasLimit": "Maximum gas to be spent by the IWitnetConsumer's callback methods.",
          "_witnetRequestTemplate": "Address of the WitnetRequestTemplate from which actual data requests will get built."
        }
      },
      "reportWitnetQueryError(uint256,uint64,bytes32,uint256,uint8,((bytes,uint256),uint8,uint8,uint8,uint64,uint64))": {
        "details": "It should revert if called from any other address different to the WitnetOracle being usedby the WitnetConsumer contract. ",
        "params": {
          "errorArgs": "Error arguments, if any. An empty buffer is to be passed if no error arguments apply.",
          "errorCode": "The error code enum identifying the error produced during resolution on the Witnet blockchain.",
          "witnetEvmFinalityBlock": "EVM block at which the provided data can be considered to be final.",
          "witnetQueryId": "The unique identifier of the Witnet query being reported.",
          "witnetResultTallyHash": "Hash of the commit/reveal witnessing act that took place in the Witnet blockahin.",
          "witnetResultTimestamp": "Timestamp at which the reported value was captured by the Witnet blockchain. "
        }
      },
      "reportWitnetQueryResult(uint256,uint64,bytes32,uint256,((bytes,uint256),uint8,uint8,uint8,uint64,uint64))": {
        "details": "It should revert if called from any other address different to the WitnetOracle being usedby the WitnetConsumer contract. ",
        "params": {
          "witnetEvmFinalityBlock": "EVM block at which the provided data can be considered to be final.",
          "witnetQueryId": "The unique identifier of the Witnet query being reported.",
          "witnetResultCborValue": "The CBOR-encoded resulting value of the Witnet query being reported.",
          "witnetResultTallyHash": "Hash of the commit/reveal witnessing act that took place in the Witnet blockahin.",
          "witnetResultTimestamp": "Timestamp at which the reported value was captured by the Witnet blockchain. "
        }
      }
    },
    "version": 1
  },
  "userdoc": {
    "events": {
      "WitnetQuery(uint256,uint256,(uint8,uint64))": {
        "notice": "Emitted every time a new query containing some verified data request is posted to the WRB."
      },
      "WitnetQueryResponse(uint256,uint256)": {
        "notice": "Emitted when a query with no callback gets reported into the WRB."
      },
      "WitnetQueryResponseDelivered(uint256,uint256,uint256)": {
        "notice": "Emitted when a query with a callback gets successfully reported into the WRB."
      },
      "WitnetQueryResponseDeliveryFailed(uint256,bytes,uint256,uint256,string)": {
        "notice": "Emitted when a query with a callback cannot get reported into the WRB."
      },
      "WitnetQueryRewardUpgraded(uint256,uint256)": {
        "notice": "Emitted when the reward of some not-yet reported query is upgraded."
      }
    },
    "kind": "user",
    "methods": {
      "reportWitnetQueryError(uint256,uint64,bytes32,uint256,uint8,((bytes,uint256),uint8,uint8,uint8,uint64,uint64))": {
        "notice": "Method to be called from the WitnetOracle contract as soon as the given Witnet `queryId`gets reported, if reported WITH errors."
      },
      "reportWitnetQueryResult(uint256,uint64,bytes32,uint256,((bytes,uint256),uint8,uint8,uint8,uint64,uint64))": {
        "notice": "Method to be called from the WitnetOracle contract as soon as the given Witnet `queryId`gets reported, if reported with no errors."
      },
      "reportableFrom(address)": {
        "notice": "=============================================================================================================== --- Base implementation of IWitnetConsumer --------------------------------------------------------------------"
      }
    },
    "version": 1
  }
}