How to let Hex to Tx Obj?

I get a hex string, how to use this string get tx?
Like this ‘tx_+K8LAfhCuEAuz7AhZeyRIyOTWioSTKa0r09AC+5CyyQLox/52ujpExACu6fsOG6Rc1c/NSbTk9C9rdbyg5bS4d0Qv8dEEVkHuGf4ZQwBoQEyZ6XOfch1MJcYcHlyU5sa18KZa0C2npfQfC2oXtArLqEBCOaI3wc3X+c2lK3QdWUm+CNaA2PjxWyse9FKixwc4DKKAbd0oA1nL7nAAIYSMJzlQAAACIphZV9tYWlubmV0cubJjw==’
And I try to broadcast it and get result is ‘Invalid tx’, Could you tell me why?
Best show me Java code Or python Code. please

I don’t know Python or Java, so I can’t help you there.

The TX is incorrectly signed:

(aeternity_ct@localhost)13> {_, SerBin} = aeser_api_encoder:decode(<<"tx_+K8LAfhCuEAuz7AhZeyRIyOTWioSTKa0r09AC+5CyyQLox/52ujpExACu6fsOG6Rc1c/NSbTk9C9rdbyg5bS4d0Qv8dEEVkHuGf4ZQwBoQEyZ6XOfch1MJcYcHlyU5sa18KZa0C2npfQfC2oXtArLqEBCOaI3wc3X+c2lK3QdWUm+CNaA2PjxWyse9FKixwc4DKKAbd0oA1nL7nAAIYSMJzlQAAACIphZV9tYWlubmV0cubJjw==">>).
{transaction,<<248,175,11,1,248,66,184,64,46,207,176,33,
               101,236,145,35,35,147,90,42,18,76,166,180,
               175,79,64,...>>}
(aeternity_ct@localhost)14> STx = aetx_sign:deserialize_from_binary(SerBin).                                                                                                                                                                                        {signed_tx,{aetx,spend_tx,aec_spend_tx,103,                   
                 #spend_tx{sender_id = {id,account,
                                           <<50,103,165,206,125,200,117,48,151,24,112,121,114,83,
                                             155,26,215,...>>},
                           recipient_id = {id,account,
                                              <<8,230,136,223,7,55,95,231,54,148,173,208,117,101,38,
                                                248,...>>},
                           amount = 8106524380000000000000,fee = 20000000000000,
                           ttl = 0,nonce = 8,payload = <<"ae_mainnet">>}},
           [<<46,207,176,33,101,236,145,35,35,147,90,42,18,76,166,
              180,175,79,64,11,238,66,203,36,11,...>>]}
(aeternity_ct@localhost)15> aetx_sign:verify(STx, not_used, 4).     
{error,signature_check_failed}                                

Hello @dean, welcome to the Forum :slight_smile: Please see the reply above :point_up:

how did you create the TX? did you use an SDK to create this TX?

@mitch_lbw and I could help out with Java.