1

I am facing a challenge with stellar APIs while transferring funds from one wallet to another. The API fails with status 400 and the result code is 'op_no_trust'. I can verify that the destination wallet has trustline enabled. I can't seem to understand why I am getting this error.

Stack trace -

Traceback (most recent call last):   File "./apis.py", line 188, in transfer_crypto
    response = builder.submit()   File "/home/ubuntu/glitzkoin-blockchain-apis/venv/lib/python3.7/site-packages/stellar_base/builder.py", line 784, in submit
    return self.horizon.submit(self.gen_xdr())   File "/home/ubuntu/glitzkoin-blockchain-apis/venv/lib/python3.7/site-packages/stellar_base/horizon.py", line 142, in submit
    return check_horizon_reply(reply.json())   File "/home/ubuntu/glitzkoin-blockchain-apis/venv/lib/python3.7/site-packages/stellar_base/horizon.py", line 917, in check_horizon_reply
    raise HorizonError('Invalid horizon reply: [{}] {}'.format(reply['status'], reply), reply['status']) stellar_base.exceptions.HorizonError: Invalid horizon reply: [400] {'type': 'https://stellar.org/horizon-errors/transaction_failed', 'title': 'Transaction Failed', 'status': 400, 'detail': 'The transaction failed when submitted to the stellar network. The `extras.result_codes` field on this response contains further details. Descriptions of each code can be found at: https://developers.stellar.org/api/errors/http-status-codes/horizon-specific/transaction-failed/', 'extras': {'envelope_xdr': 'AAAAADqRnBEyRDLb2wdAiIjLxGwDChdQ7kyAsCMXK5pnRWhEAAAAZAI4iNsAAC6QAAAAAAAAAAAAAAABAAAAAAAAAAEAAAAA+z2lv/0NsRsYLgGr7I4GYtSuRBA8zm0Yr7mwbwuthtcAAAABR1ROAAAAAAAiVgDwZxI0d7JWimI9bs0+GZHDlvHYNnurIQRTdq6PMAAAAAAExLQAAAAAAAAAAAFnRWhEAAAAQNcYSU8baXLTIhNuheBQ/U0G2YXb6YFoeVOUR15UDkEt4zWJhZ2JMEF7YjBgvoXuaiUiw440QgSPb4N0rNz6Vwc=', 'result_codes': {'transaction': 'tx_failed', 'operations': ['op_no_trust']}, 'result_xdr': 'AAAAAAAAAGT/////AAAAAQAAAAAAAAAB////+gAAAAA='}}

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Browse other questions tagged or ask your own question.