Get you own node endpoint todayStart for free and get your app to production levels immediately. No credit card required.You can sign up with your GitHub, X, Google, or Microsoft account.
Inputs
ivk— incoming viewing key as a 32‑byte (64‑hex) string, no0xprefix.d— diversifier as 11 bytes (22 hex), no0xprefix.
Outputs
pkd— payment address public key in hexadecimal format (no0x).payment_address— the complete shielded payment address.
Use case
Thewallet/getshieldedpaymentaddress method is used for:
- Generating shielded addresses to receive private TRC20 payments
- Creating diversified payment addresses from viewing keys and diversifiers
- Supporting wallet implementations that need to generate receiving addresses
- Enabling privacy-preserving transaction receiving capabilities
How it works (Sapling)
- Parse
ivk(32 bytes) andd(11 bytes) from hex. - Compute
g_d = diversifyHash(d)(Jubjub point derived from the diversifier). - Compute
pkd = ivk · g_d(scalar multiplication on Jubjub). - Encode
(d, pkd)into a TRON Sapling payment address (Bech32 with HRPztron).
Example (JavaScript, WASM Sapling)
Example (Python, Rust FFI/WASM)
- Exact lengths:
ivk= 64 hex (32 bytes),d= 22 hex (11 bytes). No0xprefix. - Use a maintained Sapling library (Rust → WASM/FFI). The node does not provide this derivation.