<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: UsdtPull</title>
    <description>The latest articles on DEV Community by UsdtPull (@usdtpull_com).</description>
    <link>https://dev.to/usdtpull_com</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4240317%2Fa9c11433-2cf4-4c56-ad6a-b150902409a1.png</url>
      <title>DEV Community: UsdtPull</title>
      <link>https://dev.to/usdtpull_com</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/usdtpull_com"/>
    <language>en</language>
    <item>
      <title>Validating TRON Addresses in Node.js: Checksum, Node API and the On-Chain Check</title>
      <dc:creator>UsdtPull</dc:creator>
      <pubDate>Thu, 03 Dec 2026 15:37:34 +0000</pubDate>
      <link>https://dev.to/usdtpull_com/validating-tron-addresses-in-nodejs-checksum-node-api-and-the-on-chain-check-4ik0</link>
      <guid>https://dev.to/usdtpull_com/validating-tron-addresses-in-nodejs-checksum-node-api-and-the-on-chain-check-4ik0</guid>
      <description>&lt;p&gt;If you accept TRON addresses from users (a withdrawal form, a payout config, an admin panel), a regex like &lt;code&gt;^T[1-9A-HJ-NP-Za-km-z]{33}$&lt;/code&gt; is the first thing everyone writes. It is also the least useful part. A TRON address carries its own checksum, and the network will tell you things about it that no regex can: whether it is a contract, and whether it exists on chain at all.&lt;/p&gt;

&lt;p&gt;This post builds the check in three layers, each one run against the public TronGrid node on Dec 2, 2026:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;offline: Base58Check decoding with nothing but &lt;code&gt;node:crypto&lt;/code&gt;;&lt;/li&gt;
&lt;li&gt;node-side: &lt;code&gt;wallet/validateaddress&lt;/code&gt;;&lt;/li&gt;
&lt;li&gt;on-chain: &lt;code&gt;wallet/getaccount&lt;/code&gt;, to tell a person's wallet from a contract or from an address nobody has ever used.&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  What is inside the 34 characters
&lt;/h2&gt;

&lt;p&gt;Decode a TRON address from Base58 and you get exactly 25 bytes:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;41                                          1 byte   version prefix, always 0x41
a614f803b6fd780986a42c78ec9c7f77e6ded13c    20 bytes account ID
xxxxxxxx                                    4 bytes  checksum
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The checksum is the first 4 bytes of SHA-256 applied twice to the first 21 bytes. The 20-byte account ID is derived from the public key (the &lt;a href="https://developers.tron.network/docs/account" rel="noopener noreferrer"&gt;accounts page&lt;/a&gt; has the details), and the example above is the USDT contract, &lt;code&gt;TR7NHqjeKQxGTCi8q8ZY4pL8otSzgjLj6t&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;Because every address starts with the byte &lt;code&gt;0x41&lt;/code&gt;, the Base58 text always starts with &lt;code&gt;T&lt;/code&gt;. Running the encoder over the two extremes shows the whole range: 20 zero bytes encode to &lt;code&gt;T9yD14Nj9j7xAB4dbGeiX9h8unkKHxuWwb&lt;/code&gt;, 20 bytes of &lt;code&gt;ff&lt;/code&gt; to &lt;code&gt;TZJozAg1ruapycCicgz31GxvYJ1FraLjZa&lt;/code&gt;. And because Base58 treats &lt;code&gt;a&lt;/code&gt; and &lt;code&gt;A&lt;/code&gt; as different digits, addresses are case-sensitive: lowercasing one destroys it.&lt;/p&gt;

&lt;p&gt;You will meet the same address in three spellings. Node APIs return &lt;code&gt;41...&lt;/code&gt; hex unless you pass &lt;code&gt;visible: true&lt;/code&gt;. Event logs and ABI parameters carry only the 20 bytes, left-padded to 32. Users see Base58. Store at least the hex next to the Base58 form; matching logs against your records gets much simpler.&lt;/p&gt;

&lt;h2&gt;
  
  
  Layer 1: offline, with Node built-ins
&lt;/h2&gt;

&lt;p&gt;SHA-256 is all the checksum needs, so there is no reason to pull a dependency in just for this. The function below returns &lt;code&gt;null&lt;/code&gt; for a good address and a short reason otherwise, which is handy for form errors. Tested on Node.js 22.23.2:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="c1"&gt;// Node 18+ built-ins only: offline TRON address check and hex &amp;lt;-&amp;gt; Base58 conversion&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="n"&gt;createHash&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nb"&gt;require&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s1"&gt;'node:crypto'&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="no"&gt;B58&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="s1"&gt;'123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="n"&gt;checksum&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;buf&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt;
  &lt;span class="nf"&gt;createHash&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s1"&gt;'sha256'&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;update&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nf"&gt;createHash&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s1"&gt;'sha256'&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;update&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;buf&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;digest&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;digest&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;subarray&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="mi"&gt;4&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;fromBase58&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;text&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="n"&gt;n&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;0n&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="n"&gt;ch&lt;/span&gt; &lt;span class="k"&gt;of&lt;/span&gt; &lt;span class="n"&gt;text&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="n"&gt;digit&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="no"&gt;B58&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;indexOf&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;ch&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
    &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;digit&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="kc"&gt;null&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;                       &lt;span class="c1"&gt;// 0, O, I, l and anything non-Base58&lt;/span&gt;
    &lt;span class="n"&gt;n&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;n&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt; &lt;span class="mi"&gt;58n&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="nc"&gt;BigInt&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;digit&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="n"&gt;hex&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;n&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;toString&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;16&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="n"&gt;hex&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;length&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&lt;/span&gt; &lt;span class="mi"&gt;50&lt;/span&gt; &lt;span class="o"&gt;?&lt;/span&gt; &lt;span class="kc"&gt;null&lt;/span&gt; &lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nc"&gt;Buffer&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="k"&gt;from&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;hex&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;padStart&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;50&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="s1"&gt;'0'&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="s1"&gt;'hex'&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;toBase58&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;hex21&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;                            &lt;span class="c1"&gt;// '41' + 40 hex chars -&amp;gt; T...&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="n"&gt;payload&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nc"&gt;Buffer&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="k"&gt;from&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;hex21&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="s1"&gt;'hex'&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="n"&gt;n&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nc"&gt;BigInt&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s1"&gt;'0x'&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="nc"&gt;Buffer&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;concat&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="n"&gt;payload&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nf"&gt;checksum&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;payload&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;toString&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s1"&gt;'hex'&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="n"&gt;out&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="s1"&gt;''&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="k"&gt;while&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;n&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&lt;/span&gt; &lt;span class="mi"&gt;0n&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="n"&gt;out&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="no"&gt;B58&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nb"&gt;Number&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;n&lt;/span&gt; &lt;span class="o"&gt;%&lt;/span&gt; &lt;span class="mi"&gt;58n&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="n"&gt;out&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="n"&gt;n&lt;/span&gt; &lt;span class="o"&gt;/=&lt;/span&gt; &lt;span class="mi"&gt;58n&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="n"&gt;out&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="c1"&gt;// returns null when the address is fine, otherwise a reason you can show to the user&lt;/span&gt;
&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;tronAddressError&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;input&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;input&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;length&lt;/span&gt; &lt;span class="o"&gt;!==&lt;/span&gt; &lt;span class="mi"&gt;34&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="s1"&gt;'length'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;input&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;!==&lt;/span&gt; &lt;span class="s1"&gt;'T'&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="s1"&gt;'prefix'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="n"&gt;bytes&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;fromBase58&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;input&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="o"&gt;!&lt;/span&gt;&lt;span class="n"&gt;bytes&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="s1"&gt;'encoding'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;bytes&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;!==&lt;/span&gt; &lt;span class="mh"&gt;0x41&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="s1"&gt;'version byte'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="o"&gt;!&lt;/span&gt;&lt;span class="nf"&gt;checksum&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;bytes&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;subarray&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="mi"&gt;21&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;equals&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;bytes&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;subarray&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;21&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="s1"&gt;'checksum'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="kc"&gt;null&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="kd"&gt;module&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;exports&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="n"&gt;tronAddressError&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;fromBase58&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;toBase58&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;What it says about a few inputs:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Input&lt;/th&gt;
&lt;th&gt;Result&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;TR7NHqjeKQxGTCi8q8ZY4pL8otSzgjLj6t&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;null&lt;/code&gt; (valid)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;same, last &lt;code&gt;t&lt;/code&gt; → &lt;code&gt;T&lt;/code&gt;
&lt;/td&gt;
&lt;td&gt;&lt;code&gt;checksum&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;same, last character dropped&lt;/td&gt;
&lt;td&gt;&lt;code&gt;length&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;same, &lt;code&gt;6&lt;/code&gt; → letter &lt;code&gt;O&lt;/code&gt;
&lt;/td&gt;
&lt;td&gt;&lt;code&gt;encoding&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;same, all lowercase&lt;/td&gt;
&lt;td&gt;&lt;code&gt;prefix&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;&lt;code&gt;toBase58('41a614f803b6fd780986a42c78ec9c7f77e6ded13c')&lt;/code&gt; gives back the USDT address, so the pair also works as a hex/Base58 converter without TronWeb.&lt;/p&gt;

&lt;h3&gt;
  
  
  Is the checksum actually worth it?
&lt;/h3&gt;

&lt;p&gt;We tested it the brute-force way. Starting from the USDT address, we replaced each character in positions 2 to 34 with every other Base58 digit: 1,881 one-character typos. The function rejected all 1,881: 1,847 on the checksum, 34 because the change pushed the first byte away from &lt;code&gt;0x41&lt;/code&gt;. Then we swapped every pair of neighbouring characters that differ: 32 variants, all rejected (31 on the checksum, 1 on the version byte).&lt;/p&gt;

&lt;p&gt;That matches the theory. A random string survives a 4-byte checksum about once in 2^32, roughly 4.3 billion tries. For a human typo, that is as good as certain.&lt;/p&gt;

&lt;h2&gt;
  
  
  Layer 2: ask the node
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://developers.tron.network/reference/validateaddress" rel="noopener noreferrer"&gt;&lt;code&gt;wallet/validateaddress&lt;/code&gt;&lt;/a&gt; does the same job server-side and accepts several encodings. Answers from TronGrid on Dec 2, 2026:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Input&lt;/th&gt;
&lt;th&gt;&lt;code&gt;result&lt;/code&gt;&lt;/th&gt;
&lt;th&gt;&lt;code&gt;message&lt;/code&gt;&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;TR7NHq...Lj6t&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;&lt;code&gt;true&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Base58check format&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;same with a broken checksum&lt;/td&gt;
&lt;td&gt;&lt;code&gt;false&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Invalid address&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;code&gt;41a614f8...d13c&lt;/code&gt; (42 hex chars)&lt;/td&gt;
&lt;td&gt;&lt;code&gt;true&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Hex string format&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;code&gt;0xa614f8...d13c&lt;/code&gt; (EVM style)&lt;/td&gt;
&lt;td&gt;&lt;code&gt;false&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Invalid address&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;code&gt;a614f8...d13c&lt;/code&gt; (40 hex, no &lt;code&gt;41&lt;/code&gt;)&lt;/td&gt;
&lt;td&gt;&lt;code&gt;false&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Length error&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;the USDT address lowercased&lt;/td&gt;
&lt;td&gt;&lt;code&gt;false&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Illegal character l at 22&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Two things to wire correctly. Every one of these came back with HTTP 200, so do not wait for an error status: branch on the &lt;code&gt;result&lt;/code&gt; boolean. And treat &lt;code&gt;message&lt;/code&gt; as a debugging hint, not a contract; the reference says it may be absent.&lt;/p&gt;

&lt;p&gt;Which layer to use? The offline one costs nothing and works without network access; the node call is fine when you already talk to a node. Neither one knows anything about the chain.&lt;/p&gt;

&lt;h2&gt;
  
  
  Layer 3: what actually lives at the address
&lt;/h2&gt;

&lt;p&gt;A valid checksum proves the string was copied intact. It does not prove that a person controls it. To show that, we generated an account ID from 20 random bytes and encoded it: &lt;code&gt;TFUzvufuC7qqUPwwjwYW6YnvGoMJcTAfTq&lt;/code&gt;. Both the offline check and &lt;code&gt;validateaddress&lt;/code&gt; accept it. Nobody has a key for it.&lt;/p&gt;

&lt;p&gt;&lt;code&gt;wallet/getaccount&lt;/code&gt; separates the cases that matter for a payout form. Here is a small classifier on top of the Layer 1 function:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="n"&gt;tronAddressError&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nb"&gt;require&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s1"&gt;'./validate.js'&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="k"&gt;async&lt;/span&gt; &lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;getAccount&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;address&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="n"&gt;res&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nb"&gt;fetch&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s1"&gt;'https://api.trongrid.io/wallet/getaccount'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="n"&gt;method&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s1"&gt;'POST'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="n"&gt;headers&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="s1"&gt;'content-type'&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s1"&gt;'application/json'&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="n"&gt;body&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;JSON&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;stringify&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="n"&gt;address&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;visible&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;true&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="n"&gt;res&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;json&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="c1"&gt;// what a payout form should know before it accepts a recipient&lt;/span&gt;
&lt;span class="k"&gt;async&lt;/span&gt; &lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;classifyRecipient&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;address&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="n"&gt;formatError&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;tronAddressError&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;address&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;trim&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;formatError&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="n"&gt;verdict&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s1"&gt;'reject'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;reason&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;formatError&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="n"&gt;account&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nf"&gt;getAccount&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;address&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;trim&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nb"&gt;Object&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;keys&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;account&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;length&lt;/span&gt; &lt;span class="o"&gt;===&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="n"&gt;verdict&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s1"&gt;'warn'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;reason&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s1"&gt;'not activated on chain'&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;account&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="kd"&gt;type&lt;/span&gt; &lt;span class="o"&gt;===&lt;/span&gt; &lt;span class="s1"&gt;'Contract'&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="n"&gt;verdict&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s1"&gt;'confirm'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;reason&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s1"&gt;'this is a smart contract'&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="n"&gt;verdict&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s1"&gt;'ok'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;createdAt&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="k"&gt;new&lt;/span&gt; &lt;span class="nb"&gt;Date&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;account&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;create_time&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;toISOString&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;slice&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="mi"&gt;10&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Run against four inputs, one request every few seconds (output condensed):&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;TR7NHqjeKQxGTCi8q8ZY4pL8otSzgjLj6t  confirm  this is a smart contract
T9yD14Nj9j7xAB4dbGeiX9h8unkKHxuWwb  ok       created 2018-12-30
TFUzvufuC7qqUPwwjwYW6YnvGoMJcTAfTq  warn     not activated on chain
TR7NHqjeKQxGTCi8q8ZY4pL8otSzgjLj6T  reject   checksum
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Why these branches:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;&lt;code&gt;{}&lt;/code&gt; means the account does not exist yet.&lt;/strong&gt; The address is valid but has never been activated. It can still receive funds, and the first TRX sent to it activates it: as of Oct 13, 2026 the sender pays 1.1 TRX for that. Show a warning rather than an error; how activation works and why USDT alone does not trigger it is in &lt;a href="https://usdtpull.com/en/blog/activate-tron-address/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=dec2026_free" rel="noopener noreferrer"&gt;our guide to activating a TRON address&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;&lt;code&gt;"type": "Contract"&lt;/code&gt; means code lives there.&lt;/strong&gt; Regular accounts simply omit &lt;code&gt;type&lt;/code&gt;, because the default value is not serialized. The most common way users hit this is by pasting the USDT token address itself as the recipient. If you need the ABI or the deployer, &lt;code&gt;wallet/getcontract&lt;/code&gt; returns them for contracts and &lt;code&gt;{}&lt;/code&gt; for everything else.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;"ok" is not the same as "safe".&lt;/strong&gt; &lt;code&gt;T9yD14...&lt;/code&gt; is the all-zero account ID. It is activated, holds about 774,000 TRX as of Dec 2, 2026, and passes every check here. Validation tells you the address is well-formed and what kind of account it is, nothing about who is behind it.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  What none of the layers can catch
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Look-alike addresses.&lt;/strong&gt; Address poisoning works precisely because the fake address is valid. Right after a user pays someone, a bot sends them dust from an address that shares the first and last characters of the real recipient, hoping it gets copied from history later. In one case we traced on the blog, 22 of 23 such dust transfers matched the last two characters of the address just paid. The only defence in a UI is to show the full address before confirming, not a shortened &lt;code&gt;TR7N...j6t&lt;/code&gt;. The mechanics are described in &lt;a href="https://usdtpull.com/en/blog/address-poisoning-tron/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=dec2026_free" rel="noopener noreferrer"&gt;address poisoning on TRON&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Cross-network confusion.&lt;/strong&gt; An EVM &lt;code&gt;0x...&lt;/code&gt; address fails validation, which is good. But if your code "helpfully" converts it by prepending &lt;code&gt;41&lt;/code&gt;, the result is a valid TRON address that the user never meant. Never convert user input between networks.&lt;/p&gt;

