A computable financial transaction model
The Future of On-Chain Market Making is Here π€ πππ°
https://cofix.io/doc/CoFiX_White_Paper.pdf
https://github.com/Computable-Finance/Doc
Guide: How to Integrate with CoFiX
thanks π¦ for great contract architecture
npm install
npm run test
Run truffle compile
, get build results in build/contracts
folder, including ABI
json files.
or
Use npx oz compile
to adopt @openzeppelin/cli
toolchain.
Deploy with truffle
and you will get a contract deployement summary on contract addresses.
truffle migrate --network ropsten
You may need to activate()
the price oracle through CoFiXController
contract manually and set kTable with the help of scripts/setKTable.js.
There are several scripts used to invoke with the protocol in scripts/
folder. Simplely run truffle exec scripts/SPECIFIC_SCRIPT.JS
with flags to execute. Here are some examples.
npm run genabi
CoFiX Governance (Multi-Sig) https://gnosis-safe.io/app/#/safes/0xF51d8FdF98286e1EA846c79f1526ECC95b93AbB8/balances
Check Record of Governance Authority Transfer to Multi-Sig Wallet and Details on CoFiX Multi-Sig Governance Contract here.
Governance ownership will be transferred to the CoFiX DAO in the next stage when the CoFi token is widely distributed.
Contract | Address |
---|---|
USDT | 0xdAC17F958D2ee523a2206206994597C13D831ec7 |
HBTC | 0x0316EB71485b0Ab14103307bf65a021042c6d380 |
NEST | 0x04abEdA201850aC0124161F037Efd70c74ddC74C |
WETH | 0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2 |
NestPriceOracle (deprecated, use NestPriceFacade) | 0x94F36FAa6bB4f74009637292b09C355CcD3e80Eb |
NestQuery (deprecated, use NestPriceFacade) | 0x3bf046c114385357838D9cAE9509C6fBBfE306d2 |
NestPriceFacade | 0xB5D2890c061c321A5B6A4a4254bb1522425BAF0A |
NEST3VoteFactory | 0x6Cd5698E8854Fb6879d6B1C694223b389B465dea |
CoFiXKTable | 0x75E360Be6248Bd46030C6818624a09403EF5eC21 |
CoFiToken | 0x1a23a6BfBAdB59fa563008c0fB7cf96dfCF34Ea1 |
CoFiXNode | 0x558201DC4741efc11031Cdc3BC1bC728C23bF512 |
CoFiXFactory | 0x66C64ecC3A6014733325a8f2EBEE46B4CA3ED550 |
CoFiXRouter | 0x26aaD4D82f6c9FA6E34D8c1067429C986A055872 |
CoFiXRouter02 (Beta) | 0x5C35BaDebD40308e409df891aC56d17C8625c2bC |
CoFiXController (deprecated) | 0xd694eF4C82E50F3f184877572dCD6A45B8FEae87 |
CoFiXController02 (deprecated) | 0x7e497Be7532CC4954D73c6dF93F016c53CC0C29a |
CoFiXController03 (deprecated) | 0xc6f45eB40609c9CD30c8750A95042De1b8B1DBFf |
CoFiXController04 | 0xB99DB9674e03A2cB07c3D7d92406aE1a3BBB9f56 |
CoFiXVaultForLP | 0x6903b1C17A5A0A9484c7346E5c0956027A713fCF |
CoFiXVaultForTrader | 0xE6183d3094a9e360B123Ec1330afAE76A74d1cbF |
CoFiXVaultForCNode | 0x7eDa8251aC08E7898E986DbeC4Ba97B421d545DD |
CoFiStakingRewards | 0x0061c52768378b84306b2665f098c3e0b2C03308 |
ETH/USDT Pair | 0xb2b7BeDd7d7fc19804C7Dd4a4E8174C4c73C210d |
ETH/HBTC Pair | 0x7C2d7b53AcA4038f2Eb649164181114B9AEE93CB |
CoFiXStakingRewards for ETH/USDT Pair | 0x3B67fe44216d3e147bA8ccF6E49d2E576441cb10 |
CoFiXStakingRewards for ETH/HBTC Pair | 0x5Fd4Eb552965F0Db9F50Ac285C55C8397F19F45B |
CNodeStakingRewards for CNode | 0xb697A2528D57a2BA8E75E2F33eD56B594cf9F308 |
- ETH/USDT
- Pair (XToken): 0xb2b7BeDd7d7fc19804C7Dd4a4E8174C4c73C210d
- XToken StakingRewards Pool: 0x3B67fe44216d3e147bA8ccF6E49d2E576441cb10
- ETH/HBTC
- Pair (XToken): 0x7C2d7b53AcA4038f2Eb649164181114B9AEE93CB
- XToken StakingRewards Pool: 0x5Fd4Eb552965F0Db9F50Ac285C55C8397F19F45B
- CNode Token StakingRewards Pool (CNodeStakingRewards): 0xb697A2528D57a2BA8E75E2F33eD56B594cf9F308
Contract | Address |
---|---|
USDT | 0x200506568C2980B4943B5EaA8713A5740eb2c98A |
HBTC | 0xA674f71ce49CE7F298aea2F23D918d114965eb40 |
NEST | 0xD287Bc43eCD3D892204aA3792165fe8728636E29 |
WETH | 0x59b8881812Ac484Ab78b8fc7c10b2543e079a6C3 |
NestPriceOracle (deprecated, use NestQuery) | 0x70B9b6F0e1E4073403cF7143b45a862fe73af3B9 |
NestQuery | 0x3bF1d76A2fb912481022fdC31bD5016cC5A6c671 |
NEST3VoteFactory | 0xAB996648c3e7E16253988d4a916456F6f63F04Ee |
CoFiXKTable | 0xe609B978635c7Bb8D22Ffc4Ec7f7a16615a3b1cA |
CoFiToken | 0x72Fd35b1dB364db812A8E726891685A25a9135D3 |
CoFiXNode | 0x655C281DC8610003d8AE490D462B950BdA71582f |
CoFiXFactory | 0x8E636BDB79752BFa2C41285535852bbBDd50b2ca |
CoFiXRouter | 0xbeE8674291328D09831cAf96eFceaCDf53066B86 |
CoFiXRouter02 (Beta) | 0xAdD27c75b7B003cc791E4062e20f9Eb872FafC65 |
CoFiXController (deprecated) | 0xEB95E090b27A67f574005F41eea83794D5ac1650 |
CoFiXController02 (deprecated) | 0x36f99d8500CB288c924B50cf4A081F4C3E6d48DD |
CoFiXController03 | 0x8a814Da4d9Dfdebf6080BbE2d8C7bb238272507B |
CoFiXVaultForLP | 0x2494853258c33A99581Abddc7b85b11D1D1885DF |
CoFiXVaultForTrader | 0xe901e7f88a377D01028aE947cFA3192b3c5f7587 |
CoFiXVaultForCNode | 0x159894c1e9712bF2EeDB4b2B84dFDA154893088B |
CoFiStakingRewards | 0x2a603D9e8b3152B6e235c7eFA41dFc073764d96a |
ETH/USDT Pair | 0xffe14368FC46EB507e5221459a480646F22558b6 |
ETH/HBTC Pair | 0xe0297aBDCCf60Ab85365694E53AF92A433c2852e |
CoFiXStakingRewards ETH/USDT Pair | 0x58FEf07559C7b19926BF4104463F80360A677144 |
CoFiXStakingRewards ETH/HBTC Pair | 0xfdFc41f8b9D8b667b7DE8a976F446C557c697981 |
CNodeStakingRewards CNode | 0x3ECD22524CDdC3E3AC2f52a595A9C7FA3b677ec1 |
- ETH/USDT
- Pair (XToken): 0xffe14368FC46EB507e5221459a480646F22558b6
- XToken StakingRewards Pool: 0x58FEf07559C7b19926BF4104463F80360A677144
- ETH/HBTC
- Pair (XToken): 0xe0297aBDCCf60Ab85365694E53AF92A433c2852e
- XToken StakingRewards Pool: 0xfdFc41f8b9D8b667b7DE8a976F446C557c697981
- CNode Token StakingRewards Pool (CNodeStakingRewards): 0x3ECD22524CDdC3E3AC2f52a595A9C7FA3b677ec1
Contract | Address |
---|---|
USDT | 0x200506568C2980B4943B5EaA8713A5740eb2c98A |
HBTC | 0xA674f71ce49CE7F298aea2F23D918d114965eb40 |
NEST | 0xD287Bc43eCD3D892204aA3792165fe8728636E29 |
WETH | 0x59b8881812Ac484Ab78b8fc7c10b2543e079a6C3 |
NestPriceOracle | 0x70B9b6F0e1E4073403cF7143b45a862fe73af3B9 |
CoFiXKTable | 0xe609B978635c7Bb8D22Ffc4Ec7f7a16615a3b1cA |
CoFiToken | 0x0c7caD803686a284542d807406f4CD0b2c6B5d17 |
CoFiXNode | 0xA4B1412EcabAbB6F3188Aa411546491790bde89B |
CoFiXFactory | 0xB19EbE64A0ca9626824abBdbdeC4a76294D460A5 |
CoFiXRouter | 0xB9a933FE0Eeb184b2E35372B3ad55fDC4b325469 |
CoFiXController | 0xe4fa2dAA56e87a927386790D41E3F9906e40f4C2 |
CoFiXVaultForLP | 0xB6ae9774D2C743B0886123A1C98d4fc92558BaBC |
CoFiXVaultForTrader | 0xcF3167AFCAf33f899d4Fa0ab431D3B6038C79dbf |
CoFiXVaultForCNode | 0xEf1976634a2fbCCeD89DFAa44FAd85A4A211E4B3 |
CoFiStakingRewards | 0xC8b29e0b4F5e9A55a0130934A690655BefbA34B4 |
Contract | Address |
---|---|
USDT | 0x3399EB8165888221A30c822753648dfc16ed3803 |
HBTC | 0xC34156BE35c870D47638eFdCfA20E39e299607B0 |
NEST | 0xa50CB75ee798268aeA5de0F0aEE271595e1CAAa2 |
WETH | 0x39edE2c2ca91295BEA2F20080C0B82872B7C64b7 |
NestPriceOracle | 0x505A054e6064fADB9277864647641EF64B7c783B |
CoFiXKTable | 0xa01FeCbeD543DCF5612D379ecbE23b0D2763c0D6 |
CoFiToken | 0x61f423C704FcFd84adF006dB84a905dDca2ba4fA |
CoFiXNode | 0xC2B66C87bFCA3900031b246a169fB6A67A911D8a |
CoFiXFactory | 0x3B4d6962A3f5184D9eb240D70070516addC3F4c5 |
CoFiXRouter | 0x5f6c887B22a8b30C2eca90B9C63ff370494790B7 |
CoFiXController | 0xed03772aFF6B83875De68C89961f83899D29EeD1 |
CoFiXVaultForLP | 0x1eAF116d62eB943fcf28A0645b8059EFBb829FAB |
CoFiXVaultForTrader | 0x37289c1d3BEAE79c0EEF494ABf5209668E1704B9 |
CoFiXVaultForCNode | 0x04983eEA3aA0A73A1487B255abA688619844B023 |
CoFiStakingRewards | 0x453FEd6fE31a17C8277bd7F477ebbCB542D4Ad5D |
Contract | Address |
---|---|
USDT | 0x04716BaA169f6E5BAFe92E4643C2f18480ba46D3 |
HBTC | 0xcae23767DF5BbEBD0d64402a7d3d82776f97bE46 |
NEST | 0x08cFf00044dECe1D817F3D30A7cc8aef43A284De |
WETH | 0x6A04aF9c9793D9eE1a27eB7A343f940282a0AB9e |
NestPriceOracle | 0x93Afa4ff16874Cf9D4f29da4973be277f53607Af |
CoFiXController | 0xf71141F66e15740DB5d59E4c31ee0D84d6584452 |
CoFiXFactory | 0x9984dCe65387d9AE8a495452F72dF0A0D4F85d2c |
CoFiXKTable | 0x0441e7e4C1ecd73a068F0696Cf4cB10Ea69dD74A |
CoFiXRouter | 0xB5852d2cC06cd394f52C9edEbF0f1d59aD4A0615 |
check test/CoFiX.test.js
for details.