Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[TON]: Add functions to help to generate Jetton user address #3922

Merged
merged 4 commits into from
Jul 1, 2024

Conversation

satoshiotomakan
Copy link
Collaborator

@satoshiotomakan satoshiotomakan commented Jun 29, 2024

Description

Add functions to help to generate Jetton user address from the main TON address:

  1. TWTONAddressConverterToBoc - Converts a TON user address into a Bag of Cells (BoC) with a single root Cell. Used in get_wallet_address RPC call.
  2. TWTONAddressConverterFromBoc - Parses a TON address from a Bag of Cells (BoC) with a single root Cell. Used to parse a Jetton user address received on get_wallet_address RPC.
    NOTE it returns a non-bounceable U address.

Doc: https://docs.ton.org/develop/dapps/asset-processing/jettons#retrieving-jetton-wallet-addresses-for-a-given-user

How to test

Run Rust, C++, Android, iOS tests

Types of changes

Checklist

  • Create pull request as draft initially, unless its complete.
  • Add tests to cover changes as needed.
  • Update documentation as needed.
  • If there is a related Issue, mention it in the description.

If you're adding a new blockchain

  • I have read the guidelines for adding a new blockchain.

@satoshiotomakan satoshiotomakan marked this pull request as ready for review June 30, 2024 11:54
Copy link

github-actions bot commented Jun 30, 2024

Binary size comparison

➡️ aarch64-apple-ios:

- 11.73 MB
+ 11.75 MB 	 +19 KB

➡️ aarch64-apple-ios-sim:

- 11.72 MB
+ 11.74 MB 	 +19 KB

➡️ aarch64-linux-android:

- 15.22 MB
+ 15.25 MB 	 +31 KB

➡️ armv7-linux-androideabi:

- 12.72 MB
+ 12.74 MB 	 +25 KB

➡️ wasm32-unknown-emscripten:

- 10.55 MB
+ 10.57 MB 	 +17 KB

@satoshiotomakan satoshiotomakan merged commit feafc27 into master Jul 1, 2024
13 checks passed
@satoshiotomakan satoshiotomakan deleted the s/ton-jetton-address branch July 1, 2024 09:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants