Hello! I am continue TON blockchain parsing journey and have another question)

I am querying transactions for address (UQDqDHsF9FNi-_GqodxGvgcnOwFcfZXP007OQBbNjIllPVFJ):
https://toncenter.com/api/v2/getTransactions?address=UQDqDHsF9FNi-_GqodxGvgcnOwFcfZXP007OQBbNjIllPVFJ&limit=10&to_lt=0&archival=true

Got first returned transaction unixtime (1639393650) and searching for a block seqno in the basechain:
https://toncenter.com/api/v2/lookupBlock?workchain=0&shard=-9223372036854775808&unixtime=1639393650

Than I found my initial transaction with the same lt and hash as fifth in the block:
https://toncenter.com/api/v2/getBlockTransactions?workchain=0&shard=-9223372036854775808&seqno=21694181

But initial transaction address (base64 - UQDqDHsF9FNi-_GqodxGvgcnOwFcfZXP007OQBbNjIllPVFJ) is not the same as the returned one (hex - 0:ea0c7b05f45362fbf1aaa1dc46be07273b015c7d95cfd34ece4016cd8c89653d). Base64url to hex converting of the first transaction gives me 5100ea0c7b05f45362fbf1aaa1dc46be07273b015c7d95cfd34ece4016cd8c89653d5149, which is similar to returned one, but there are additional 2 bytes of data in the beginning and in the end of the address. Moreover, combination of hex to Base64 encoding of the returned address with /getTransactions method returns me "error": "Incorrect address" and absolutely other address (6gx7BfRTYvvxqqHcRr4HJzsBXH2Vz9NOzkAWzYyJZT0=). I thought that Base64 wallet address string equality check is enough, but it seems that I am wrong. Can you explain me such behaviour, please?

Apr 11, 2022, 3:44 PM
The addresses that you've provided are the same.
Apr 11, 2022, 3:50 PM
We needed FAQ with top10 questions :))
Apr 11, 2022, 3:51 PM
I'm already working on it :)
Apr 11, 2022, 3:51 PM
All devs must know that 1 raw address has 4 base64 forms
Also 1 raw address is valid with / without leading zeroes
Apr 11, 2022, 3:52 PM
Actually eight :)
Apr 11, 2022, 3:53 PM
OK, bounce / not bounce , b64 / b64url
Other?
Apr 11, 2022, 3:53 PM
These are all possible variants of the same address ^
test-only flag :)
Apr 11, 2022, 3:54 PM
Ah))
Apr 11, 2022, 3:54 PM
Thank you for you answers)
Apr 11, 2022, 4:01 PM
Each address in TON could be represented in nine different formats.
Jul 17, 2022, 12:50 PM

© 2024 Draquery.com All rights reserved.