[
    {
        "anonymous": false,
        "inputs": [
            {
                "indexed": true,
                "name": "buyer",
                "type": "address"
            },
            {
                "indexed": false,
                "name": "sold_id",
                "type": "int128"
            },
            {
                "indexed": false,
                "name": "tokens_sold",
                "type": "uint256"
            },
            {
                "indexed": false,
                "name": "bought_id",
                "type": "int128"
            },
            {
                "indexed": false,
                "name": "tokens_bought",
                "type": "uint256"
            }
        ],
        "name": "TokenExchange",
        "type": "event"
    },
    {
        "anonymous": false,
        "inputs": [
            {
                "indexed": true,
                "name": "buyer",
                "type": "address"
            },
            {
                "indexed": false,
                "name": "sold_id",
                "type": "int128"
            },
            {
                "indexed": false,
                "name": "tokens_sold",
                "type": "uint256"
            },
            {
                "indexed": false,
                "name": "bought_id",
                "type": "int128"
            },
            {
                "indexed": false,
                "name": "tokens_bought",
                "type": "uint256"
            }
        ],
        "name": "TokenExchangeUnderlying",
        "type": "event"
    },
    {
        "anonymous": false,
        "inputs": [
            {
                "indexed": true,
                "name": "provider",
                "type": "address"
            },
            {
                "indexed": false,
                "name": "token_amounts",
                "type": "uint256[4]"
            },
            {
                "indexed": false,
                "name": "fees",
                "type": "uint256[4]"
            },
            {
                "indexed": false,
                "name": "invariant",
                "type": "uint256"
            },
            {
                "indexed": false,
                "name": "token_supply",
                "type": "uint256"
            }
        ],
        "name": "AddLiquidity",
        "type": "event"
    },
    {
        "anonymous": false,
        "inputs": [
            {
                "indexed": true,
                "name": "provider",
                "type": "address"
            },
            {
                "indexed": false,
                "name": "token_amounts",
                "type": "uint256[4]"
            },
            {
                "indexed": false,
                "name": "fees",
                "type": "uint256[4]"
            },
            {
                "indexed": false,
                "name": "token_supply",
                "type": "uint256"
            }
        ],
        "name": "RemoveLiquidity",
        "type": "event"
    },
    {
        "anonymous": false,
        "inputs": [
            {
                "indexed": true,
                "name": "provider",
                "type": "address"
            },
            {
                "indexed": false,
                "name": "token_amounts",
                "type": "uint256[4]"
            },
            {
                "indexed": false,
                "name": "fees",
                "type": "uint256[4]"
            },
            {
                "indexed": false,
                "name": "invariant",
                "type": "uint256"
            },
            {
                "indexed": false,
                "name": "token_supply",
                "type": "uint256"
            }
        ],
        "name": "RemoveLiquidityImbalance",
        "type": "event"
    },
    {
        "anonymous": false,
        "inputs": [
            {
                "indexed": true,
                "name": "deadline",
                "type": "uint256",
                "unit": "sec"
            },
            {
                "indexed": true,
                "name": "admin",
                "type": "address"
            }
        ],
        "name": "CommitNewAdmin",
        "type": "event"
    },
    {
        "anonymous": false,
        "inputs": [
            {
                "indexed": true,
                "name": "admin",
                "type": "address"
            }
        ],
        "name": "NewAdmin",
        "type": "event"
    },
    {
        "anonymous": false,
        "inputs": [
            {
                "indexed": true,
                "name": "deadline",
                "type": "uint256",
                "unit": "sec"
            },
            {
                "indexed": false,
                "name": "A",
                "type": "uint256"
            },
            {
                "indexed": false,
                "name": "fee",
                "type": "uint256"
            },
            {
                "indexed": false,
                "name": "admin_fee",
                "type": "uint256"
            }
        ],
        "name": "CommitNewParameters",
        "type": "event"
    },
    {
        "anonymous": false,
        "inputs": [
            {
                "indexed": false,
                "name": "A",
                "type": "uint256"
            },
            {
                "indexed": false,
                "name": "fee",
                "type": "uint256"
            },
            {
                "indexed": false,
                "name": "admin_fee",
                "type": "uint256"
            }
        ],
        "name": "NewParameters",
        "type": "event"
    },
    {
        "constant": false,
        "inputs": [
            {
                "name": "_coins",
                "type": "address[4]"
            },
            {
                "name": "_underlying_coins",
                "type": "address[4]"
            },
            {
                "name": "_pool_token",
                "type": "address"
            },
            {
                "name": "_A",
                "type": "uint256"
            },
            {
                "name": "_fee",
                "type": "uint256"
            }
        ],
        "outputs": [],
        "payable": false,
        "type": "constructor"
    },
    {
        "constant": true,
        "gas": 1570535,
        "inputs": [],
        "name": "get_virtual_price",
        "outputs": [
            {
                "name": "",
                "type": "uint256"
            }
        ],
        "payable": false,
        "type": "function"
    },
    {
        "constant": true,
        "gas": 6103471,
        "inputs": [
            {
                "name": "amounts",
                "type": "uint256[4]"
            },
            {
                "name": "deposit",
                "type": "bool"
            }
        ],
        "name": "calc_token_amount",
        "outputs": [
            {
                "name": "",
                "type": "uint256"
            }
        ],
        "payable": false,
        "type": "function"
    },
    {
        "constant": false,
        "gas": 9331701,
        "inputs": [
            {
                "name": "amounts",
                "type": "uint256[4]"
            },
            {
                "name": "min_mint_amount",
                "type": "uint256"
            }
        ],
        "name": "add_liquidity",
        "outputs": [],
        "payable": false,
        "type": "function"
    },
    {
        "constant": true,
        "gas": 3489637,
        "inputs": [
            {
                "name": "i",
                "type": "int128"
            },
            {
                "name": "j",
                "type": "int128"
            },
            {
                "name": "dx",
                "type": "uint256"
            }
        ],
        "name": "get_dy",
        "outputs": [
            {
                "name": "",
                "type": "uint256"
            }
        ],
        "payable": false,
        "type": "function"
    },
    {
        "constant": true,
        "gas": 3489467,
        "inputs": [
            {
                "name": "i",
                "type": "int128"
            },
            {
                "name": "j",
                "type": "int128"
            },
            {
                "name": "dx",
                "type": "uint256"
            }
        ],
        "name": "get_dy_underlying",
        "outputs": [
            {
                "name": "",
                "type": "uint256"
            }
        ],
        "payable": false,
        "type": "function"
    },
    {
        "constant": false,
        "gas": 7034253,
        "inputs": [
            {
                "name": "i",
                "type": "int128"
            },
            {
                "name": "j",
                "type": "int128"
            },
            {
                "name": "dx",
                "type": "uint256"
            },
            {
                "name": "min_dy",
                "type": "uint256"
            }
        ],
        "name": "exchange",
        "outputs": [],
        "payable": false,
        "type": "function"
    },
    {
        "constant": false,
        "gas": 7050488,
        "inputs": [
            {
                "name": "i",
                "type": "int128"
            },
            {
                "name": "j",
                "type": "int128"
            },
            {
                "name": "dx",
                "type": "uint256"
            },
            {
                "name": "min_dy",
                "type": "uint256"
            }
        ],
        "name": "exchange_underlying",
        "outputs": [],
        "payable": false,
        "type": "function"
    },
    {
        "constant": false,
        "gas": 241191,
        "inputs": [
            {
                "name": "_amount",
                "type": "uint256"
            },
            {
                "name": "min_amounts",
                "type": "uint256[4]"
            }
        ],
        "name": "remove_liquidity",
        "outputs": [],
        "payable": false,
        "type": "function"
    },
    {
        "constant": false,
        "gas": 9330864,
        "inputs": [
            {
                "name": "amounts",
                "type": "uint256[4]"
            },
            {
                "name": "max_burn_amount",
                "type": "uint256"
            }
        ],
        "name": "remove_liquidity_imbalance",
        "outputs": [],
        "payable": false,
        "type": "function"
    },
    {
        "constant": false,
        "gas": 146045,
        "inputs": [
            {
                "name": "amplification",
                "type": "uint256"
            },
            {
                "name": "new_fee",
                "type": "uint256"
            },
            {
                "name": "new_admin_fee",
                "type": "uint256"
            }
        ],
        "name": "commit_new_parameters",
        "outputs": [],
        "payable": false,
        "type": "function"
    },
    {
        "constant": false,
        "gas": 133452,
        "inputs": [],
        "name": "apply_new_parameters",
        "outputs": [],
        "payable": false,
        "type": "function"
    },
    {
        "constant": false,
        "gas": 21775,
        "inputs": [],
        "name": "revert_new_parameters",
        "outputs": [],
        "payable": false,
        "type": "function"
    },
    {
        "constant": false,
        "gas": 74452,
        "inputs": [
            {
                "name": "_owner",
                "type": "address"
            }
        ],
        "name": "commit_transfer_ownership",
        "outputs": [],
        "payable": false,
        "type": "function"
    },
    {
        "constant": false,
        "gas": 60508,
        "inputs": [],
        "name": "apply_transfer_ownership",
        "outputs": [],
        "payable": false,
        "type": "function"
    },
    {
        "constant": false,
        "gas": 21865,
        "inputs": [],
        "name": "revert_transfer_ownership",
        "outputs": [],
        "payable": false,
        "type": "function"
    },
    {
        "constant": false,
        "gas": 23448,
        "inputs": [],
        "name": "withdraw_admin_fees",
        "outputs": [],
        "payable": false,
        "type": "function"
    },
    {
        "constant": false,
        "gas": 37818,
        "inputs": [],
        "name": "kill_me",
        "outputs": [],
        "payable": false,
        "type": "function"
    },
    {
        "constant": false,
        "gas": 21955,
        "inputs": [],
        "name": "unkill_me",
        "outputs": [],
        "payable": false,
        "type": "function"
    },
    {
        "constant": true,
        "gas": 2130,
        "inputs": [
            {
                "name": "arg0",
                "type": "int128"
            }
        ],
        "name": "coins",
        "outputs": [
            {
                "name": "",
                "type": "address"
            }
        ],
        "payable": false,
        "type": "function"
    },
    {
        "constant": true,
        "gas": 2160,
        "inputs": [
            {
                "name": "arg0",
                "type": "int128"
            }
        ],
        "name": "underlying_coins",
        "outputs": [
            {
                "name": "",
                "type": "address"
            }
        ],
        "payable": false,
        "type": "function"
    },
    {
        "constant": true,
        "gas": 2190,
        "inputs": [
            {
                "name": "arg0",
                "type": "int128"
            }
        ],
        "name": "balances",
        "outputs": [
            {
                "name": "",
                "type": "uint256"
            }
        ],
        "payable": false,
        "type": "function"
    },
    {
        "constant": true,
        "gas": 2021,
        "inputs": [],
        "name": "A",
        "outputs": [
            {
                "name": "",
                "type": "uint256"
            }
        ],
        "payable": false,
        "type": "function"
    },
    {
        "constant": true,
        "gas": 2051,
        "inputs": [],
        "name": "fee",
        "outputs": [
            {
                "name": "",
                "type": "uint256"
            }
        ],
        "payable": false,
        "type": "function"
    },
    {
        "constant": true,
        "gas": 2081,
        "inputs": [],
        "name": "admin_fee",
        "outputs": [
            {
                "name": "",
                "type": "uint256"
            }
        ],
        "payable": false,
        "type": "function"
    },
    {
        "constant": true,
        "gas": 2111,
        "inputs": [],
        "name": "owner",
        "outputs": [
            {
                "name": "",
                "type": "address"
            }
        ],
        "payable": false,
        "type": "function"
    },
    {
        "constant": true,
        "gas": 2141,
        "inputs": [],
        "name": "admin_actions_deadline",
        "outputs": [
            {
                "name": "",
                "type": "uint256",
                "unit": "sec"
            }
        ],
        "payable": false,
        "type": "function"
    },
    {
        "constant": true,
        "gas": 2171,
        "inputs": [],
        "name": "transfer_ownership_deadline",
        "outputs": [
            {
                "name": "",
                "type": "uint256",
                "unit": "sec"
            }
        ],
        "payable": false,
        "type": "function"
    },
    {
        "constant": true,
        "gas": 2201,
        "inputs": [],
        "name": "future_A",
        "outputs": [
            {
                "name": "",
                "type": "uint256"
            }
        ],
        "payable": false,
        "type": "function"
    },
    {
        "constant": true,
        "gas": 2231,
        "inputs": [],
        "name": "future_fee",
        "outputs": [
            {
                "name": "",
                "type": "uint256"
            }
        ],
        "payable": false,
        "type": "function"
    },
    {
        "constant": true,
        "gas": 2261,
        "inputs": [],
        "name": "future_admin_fee",
        "outputs": [
            {
                "name": "",
                "type": "uint256"
            }
        ],
        "payable": false,
        "type": "function"
    },
    {
        "constant": true,
        "gas": 2291,
        "inputs": [],
        "name": "future_owner",
        "outputs": [
            {
                "name": "",
                "type": "address"
            }
        ],
        "payable": false,
        "type": "function"
    }
]