&lt;h2&gt;
  
  
  A routine for a payout form
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;Trim whitespace. Never change the case.&lt;/li&gt;
&lt;li&gt;Run the offline check; on failure, show the reason.&lt;/li&gt;
&lt;li&gt;Store the hex form alongside the Base58 one.&lt;/li&gt;
&lt;li&gt;Call &lt;code&gt;getaccount&lt;/code&gt;: warn on &lt;code&gt;{}&lt;/code&gt;, ask for confirmation on &lt;code&gt;"type": "Contract"&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Echo the full address back before the user confirms.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;All of these are read calls: none of them creates a transaction or costs energy or TRX.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;I work on UsdtPull, a TRON energy rental service, and this post is based on our blog article about TRON address validation.&lt;/em&gt;&lt;/p&gt;

</description>
      <category>tron</category>
      <category>javascript</category>
      <category>node</category>
      <category>web3</category>
    </item>
    <item>
      <title>Decoding USDT TRC-20 Transfers on TRON: Trust the Log, Not the Input</title>
      <dc:creator>UsdtPull</dc:creator>
      <pubDate>Wed, 02 Dec 2026 06:44:32 +0000</pubDate>
      <link>https://dev.to/usdtpull_com/decoding-usdt-trc-20-transfers-on-tron-trust-the-log-not-the-input-1m52</link>
      <guid>https://dev.to/usdtpull_com/decoding-usdt-trc-20-transfers-on-tron-trust-the-log-not-the-input-1m52</guid>
      <description>&lt;p&gt;Here is a USDT transaction from TRON block 88,160,500 (Nov 20, 2026). Its input data is a perfectly normal &lt;code&gt;transfer&lt;/code&gt; call: selector &lt;code&gt;a9059cbb&lt;/code&gt;, a recipient, and an amount of &lt;code&gt;0xc2459443c0&lt;/code&gt;, which is 834,391 USDT. If your indexer decodes the input and stops there, it records a large payment.&lt;/p&gt;

&lt;p&gt;Nothing moved. The transaction is &lt;a href="https://tronscan.org/#/transaction/90f6da29954d9e88934a6c4d60d2a03076eb8878ba53de81a897bd1eac6d1474" rel="noopener noreferrer"&gt;90f6da29...1474&lt;/a&gt;, its result is &lt;code&gt;OUT_OF_ENERGY&lt;/code&gt;, and its receipt has no event log at all. The only thing it consumed was 345 bandwidth on the sender's side.&lt;/p&gt;

&lt;p&gt;That is the whole argument of this post in one example. The input is what someone asked for. The Transfer event in the receipt is what the USDT contract actually did. Below is how to read both, a small decoder with no dependencies, and a second real case where the input does not mention USDT at all, yet two USDT transfers happened.&lt;/p&gt;

&lt;h2&gt;
  
  
  Two records of one transfer
&lt;/h2&gt;

&lt;p&gt;Every TRON transaction you care about here has two halves, and they come from different endpoints:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;POST /wallet/gettransactionbyid&lt;/code&gt; returns the signed transaction: &lt;code&gt;raw_data.contract[0].parameter.value&lt;/code&gt; holds &lt;code&gt;owner_address&lt;/code&gt; (the signer), &lt;code&gt;contract_address&lt;/code&gt; (the contract being called) and &lt;code&gt;data&lt;/code&gt; (the ABI-encoded call). &lt;code&gt;ret[0].contractRet&lt;/code&gt; carries the result code.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;POST /wallet/gettransactioninfobyid&lt;/code&gt; returns the receipt: block number, energy and bandwidth used, &lt;code&gt;receipt.result&lt;/code&gt;, and &lt;code&gt;log&lt;/code&gt;, an array with one entry per event the contracts emitted.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Only the second one tells you whether tokens moved.&lt;/p&gt;

&lt;h2&gt;
  
  
  Reading the input by hand
&lt;/h2&gt;

&lt;p&gt;Take a successful transfer from the same block: &lt;a href="https://tronscan.org/#/transaction/6cfb8f537b9b1e76858f8129bdcf2c0b600d1e0e3646f390a4d6b70ed152b336" rel="noopener noreferrer"&gt;6cfb8f53...b336&lt;/a&gt;, block time 06:19:51 UTC. Its &lt;code&gt;data&lt;/code&gt; is 68 bytes:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;a9059cbb                                                          selector: transfer(address,uint256)
00000000000000000000000095dca292f5d69fecd796ebfe31322d116e242172  recipient, left-padded to 32 bytes
00000000000000000000000000000000000000000000000000000000144f47a0  amount
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;code&gt;0x144f47a0&lt;/code&gt; is 340,740,000. USDT on TRON has 6 decimals, so that is 340.74 USDT. The recipient word ends in 20 meaningful bytes; put the TRON prefix byte &lt;code&gt;41&lt;/code&gt; in front and Base58Check-encode it, and you get &lt;code&gt;TPdbzdjNWqDLPUSfmfWVotDV3dRK5ZorjP&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;Notice what the input does not contain: the sender. That is &lt;code&gt;owner_address&lt;/code&gt; (&lt;code&gt;410b35cb...3d2c&lt;/code&gt;), a sibling field. And the token is identified only by &lt;code&gt;contract_address&lt;/code&gt;, &lt;code&gt;41a614f8...d13c&lt;/code&gt;, which is the hex form of the USDT contract &lt;code&gt;TR7NHqjeKQxGTCi8q8ZY4pL8otSzgjLj6t&lt;/code&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Reading the Transfer log
&lt;/h2&gt;

&lt;p&gt;The receipt of the same transaction says &lt;code&gt;result: SUCCESS&lt;/code&gt;, &lt;code&gt;energy_usage_total: 64285&lt;/code&gt;, &lt;code&gt;net_usage: 345&lt;/code&gt;, and has exactly one log entry:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Field&lt;/th&gt;
&lt;th&gt;Value&lt;/th&gt;
&lt;th&gt;What it is&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;address&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;&lt;code&gt;a614f803b6fd780986a42c78ec9c7f77e6ded13c&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;the emitting contract, USDT, without &lt;code&gt;41&lt;/code&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;topics[0]&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;&lt;code&gt;ddf252ad...523b3ef&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Keccak-256 of &lt;code&gt;Transfer(address,address,uint256)&lt;/code&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;topics[1]&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;&lt;code&gt;...0b35cb995374111effd4be67be0c762cae883d2c&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;from&lt;/code&gt;, indexed&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;topics[2]&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;&lt;code&gt;...95dca292f5d69fecd796ebfe31322d116e242172&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;to&lt;/code&gt;, indexed&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;data&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;&lt;code&gt;...144f47a0&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;value&lt;/code&gt;: 340.74 USDT&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;The split follows the event declaration &lt;code&gt;Transfer(address indexed from, address indexed to, uint256 value)&lt;/code&gt;: indexed parameters become topics, everything else is packed into &lt;code&gt;data&lt;/code&gt;. The topic hash is the same one you know from ERC-20 on Ethereum, because TRON's virtual machine uses the same event encoding. Only the address format differs.&lt;/p&gt;

&lt;p&gt;Two gotchas worth knowing before you write code:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Node's &lt;code&gt;sha3-256&lt;/code&gt; is not Keccak-256.&lt;/strong&gt; Hashing &lt;code&gt;Transfer(address,address,uint256)&lt;/code&gt; with &lt;code&gt;crypto.createHash('sha3-256')&lt;/code&gt; gives &lt;code&gt;c17a9d92...07a1&lt;/code&gt;, not &lt;code&gt;ddf252ad...&lt;/code&gt;. Standard SHA-3 and Ethereum-style Keccak use different padding, and Node 22 ships only the former. Hard-code the topic or use a Keccak library.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;The return value can lie, too.&lt;/strong&gt; &lt;code&gt;contractResult&lt;/code&gt; for this successful transfer is 32 zero bytes. The ABI says &lt;code&gt;transfer&lt;/code&gt; returns &lt;code&gt;bool&lt;/code&gt;, so a strict decoder reads &lt;code&gt;false&lt;/code&gt;. The tokens moved anyway. Use &lt;code&gt;receipt.result&lt;/code&gt; and the log; ignore the return value.&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  A decoder with zero dependencies
&lt;/h2&gt;

&lt;p&gt;This runs on Node.js 18+ (we ran it on 22.23.2 against the public TronGrid node on Dec 2, 2026). It ignores the input completely and lists the USDT transfers that the receipt proves:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="c1"&gt;// Node 18+ built-ins only: list USDT TRC-20 transfers that actually happened in a transaction&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="n"&gt;createHash&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nb"&gt;require&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s1"&gt;'node:crypto'&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="no"&gt;NODE&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="s1"&gt;'https://api.trongrid.io'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="no"&gt;USDT&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="s1"&gt;'a614f803b6fd780986a42c78ec9c7f77e6ded13c'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;          &lt;span class="c1"&gt;// TR7NH...Lj6t, 20 bytes&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="no"&gt;TRANSFER&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="s1"&gt;'ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="no"&gt;B58&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="s1"&gt;'123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="n"&gt;sha256&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;buf&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="nf"&gt;createHash&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s1"&gt;'sha256'&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;update&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;buf&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;digest&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="c1"&gt;// 32-byte word (64 hex chars) -&amp;gt; T... address: keep the last 20 bytes, add 0x41, Base58Check&lt;/span&gt;
&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;wordToAddress&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;word&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="n"&gt;payload&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nc"&gt;Buffer&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="k"&gt;from&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s1"&gt;'41'&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="n"&gt;word&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;slice&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="mi"&gt;40&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="s1"&gt;'hex'&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="n"&gt;bytes&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nc"&gt;Buffer&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;concat&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="n"&gt;payload&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nf"&gt;sha256&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nf"&gt;sha256&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;payload&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;subarray&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="mi"&gt;4&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="n"&gt;n&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nc"&gt;BigInt&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s1"&gt;'0x'&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="n"&gt;bytes&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;toString&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s1"&gt;'hex'&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="n"&gt;out&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="s1"&gt;''&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="k"&gt;while&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;n&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&lt;/span&gt; &lt;span class="mi"&gt;0n&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="n"&gt;out&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="no"&gt;B58&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nb"&gt;Number&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;n&lt;/span&gt; &lt;span class="o"&gt;%&lt;/span&gt; &lt;span class="mi"&gt;58n&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="n"&gt;out&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="n"&gt;n&lt;/span&gt; &lt;span class="o"&gt;/=&lt;/span&gt; &lt;span class="mi"&gt;58n&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="n"&gt;out&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="c1"&gt;// raw units (6 decimals) -&amp;gt; string, no floating point anywhere&lt;/span&gt;
&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;formatUsdt&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;hex&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="n"&gt;units&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nc"&gt;BigInt&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s1"&gt;'0x'&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="n"&gt;hex&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="sb"&gt;`${units / 1_000_000n}.${(units % 1_000_000n).toString().padStart(6, '0')}`&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="k"&gt;async&lt;/span&gt; &lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;call&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;path&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;txid&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="n"&gt;res&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nb"&gt;fetch&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="no"&gt;NODE&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="n"&gt;path&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="n"&gt;method&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s1"&gt;'POST'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="n"&gt;headers&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="s1"&gt;'content-type'&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s1"&gt;'application/json'&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="n"&gt;body&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;JSON&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;stringify&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="n"&gt;value&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;txid&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="n"&gt;res&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;json&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="k"&gt;async&lt;/span&gt; &lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;usdtTransfers&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;txid&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="n"&gt;info&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nf"&gt;call&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s1"&gt;'/wallet/gettransactioninfobyid'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;txid&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="n"&gt;result&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;info&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;receipt&lt;/span&gt;&lt;span class="o"&gt;?&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;result&lt;/span&gt; &lt;span class="o"&gt;??&lt;/span&gt; &lt;span class="s1"&gt;'NOT_FOUND'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;result&lt;/span&gt; &lt;span class="o"&gt;!==&lt;/span&gt; &lt;span class="s1"&gt;'SUCCESS'&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="n"&gt;result&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;transfers&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="n"&gt;transfers&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;info&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;log&lt;/span&gt; &lt;span class="o"&gt;??&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
    &lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;map&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;entry&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;index&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="n"&gt;entry&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;index&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
    &lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;filter&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="n"&gt;entry&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="n"&gt;entry&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;address&lt;/span&gt; &lt;span class="o"&gt;===&lt;/span&gt; &lt;span class="no"&gt;USDT&lt;/span&gt; &lt;span class="o"&gt;&amp;amp;&amp;amp;&lt;/span&gt; &lt;span class="n"&gt;entry&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;topics&lt;/span&gt;&lt;span class="o"&gt;?&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;===&lt;/span&gt; &lt;span class="no"&gt;TRANSFER&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
    &lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;map&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="n"&gt;entry&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;index&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="n"&gt;key&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="sb"&gt;`${txid}:${index}`&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;                     &lt;span class="c1"&gt;// dedup key: tx id + log index&lt;/span&gt;
      &lt;span class="k"&gt;from&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nf"&gt;wordToAddress&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;entry&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;topics&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="n"&gt;to&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nf"&gt;wordToAddress&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;entry&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;topics&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="n"&gt;amount&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nf"&gt;formatUsdt&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;entry&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;data&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="n"&gt;result&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;transfers&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nf"&gt;usdtTransfers&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nb"&gt;process&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;argv&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;then&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;r&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="nb"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nb"&gt;JSON&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;stringify&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;r&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="kc"&gt;null&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Output for the three transactions in this post (one call every few seconds; the public node rate-limits):&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;6cfb8f53...  SUCCESS        1 transfer:  TAzUsw...LsF7 -&amp;gt; TPdbzd...ZorjP  340.740000
90f6da29...  OUT_OF_ENERGY  0 transfers
8f8240c1...  SUCCESS        2 transfers: TC5tbs...dxg9n -&amp;gt; TLntW9...8ird   1.500000
                                         TC5tbs...dxg9n -&amp;gt; TGhe1a...NpJ2m 12.000000
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;(The script prints JSON; it is condensed here for reading.) A few choices in it are deliberate:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Amounts stay &lt;code&gt;BigInt&lt;/code&gt; until display.&lt;/strong&gt; A JavaScript &lt;code&gt;number&lt;/code&gt; is exact only up to 2^53, which is about 9 billion USDT in 6-decimal units. That sounds like plenty until someone sums balances.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;The filter checks the emitting contract, not just the topic.&lt;/strong&gt; Any token contract, including a fake one named "USDT", can emit an event with the same &lt;code&gt;ddf252ad...&lt;/code&gt; topic. Only &lt;code&gt;address === a614f8...d13c&lt;/code&gt; makes it real USDT.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;The key is &lt;code&gt;txid:logIndex&lt;/code&gt;.&lt;/strong&gt; One transaction can carry several transfers, so the transaction ID alone is not unique.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  The case where the input says nothing about USDT
&lt;/h2&gt;

&lt;p&gt;Transaction &lt;a href="https://tronscan.org/#/transaction/8f8240c1670d2beea436fd98e361d3870a298bca6b9191a51597b57d5cc0a90d" rel="noopener noreferrer"&gt;8f8240c1...a90d&lt;/a&gt;, same block, was signed by &lt;code&gt;TFNX7T...XQNy&lt;/code&gt; and called a different contract, &lt;code&gt;TFFAMQ...jF3U&lt;/code&gt; (hex &lt;code&gt;4139dd12...d510&lt;/code&gt;), with selector &lt;code&gt;6f21b898&lt;/code&gt;. An input-only parser that looks for &lt;code&gt;a9059cbb&lt;/code&gt; on the USDT contract skips it.&lt;/p&gt;

