TRON TronGrid.io (USDT TRC-20)
This article describes how to use a TronGrid account to send USD₮ over TRON using CAS.
When using the TronGrid API with CAS, you’re granting CAS access to your TronGrid account to transmit your tokens (in this case: USD₮) over the TRON network.
In this article, we’re going to:
create a TronLink Hot Wallet for TRON,
add the wallet details to TronGrid,
add those details to CAS, and
test that CAS can submit USDT transactions to TRON.
Tether (USD₮)
Tether is the cryptocurrency token “USD₮”. Tether can be exchanged using a number of different networks. Supported (2024) networks include Algorand, Avalanche, Bitcoin, Ethereum, EOS, Kava, Polka, Polygon, Solana, TRON and Tezos. TRON is just one of those networks. Using CAS, USD₮ may be sent via either TRON or ETH (the ETH method of USD₮ transmission is called ERC-20).
TRON
TRON is a cryptocurrency Proof-of-Stake blockchain (similar to Ethereum). TRON uses its own version of USD₮ transmission called TRC-20. This Crypto Setting (TRC-20) is incompatible with ERC-20, and the two are in no way interchangeable - in the same way that BTC and LTC are incompatible.
The native coin to the TRON blockchain is TRX.
TRX is spent/burned (or staked) as a fee for token transmission (called energy and bandwidth).
Not all wallets or exchanges support TRON/TRX and TRC-20 tokens.
USD₮ cannot be sent using TRON to those wallets/exchanges that do not support TRON/TRX.
The Crypto Setting described in this article ONLY facilitates USD₮ using the TRC-20 protocol on TRON.
https://developers.tron.network/docs/faq
TronGrid.io
TronGrid is a communications platform that enables you to submit USD₮ (and other) transactions to the TRON network with little more than a TronGrid API key and your TRON private key.
The free account is sufficient for most Operators in CAS.
Part 1: TronLink wallet
You’ll need a TRON Private Key for the CAS Crypto Setting parameter. You may use any TRON wallet to generate that Private Key, but TronGrid recommends TronLink. The instructions in this part will help you install the TronLink Chrome wallet, and locate the Private Key in that wallet.
TronLink is not required, but we’re demonstrating this wallet since it is preferred by TronGrid.
As of publication, TronGrid has no way of manually linking another wallet. That doesn’t mean you need TronLink for sending USD₮ over TRON via CAS, it just means that you cannot link any other wallet to TronGrid. You will need a TRON wallet at some point in any event.
Once setup, TronLink is not used in your day-to-day operations (for CAS).
TronLink is required to obtain a TRON Wallet keyset. Once you have those, and TronGrid has been linked to that wallet, the extension itself is no longer a critical component.
TronLink: https://chromewebstore.google.com/detail/tronlink/ibnejdfjmmkpcnlpebklmnkoeoihofec
Install the TronLink wallet Chrome extension:
Install the extension,
enable the requested default permissions,
restart Chrome,
open the TronLink extension, and
click “Create Wallet”.
Create secure credentials:
Name the Wallet something relevant,
create a memorable (yet complicated/secure) password, then
again click “Create Wallet”.
Backup your wallet:
Upon success, you should backup your wallet mnemonics to prevent catastrophe.
Click “Back Up Wallet”.
While not absolutely required, backing up now will make the remaining steps smoother. The app will hound you until you backup, and that’s not a bad policy.
Secure the mnemonics. Anyone finding them can recover your wallet - and drain your funds.
Export your TRON Account:
Click on the TRX dot sandwich to bring up a menu, and
click on “Export Account” to bring up the “Private Key” option.
If you didn’t backup yet, you’ll be reminded (again) now.
Export the wallet’s Private Key:
You’ll be required to enter your password.
Save the Private Key:
Save the private key somewhere safe, such as in a password manager app (e.g. KeePass).
This key will be required as the Crypto Setting parameter
privatekey
.
Part 2: TronGrid
TronGrid provides CAS with a method of posting TRON transactions on the TRON network using your TRON private key (generated by TronLink) and authorized by your TronGrid API Key.
1. Create an account on TronGrid.io
Confirmation usually occurs within a day or two, rarely longer than a week.
A free account will suffice for initial setup and testing.
After you’re confirmed, log in and move on to step 2.
2. Login.
You should be presented with an opportunity to link TronGrid with the recently created TronLink wallet. You can do so, or skip it. You may use TronLink as your wallet’s manual interface - and using the TronGrid recommended wallet may be useful - but it is not required to move forward in the article.
3. View your API Keys.
Using either link, navigate to: https://www.trongrid.io/dashboard/keys
4. Create a new API Key.
Name the key something relevant, e.g. “CAS USD₮ BUY Crypto Setting”.
Click “Create API Key” to: create the key.
5. View the API Key.
Click “Check” on the relevant line to view the newly created API Key.
6. Save the API Key.
The API Key will be viewable on this page.
Example API key:
64bee9b8-0873-6940-b1ce-762092ef5efe
Save the API Key for future reference. You can review it at any time.
The API Key found here is the
apikey
parameter required by CAS for the Crypto Setting.
Part 3: Configure the Crypto Setting.
Assemble the required parameters.
The Crypto Setting parameters are: apikey:privatekey:feeLimit
The
apikey
parameter from the previous example in Part 2 is:64bee9b8-0873-6940-b1ce-762092ef5efe
The
privatekey
parameter from Part 1 is (example):63abcdef1234567890abcdef987654321fedcba
The
feeLimit
is optional and defaults to 30 (TRX). Tokens (like USD₮) will typically “burn” a rather fixed amount of TRX for every transmission. In my recent testing, it cost ~28 TRX per transaction.The feeLimit is described in detail here: https://developers.tron.network/docs/set-feelimit
So in this example, using the above info, our complete (required) "Parameters" should look like this:
64bee9b8-0873-6940-b1ce-762092ef5efe:63abcdef1234567890abcdef987654321fedcba
Select the “Tron TRC20 Trident wallet - USDT” Hot Wallet:
Insert the proper Parameters where specified.
Do not include the optional parameter (
feeLimit
) until the BUY test has passed.
You should copy & paste the complete parameter string in a single operation!
You can’t append/add the parameters separately - each paste overwrites the previous contents completely.
Save the Crypto Setting!
Part 4: Test it (you’re done):
Test your settings before deploying them.
Save your setting,
return to the same Crypto Setting,
run the test(s).
If the "Test Hot Wallet Buy" is successful, you've configured the TronGrid settings properly!
If you encounter an error during live testing, please verify that you have sufficient TRX in your wallet.
FAILED TRANSACTIONS WILL STILL BURN TRX.
Transfers typically post within seconds, and will appear in the target wallet within a couple of minutes.
A typical USD₮ BUY transaction will cost up to 30 TRX - whether it succeeds or not.
Additional references:
TRON: https://developers.tron.network/reference/full-node-api-overview
TronGrid KB: https://trongrid.zendesk.com/hc/en-us/articles/900007033343-Get-started
TronGrid Support: Discord - TRON Developers & SRs
TRONLink website: https://www.tronlink.org/
TRON Explorer: https://tronscan.org
Copyright © 2020-2024 General Bytes USA LLC