Example #1
0
def callbtcrpc(node_id,
               method,
               params=[],
               wallet=None,
               base_rpc_port=BASE_BTC_RPC_PORT + PORT_OFS):
    auth = 'test_btc_{0}:test_btc_pwd_{0}'.format(node_id)
    return callrpc(base_rpc_port + node_id, auth, method, params, wallet)
Example #2
0
def callnoderpc(node_id,
                method,
                params=[],
                wallet=None,
                base_rpc_port=BASE_RPC_PORT):
    auth = 'test{0}:test_pass{0}'.format(node_id)
    return callrpc(base_rpc_port + node_id, auth, method, params, wallet)
Example #3
0
 def rpc_func(method, params=None, wallet=None):
     nonlocal node_id, auth
     return callrpc(base_rpc_port + node_id, auth, method, params, wallet)