&lt;p&gt;The receipt holds three log entries. Two were emitted by the USDT contract, both from &lt;code&gt;TC5tbs...dxg9n&lt;/code&gt;: 1.5 USDT and 12 USDT. The third came from the calling contract itself, with its own event signature &lt;code&gt;fe6f7f85...&lt;/code&gt;. The whole thing used 154,896 energy and 701 bandwidth.&lt;/p&gt;

&lt;p&gt;So the same filter rule cuts both ways: it drops the third entry, which is not a token transfer, and it catches the two real USDT movements that the input never mentioned. Payment routers and batch-payout contracts produce receipts like this all the time.&lt;/p&gt;

&lt;h2&gt;
  
  
  TronGrid's pre-decoded view
&lt;/h2&gt;

&lt;p&gt;If you would rather not parse topics, TronGrid has &lt;code&gt;GET /v1/transactions/{id}/events&lt;/code&gt; (&lt;a href="https://developers.tron.network/reference/get-events-by-transaction-id" rel="noopener noreferrer"&gt;reference&lt;/a&gt;). For &lt;code&gt;6cfb8f53...&lt;/code&gt; it returned on Dec 2, 2026:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;"event_name"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Transfer"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"contract_address"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"TR7NHqjeKQxGTCi8q8ZY4pL8otSzgjLj6t"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"event_index"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"result"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;"from"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"0x0b35cb995374111effd4be67be0c762cae883d2c"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"to"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"0x95dca292f5d69fecd796ebfe31322d116e242172"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"value"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"340740000"&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;(trimmed). Three details trip people up: the contract is Base58 but &lt;code&gt;from&lt;/code&gt; and &lt;code&gt;to&lt;/code&gt; are 20-byte hex with &lt;code&gt;0x&lt;/code&gt; and no &lt;code&gt;41&lt;/code&gt;; &lt;code&gt;value&lt;/code&gt; is a string in raw units; and items not yet in a confirmed block carry &lt;code&gt;_unconfirmed: true&lt;/code&gt;. It is convenient, but it is an indexer's reading of the log. For crediting money, the raw receipt from a node is the primary source.&lt;/p&gt;

&lt;p&gt;How to turn either of these into an incoming-payment pipeline (polling vs event streams, confirmation depth, the traps that credit money you never got) is covered in &lt;a href="https://usdtpull.com/en/blog/monitor-incoming-usdt-trc20/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=dec2026_free" rel="noopener noreferrer"&gt;monitoring incoming USDT TRC-20&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Checklist
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;Fetch the receipt with &lt;code&gt;gettransactioninfobyid&lt;/code&gt;. No receipt or anything but &lt;code&gt;SUCCESS&lt;/code&gt; means nothing to credit.&lt;/li&gt;
&lt;li&gt;Walk every entry in &lt;code&gt;log&lt;/code&gt;, not just &lt;code&gt;log[0]&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Keep entries where &lt;code&gt;address&lt;/code&gt; is the USDT contract and &lt;code&gt;topics[0]&lt;/code&gt; is the Transfer topic.&lt;/li&gt;
&lt;li&gt;Decode &lt;code&gt;from&lt;/code&gt; and &lt;code&gt;to&lt;/code&gt; from the last 40 hex characters of &lt;code&gt;topics[1]&lt;/code&gt; and &lt;code&gt;topics[2]&lt;/code&gt;: prefix &lt;code&gt;41&lt;/code&gt;, Base58Check.&lt;/li&gt;
&lt;li&gt;Parse &lt;code&gt;data&lt;/code&gt; as a big integer; divide by 1,000,000 only when rendering.&lt;/li&gt;
&lt;li&gt;Deduplicate on transaction ID plus log index.&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  What the receipt says about cost
&lt;/h2&gt;

&lt;p&gt;The successful transfer above used 64,285 energy, and 49,635 of that was the dynamic-energy surcharge the network adds to busy contracts like USDT. A sender with no energy on the address pays for all of it by burning TRX at 100 SUN per unit, about 6.43 TRX for this one transfer, or roughly 13.1 TRX when the recipient holds no USDT yet. Renting 65,000 energy for an hour instead cost 1.17 TRX as of Dec 2, 2026 (18 SUN per unit); the rate changes. If your backend sends USDT as well as receiving it, energy can be ordered from code, see the &lt;a href="https://usdtpull.com/en/api/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=dec2026_free" rel="noopener noreferrer"&gt;energy rental API&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;I work on UsdtPull, a TRON energy rental service, and this post is based on our blog article about decoding USDT transfer events.&lt;/em&gt;&lt;/p&gt;

</description>
      <category>tron</category>
      <category>blockchain</category>
      <category>javascript</category>
      <category>web3</category>
    </item>
    <item>
      <title>How Much TRON Energy Does Each Transaction Type Use?</title>
      <dc:creator>UsdtPull</dc:creator>
      <pubDate>Thu, 26 Nov 2026 06:39:03 +0000</pubDate>
      <link>https://dev.to/usdtpull_com/how-much-tron-energy-does-each-transaction-type-use-3l26</link>
      <guid>https://dev.to/usdtpull_com/how-much-tron-energy-does-each-transaction-type-use-3l26</guid>
      <description>&lt;p&gt;&lt;em&gt;Disclosure: I work on UsdtPull, a TRON energy rental service. This article was first published on the &lt;a href="https://usdtpull.com/en/blog/tron-energy-per-transaction/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;UsdtPull blog&lt;/a&gt;.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Only smart contract calls use TRON energy. Plain TRX and TRC-10 transfers, staking, delegating energy and voting use none at all, only about 250 to 340 units of bandwidth. Contract calls are where the energy goes: as of Oct 19, 2026 a USDT transfer used 64,285 energy (130,285 to an address with no USDT), a USDT approve 99,764 and a swap between TRX and USDT on SunSwap V2 between 157,354 and 223,354.&lt;/p&gt;

&lt;p&gt;Every number below links to a real mainnet receipt on TronScan.&lt;/p&gt;

&lt;h2&gt;
  
  
  Energy and bandwidth by transaction type
&lt;/h2&gt;

&lt;p&gt;We read every receipt in six consecutive blocks, 87,238,000 to 87,238,005 (Oct 19, 2026, 05:17:00 to 05:17:15 UTC, 2,940 transactions). Swaps and approvals are rarer, so we added the last 30 calls to the SunSwap V2 router (Oct 17-19), recent USDT approvals, and staking and voting transactions from the next 30 blocks.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Transaction&lt;/th&gt;
&lt;th&gt;Energy&lt;/th&gt;
&lt;th&gt;Bandwidth&lt;/th&gt;
&lt;th&gt;Example&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;TRX transfer&lt;/td&gt;
&lt;td&gt;0&lt;/td&gt;
&lt;td&gt;265 (most of the sample)&lt;/td&gt;
&lt;td&gt;&lt;a href="https://tronscan.org/#/transaction/3afd2221060acea5fb52f5ee40d48b119bbaec6d58883b644597f820c4b908e7" rel="noopener noreferrer"&gt;3afd2221...&lt;/a&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;TRC-10 token transfer (token ID 1002000)&lt;/td&gt;
&lt;td&gt;0&lt;/td&gt;
&lt;td&gt;279 to 283 (280 in the example)&lt;/td&gt;
&lt;td&gt;&lt;a href="https://tronscan.org/#/transaction/2052dc2266d808e4d8685318bf439a1f68e099fcb6a65f130062063fcb3de57e" rel="noopener noreferrer"&gt;2052dc22...&lt;/a&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;USDT transfer, recipient holds USDT&lt;/td&gt;
&lt;td&gt;64,285&lt;/td&gt;
&lt;td&gt;345&lt;/td&gt;
&lt;td&gt;&lt;a href="https://tronscan.org/#/transaction/7e08f5e2617e8308fc8435cbce315c19a4d5d84679f8bdf9351b72d430b72664" rel="noopener noreferrer"&gt;7e08f5e2...&lt;/a&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;USDT transfer, recipient has no USDT&lt;/td&gt;
&lt;td&gt;130,285&lt;/td&gt;
&lt;td&gt;345&lt;/td&gt;
&lt;td&gt;&lt;a href="https://tronscan.org/#/transaction/0b3a2a3d60adb53404562a65373665abfbb157aeb7193f3a43e89b4b5ae0d55d" rel="noopener noreferrer"&gt;0b3a2a3d...&lt;/a&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;USDT approve&lt;/td&gt;
&lt;td&gt;99,764&lt;/td&gt;
&lt;td&gt;345&lt;/td&gt;
&lt;td&gt;&lt;a href="https://tronscan.org/#/transaction/cd35d59cc259cd43a1f827d7eea741fd98689824f39dd033d13a1b059d305739" rel="noopener noreferrer"&gt;cd35d59c...&lt;/a&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Swap TRX for USDT, SunSwap V2&lt;/td&gt;
&lt;td&gt;157,354&lt;/td&gt;
&lt;td&gt;513&lt;/td&gt;
&lt;td&gt;&lt;a href="https://tronscan.org/#/transaction/f08027b06f1fbdc607ff6fc140cf58b774c003c93261d21e03109c31715dc719" rel="noopener noreferrer"&gt;f08027b0...&lt;/a&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Same swap, recipient likely without USDT&lt;/td&gt;
&lt;td&gt;223,354&lt;/td&gt;
&lt;td&gt;512&lt;/td&gt;
&lt;td&gt;&lt;a href="https://tronscan.org/#/transaction/ae37eee647875147e960aeab090a7b81f3428f51a02899843bd093e1ef177d60" rel="noopener noreferrer"&gt;ae37eee6...&lt;/a&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Swap USDT for TRX, SunSwap V2&lt;/td&gt;
&lt;td&gt;166,663 or 190,865&lt;/td&gt;
&lt;td&gt;539&lt;/td&gt;
&lt;td&gt;&lt;a href="https://tronscan.org/#/transaction/db3986db5a241d0be4201db701451e7c0d4272b64819520282629cb58c3bd192" rel="noopener noreferrer"&gt;db3986db...&lt;/a&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Stake TRX for energy (FreezeBalanceV2)&lt;/td&gt;
&lt;td&gt;0&lt;/td&gt;
&lt;td&gt;255&lt;/td&gt;
&lt;td&gt;&lt;a href="https://tronscan.org/#/transaction/d121aa841a6039c22a810d9e384462cca0c5273d1477bc369fbf49331f72afd7" rel="noopener noreferrer"&gt;d121aa84...&lt;/a&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Delegate energy (DelegateResource)&lt;/td&gt;
&lt;td&gt;0&lt;/td&gt;
&lt;td&gt;281 (277 to 299)&lt;/td&gt;
&lt;td&gt;&lt;a href="https://tronscan.org/#/transaction/77605fd28ad8cb30767392004c27df80d5fba813052e572fe346f800bce6ba72" rel="noopener noreferrer"&gt;77605fd2...&lt;/a&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Reclaim delegated energy (UnDelegateResource)&lt;/td&gt;
&lt;td&gt;0&lt;/td&gt;
&lt;td&gt;283 (279 to 301)&lt;/td&gt;
&lt;td&gt;&lt;a href="https://tronscan.org/#/transaction/20f11e581415d852d259abdd0c5b98497fb9592a43ea0cb877d4866c23516c75" rel="noopener noreferrer"&gt;20f11e58...&lt;/a&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Vote for 3 Super Representatives&lt;/td&gt;
&lt;td&gt;0&lt;/td&gt;
&lt;td&gt;332&lt;/td&gt;
&lt;td&gt;&lt;a href="https://tronscan.org/#/transaction/43ec228f17b1b0124d4e8ddaeb738084e02d12d2cd7c2e4a259cd56c9b2bdaa1" rel="noopener noreferrer"&gt;43ec228f...&lt;/a&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Claim voting rewards (WithdrawBalance)&lt;/td&gt;
&lt;td&gt;0&lt;/td&gt;
&lt;td&gt;246&lt;/td&gt;
&lt;td&gt;&lt;a href="https://tronscan.org/#/transaction/a8263a1a7300fd4fc1e0475674b7c0d1caabda3b10466ec3fe4ff1be0cef9738" rel="noopener noreferrer"&gt;a8263a1a...&lt;/a&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Change account permissions&lt;/td&gt;
&lt;td&gt;0&lt;/td&gt;
&lt;td&gt;373, plus a 100 TRX fee&lt;/td&gt;
&lt;td&gt;&lt;a href="https://tronscan.org/#/transaction/38afb5c81997d3ff4fb19669c940cebc3d7bc1eeb270d4e84b06dcd0049591ca" rel="noopener noreferrer"&gt;38afb5c8...&lt;/a&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;The counts in the six blocks back up the zeros: 1,082 TRX transfers, 333 TRC-10 transfers, 304 delegations and 799 reclaims, and every one of them used 0 energy. Of 383 successful USDT transfers, 319 used exactly 64,285 and 64 used exactly 130,285. No other values appeared.&lt;/p&gt;

&lt;p&gt;Bandwidth follows the size of the transaction in bytes: a swap carries a token path and takes over 500. What bandwidth costs once the free 600 units run out is covered in &lt;a href="https://usdtpull.com/en/blog/tron-bandwidth-cost/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;TRON bandwidth cost&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why staking, delegation and voting need no energy
&lt;/h2&gt;

&lt;p&gt;TRON has two kinds of transactions. Most operations, such as TRX transfers, staking, delegation and voting, are built-in system contracts that the protocol handles directly. Energy pays only for code that runs in the TRON virtual machine, that is, for calls to smart contracts and for deploying them (&lt;a href="https://developers.tron.network/docs/bandwidth-and-energy" rel="noopener noreferrer"&gt;TRON docs&lt;/a&gt;).&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;You can stake TRX for energy with zero energy on the address.&lt;/strong&gt; All you need is enough bandwidth, free or burned. Staking itself is compared with renting in &lt;a href="https://usdtpull.com/en/blog/freeze-trx-vs-rent-energy/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;freeze TRX or rent energy&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Delegating energy costs the delegator no energy.&lt;/strong&gt; The address that passes energy to you pays only about 280 bandwidth for the operation, and the same again to take it back. A TRC-10 token is a system asset too, so it moves like TRX; USDT is a TRC-20 smart contract.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Why contract calls differ so much
&lt;/h2&gt;

