iexbase / tron-api

A PHP API for interacting with Tron (TRX)
https://iexbase.github.io/tron-api/
MIT License
407 stars 288 forks source link

how to decode raw_data_hex? #135

Open kendol07 opened 2 years ago

kendol07 commented 2 years ago

I need to get the address where the amount of usdt was sent and the amount of usdt sent

array ( 'ret' => array ( 0 => array ( 'contractRet' => 'SUCCESS', ), ), 'signature' => array ( 0 => '8f5f16f37dcb1aa1c7e7c1a8a1c5ab3423cf8fbc2b47846379ff929345443ea523c83af5a676ed6751e6a702336ab9a7da392524e032bcf22d5d7ede9be9f34d01', ), 'txID' => '2e3dcf9eb604413f247426f4efb50a475ac6544d8174ac44f2227a396641a8fd', 'raw_data' => array ( 'contract' => array ( 0 => array ( 'parameter' => array ( 'value' => array ( 'data' => 'a9059cbb0000000000000000000000411809c964e7a4159f927303b214f53bf28a9f17040000000000000000000000000000000000000000000000000000000078d55f0c', 'owner_address' => '410b48984414cc0c6a8e599fb6e3bc11e599de2e24', 'contract_address' => '41a614f803b6fd780986a42c78ec9c7f77e6ded13c', ), 'type_url' => 'type.googleapis.com/protocol.TriggerSmartContract', ), 'type' => 'TriggerSmartContract', ), ), 'ref_block_bytes' => 'ed16', 'ref_block_hash' => '8e48a51af51b98ae', 'expiration' => 1659536029991, 'fee_limit' => 10000000, 'timestamp' => 1659535968000, ), 'raw_data_hex' => '0a02ed1622088e48a51af51b98ae40a7f2b8a0a6305aae01081f12a9010a31747970652e676f6f676c65617069732e636f6d2f70726f746f636f6c2e54726967676572536d617274436f6e747261637412740a15410b48984414cc0c6a8e599fb6e3bc11e599de2e24121541a614f803b6fd780986a42c78ec9c7f77e6ded13c2244a9059cbb0000000000000000000000411809c964e7a4159f927303b214f53bf28a9f17040000000000000000000000000000000000000000000000000000000078d55f0c70808eb5a0a630900180ade204', )