-
Notifications
You must be signed in to change notification settings - Fork 57
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #145 from LibertyFi/libertify/add-libertify-polygon
add libertify on polygon
- Loading branch information
Showing
2 changed files
with
270 additions
and
0 deletions.
There are no files selected for viewing
243 changes: 243 additions & 0 deletions
243
polygon/libertify/abis/0x9f4294dc2ba0e4569cbfa3d8a0a5f2f23385db50.abi.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,243 @@ | ||
[ | ||
{ | ||
"inputs": [ | ||
{ | ||
"internalType": "address", | ||
"name": "_wethAddr", | ||
"type": "address" | ||
} | ||
], | ||
"stateMutability": "nonpayable", | ||
"type": "constructor" | ||
}, | ||
{ | ||
"inputs": [], | ||
"name": "BadData", | ||
"type": "error" | ||
}, | ||
{ | ||
"inputs": [], | ||
"name": "BadReceiver", | ||
"type": "error" | ||
}, | ||
{ | ||
"inputs": [], | ||
"name": "BadReturn", | ||
"type": "error" | ||
}, | ||
{ | ||
"inputs": [], | ||
"name": "BadSelector", | ||
"type": "error" | ||
}, | ||
{ | ||
"inputs": [], | ||
"name": "BadSymbol", | ||
"type": "error" | ||
}, | ||
{ | ||
"inputs": [], | ||
"name": "BadToken", | ||
"type": "error" | ||
}, | ||
{ | ||
"inputs": [], | ||
"name": "BadValue", | ||
"type": "error" | ||
}, | ||
{ | ||
"inputs": [], | ||
"name": "FailedTransfer", | ||
"type": "error" | ||
}, | ||
{ | ||
"inputs": [], | ||
"name": "UnevenSwap", | ||
"type": "error" | ||
}, | ||
{ | ||
"inputs": [ | ||
{ | ||
"internalType": "uint256", | ||
"name": "amountIn", | ||
"type": "uint256" | ||
}, | ||
{ | ||
"internalType": "address", | ||
"name": "srcToken", | ||
"type": "address" | ||
}, | ||
{ | ||
"internalType": "address", | ||
"name": "vaultAddr", | ||
"type": "address" | ||
}, | ||
{ | ||
"internalType": "bytes[]", | ||
"name": "data", | ||
"type": "bytes[]" | ||
} | ||
], | ||
"name": "deposit", | ||
"outputs": [ | ||
{ | ||
"internalType": "uint256", | ||
"name": "", | ||
"type": "uint256" | ||
} | ||
], | ||
"stateMutability": "payable", | ||
"type": "function" | ||
}, | ||
{ | ||
"inputs": [ | ||
{ | ||
"internalType": "uint256", | ||
"name": "amountIn", | ||
"type": "uint256" | ||
}, | ||
{ | ||
"internalType": "address", | ||
"name": "srcToken", | ||
"type": "address" | ||
}, | ||
{ | ||
"internalType": "address", | ||
"name": "vaultAddr", | ||
"type": "address" | ||
}, | ||
{ | ||
"internalType": "string", | ||
"name": "vaultSymbol", | ||
"type": "string" | ||
}, | ||
{ | ||
"internalType": "bytes[]", | ||
"name": "data", | ||
"type": "bytes[]" | ||
} | ||
], | ||
"name": "depositWithSymbolCheck", | ||
"outputs": [ | ||
{ | ||
"internalType": "uint256", | ||
"name": "", | ||
"type": "uint256" | ||
} | ||
], | ||
"stateMutability": "payable", | ||
"type": "function" | ||
}, | ||
{ | ||
"inputs": [ | ||
{ | ||
"internalType": "uint256", | ||
"name": "amountIn", | ||
"type": "uint256" | ||
}, | ||
{ | ||
"internalType": "address", | ||
"name": "vaultAddr", | ||
"type": "address" | ||
} | ||
], | ||
"name": "previewWithdraw", | ||
"outputs": [ | ||
{ | ||
"internalType": "address[]", | ||
"name": "tokens", | ||
"type": "address[]" | ||
}, | ||
{ | ||
"internalType": "uint256[]", | ||
"name": "amountsOut", | ||
"type": "uint256[]" | ||
} | ||
], | ||
"stateMutability": "view", | ||
"type": "function" | ||
}, | ||
{ | ||
"inputs": [ | ||
{ | ||
"internalType": "uint256", | ||
"name": "amountIn", | ||
"type": "uint256" | ||
}, | ||
{ | ||
"internalType": "address", | ||
"name": "dstToken", | ||
"type": "address" | ||
}, | ||
{ | ||
"internalType": "address", | ||
"name": "vaultAddr", | ||
"type": "address" | ||
}, | ||
{ | ||
"internalType": "uint256", | ||
"name": "minAmountOut", | ||
"type": "uint256" | ||
}, | ||
{ | ||
"internalType": "bytes[]", | ||
"name": "data", | ||
"type": "bytes[]" | ||
} | ||
], | ||
"name": "withdraw", | ||
"outputs": [ | ||
{ | ||
"internalType": "uint256", | ||
"name": "amountOut", | ||
"type": "uint256" | ||
} | ||
], | ||
"stateMutability": "nonpayable", | ||
"type": "function" | ||
}, | ||
{ | ||
"inputs": [ | ||
{ | ||
"internalType": "uint256", | ||
"name": "amountIn", | ||
"type": "uint256" | ||
}, | ||
{ | ||
"internalType": "address", | ||
"name": "dstToken", | ||
"type": "address" | ||
}, | ||
{ | ||
"internalType": "address", | ||
"name": "vaultAddr", | ||
"type": "address" | ||
}, | ||
{ | ||
"internalType": "uint256", | ||
"name": "minAmountOut", | ||
"type": "uint256" | ||
}, | ||
{ | ||
"internalType": "string", | ||
"name": "vaultSymbol", | ||
"type": "string" | ||
}, | ||
{ | ||
"internalType": "bytes[]", | ||
"name": "data", | ||
"type": "bytes[]" | ||
} | ||
], | ||
"name": "withdrawWithSymbolCheck", | ||
"outputs": [ | ||
{ | ||
"internalType": "uint256", | ||
"name": "", | ||
"type": "uint256" | ||
} | ||
], | ||
"stateMutability": "nonpayable", | ||
"type": "function" | ||
} | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
{ | ||
"blockchainName": "polygon", | ||
"chainId": 137, | ||
"contracts": [ | ||
{ | ||
"address": "0x9f4294dc2ba0e4569cbfa3d8a0a5f2f23385db50", | ||
"contractName": "LibertiV2Proxy", | ||
"selectors": { | ||
"0xa2922622": { | ||
"erc20OfInterest": [ | ||
"dstToken" | ||
], | ||
"method": "withdrawWithSymbolCheck", | ||
"plugin": "libertify" | ||
}, | ||
"0xaa2daba6": { | ||
"erc20OfInterest": [ | ||
"srcToken" | ||
], | ||
"method": "depositWithSymbolCheck", | ||
"plugin": "libertify" | ||
} | ||
} | ||
} | ||
], | ||
"name": "libertify" | ||
} |