I was trying to create a python program to convert ETH to BTC. I was using the command :
client.transfer_money("ETH Account ID ", to="BTC Account ID", amount="0.1", currency=:"ETH")
I had obtained the account IDs using the command :
client.get_accounts()
And copy pasted the IDs onto my transfer command. However i get this error :
~/opt/anaconda3/envs/Coinbase/lib/python3.8/site-packages/coinbase/wallet/client.py in transfer_money(self, account_id, **params)
338 params['type'] = 'transfer'
339 response = self._post('v2', 'accounts', account_id, 'transactions', data=params)
--> 340 return self._make_api_object(response, Transaction)
341
342 def request_money(self, account_id, **params):
~/opt/anaconda3/envs/Coinbase/lib/python3.8/site-packages/coinbase/wallet/client.py in _make_api_object(self, response, model_type)
143 # All valid responses have a "data" key.
144 if data is None:
--> 145 raise build_api_error(response, blob)
146 # Warn the user about each warning that was returned.
147 warnings_data = blob.get('warnings', None)
APIError: APIError(id=):
Would someone be able to isolate what this error is ?
account.transfer_money()
method instead of theclient.transfer_money()
? – Unchartedaccount.transfer_money()
method produces the same error as theclient.transfer_money()
method – Campion