&lt;p&gt;A contract call costs the sum of the instructions it runs. Writing data is the expensive part. A USDT transfer to a holder updates two balances; a transfer to an address with no USDT also creates a new balance record, and that is the whole difference between 64,285 and 130,285 (see &lt;a href="https://usdtpull.com/en/blog/why-transfer-to-new-address-costs-more/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;why sending to a new address costs more&lt;/a&gt;). An approve writes an allowance record. A swap runs the router, the trading pair and two token contracts in one transaction.&lt;/p&gt;

&lt;p&gt;The two TRX-to-USDT swaps differ by exactly 66,000 energy, the same gap as between the two kinds of USDT transfer. That points to the second recipient having no USDT before the swap; the receipt does not show the earlier balance, so treat it as likely, not proven.&lt;/p&gt;

&lt;h3&gt;
  
  
  Dynamic energy and energy_factor
&lt;/h3&gt;

&lt;p&gt;The second reason is the dynamic energy model. Each contract has an &lt;code&gt;energy_factor&lt;/code&gt; that the network raises when the contract is heavily used and lowers when it is not (&lt;a href="https://github.com/tronprotocol/tips/blob/master/tip-491.md" rel="noopener noreferrer"&gt;TIP-491&lt;/a&gt;, &lt;a href="https://developers.tron.network/docs/paying-for-resources" rel="noopener noreferrer"&gt;paying for resources&lt;/a&gt;). The rules, with chain parameters as of Oct 19, 2026:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;a contract that used more than 5,000,000,000 energy in a maintenance period (&lt;code&gt;getDynamicEnergyThreshold&lt;/code&gt;) gets a higher factor in the next one;&lt;/li&gt;
&lt;li&gt;each such period multiplies the contract's cost multiplier (1 + factor) by 1.2 (&lt;code&gt;getDynamicEnergyIncreaseFactor&lt;/code&gt; = 2,000, in units of 1/10,000);&lt;/li&gt;
&lt;li&gt;a quiet period lowers it by a quarter of that step: the multiplier is multiplied by 0.95;&lt;/li&gt;
&lt;li&gt;the cap is 34,000 (&lt;code&gt;getDynamicEnergyMaxFactor&lt;/code&gt;), which means the contract's own instructions cost up to 4.4 times their base price;&lt;/li&gt;
&lt;li&gt;a maintenance period lasts 6 hours (&lt;code&gt;getMaintenanceTimeInterval&lt;/code&gt; = 21,600,000 ms).&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Here is what the contract state looked like on Oct 19, 2026, between 05:12 and 05:25 UTC (&lt;code&gt;getcontractinfo&lt;/code&gt; in the TronGrid API):&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Contract&lt;/th&gt;
&lt;th&gt;energy_factor&lt;/th&gt;
&lt;th&gt;Energy counted in the current period&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;USDT (TR7NHqjeKQxGTCi8q8ZY4pL8otSzgjLj6t)&lt;/td&gt;
&lt;td&gt;34,000, the cap&lt;/td&gt;
&lt;td&gt;6,022,947,503&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;SunSwap V2 router (TKzxdSv2FZKQrEqkKVgp5DcwEXBEKMg2Ax)&lt;/td&gt;
&lt;td&gt;0&lt;/td&gt;
&lt;td&gt;397,480&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;The surcharge is charged contract by contract, and every receipt shows it in &lt;code&gt;energy_penalty_total&lt;/code&gt;. For a USDT transfer to a holder it is 49,635 of the 64,285. For the approve it is 77,076 of 99,764. For the TRX-to-USDT swap it is 52,762 of 157,354: close to the surcharge of one USDT transfer, because the router itself sits at factor 0 and only the USDT part is charged extra.&lt;/p&gt;

&lt;p&gt;Our own calculation from these rules, not a documented figure: from 0 a contract reaches the cap after 9 busy periods (about 2.25 days), and falls back to 0 after about 29 quiet ones (over 7 days). USDT had already passed the threshold in the current period, so its factor stays at the cap for now.&lt;/p&gt;

&lt;h2&gt;
  
  
  How much energy you need: planning by task
&lt;/h2&gt;

&lt;p&gt;Add up the transactions you plan, using the measured figures. Burn costs use 100 SUN per unit of energy as of Oct 19, 2026; if SUN is new to you, see &lt;a href="https://usdtpull.com/en/blog/what-is-sun-tron/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;what SUN is and how to convert it&lt;/a&gt;.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;What you plan&lt;/th&gt;
&lt;th&gt;Energy to have on the address&lt;/th&gt;
&lt;th&gt;If burned instead&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Stake, delegate, vote, send TRX&lt;/td&gt;
&lt;td&gt;0&lt;/td&gt;
&lt;td&gt;only bandwidth, about 0.25 to 0.34 TRX if free bandwidth is used up&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;One USDT transfer to a holder&lt;/td&gt;
&lt;td&gt;64,285 (plan 65,000)&lt;/td&gt;
&lt;td&gt;6.43 TRX&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;One USDT transfer to an address with no USDT&lt;/td&gt;
&lt;td&gt;130,285 (plan 131,000)&lt;/td&gt;
&lt;td&gt;13.03 TRX&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;First swap of USDT for TRX: approve, then swap&lt;/td&gt;
&lt;td&gt;99,764 + 190,865 = 290,629&lt;/td&gt;
&lt;td&gt;29.06 TRX&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Swap TRX for USDT&lt;/td&gt;
&lt;td&gt;157,354 to 223,354&lt;/td&gt;
&lt;td&gt;15.74 to 22.34 TRX&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Receipts confirm the burn column: the USDT-to-TRX swap in our table had no energy, and the network burned 16,666,300 SUN (16.67 TRX) for its 166,663 energy.&lt;/p&gt;

&lt;p&gt;With rented energy, the same plan is cheaper by the ratio of prices. At the current rate on Nov 15, 2026, 28 SUN per unit of energy for 1 hour, the approve and swap above (290,629 energy) come to 290,629 × 28 = 8,137,612 SUN, or about 8.14 TRX, against 29.06 TRX burned. The rate changes. The exact price is shown in the service before you pay, and reference prices are on the &lt;a href="https://usdtpull.com/en/pricing/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;pricing page&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  How to check energy before you send
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Look up the transaction type in the table.&lt;/strong&gt; If it is a system operation, you need bandwidth only.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;For a contract call, get an estimate.&lt;/strong&gt; Wallets show one before you sign. Developers can call &lt;code&gt;triggerconstantcontract&lt;/code&gt; in the TronGrid API, which returns &lt;code&gt;energy_used&lt;/code&gt; for a simulated call.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Add a margin for USDT.&lt;/strong&gt; Check whether the recipient already holds USDT; if not, plan for 130,285, not 64,285.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Compare with what the address has.&lt;/strong&gt; Your address page in TronScan shows available energy; any shortfall is burned in TRX, within the fee limit.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Read the receipt afterwards.&lt;/strong&gt; &lt;code&gt;energy_usage_total&lt;/code&gt; shows what the call used and &lt;code&gt;energy_penalty_total&lt;/code&gt; how much of it was the dynamic surcharge.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;For USDT, burning, staking and renting are compared in &lt;a href="https://usdtpull.com/en/blog/usdt-trc20-transfer-fee/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;USDT TRC-20 transfer fee&lt;/a&gt;, and what energy is in the first place is explained in &lt;a href="https://usdtpull.com/en/blog/what-is-tron-energy/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;what is TRON energy&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  FAQ
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Does a TRX transfer need energy?&lt;/strong&gt;&lt;br&gt;
No. In our sample, 1,082 TRX transfers used 0 energy and about 265 bandwidth each.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Do I need energy to stake TRX or vote?&lt;/strong&gt;&lt;br&gt;
No. FreezeBalanceV2 and voting are system operations. They use only bandwidth: 255 and 332 units in our examples.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Will these numbers change?&lt;/strong&gt;&lt;br&gt;
Yes, if a contract's &lt;code&gt;energy_factor&lt;/code&gt; moves or validators change the parameters. As of Oct 19, 2026 USDT is at the cap. More answers are in the &lt;a href="https://usdtpull.com/en/faq/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;FAQ&lt;/a&gt;.&lt;/p&gt;




&lt;p&gt;&lt;em&gt;Network figures are from TRON mainnet receipts and chain parameters as of Oct 19, 2026; the rental rate is UsdtPull's rate on Nov 15, 2026. Drafted with AI assistance and checked by the author.&lt;/em&gt;&lt;/p&gt;

</description>
      <category>tron</category>
      <category>blockchain</category>
      <category>web3</category>
      <category>smartcontract</category>
    </item>
    <item>
      <title>How to Check Energy and Bandwidth of a TRON Address on TronScan</title>
      <dc:creator>UsdtPull</dc:creator>
      <pubDate>Wed, 25 Nov 2026 10:31:06 +0000</pubDate>
      <link>https://dev.to/usdtpull_com/how-to-check-energy-and-bandwidth-of-a-tron-address-on-tronscan-3f29</link>
      <guid>https://dev.to/usdtpull_com/how-to-check-energy-and-bandwidth-of-a-tron-address-on-tronscan-3f29</guid>
      <description>&lt;p&gt;&lt;em&gt;Disclosure: I work on UsdtPull, a TRON energy rental service. This article was first published on the &lt;a href="https://usdtpull.com/en/blog/check-energy-bandwidth-tronscan/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;UsdtPull blog&lt;/a&gt;.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;To check the energy of a TRON address, open tronscan.org, paste the address into the search bar and look at the account overview: the &lt;strong&gt;Energy&lt;/strong&gt; row shows "Available: X / Y", where X is what you can spend right now and Y is your total limit. The &lt;strong&gt;Bandwidth&lt;/strong&gt; row works the same way. As of Oct 19, 2026, a standard USDT transfer needs 64,285 energy and 345 bandwidth, and a transfer to an address with no USDT needs 130,285 energy, so compare the first number in each row with those figures.&lt;/p&gt;

&lt;p&gt;Below: where the numbers sit, how to read them, a real address that still paid TRX, who delegated the energy and the same check through the API.&lt;/p&gt;

&lt;h2&gt;
  
  
  Where TronScan shows energy and bandwidth
&lt;/h2&gt;

&lt;p&gt;Labels below are quoted from the English interface of TronScan as we saw it on Oct 19, 2026.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Open &lt;a href="https://tronscan.org" rel="noopener noreferrer"&gt;tronscan.org&lt;/a&gt; and paste the address. The account page opens on the Transactions tab.&lt;/li&gt;
&lt;li&gt;In the overview block, find the rows &lt;strong&gt;TRX Available&lt;/strong&gt;, &lt;strong&gt;TRX Staked&lt;/strong&gt;, &lt;strong&gt;Energy&lt;/strong&gt; and &lt;strong&gt;Bandwidth&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Read the Energy row, for example "Available: 810 / 130,015".&lt;/li&gt;
&lt;li&gt;Hover over the second number to see where the limit comes from. For energy, TronScan splits it into "From my stake" (your own staked TRX) and "From others' delegation" (energy another address passed to you), with a percentage for each.&lt;/li&gt;
&lt;li&gt;Hover over the bandwidth limit. Most wallets show "Free" 600 Bandwidth (100%), the daily allowance of an activated address.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;The token list shows whether the address holds USDT. Unknown tokens with advertising names are airdropped spam: ignore them.&lt;/p&gt;

&lt;h2&gt;
  
  
  What the numbers mean for a USDT transfer
&lt;/h2&gt;

&lt;p&gt;The rule is simple: compare &lt;strong&gt;Available&lt;/strong&gt;, not the total. Network figures are as of Oct 19, 2026: 100 SUN per unit of energy and 1,000 SUN per unit of bandwidth when the network burns TRX.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;What you see&lt;/th&gt;
&lt;th&gt;What it means&lt;/th&gt;
&lt;th&gt;Enough for a USDT transfer?&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Energy: Available 70,000 / 72,000, recipient holds USDT&lt;/td&gt;
&lt;td&gt;Most of the limit is unused&lt;/td&gt;
&lt;td&gt;Yes, 64,285 is covered&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Energy: Available 70,000 / 72,000, recipient has no USDT&lt;/td&gt;
&lt;td&gt;Covers about half of 130,285&lt;/td&gt;
&lt;td&gt;Partly: the network burns 6.0285 TRX for the missing 60,285&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Energy: Available 0 / 0&lt;/td&gt;
&lt;td&gt;No stake and no delegation&lt;/td&gt;
&lt;td&gt;No: 6.4285 TRX burned for a standard transfer&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Energy: Available 810 / 130,015&lt;/td&gt;
&lt;td&gt;The limit is large, but it was just spent and is recovering&lt;/td&gt;
&lt;td&gt;No, not right now&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;"From others' delegation" 100%&lt;/td&gt;
&lt;td&gt;All the energy is delegated by another address&lt;/td&gt;
&lt;td&gt;Yes while the delegation lasts; it can be taken back&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Bandwidth: Available 600 / 600&lt;/td&gt;
&lt;td&gt;Free allowance untouched&lt;/td&gt;
&lt;td&gt;Yes, 345 fits&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Bandwidth: Available 256 / 600&lt;/td&gt;
&lt;td&gt;Free allowance partly used today&lt;/td&gt;
&lt;td&gt;No: 0.345 TRX burned for all 345 units&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;TRX Available below the burn you expect&lt;/td&gt;
&lt;td&gt;Nothing to cover a shortfall&lt;/td&gt;
&lt;td&gt;The transfer may fail with OUT OF ENERGY&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Bandwidth is all or nothing: with 256 free units left and 345 needed, the network burns TRX for all 345. Details are in &lt;a href="https://usdtpull.com/en/blog/tron-energy-vs-bandwidth/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;TRON energy vs bandwidth&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  A real address: 281 energy short
&lt;/h2&gt;

&lt;p&gt;One address around a single transfer on Oct 19, 2026, times in UTC:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;05:15:51 and 05:17:48.&lt;/strong&gt; Another address delegated energy to &lt;a href="https://tronscan.org/#/address/TW1NsYZg4bjFHoqUgDeakbTdGbEXRo7JwV" rel="noopener noreferrer"&gt;TW1NsYZg4bjFHoqUgDeakbTdGbEXRo7JwV&lt;/a&gt; in two operations of 6,778 TRX each (&lt;a href="https://tronscan.org/#/transaction/d76d0abef3f558ffdc22ef5c4dabd68c692285debcefe828e17225125ab90847" rel="noopener noreferrer"&gt;first&lt;/a&gt;, &lt;a href="https://tronscan.org/#/transaction/db460aaf9e99bc01ae3c9180389c2b135167da9a8ef5e603f6bae70d71e5534d" rel="noopener noreferrer"&gt;second&lt;/a&gt;). The address had no stake of its own.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;05:15:48 and 05:17:45.&lt;/strong&gt; The address sent 2 TRX twice, each time using 267 units of free bandwidth.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;05:18:06.&lt;/strong&gt; It sent USDT to an address with no USDT. The &lt;a href="https://tronscan.org/#/transaction/464cd979e78bbc1342ec56621df2ffff4d2069149457d529f49ba777e95d7e8d" rel="noopener noreferrer"&gt;receipt&lt;/a&gt; shows 130,285 energy needed, 130,004 covered by the delegation and 28,100 SUN burned for the missing 281. Free bandwidth left was below 345, so another 345,000 SUN was burned. Total: 0.3731 TRX.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;05:27.&lt;/strong&gt; The overview showed Energy "Available: 810 / 130,015" and Bandwidth "Available: 71 / 600".&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Why 13,556 TRX was not quite enough
&lt;/h3&gt;

&lt;p&gt;A delegation is set in TRX, not in energy. The energy it brings follows the network ratio, which changes as other people stake. On Oct 19, 2026, one staked TRX gave 9.59 energy a day (180,000,000,000 / 18,769,250,144 = 9.5902), so:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;13,556 TRX × 9.5902 = &lt;strong&gt;130,004 energy&lt;/strong&gt;, exactly what the receipt used;&lt;/li&gt;
&lt;li&gt;130,285 / 9.5902 = 13,585.3, so &lt;strong&gt;13,586 TRX&lt;/strong&gt; would have covered it fully.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;At the Oct 13 ratio of 9.61, the same 13,556 TRX would have been almost exactly enough. The loss is 0.0281 TRX, but the lesson holds: check Available, not the amount ordered. The bandwidth burn was over ten times bigger: the two 2 TRX transfers had used 534 of 600 free units.&lt;/p&gt;

&lt;h3&gt;
  
  
  Leftover energy can vanish
&lt;/h3&gt;

&lt;p&gt;Two other senders in the same block had no stake and burned nothing for energy at 05:18:06, so their energy was delegated. Less than two minutes later the API showed no energy on either address: the delegation had been taken back. Do not plan around leftovers.&lt;/p&gt;

&lt;h2&gt;
  
  
  How to see that rented energy arrived and who sent it
&lt;/h2&gt;

&lt;p&gt;Rental works through delegation, which TronScan shows in three places:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Transactions tab.&lt;/strong&gt; A new row with the type &lt;strong&gt;Delegate Resources&lt;/strong&gt;. The From column is the address that delegated. When the energy is taken back, a row with the type &lt;strong&gt;Reclaim Resources&lt;/strong&gt; appears.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Staking tab, Stake 2.0, "Delegated by others (N)".&lt;/strong&gt; The table has the columns From, Type, Delegation Amount, Unlock At (Local), TRX Withheld and Updated At (Local). For our address it read: Energy, 130,015, "(No active lock)", 13,556 TRX.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Hover over the energy limit.&lt;/strong&gt; "From others' delegation" shows the delegated share in energy and percent.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;"(No active lock)" means the delegator can take the energy back at any time. With a lock, Unlock At shows the earliest date; the longest lock allowed by &lt;code&gt;getMaxDelegateLockPeriod&lt;/code&gt; as of Oct 19, 2026 is 864,000 blocks, about 30 days. Ordering step by step is in the &lt;a href="https://usdtpull.com/en/guides/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;guides&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;If Available falls short, you burn the difference or bring energy. At the current rate on Nov 15, 2026, 28 SUN per unit of energy for 1 hour, 65,000 energy costs 1.82 TRX against 6.5 TRX burned. The rate changes. The exact price is shown in the app before you pay, and reference prices are on the &lt;a href="https://usdtpull.com/en/pricing/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;pricing page&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  The same check through the API
&lt;/h2&gt;

&lt;p&gt;The public TronGrid method &lt;a href="https://developers.tron.network/reference/getaccountresource" rel="noopener noreferrer"&gt;getaccountresource&lt;/a&gt; returns the same data:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -X POST https://api.trongrid.io/wallet/getaccountresource \
  -H &lt;span class="s2"&gt;"content-type: application/json"&lt;/span&gt; \
  -d &lt;span class="s1"&gt;'{"address":"TW1NsYZg4bjFHoqUgDeakbTdGbEXRo7JwV","visible":true}'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Our call at 05:28:45 UTC on Oct 19, 2026 returned, among other fields:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="nl"&gt;"freeNetUsed"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;528&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"freeNetLimit"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;600&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"EnergyUsed"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;129042&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"EnergyLimit"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;130015&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
 &lt;span class="nl"&gt;"TotalEnergyLimit"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;180000000000&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="nl"&gt;"TotalEnergyWeight"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;18767650134&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Field&lt;/th&gt;
&lt;th&gt;What it holds&lt;/th&gt;
&lt;th&gt;How to use it&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;EnergyLimit&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Energy limit of the address&lt;/td&gt;
&lt;td&gt;Available energy = &lt;code&gt;EnergyLimit&lt;/code&gt; - &lt;code&gt;EnergyUsed&lt;/code&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;EnergyUsed&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Spent, not yet recovered&lt;/td&gt;
&lt;td&gt;Falls as energy recovers&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;code&gt;freeNetLimit&lt;/code&gt;, &lt;code&gt;freeNetUsed&lt;/code&gt;
&lt;/td&gt;
&lt;td&gt;Free daily bandwidth and its use&lt;/td&gt;
&lt;td&gt;Free left = &lt;code&gt;freeNetLimit&lt;/code&gt; - &lt;code&gt;freeNetUsed&lt;/code&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;code&gt;NetLimit&lt;/code&gt;, &lt;code&gt;NetUsed&lt;/code&gt;
&lt;/td&gt;
&lt;td&gt;Staked or delegated bandwidth&lt;/td&gt;
&lt;td&gt;Left = &lt;code&gt;NetLimit&lt;/code&gt; - &lt;code&gt;NetUsed&lt;/code&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;code&gt;TotalEnergyLimit&lt;/code&gt;, &lt;code&gt;TotalEnergyWeight&lt;/code&gt;
&lt;/td&gt;
&lt;td&gt;Network energy and TRX staked for it&lt;/td&gt;
&lt;td&gt;Ratio = energy per staked TRX&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Three things the documentation does not spell out:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Zero fields are left out.&lt;/strong&gt; No &lt;code&gt;EnergyLimit&lt;/code&gt; means no energy; treat a missing field as 0.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;&lt;code&gt;EnergyLimit&lt;/code&gt; includes delegated energy.&lt;/strong&gt; The reference calls it energy obtained by staking, yet our address has 0 TRX staked and shows 130,015.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Who delegated:&lt;/strong&gt; &lt;code&gt;getdelegatedresourceaccountindexv2&lt;/code&gt; lists delegators in &lt;code&gt;fromAccounts&lt;/code&gt;, and &lt;code&gt;getdelegatedresourcev2&lt;/code&gt; for a pair returns &lt;code&gt;frozen_balance_for_energy&lt;/code&gt;: 13,556,000,000 SUN for ours, the TRX Withheld figure on TronScan.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Before you send: a short checklist
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Look up the recipient.&lt;/strong&gt; No USDT in their token list means 130,285 energy, not 64,285. &lt;a href="https://usdtpull.com/en/blog/why-transfer-to-new-address-costs-more/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;Why a new address costs more&lt;/a&gt; explains the difference.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Read Available energy&lt;/strong&gt; on your own address and compare it with that number.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Read Available bandwidth.&lt;/strong&gt; Below 345 means 0.345 TRX will be burned, so keep at least that much TRX.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;If energy was just delivered, open Delegated by others&lt;/strong&gt; and check the amount and the lock.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Send right after the check&lt;/strong&gt; and read the receipt afterwards. The exact TRX for each case is in &lt;a href="https://usdtpull.com/en/blog/how-much-trx-to-send-usdt/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;how much TRX you need to send USDT&lt;/a&gt;.&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  FAQ
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Why does TronScan show energy but my transfer still burned TRX?&lt;/strong&gt;&lt;br&gt;
Available was below what the transfer needed, often because the recipient had no USDT. A 0.345 TRX bandwidth burn is separate.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;How fast does energy come back after a transfer?&lt;/strong&gt;&lt;br&gt;
Gradually, over a rolling 24 hours for a standard stake.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Can I see when rented energy will leave?&lt;/strong&gt;&lt;br&gt;
Only if the delegation is locked: see Unlock At. Otherwise it is usually taken back at the end of the rental term.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Does TronLink show the same numbers?&lt;/strong&gt;&lt;br&gt;
It reads the same chain data but may refresh later. Wallet steps are in &lt;a href="https://usdtpull.com/en/blog/send-usdt-from-tronlink-with-energy/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;sending USDT from TronLink with energy&lt;/a&gt;, and errors after a short balance are covered in the &lt;a href="https://usdtpull.com/en/blog/tron-out-of-energy-error/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;OUT OF ENERGY guide&lt;/a&gt;.&lt;/p&gt;




&lt;p&gt;&lt;em&gt;Network figures are from TronScan and TronGrid as of Oct 19, 2026; the rental rate is UsdtPull's rate on Nov 15, 2026. Drafted with AI assistance and checked by the author.&lt;/em&gt;&lt;/p&gt;

</description>
      <category>tron</category>
      <category>blockchain</category>
      <category>api</category>
      <category>tutorial</category>
    </item>
    <item>
      <title>TRON Bandwidth Cost: What Happens When Free Bandwidth Runs Out</title>
      <dc:creator>UsdtPull</dc:creator>
      <pubDate>Wed, 25 Nov 2026 10:29:00 +0000</pubDate>
      <link>https://dev.to/usdtpull_com/tron-bandwidth-cost-what-happens-when-free-bandwidth-runs-out-402m</link>
      <guid>https://dev.to/usdtpull_com/tron-bandwidth-cost-what-happens-when-free-bandwidth-runs-out-402m</guid>
      <description>&lt;p&gt;&lt;em&gt;Disclosure: I work on UsdtPull, a TRON energy rental service. This article was first published on the &lt;a href="https://usdtpull.com/en/blog/tron-bandwidth-cost/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;UsdtPull blog&lt;/a&gt;.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;When your free bandwidth runs out, TRON burns TRX at 1,000 SUN (0.001 TRX) per unit of bandwidth, and one unit is one byte of the transaction. A USDT transfer takes 345 units, so it costs 0.345 TRX; a plain TRX transfer usually takes 265 to 268 units and costs 0.265 to 0.268 TRX. Every address gets 600 free units per rolling 24 hours, enough for about 1.7 USDT transfers a day.&lt;/p&gt;

&lt;p&gt;All figures below are as of Oct 13, 2026, taken from the TRON chain parameters (&lt;a href="https://tronscan.org/#/sr/committee" rel="noopener noreferrer"&gt;TronScan&lt;/a&gt;) and real mainnet receipts.&lt;/p&gt;

&lt;h2&gt;
  
  
  How bandwidth is priced
&lt;/h2&gt;

&lt;p&gt;Bandwidth pays for the space a transaction takes in a block: the size of the signed transaction plus a fixed 64 units for its result (&lt;a href="https://developers.tron.network/docs/bandwidth-and-energy" rel="noopener noreferrer"&gt;TRON docs&lt;/a&gt;). The network pays for it in this order:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;bandwidth you got by staking TRX, or that another address delegated to you;&lt;/li&gt;
&lt;li&gt;the free allowance, 600 units per address (&lt;code&gt;getFreeNetLimit&lt;/code&gt;);&lt;/li&gt;
&lt;li&gt;a TRX burn at the &lt;code&gt;getTransactionFee&lt;/code&gt; rate, 1,000 SUN per unit.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;The formula for the burn is simple:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Bandwidth cost in TRX = transaction size in units × 1,000 SUN / 1,000,000&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;One detail changes the math: each step must cover the whole transaction on its own. If you have 200 free units left and need 345, the network does not use the 200 and burn for 145. It burns for all 345. The docs say it directly: the network "does not combine payment methods or burn TRX only for the portion that a quota does not cover" (&lt;a href="https://developers.tron.network/docs/paying-for-resources" rel="noopener noreferrer"&gt;paying for resources&lt;/a&gt;). Energy works differently, as explained in &lt;a href="https://usdtpull.com/en/blog/tron-energy-vs-bandwidth/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;TRON energy vs bandwidth&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  What common transactions cost
&lt;/h2&gt;

&lt;p&gt;We read the receipts of ten mainnet blocks from Oct 12-13, 2026: 656 USDT transfers and 1,509 TRX transfers. Here is what bandwidth costs when it is burned:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Transaction&lt;/th&gt;
&lt;th&gt;Bandwidth used&lt;/th&gt;
&lt;th&gt;Burn for bandwidth&lt;/th&gt;
&lt;th&gt;Other fixed fees&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;TRX transfer&lt;/td&gt;
&lt;td&gt;257 to 275, usually 265&lt;/td&gt;
&lt;td&gt;0.257 to 0.275 TRX&lt;/td&gt;
&lt;td&gt;none&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;USDT transfer (613 of 656 in our sample)&lt;/td&gt;
&lt;td&gt;345&lt;/td&gt;
&lt;td&gt;0.345 TRX&lt;/td&gt;
&lt;td&gt;none; energy is charged separately&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;USDT transfer, other sizes seen&lt;/td&gt;
&lt;td&gt;338 to 479&lt;/td&gt;
&lt;td&gt;0.338 to 0.479 TRX&lt;/td&gt;
&lt;td&gt;depends on the transaction&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;USDT transfer signed by 3 keys (multi-signature)&lt;/td&gt;
&lt;td&gt;479&lt;/td&gt;
&lt;td&gt;0.479 TRX&lt;/td&gt;
&lt;td&gt;+1 TRX&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;TRX or token transfer with a memo note&lt;/td&gt;
&lt;td&gt;more bytes than without&lt;/td&gt;
&lt;td&gt;depends on memo length&lt;/td&gt;
&lt;td&gt;+1 TRX (&lt;code&gt;getMemoFee&lt;/code&gt;)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;TRX transfer to a never-used address&lt;/td&gt;
&lt;td&gt;normal size&lt;/td&gt;
&lt;td&gt;0.1 TRX unless staked or delegated bandwidth covers it&lt;/td&gt;
&lt;td&gt;+1 TRX account creation&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Two of these lines are worth a closer look.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Multi-signature.&lt;/strong&gt; &lt;a href="https://tronscan.org/#/transaction/44865d5c692c2e9dd24cce21a1868a255a6852194ef7a6fa1fbf6aba45e2f270" rel="noopener noreferrer"&gt;This USDT transfer&lt;/a&gt; carries three signatures. It used 479 bandwidth instead of 345, and its total fee was 7,428,500 SUN: 6,428,500 for energy plus exactly 1,000,000, which matches the network's multi-signature fee parameter (1 TRX).&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Account creation.&lt;/strong&gt; Sending TRX to an address that has never been used creates an account. That costs 1 TRX, and the bandwidth for it cannot come from the free allowance: if your staked or delegated bandwidth does not cover it, the network burns another 0.1 TRX (&lt;a href="https://developers.tron.network/docs/paying-for-resources" rel="noopener noreferrer"&gt;paying for resources&lt;/a&gt;).&lt;/p&gt;

&lt;h2&gt;
  
  
  How far 600 free units go
&lt;/h2&gt;

&lt;p&gt;The free allowance recovers over a rolling 24-hour window, so on average you get 600 units a day:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;USDT transfers: 600 / 345 = about &lt;strong&gt;1.7 a day&lt;/strong&gt;;&lt;/li&gt;
&lt;li&gt;TRX transfers of 265 to 268 units: about &lt;strong&gt;2.2 a day&lt;/strong&gt; (600 / 268 = 2.24).&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;In practice, timing decides whether you pay. Say you send two USDT transfers ten minutes apart with a full allowance:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;first transfer: 345 of 600 used, nothing burned;&lt;/li&gt;
&lt;li&gt;second transfer: about 255 left, which does not cover 345, so the network burns &lt;strong&gt;0.345 TRX&lt;/strong&gt;.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Space the same two transfers half a day apart, and part of the first 345 has already recovered, so the second one may go through for free.&lt;/p&gt;

&lt;p&gt;In our sample, 283 of 656 USDT transfers (43.1%) burned TRX for bandwidth, while only 72 (11%) burned anything for energy. For TRX transfers the share was 188 of 1,509 (12.5%). Ten blocks are not the whole network, but the pattern is clear: senders plan energy and forget bandwidth.&lt;/p&gt;

&lt;h2&gt;
  
  
  How the price has changed
&lt;/h2&gt;

&lt;p&gt;Both bandwidth parameters are set by votes of Super Representatives. From the list of approved proposals on the TRON mainnet:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Proposal&lt;/th&gt;
&lt;th&gt;Approved&lt;/th&gt;
&lt;th&gt;Change&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;#48&lt;/td&gt;
&lt;td&gt;Nov 2020&lt;/td&gt;
&lt;td&gt;Burn price set to 40 SUN per unit&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;#51&lt;/td&gt;
&lt;td&gt;Feb 2021&lt;/td&gt;
&lt;td&gt;Burn price raised to 140 SUN&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;#67&lt;/td&gt;
&lt;td&gt;Jul 2021&lt;/td&gt;
&lt;td&gt;Burn price raised to 1,000 SUN&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;#69&lt;/td&gt;
&lt;td&gt;Sep 2021&lt;/td&gt;
&lt;td&gt;Free allowance set to 1,500 units a day&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;#87&lt;/td&gt;
&lt;td&gt;Jul 2023&lt;/td&gt;
&lt;td&gt;Free allowance cut to 600 units a day&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;The burn price has stayed at 1,000 SUN for more than five years, while the energy price was cut twice since 2024 (see &lt;a href="https://usdtpull.com/en/blog/what-is-tron-energy/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;What is TRON energy&lt;/a&gt;). The free allowance has shrunk, so before July 2023 the free 1,500 units covered about four USDT transfers of today's size a day; now it is one, sometimes two.&lt;/p&gt;

&lt;h2&gt;
  
  
  Burn or stake for bandwidth: a model calculation
&lt;/h2&gt;

&lt;p&gt;Model calculation, network figures as of Oct 13, 2026. Staking yield for bandwidth is 43,200,000,000 units a day shared among 26,685,858,067 staked TRX, that is &lt;strong&gt;1.62 units per staked TRX per day&lt;/strong&gt;. The free allowance is left out for simplicity.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;USDT transfers a day&lt;/th&gt;
&lt;th&gt;Bandwidth a day&lt;/th&gt;
&lt;th&gt;Burned per day&lt;/th&gt;
&lt;th&gt;Burned per 30 days&lt;/th&gt;
&lt;th&gt;TRX to stake instead&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;1&lt;/td&gt;
&lt;td&gt;345&lt;/td&gt;
&lt;td&gt;0.345 TRX&lt;/td&gt;
&lt;td&gt;10.35 TRX&lt;/td&gt;
&lt;td&gt;about 213 TRX&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;10&lt;/td&gt;
&lt;td&gt;3,450&lt;/td&gt;
&lt;td&gt;3.45 TRX&lt;/td&gt;
&lt;td&gt;103.5 TRX&lt;/td&gt;
&lt;td&gt;about 2,131 TRX&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;100&lt;/td&gt;
&lt;td&gt;34,500&lt;/td&gt;
&lt;td&gt;34.5 TRX&lt;/td&gt;
&lt;td&gt;1,035 TRX&lt;/td&gt;
&lt;td&gt;about 21,312 TRX&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;How to read it: staking 213 TRX saves 10.35 TRX a month for one daily transfer. Over a year that is 125.9 TRX, more than half of the staked amount, and you keep the 213 TRX. The trade-offs are that staked TRX is locked and comes back only 14 days after unstaking, and that the staking yield changes as others stake or unstake.&lt;/p&gt;

&lt;p&gt;For comparison, energy for the same single daily transfer takes about 6,689 TRX staked. Bandwidth is the cheap resource to stake; energy is the expensive one. Energy options are compared on the &lt;a href="https://usdtpull.com/en/pricing/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;pricing page&lt;/a&gt; and in &lt;a href="https://usdtpull.com/en/blog/usdt-trc20-transfer-fee/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;the USDT TRC-20 fee guide&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  How to stop paying for bandwidth
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Check your allowance before sending.&lt;/strong&gt; Your address page in TronScan shows free and staked bandwidth. You need at least 345 for a USDT transfer.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Space out transfers&lt;/strong&gt; if you send one or two a day: the allowance recovers gradually.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Stake TRX for bandwidth&lt;/strong&gt; if you send several transfers every day. Use the table above to size the stake.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Skip the memo&lt;/strong&gt; unless the recipient requires one: it adds 1 TRX to the transaction.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Keep about 0.35 TRX on the address&lt;/strong&gt; for the days when the allowance runs short. Without TRX, a transaction that needs a burn cannot go through.&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  FAQ
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Is bandwidth free on TRON?&lt;/strong&gt;&lt;br&gt;
Partly. Each address gets 600 units per rolling 24 hours. Beyond that, the network burns 0.001 TRX per unit.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Why was I charged 0.345 TRX when I still had free bandwidth?&lt;/strong&gt;&lt;br&gt;
The free units you had left were fewer than 345. The allowance must cover the whole transaction, otherwise the network burns TRX for all of it.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Does renting energy cover bandwidth?&lt;/strong&gt;&lt;br&gt;
No. Energy pays for the contract call only. Bandwidth comes from staking, delegation, the free allowance or a burn.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Can bandwidth be delegated like energy?&lt;/strong&gt;&lt;br&gt;
Yes. An address can delegate staked bandwidth to another address with the same operation used for energy. More answers are in the &lt;a href="https://usdtpull.com/en/faq/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;FAQ&lt;/a&gt;.&lt;/p&gt;




&lt;p&gt;&lt;em&gt;Network figures are from the TRON chain parameters, mainnet receipts and the TRON developer documentation as of Oct 13, 2026. Drafted with AI assistance and checked by the author.&lt;/em&gt;&lt;/p&gt;

</description>
      <category>tron</category>
      <category>blockchain</category>
      <category>cryptocurrency</category>
      <category>web3</category>
    </item>
    <item>
      <title>TRON Energy Rental API: How Automated Energy Orders Work</title>
      <dc:creator>UsdtPull</dc:creator>
      <pubDate>Mon, 16 Nov 2026 06:01:03 +0000</pubDate>
      <link>https://dev.to/usdtpull_com/tron-energy-rental-api-how-automated-energy-orders-work-1pdp</link>
      <guid>https://dev.to/usdtpull_com/tron-energy-rental-api-how-automated-energy-orders-work-1pdp</guid>
      <description>&lt;p&gt;&lt;em&gt;Disclosure: I work on UsdtPull, a TRON energy rental service. This article was first published on the &lt;a href="https://usdtpull.com/en/blog/tron-energy-rental-api/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;UsdtPull blog&lt;/a&gt;.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;A TRON energy rental API lets your own system put energy on a sending address right before it sends USDT, so the network uses that energy instead of burning TRX. The flow has four calls: get a price, create an order for the right amount of energy, check that the order went through, then sign and send the transfer as usual. Below we map this flow to the methods that are actually listed in the UsdtPull API documentation as of Oct 13, 2026.&lt;/p&gt;

&lt;h2&gt;
  
  
  What the API does and what it never touches
&lt;/h2&gt;

&lt;p&gt;An energy order only needs a TRON address. UsdtPull delegates energy to that address for the rental term, and when the term ends the energy goes back on its own. The USDT transfer itself is still created and signed by your system with your own key. The API never sees private keys or recovery phrases, and it cannot move funds from the address.&lt;/p&gt;

&lt;p&gt;So the API key can spend your service balance on orders, but it has no power over your payout wallets. Every delegation is an on-chain operation you can check in the TronScan block explorer.&lt;/p&gt;

&lt;p&gt;One network rule to keep in mind: energy can only be delegated to an address that already exists on chain. The java-tron code rejects a delegation to an account that has not been activated, so a brand new address first needs an incoming TRX transfer.&lt;/p&gt;

&lt;h2&gt;
  
  
  Which methods the documentation lists
&lt;/h2&gt;

&lt;p&gt;The &lt;a href="https://usdtpull.apidog.io/" rel="noopener noreferrer"&gt;API documentation&lt;/a&gt; groups methods by service. For energy, these are the ones you need:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Task&lt;/th&gt;
&lt;th&gt;Method&lt;/th&gt;
&lt;th&gt;Key fields&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;See available energy tariffs&lt;/td&gt;
&lt;td&gt;&lt;code&gt;GET /v1/energy/tariffs/for-user&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;energyVolume, duration, priceTrx&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Get a price without ordering&lt;/td&gt;
&lt;td&gt;&lt;code&gt;GET /v1/energy/orders/quote&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;priceTrx, markupSun, minVolume, maxVolume&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Order a ready-made tariff&lt;/td&gt;
&lt;td&gt;&lt;code&gt;POST /v1/energy/orders/preset&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;tariffId, toAddress, currency&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Order any amount of energy&lt;/td&gt;
&lt;td&gt;&lt;code&gt;POST /v1/energy/orders/custom&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;volume, toAddress, currency&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;List your orders and their status&lt;/td&gt;
&lt;td&gt;&lt;code&gt;GET /v1/energy/orders/for-user&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;StatusType, PageNumber, PageSize&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Check the service balance&lt;/td&gt;
&lt;td&gt;&lt;code&gt;GET /v1/crypto/account/balance&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;balance, availableBalance&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;A few details from the same documentation that shape the integration:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Rental term.&lt;/strong&gt; The duration field has one value, &lt;code&gt;Hour1&lt;/code&gt;. Plan each order so the transfers it covers go out within that hour.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Payment.&lt;/strong&gt; An order is charged to your balance in the service, in TRX or USDT (&lt;code&gt;currency&lt;/code&gt; field).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Order status.&lt;/strong&gt; The documented statuses are Created, Delegating, Delegated, Confirmed, Failed and Expired. There is no "get one order by id" method, so you track orders through the list endpoint.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Beyond energy, the documentation also covers always-on energy on an address (subscriptions with a daily price quote and a refill history), bandwidth orders, AML checks, wallet tracking, the USDT freeze check, crypto acquiring and the TRON node subscription. The &lt;a href="https://usdtpull.com/en/api/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;API page&lt;/a&gt; gives an overview of these groups.&lt;/p&gt;

&lt;h2&gt;
  
  
  How requests are signed
&lt;/h2&gt;

&lt;p&gt;Every request carries four headers: &lt;code&gt;X-Api-Key&lt;/code&gt;, &lt;code&gt;X-Timestamp&lt;/code&gt;, &lt;code&gt;X-Nonce&lt;/code&gt; and &lt;code&gt;X-Signature&lt;/code&gt;. The signature is an HMAC-SHA256 over five lines joined with &lt;code&gt;\n&lt;/code&gt;: the timestamp, the nonce, the HTTP method, the path with query string, and the request body exactly as sent. The result is Base64-encoded.&lt;/p&gt;

&lt;p&gt;The documented limits:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;the timestamp must be within 2 minutes of the server time;&lt;/li&gt;
&lt;li&gt;a nonce cannot be reused for 5 minutes;&lt;/li&gt;
&lt;li&gt;the key is tied to the IP address it was issued from;&lt;/li&gt;
&lt;li&gt;a single identity can send 10 requests per second or 300 per minute, and above that the API answers 429 with a Retry-After header.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Here is what signing looks like in Node.js. This is an illustrative example, the exact format is in the documentation:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="c1"&gt;// illustrative example, the exact format is in the documentation&lt;/span&gt;
&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="n"&gt;crypto&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="s1"&gt;'node:crypto'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;signedHeaders&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;method&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;pathWithQuery&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;body&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;apiKey&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;secret&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="n"&gt;timestamp&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nb"&gt;Math&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;floor&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nb"&gt;Date&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;now&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;/&lt;/span&gt; &lt;span class="mi"&gt;1000&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;toString&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="n"&gt;nonce&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;crypto&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;randomUUID&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="n"&gt;payload&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="n"&gt;timestamp&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;nonce&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;method&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;pathWithQuery&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;body&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;join&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s1"&gt;'\n'&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="n"&gt;signature&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;crypto&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;createHmac&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s1"&gt;'sha256'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;secret&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;update&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;payload&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="s1"&gt;'utf8'&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;digest&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s1"&gt;'base64'&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="s1"&gt;'X-Api-Key'&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;apiKey&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="s1"&gt;'X-Timestamp'&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;timestamp&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="s1"&gt;'X-Nonce'&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;nonce&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="s1"&gt;'X-Signature'&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;signature&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Sign the body string you actually send. If you serialize the JSON twice, a single changed space breaks the signature.&lt;/p&gt;

&lt;h2&gt;
  
  
  The order flow, step by step
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Check the recipient.&lt;/strong&gt; If the recipient's address already holds USDT, the transfer needs about 65,000 energy. If it holds none, about 131,000. On Oct 13, 2026 we sampled one block (87067211) with 82 USDT transfers: 68 used exactly 64,285 energy and 14 used exactly 130,285.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Get a quote.&lt;/strong&gt; Call the quote method with the amount type Custom, the volume and the currency. Use &lt;code&gt;minVolume&lt;/code&gt; and &lt;code&gt;maxVolume&lt;/code&gt; from the answer to validate the order before you place it.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Create the order.&lt;/strong&gt; Send the volume, the sending address (&lt;code&gt;toAddress&lt;/code&gt; is the address that receives the energy, which is your payout address) and the currency.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Wait for delegation.&lt;/strong&gt; Read the order list until your order reaches Delegated or Confirmed. The documentation names the statuses but does not describe each one, so on your first orders also check the delegation in TronScan. If the order ends up Failed, do not send: without energy the network burns TRX.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Send the transfer.&lt;/strong&gt; Sign and broadcast the USDT transfer from your own code.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Check the receipt.&lt;/strong&gt; The transaction page in TronScan shows the energy used and whether any TRX was burned.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;The body of a custom order is short. Again, this is an illustrative example, the exact format is in the documentation:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight http"&gt;&lt;code&gt;&lt;span class="no"&gt;POST&lt;/span&gt; &lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="n"&gt;v1&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="n"&gt;energy&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="n"&gt;orders&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="n"&gt;custom&lt;/span&gt;
&lt;span class="nc"&gt;Content&lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="nc"&gt;Type&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;application&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="n"&gt;json&lt;/span&gt;

&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="s2"&gt;"volume"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;65000&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="s2"&gt;"toAddress"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"TXa4...q9Rm"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="s2"&gt;"currency"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Trx"&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The base URL is not part of this example on purpose: take it from the documentation.&lt;/p&gt;

&lt;h2&gt;
  
  
  What an order saves, in numbers
&lt;/h2&gt;

&lt;p&gt;Take the current rate on Nov 15, 2026, 28 SUN per unit of energy for 1 hour. The rate changes. The exact price is shown in the app before you pay, and reference prices are on the &lt;a href="https://usdtpull.com/en/pricing/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;pricing page&lt;/a&gt;. Network burn is 100 SUN per unit as of Oct 13, 2026 (TronScan chain parameters).&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Transfer&lt;/th&gt;
&lt;th&gt;Energy used (measured)&lt;/th&gt;
&lt;th&gt;TRX burned without energy&lt;/th&gt;
&lt;th&gt;Rental at 28 SUN&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Recipient holds USDT&lt;/td&gt;
&lt;td&gt;64,285&lt;/td&gt;
&lt;td&gt;6.43 TRX&lt;/td&gt;
&lt;td&gt;1.8 TRX&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Recipient has no USDT&lt;/td&gt;
&lt;td&gt;130,285&lt;/td&gt;
&lt;td&gt;13.03 TRX&lt;/td&gt;
&lt;td&gt;3.65 TRX&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;The formula is the same for any rate: TRX = energy × rate in SUN / 1,000,000. The USDT contract's dynamic energy factor is 34,000 as of Oct 13, 2026, which equals the network maximum, so under current parameters these per-transfer figures sit at the top of the dynamic model.&lt;/p&gt;

&lt;h2&gt;
  
  
  A request budget for high volume
&lt;/h2&gt;

&lt;p&gt;The rate limit is easy to hit if every payout makes its own calls. Count the requests per payout:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;naive flow: 1 quote + 1 order + 1 status check = 3 requests, so 300 per minute allows at most 100 payouts a minute;&lt;/li&gt;
&lt;li&gt;batched status checks: read the order list once per cycle for all pending orders. That brings you close to 2 requests per payout (quote and order), or about 150 payouts a minute;&lt;/li&gt;
&lt;li&gt;if you also skip the quote when the volume is a standard 65,000 or 131,000 you have already validated, you get close to 1 request per payout.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;For a steady payout flow from one address, always-on energy removes the per-transfer order entirely: the address is topped up after each transaction. How this works for payout services and exchanges is described on the &lt;a href="https://usdtpull.com/en/business/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;For business&lt;/a&gt; page, and a cost model for 100 to 1,000 transfers a day is in &lt;a href="https://usdtpull.com/en/blog/exchange-usdt-transfer-costs/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;USDT transfer costs for exchanges&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Things to code for from day one
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Keep TRX for bandwidth.&lt;/strong&gt; A USDT transfer takes about 345 bandwidth. The free daily allowance is 600, so a busy address burns 1,000 SUN per unit, about 0.35 TRX per transfer, unless it has its own bandwidth.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Treat Failed as "do not send".&lt;/strong&gt; Retry the order or hold the payout. Sending anyway costs the full burn price.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Set a fee limit.&lt;/strong&gt; If energy falls short and the fee limit is too low, the transfer fails with OUT_OF_ENERGY, as explained in &lt;a href="https://usdtpull.com/en/blog/tron-out-of-energy-error/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;the out-of-energy error guide&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Start with one small order.&lt;/strong&gt; Check the first delegations on TronScan before you scale the flow up.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Open the &lt;a href="https://app.usdtpull.com/register" rel="noopener noreferrer"&gt;UsdtPull app&lt;/a&gt; to create an API key and see the current rate.&lt;/p&gt;

&lt;h2&gt;
  
  
  FAQ
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Does the API need my private key?&lt;/strong&gt;&lt;br&gt;
No. Orders only need the address that should receive energy. You sign USDT transfers yourself.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Can I order energy for a new, empty address?&lt;/strong&gt;&lt;br&gt;
Only after it has been activated with an incoming TRX transfer. The network rejects delegation to an address that does not exist on chain yet.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;How long does rented energy stay on the address?&lt;/strong&gt;&lt;br&gt;
The documentation lists one rental term, 1 hour. After that the energy returns automatically.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;What if the recipient might be a new address?&lt;/strong&gt;&lt;br&gt;
Order 131,000. If the transfer turns out standard, the rest stays on the address until the term ends and can cover the next transfer. Why the two amounts differ is covered in &lt;a href="https://usdtpull.com/en/blog/why-transfer-to-new-address-costs-more/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;why sending to a new address costs more&lt;/a&gt;.&lt;/p&gt;




&lt;p&gt;&lt;em&gt;API methods are from the UsdtPull API documentation and network figures from TronScan as of Oct 13, 2026; the rental rate is UsdtPull's rate on Nov 15, 2026. Drafted with AI assistance and checked by the author.&lt;/em&gt;&lt;/p&gt;

</description>
      <category>tron</category>
      <category>api</category>
      <category>blockchain</category>
      <category>cryptocurrency</category>
    </item>
    <item>
      <title>Estimate TRON Energy Before a USDT Transfer with triggerconstantcontract</title>
      <dc:creator>UsdtPull</dc:creator>
      <pubDate>Sun, 15 Nov 2026 08:39:21 +0000</pubDate>
      <link>https://dev.to/usdtpull_com/estimate-tron-energy-before-a-usdt-transfer-with-triggerconstantcontract-2jm0</link>
      <guid>https://dev.to/usdtpull_com/estimate-tron-energy-before-a-usdt-transfer-with-triggerconstantcontract-2jm0</guid>
      <description>&lt;p&gt;&lt;em&gt;Disclosure: I work on UsdtPull, a TRON energy rental service. This article was first published on the &lt;a href="https://usdtpull.com/en/blog/estimate-energy-triggerconstantcontract/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;UsdtPull blog&lt;/a&gt;.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;To estimate the energy of a USDT transfer before you send it, simulate the call: post the sender, the USDT contract, &lt;code&gt;transfer(address,uint256)&lt;/code&gt; and the ABI-encoded arguments to &lt;code&gt;wallet/triggerconstantcontract&lt;/code&gt;, then read &lt;code&gt;energy_used&lt;/code&gt;. On Nov 2, 2026 the public TronGrid node returned 64,285 for a recipient that holds USDT and 130,285 for one that holds none, exactly what the chain charged for real transfers that morning. The other method, &lt;code&gt;wallet/estimateenergy&lt;/code&gt;, answered "this node does not support estimate energy".&lt;/p&gt;

&lt;p&gt;From that number you get the energy to rent and the &lt;code&gt;fee_limit&lt;/code&gt;. Below: the calls, the results and when the estimate misses.&lt;/p&gt;

&lt;h2&gt;
  
  
  Two endpoints, one question
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;&lt;/th&gt;
&lt;th&gt;&lt;code&gt;wallet/triggerconstantcontract&lt;/code&gt;&lt;/th&gt;
&lt;th&gt;&lt;code&gt;wallet/estimateenergy&lt;/code&gt;&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;What it returns&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;energy_used&lt;/code&gt; (total) and &lt;code&gt;energy_penalty&lt;/code&gt; (the dynamic part inside it)&lt;/td&gt;
&lt;td&gt;&lt;code&gt;energy_required&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;On api.trongrid.io, Nov 2, 2026&lt;/td&gt;
&lt;td&gt;worked&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;CONTRACT_VALIDATE_ERROR&lt;/code&gt;: this node does not support estimate energy&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Node setting&lt;/td&gt;
&lt;td&gt;needs constant calls allowed (&lt;code&gt;vm.supportConstant&lt;/code&gt;)&lt;/td&gt;
&lt;td&gt;closed by default; needs &lt;code&gt;vm.estimateEnergy&lt;/code&gt; and &lt;code&gt;vm.supportConstant&lt;/code&gt; in the node config&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Writes to chain&lt;/td&gt;
&lt;td&gt;no, the unsigned transaction is not broadcast&lt;/td&gt;
&lt;td&gt;no&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;The &lt;a href="https://developers.tron.network/reference/estimateenergy" rel="noopener noreferrer"&gt;estimateenergy reference&lt;/a&gt; calls &lt;code&gt;triggerconstantcontract&lt;/code&gt; sufficient for most contracts and &lt;code&gt;estimateenergy&lt;/code&gt; possibly more precise for a few special ones. For USDT the simulation matched the receipts to the unit, so it is the method to build on; &lt;code&gt;estimateenergy&lt;/code&gt; is an option only on a node that has it turned on, such as your own.&lt;/p&gt;

&lt;h2&gt;
  
  
  Building the request
&lt;/h2&gt;

&lt;p&gt;&lt;code&gt;function_selector&lt;/code&gt; is the plain signature, with no spaces. &lt;code&gt;parameter&lt;/code&gt; is the arguments in ABI encoding, as one hex string of 32-byte words:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;word 1, the recipient:&lt;/strong&gt; the hex address without the &lt;code&gt;41&lt;/code&gt; prefix, padded with zeros on the left to 64 characters;&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;word 2, the amount:&lt;/strong&gt; in the token's smallest units. USDT has 6 decimals, so 10 USDT is 10,000,000, or &lt;code&gt;989680&lt;/code&gt; in hex, padded the same way.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;code&gt;owner_address&lt;/code&gt; must be the real sender: the node runs the contract against its balance.&lt;/p&gt;

&lt;p&gt;Illustrative example, check the exact format in the TRON documentation:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -s https://api.trongrid.io/wallet/triggerconstantcontract \
  -H &lt;span class="s1"&gt;'content-type: application/json'&lt;/span&gt; \
  -d &lt;span class="s1"&gt;'{
    "owner_address": "TU4vEruvZwLLkSfV9bNw12EJTPvNr7Pvaa",
    "contract_address": "TR7NHqjeKQxGTCi8q8ZY4pL8otSzgjLj6t",
    "function_selector": "transfer(address,uint256)",
    "parameter": "0000000000000000000000003aae419529463d07b5dd02fadb2788c9d24c31570000000000000000000000000000000000000000000000000000000000989680",
    "visible": true
  }'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;In TronWeb the library does the encoding. Illustrative example, check the exact format in the &lt;a href="https://tronweb.network/docu/docs/API%20List/transactionBuilder/triggerConstantContract" rel="noopener noreferrer"&gt;TronWeb docs&lt;/a&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="c1"&gt;// illustrative example, check the exact format in the TRON documentation&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="n"&gt;sim&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="n"&gt;tronWeb&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;transactionBuilder&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;triggerConstantContract&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
  &lt;span class="s1"&gt;'TR7NHqjeKQxGTCi8q8ZY4pL8otSzgjLj6t'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="s1"&gt;'transfer(address,uint256)'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="kd"&gt;type&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s1"&gt;'address'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;value&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;recipient&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="kd"&gt;type&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s1"&gt;'uint256'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;value&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;10_000_000&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="n"&gt;tronWeb&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;address&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;toHex&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;sender&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="n"&gt;ok&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;sim&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;transaction&lt;/span&gt;&lt;span class="o"&gt;?&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;ret&lt;/span&gt;&lt;span class="o"&gt;?&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="o"&gt;?&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;ret&lt;/span&gt; &lt;span class="o"&gt;!==&lt;/span&gt; &lt;span class="s1"&gt;'FAILED'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="n"&gt;energy&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;sim&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;energy_used&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  What TronGrid returned on Nov 2, 2026
&lt;/h2&gt;

&lt;p&gt;Sender: &lt;a href="https://tronscan.org/#/address/TU4vEruvZwLLkSfV9bNw12EJTPvNr7Pvaa" rel="noopener noreferrer"&gt;TU4vEr...7Pvaa&lt;/a&gt;, an address that held about 131 million USDT at the time of the calls. Amount: 10 USDT. We checked each recipient with a &lt;code&gt;balanceOf&lt;/code&gt; call first.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Call (UTC)&lt;/th&gt;
&lt;th&gt;Recipient&lt;/th&gt;
&lt;th&gt;Its USDT before&lt;/th&gt;
&lt;th&gt;&lt;code&gt;energy_used&lt;/code&gt;&lt;/th&gt;
&lt;th&gt;&lt;code&gt;energy_penalty&lt;/code&gt;&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;05:12:24&lt;/td&gt;
&lt;td&gt;&lt;a href="https://tronscan.org/#/address/TFKUwiY8YuSucXbPxESmnJpL9A37wpQkx1" rel="noopener noreferrer"&gt;TFKUwi...pQkx1&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;300.000001&lt;/td&gt;
&lt;td&gt;64,285&lt;/td&gt;
&lt;td&gt;49,635&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;05:12:32&lt;/td&gt;
&lt;td&gt;&lt;a href="https://tronscan.org/#/address/TQepJAfoBzn2HFDTeeu1R5RtbQW4tCjTom" rel="noopener noreferrer"&gt;TQepJA...CjTom&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;0&lt;/td&gt;
&lt;td&gt;130,285&lt;/td&gt;
&lt;td&gt;100,635&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;05:12:38 and 05:12:45&lt;/td&gt;
&lt;td&gt;the same two, via &lt;code&gt;estimateenergy&lt;/code&gt;
&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;not supported&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Then we read real receipts with &lt;code&gt;gettransactioninfobyid&lt;/code&gt;:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Transaction&lt;/th&gt;
&lt;th&gt;Block&lt;/th&gt;
&lt;th&gt;&lt;code&gt;energy_usage_total&lt;/code&gt;&lt;/th&gt;
&lt;th&gt;&lt;code&gt;energy_penalty_total&lt;/code&gt;&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;a href="https://tronscan.org/#/transaction/c1529f990eff64c4ea03e12aa7bad31e40939b248a19bcc4c91d789936d84bb3" rel="noopener noreferrer"&gt;c1529f99...&lt;/a&gt;, same sender to TFKUwi...pQkx1, 04:52:33&lt;/td&gt;
&lt;td&gt;87,640,554&lt;/td&gt;
&lt;td&gt;64,285&lt;/td&gt;
&lt;td&gt;49,635&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;a href="https://tronscan.org/#/transaction/b0ee3f24432b1a03b6dee843fb087ccc2bf66d0788371ff778bc740202f8195e" rel="noopener noreferrer"&gt;b0ee3f24...&lt;/a&gt;, same sender to another holder, 05:13:09&lt;/td&gt;
&lt;td&gt;87,640,966&lt;/td&gt;
&lt;td&gt;64,285&lt;/td&gt;
&lt;td&gt;49,635&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;a href="https://tronscan.org/#/transaction/4771d00bbde776a35c441ced2f0ab1b9bfbe1d38ad5033b071316f88e34f673d" rel="noopener noreferrer"&gt;4771d00b...&lt;/a&gt;, another sender to an address without USDT, 04:52:33&lt;/td&gt;
&lt;td&gt;87,640,554&lt;/td&gt;
&lt;td&gt;130,285&lt;/td&gt;
&lt;td&gt;100,635&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;All six figures match the simulation exactly. The dynamic part is 77% of the energy in both cases: the USDT contract sits at the maximum &lt;code&gt;energy_factor&lt;/code&gt;, which is why the penalty is so large (&lt;a href="https://usdtpull.com/en/blog/tron-energy-per-transaction/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;how dynamic energy works&lt;/a&gt;).&lt;/p&gt;

&lt;h3&gt;
  
  
  What a failed simulation looks like
&lt;/h3&gt;

&lt;p&gt;With an address holding no USDT as &lt;code&gt;owner_address&lt;/code&gt;, the answer was &lt;code&gt;energy_used&lt;/code&gt; 8,624, &lt;code&gt;message&lt;/code&gt; "REVERT opcode executed", an empty &lt;code&gt;constant_result&lt;/code&gt; and &lt;code&gt;transaction.ret[0].ret&lt;/code&gt; FAILED. The top-level &lt;code&gt;result.result&lt;/code&gt; was still &lt;code&gt;true&lt;/code&gt;: it reports the API request, not the contract. Check &lt;code&gt;ret&lt;/code&gt; before you trust the number.&lt;/p&gt;

&lt;h2&gt;
  
  
  From the estimate to an energy order
&lt;/h2&gt;

&lt;p&gt;Read what the sender already has with &lt;a href="https://developers.tron.network/reference/getaccountresource" rel="noopener noreferrer"&gt;getaccountresource&lt;/a&gt;: available energy = &lt;code&gt;EnergyLimit&lt;/code&gt; - &lt;code&gt;EnergyUsed&lt;/code&gt;, a missing field counts as 0. &lt;code&gt;EnergyLimit&lt;/code&gt; already includes energy delegated to the address, so a rental that is in place is counted once.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Shortfall = max(0, &lt;code&gt;energy_used&lt;/code&gt; - available)&lt;/strong&gt;. That is the volume to order.&lt;/p&gt;

&lt;p&gt;Our sender had an &lt;code&gt;EnergyLimit&lt;/code&gt; of 2,832,678,142 and &lt;code&gt;EnergyUsed&lt;/code&gt; of 959,730,701: about 1.87 billion free, shortfall 0. Its receipts show no &lt;code&gt;energy_fee&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;A small payout address is different. &lt;strong&gt;Model calculation:&lt;/strong&gt; the address has 20,000 energy left from its own stake and the next recipient holds no USDT. Shortfall = 130,285 - 20,000 = 110,285.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Shortfall&lt;/th&gt;
&lt;th&gt;Burned at 100 SUN, TRX&lt;/th&gt;
&lt;th&gt;Rented at 28 SUN for 1 hour, TRX&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;64,285 (no energy on the sender, recipient holds USDT)&lt;/td&gt;
&lt;td&gt;6.43&lt;/td&gt;
&lt;td&gt;1.80&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;110,285 (the model above)&lt;/td&gt;
&lt;td&gt;11.03&lt;/td&gt;
&lt;td&gt;3.09&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;130,285 (no energy on the sender, recipient without USDT)&lt;/td&gt;
&lt;td&gt;13.03&lt;/td&gt;
&lt;td&gt;3.65&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Rental figures use the current rate on Nov 15, 2026. The rate changes, and the exact price is shown in the service before you pay; reference prices are on the &lt;a href="https://usdtpull.com/en/pricing/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;pricing page&lt;/a&gt;. The order method that takes any volume, and how to sign it, are covered in the &lt;a href="https://usdtpull.com/en/blog/tron-energy-rental-api/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;energy rental API guide&lt;/a&gt; and on the &lt;a href="https://usdtpull.com/en/api/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;API page&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Setting fee_limit from the estimate
&lt;/h2&gt;

&lt;p&gt;The &lt;a href="https://developers.tron.network/docs/set-feelimit" rel="noopener noreferrer"&gt;fee limit guide&lt;/a&gt; gives three rules that matter here:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;fee_limit&lt;/code&gt; is in SUN and caps all the energy the caller covers, staked and delegated included, not only the part burned. So base it on the full &lt;code&gt;energy_used&lt;/code&gt;, never on the shortfall.&lt;/li&gt;
&lt;li&gt;The simple form is &lt;code&gt;energy_used&lt;/code&gt; × &lt;code&gt;getEnergyFee&lt;/code&gt;. At 100 SUN that is 6,428,500 SUN for 64,285 and 13,028,500 SUN for 130,285.&lt;/li&gt;
&lt;li&gt;The upper bound is base energy × (1 + max factor) × price, where base energy = &lt;code&gt;energy_used&lt;/code&gt; - &lt;code&gt;energy_penalty&lt;/code&gt; and the max factor is 3.4. For our two cases: 14,650 × 4.4 = 64,460 and 29,650 × 4.4 = 130,460, so 6,446,000 and 13,046,000 SUN.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;code&gt;fee_limit&lt;/code&gt; is a ceiling, not a charge, so a round margin costs nothing. Our own rounding, not a value from the guide: 15 TRX (15,000,000 SUN) covers both USDT cases at 100 SUN, far below the network maximum of 15,000 TRX (&lt;code&gt;getMaxFeeLimit&lt;/code&gt;, Nov 2, 2026). Too low a limit stops the transfer with OUT_OF_ENERGY even when the address has energy (&lt;a href="https://usdtpull.com/en/blog/tron-out-of-energy-error/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;the out-of-energy guide&lt;/a&gt;).&lt;/p&gt;

&lt;h2&gt;
  
  
  When the estimate and the receipt disagree
&lt;/h2&gt;

&lt;p&gt;The simulation runs on the state of one block. Three things change the answer before your transaction lands:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;The recipient's balance moves.&lt;/strong&gt; A holder that withdraws to zero turns 64,285 into 130,285; an empty address that receives USDT from someone else does the opposite. The gap is 66,000, explained in &lt;a href="https://usdtpull.com/en/blog/why-transfer-to-new-address-costs-more/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;why sending to a new address costs more&lt;/a&gt;. Estimate right before signing, not when the payout is queued.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;The dynamic factor moves.&lt;/strong&gt; The network updates a contract's &lt;code&gt;energy_factor&lt;/code&gt; once per maintenance period of 6 hours (&lt;code&gt;update_cycle&lt;/code&gt; 10,235 for USDT on Nov 2, 2026). USDT was at the cap of 34,000, so under current parameters the factor could only go down. Committee proposals can change the parameters themselves: see &lt;a href="https://usdtpull.com/en/blog/tron-committee-proposals-fees/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;how proposals change TRON fees&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;The sender is not the one you simulated.&lt;/strong&gt; The result depends on &lt;code&gt;owner_address&lt;/code&gt;. A wrong sender, or one without enough USDT, gives a revert, as in our test.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;One more for batches: the simulation neither checks nor reserves the sender's energy. It returns the same 64,285 whether the address has 70,000 free units or none, and ten queued transfers will each look fine on their own. Subtract every planned transfer from the available energy before you check the next one.&lt;/p&gt;

&lt;h2&gt;
  
  
  A pre-send check for a payout service
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Simulate&lt;/strong&gt; from the real sender; stop if &lt;code&gt;ret&lt;/code&gt; is FAILED.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Read&lt;/strong&gt; available energy and subtract transfers already planned.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Order&lt;/strong&gt; the shortfall plus a margin, and wait until &lt;code&gt;EnergyLimit&lt;/code&gt; grows.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Sign&lt;/strong&gt; with &lt;code&gt;fee_limit&lt;/code&gt; from the full estimate.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Send early in the rental term&lt;/strong&gt; (&lt;a href="https://usdtpull.com/en/blog/how-long-rented-tron-energy-lasts/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;how long rented energy lasts&lt;/a&gt;).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Log&lt;/strong&gt; the gap between &lt;code&gt;energy_usage_total&lt;/code&gt; and the estimate.&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  FAQ
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Does triggerconstantcontract cost energy or TRX?&lt;/strong&gt;&lt;br&gt;
No. The node runs the call without committing it, and the reference says it uses neither bandwidth nor energy of the account.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Why does estimateenergy return "this node does not support estimate energy"?&lt;/strong&gt;&lt;br&gt;
The method is off by default. On Nov 2, 2026 the public TronGrid node gave this answer to both of our calls; it works only on a node with the setting turned on.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Can I estimate a transfer from an address that has no USDT?&lt;/strong&gt;&lt;br&gt;
You get a revert and a small &lt;code&gt;energy_used&lt;/code&gt; that means nothing. Simulate from the address that will really send, with enough USDT for the amount.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Should fee_limit equal the energy I rent?&lt;/strong&gt;&lt;br&gt;
No. It caps all energy the transfer uses, so set it from the full estimate. More answers are in the &lt;a href="https://usdtpull.com/en/faq/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;FAQ&lt;/a&gt;.&lt;/p&gt;




&lt;p&gt;&lt;em&gt;Network figures are from TronGrid and the TRON developer documentation as of Nov 2, 2026; the rental rate is UsdtPull's rate on Nov 15, 2026. Drafted with AI assistance and checked by the author.&lt;/em&gt;&lt;/p&gt;

</description>
      <category>tron</category>
      <category>blockchain</category>
      <category>web3</category>
      <category>api</category>
    </item>
    <item>
      <title>How Energy Delegation Works on TRON</title>
      <dc:creator>UsdtPull</dc:creator>
      <pubDate>Thu, 12 Nov 2026 06:13:02 +0000</pubDate>
      <link>https://dev.to/usdtpull_com/how-energy-delegation-works-on-tron-45a6</link>
      <guid>https://dev.to/usdtpull_com/how-energy-delegation-works-on-tron-45a6</guid>
      <description>&lt;p&gt;&lt;em&gt;Disclosure: I work on UsdtPull, a TRON energy rental service. This article was first published on the &lt;a href="https://usdtpull.com/en/blog/how-tron-energy-delegation-works/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;UsdtPull blog&lt;/a&gt;.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Energy delegation on TRON lets an address that has staked TRX for energy hand that energy to another address, while the TRX itself never leaves the owner. The owner signs a &lt;code&gt;DelegateResource&lt;/code&gt; transaction that names a receiver and an amount in TRX, and the network turns that amount into energy at the current network ratio: as of Oct 19, 2026, 1 delegated TRX gives about 9.59 energy a day, so 65,000 energy needs about 6,778 TRX. The owner takes it back with &lt;code&gt;UnDelegateResource&lt;/code&gt;, at any moment unless the delegation was locked.&lt;/p&gt;

&lt;p&gt;Renting energy is this same operation with a price and a term. Below: the fields, the TRX math, locks, what happens to used energy, and a real delegation followed block by block.&lt;/p&gt;

&lt;h2&gt;
  
  
  What delegation moves and what it does not
&lt;/h2&gt;

&lt;p&gt;Delegation is part of Stake 2.0. According to the &lt;a href="https://developers.tron.network/docs/delegation" rel="noopener noreferrer"&gt;delegation guide&lt;/a&gt; in the TRON documentation:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;the TRX stays staked under the owner's name. Only the routing of the resource changes;&lt;/li&gt;
&lt;li&gt;energy and bandwidth can be delegated, TRON Power cannot: voting rights stay with the owner;&lt;/li&gt;
&lt;li&gt;TRX that is delegated cannot be unstaked until the owner takes the delegation back;&lt;/li&gt;
&lt;li&gt;the minimum is 1 TRX, an address cannot delegate to itself, and the receiver cannot be a contract. The java-tron code also requires the receiver to exist on chain, so a new address must be &lt;a href="https://usdtpull.com/en/blog/activate-tron-address/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;activated&lt;/a&gt; first;&lt;/li&gt;
&lt;li&gt;only the unused part of the owner's stake can be delegated. &lt;code&gt;wallet/getcandelegatedmaxsize&lt;/code&gt; returns how much an address can delegate right now.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;How the owner gets staked energy and the 14-day unstaking wait are in &lt;a href="https://usdtpull.com/en/blog/freeze-trx-vs-rent-energy/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;freeze TRX or rent energy&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  The two transactions and their fields
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Field&lt;/th&gt;
&lt;th&gt;DelegateResource&lt;/th&gt;
&lt;th&gt;Meaning&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;owner_address&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;required&lt;/td&gt;
&lt;td&gt;The address whose staked TRX backs the energy. It signs the transaction&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;receiver_address&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;required&lt;/td&gt;
&lt;td&gt;The address that gets the energy. It signs nothing&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;balance&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;required&lt;/td&gt;
&lt;td&gt;Amount in SUN of staked TRX, not an amount of energy&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;resource&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;required&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;ENERGY&lt;/code&gt; or &lt;code&gt;BANDWIDTH&lt;/code&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;lock&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;optional, default false&lt;/td&gt;
&lt;td&gt;If true, the owner cannot take the delegation back during the lock period&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;lock_period&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;optional&lt;/td&gt;
&lt;td&gt;Lock length in blocks, about 3 seconds each&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;&lt;code&gt;UnDelegateResource&lt;/code&gt; takes the same owner, receiver, balance and resource. Field names are from the &lt;a href="https://developers.tron.network/reference/delegateresource-1" rel="noopener noreferrer"&gt;delegateresource reference&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Only the owner signs. The receiver's address is just a value in someone else's transaction, so receiving energy never needs the receiver's key or signature.&lt;/p&gt;

&lt;h2&gt;
  
  
  How much TRX to delegate for 65,000 or 131,000 energy
&lt;/h2&gt;

&lt;p&gt;Because &lt;code&gt;balance&lt;/code&gt; is in TRX, the energy it produces depends on the network ratio:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;TRX to delegate = energy you need / (180,000,000,000 / total TRX staked for energy)&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;As of Oct 19, 2026, 05:12 UTC (TronGrid, &lt;code&gt;getTotalEnergyCurrentLimit&lt;/code&gt; and &lt;code&gt;TotalEnergyWeight&lt;/code&gt;): 180,000,000,000 / 18,769,301,712 = &lt;strong&gt;9.59 energy per TRX&lt;/strong&gt;.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Energy target&lt;/th&gt;
&lt;th&gt;What it covers&lt;/th&gt;
&lt;th&gt;TRX to delegate&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;64,285&lt;/td&gt;
&lt;td&gt;A standard USDT transfer, exact&lt;/td&gt;
&lt;td&gt;6,703.25&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;65,000&lt;/td&gt;
&lt;td&gt;A standard USDT transfer, rounded&lt;/td&gt;
&lt;td&gt;6,777.80&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;130,285&lt;/td&gt;
&lt;td&gt;A transfer to an address with no USDT, exact&lt;/td&gt;
&lt;td&gt;13,585.32&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;131,000&lt;/td&gt;
&lt;td&gt;Same, rounded&lt;/td&gt;
&lt;td&gt;13,659.88&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;These numbers show up on chain. In block 87,237,917 (Oct 19, 2026, 05:12:51 UTC) there were 30 energy delegations. Six were for exactly 6,778 TRX, one for 6,777.803396 TRX, which is the 65,000 target computed to the last SUN at that block's ratio, and three for 13,660 TRX.&lt;/p&gt;

&lt;h3&gt;
  
  
  The same TRX gives different energy over time
&lt;/h3&gt;

&lt;p&gt;Since the delegation is fixed in TRX, the receiver's energy floats with the network. On Oct 13, 2026, with 18,729,496,901 TRX staked for energy, 6,778 TRX produced 65,140 energy. By Oct 19 the total had grown by 0.21%, and the same 6,778 TRX gave 65,002. Over an hour the drift is invisible; over a month it can matter.&lt;/p&gt;

&lt;h2&gt;
  
  
  Locks: lock and lock_period
&lt;/h2&gt;

&lt;p&gt;A lock is the receiver's protection. Without it, the owner can undelegate at any time, even a few seconds after delegating.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;lock_period&lt;/code&gt; is counted in blocks. One hour is 1,200 blocks, one day 28,800.&lt;/li&gt;
&lt;li&gt;If &lt;code&gt;lock&lt;/code&gt; is true and &lt;code&gt;lock_period&lt;/code&gt; is 0, java-tron uses 86,400 blocks, about 3 days.&lt;/li&gt;
&lt;li&gt;The maximum is the chain parameter &lt;code&gt;getMaxDelegateLockPeriod&lt;/code&gt;. It was set to 864,000 blocks by Proposal #88 (July 2023) and is still 864,000 as of Oct 19, 2026: 864,000 × 3 seconds = &lt;strong&gt;30 days&lt;/strong&gt;. The java-tron proposal code allows this limit only to be raised, up to one year (10,512,000 blocks).&lt;/li&gt;
&lt;li&gt;A new locked delegation to the same receiver must last at least as long as the time left on the current lock, so a lock can be extended, never shortened.&lt;/li&gt;
&lt;li&gt;When a lock expires, nothing happens on its own: the energy stays with the receiver until the owner sends &lt;code&gt;UnDelegateResource&lt;/code&gt;.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Locks are rare in practice: none of the 37 delegations in the block above (30 for energy, 7 for bandwidth) used one.&lt;/p&gt;

&lt;h2&gt;
  
  
  What happens to used energy when the delegation ends
&lt;/h2&gt;

&lt;p&gt;Spent energy is counted as usage and recovers over 24 hours. When the owner undelegates, the network moves part of the receiver's unrecovered usage back to the owner (&lt;a href="https://developers.tron.network/docs/resource-reclamation-upon-undelegation" rel="noopener noreferrer"&gt;resource reclamation&lt;/a&gt;):&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Usage moved to owner = (TRX undelegated / receiver's total TRX for energy) × receiver's unrecovered usage&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The result is capped at the energy that the undelegated TRX give at the current network ratio.&lt;/p&gt;

&lt;p&gt;If the receiver has no stake of its own and the whole delegation is withdrawn, the fraction is 1: all the usage goes to the owner, and the receiver is left with neither energy nor debt. If the receiver also stakes TRX, only the delegated share moves. Delegated energy that was not spent leaves with the delegation.&lt;/p&gt;

&lt;h2&gt;
  
  
  A real delegation, block by block
&lt;/h2&gt;

&lt;p&gt;Here is one delegation cycle from Oct 19, 2026, checked through the TronGrid API:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Time (UTC)&lt;/th&gt;
&lt;th&gt;Block&lt;/th&gt;
&lt;th&gt;Transaction&lt;/th&gt;
&lt;th&gt;What happened&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;05:12:51&lt;/td&gt;
&lt;td&gt;87,237,917&lt;/td&gt;
&lt;td&gt;&lt;a href="https://tronscan.org/#/transaction/27c57c1834df0638a9043201f6d2ec997bc6e1168430ac98c97a481b41ae2fba" rel="noopener noreferrer"&gt;DelegateResource&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;6,778 TRX of energy from TWkvff...98cdn to TMkZ8A...BzT2fp&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;05:12:57&lt;/td&gt;
&lt;td&gt;87,237,919&lt;/td&gt;
&lt;td&gt;&lt;a href="https://tronscan.org/#/transaction/1deb3fe93ad71bd5440694714ca7c24080ce9db03e7b453f049c5df9cde6bd36" rel="noopener noreferrer"&gt;USDT transfer&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;The receiver sent USDT, used 64,285 energy and 345 bandwidth, burned 0 TRX&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;05:13:00&lt;/td&gt;
&lt;td&gt;87,237,920&lt;/td&gt;
&lt;td&gt;&lt;a href="https://tronscan.org/#/transaction/ebc029121ae325106217194e2c95e2f6fa40fb46ae7175a667094f8ebd56c5d6" rel="noopener noreferrer"&gt;UnDelegateResource&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;The same 6,778 TRX taken back&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;What the cycle shows:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;The receiver paid nothing for the delegation.&lt;/strong&gt; The &lt;code&gt;DelegateResource&lt;/code&gt; transaction cost the owner 279 bandwidth and no energy; nothing was charged to the receiver.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;The energy matched the target.&lt;/strong&gt; At that block's ratio, 6,778 TRX gave about 65,002 energy; the transfer needed 64,285, leaving about 717 unused.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;The owner took it back after 9 seconds.&lt;/strong&gt; With no lock, nothing guaranteed the receiver that it would come after the transfer.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;The usage left with the delegation.&lt;/strong&gt; The receiver has no stake of its own, so by the reclaim formula all of its usage, about 64,285 units, moved to the owner.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;For a renter, step 3 is the lesson: send the transfer as soon as the energy arrives, inside the paid term. What a provider can and cannot do to your address is in &lt;a href="https://usdtpull.com/en/blog/is-tron-energy-rental-safe/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;is renting TRON energy safe&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  How to see a delegation in TronScan
&lt;/h2&gt;

&lt;p&gt;Open the transaction by hash on &lt;a href="https://tronscan.org" rel="noopener noreferrer"&gt;tronscan.org&lt;/a&gt;. A delegation page names the operation, both addresses, the resource and the amount in TRX, and TronScan converts that TRX into energy at the ratio of the moment you open the page, so the figure drifts: for the delegation above its API returned 65,007.62 at about 05:40 UTC on Oct 19, 2026.&lt;/p&gt;

&lt;p&gt;The same transaction appears in the history of both addresses. The receiver's address page shows its available energy, delegated energy included. For an exact list, the node API has &lt;code&gt;wallet/getdelegatedresourcev2&lt;/code&gt; (how much one address delegates to another) and &lt;code&gt;wallet/getdelegatedresourceaccountindexv2&lt;/code&gt; (who an address delegates to and receives from).&lt;/p&gt;

&lt;h2&gt;
  
  
  Delegating energy yourself, step by step
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Stake TRX for energy&lt;/strong&gt; under Stake 2.0.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Check what is free to delegate&lt;/strong&gt; with &lt;code&gt;getcandelegatedmaxsize&lt;/code&gt;. Energy used in the last 24 hours reduces it.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Check the receiver&lt;/strong&gt;: activated, not a contract.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Enter the amount in TRX&lt;/strong&gt;, from the table above plus a small margin.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Decide on a lock&lt;/strong&gt;: it gives the receiver a guarantee, but you cannot take the energy back early.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Sign, check in TronScan&lt;/strong&gt;, and undelegate when the job is done.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Renting replaces steps 1 to 6 with one order: the provider delegates from its own stake. At the current rate on Nov 12, 2026, 30 SUN per unit for 1 hour, 65,000 energy costs 65,000 × 30 SUN = 1.95 TRX, against about 6,778 TRX staked to delegate it yourself. The rate changes. The exact price is shown in the service before you pay, and reference prices are on the &lt;a href="https://usdtpull.com/en/pricing/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;pricing page&lt;/a&gt;. Ordering steps are in the &lt;a href="https://usdtpull.com/en/guides/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;guides&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  FAQ
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Does the receiver have to sign anything?&lt;/strong&gt;&lt;br&gt;
No. &lt;code&gt;DelegateResource&lt;/code&gt; and &lt;code&gt;UnDelegateResource&lt;/code&gt; are signed by the owner only.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;How long can energy be locked?&lt;/strong&gt;&lt;br&gt;
Up to 864,000 blocks, about 30 days, as of Oct 19, 2026. Without a lock, the owner can take the energy back at any time.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Can I rent energy without staking anything?&lt;/strong&gt;&lt;br&gt;
Yes. The provider delegates from its own stake; your address only receives. More answers are in the &lt;a href="https://usdtpull.com/en/faq/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=nov2026_free" rel="noopener noreferrer"&gt;FAQ&lt;/a&gt;.&lt;/p&gt;




&lt;p&gt;&lt;em&gt;Network figures are from TronScan and the TRON developer documentation as of Oct 19, 2026; the rental rate is UsdtPull's rate on Nov 12, 2026. Drafted with AI assistance and checked by the author.&lt;/em&gt;&lt;/p&gt;

</description>
      <category>tron</category>
      <category>blockchain</category>
      <category>web3</category>
      <category>cryptocurrency</category>
    </item>
  </channel>
</rss>
