@mean-finance/dca-v2-periphery
Version:
💱 Periphery smart contracts of DCA V2 by mean.finance
267 lines (266 loc) • 7.21 kB
JSON
{
"_format": "hh-sol-artifact-1",
"contractName": "IDCAHubCompanionLibrariesHandler",
"sourceName": "contracts/interfaces/IDCAHubCompanion.sol",
"abi": [
{
"inputs": [
{
"internalType": "contract IDCAHub",
"name": "hub",
"type": "address"
},
{
"components": [
{
"internalType": "address",
"name": "tokenA",
"type": "address"
},
{
"internalType": "address",
"name": "tokenB",
"type": "address"
}
],
"internalType": "struct Pair[]",
"name": "pairs",
"type": "tuple[]"
},
{
"internalType": "bool",
"name": "calculatePrivilegedAvailability",
"type": "bool"
},
{
"internalType": "bytes",
"name": "oracleData",
"type": "bytes"
}
],
"name": "getNextSwapInfo",
"outputs": [
{
"components": [
{
"components": [
{
"internalType": "address",
"name": "token",
"type": "address"
},
{
"internalType": "uint256",
"name": "reward",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "toProvide",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "platformFee",
"type": "uint256"
}
],
"internalType": "struct IDCAHubSwapHandler.TokenInSwap[]",
"name": "tokens",
"type": "tuple[]"
},
{
"components": [
{
"internalType": "address",
"name": "tokenA",
"type": "address"
},
{
"internalType": "address",
"name": "tokenB",
"type": "address"
},
{
"internalType": "uint256",
"name": "totalAmountToSwapTokenA",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "totalAmountToSwapTokenB",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "ratioAToB",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "ratioBToA",
"type": "uint256"
},
{
"internalType": "bytes1",
"name": "intervalsInSwap",
"type": "bytes1"
}
],
"internalType": "struct IDCAHubSwapHandler.PairInSwap[]",
"name": "pairs",
"type": "tuple[]"
}
],
"internalType": "struct IDCAHubSwapHandler.SwapInfo",
"name": "",
"type": "tuple"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "contract ILegacyDCAHub",
"name": "hub",
"type": "address"
},
{
"components": [
{
"internalType": "address",
"name": "tokenA",
"type": "address"
},
{
"internalType": "address",
"name": "tokenB",
"type": "address"
}
],
"internalType": "struct Pair[]",
"name": "pairs",
"type": "tuple[]"
}
],
"name": "legacyGetNextSwapInfo",
"outputs": [
{
"components": [
{
"components": [
{
"internalType": "address",
"name": "token",
"type": "address"
},
{
"internalType": "uint256",
"name": "reward",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "toProvide",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "platformFee",
"type": "uint256"
}
],
"internalType": "struct ILegacyDCAHub.TokenInSwap[]",
"name": "tokens",
"type": "tuple[]"
},
{
"components": [
{
"internalType": "address",
"name": "tokenA",
"type": "address"
},
{
"internalType": "address",
"name": "tokenB",
"type": "address"
},
{
"internalType": "uint256",
"name": "ratioAToB",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "ratioBToA",
"type": "uint256"
},
{
"internalType": "bytes1",
"name": "intervalsInSwap",
"type": "bytes1"
}
],
"internalType": "struct ILegacyDCAHub.PairInSwap[]",
"name": "pairs",
"type": "tuple[]"
}
],
"internalType": "struct ILegacyDCAHub.SwapInfo",
"name": "",
"type": "tuple"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "contract IDCAHub",
"name": "hub",
"type": "address"
},
{
"components": [
{
"internalType": "address",
"name": "tokenA",
"type": "address"
},
{
"internalType": "address",
"name": "tokenB",
"type": "address"
}
],
"internalType": "struct Pair[]",
"name": "pairs",
"type": "tuple[]"
},
{
"internalType": "bool",
"name": "calculatePrivilegedAvailability",
"type": "bool"
}
],
"name": "secondsUntilNextSwap",
"outputs": [
{
"internalType": "uint256[]",
"name": "",
"type": "uint256[]"
}
],
"stateMutability": "view",
"type": "function"
}
],
"bytecode": "0x",
"deployedBytecode": "0x",
"linkReferences": {},
"deployedLinkReferences": {}
}