TronGRPC by Tronsave Team - Typescript powerful GRPC client

Project Name: TronGRPC
Project Track: infra-security
Team Name: TronSave team
Team Member(s): @tronsave.io

Social Info:
Github
NPM
X - Twitter
Telegram
TronSave
SaveWallet
TronTools

Project Goal:
TronGRPC is a powerful GRPC client implementation for the TRON blockchain, developed by TronSave and SaveWallet. It provides a streamlined interface for interacting with TRON’s GRPC services, making it easier to build and integrate TRON-based applications.

The library offers a unified, seamless development experience for interacting with the TRON blockchain through GRPC. Built with TypeScript, it provides type-safe interactions and modern development features while maintaining high performance and reliability.

Unique Value Proposition:

  • Full TypeScript support with complete type definitions
  • Direct gRPC communication for better performance
  • Comprehensive API coverage of TRON’s gRPC methods
  • Optimized for tree-shaking and minimal bundle size
  • Built-in utilities for common TRON operations

Project Demo: Available via NPM package

Current Progress (%): 20%

Technical & Governance Details: Open-source

Project Test Instructions:

npm i --save tron-grpc tslib google-protobuf
import { TronGrpcClient } from 'tron-grpc';
const client = new TronGrpcClient('grpc.trongrid.io:50051');
const account = await client.getAccount('TRxxxxxxxxxxx');

Technical Details:

GRPC Supported Methods

Account Methods

  • getAccount - Get account information
  • getAccountBalance - Get account balance at a specific block
  • getAccountNet - Get account bandwidth information
  • getAccountResource - Get account resource information
  • createAccount - Create a new account
  • updateAccount - Update account name
  • accountPermissionUpdate - Update account permissions
  • getAccountById - Get account by ID
  • getAccountAssets - Get all assets owned by account
  • getAccountNotExists - Check if account doesn’t exist

Transaction Methods

  • createTransaction - Create a TRX transfer transaction
  • getTransaction - Get transaction by ID
  • getTransactionInfo - Get transaction info by ID
  • getTransactionById - Get transaction details by ID
  • getTransactionInfoByBlockNum - Get all transaction info in a block
  • getTransactionCountByBlockNum - Get transaction count in a block
  • broadcastTransaction - Broadcast signed transaction
  • getTransactionSignWeight - Get transaction sign weight
  • getTransactionApprovedList - Get transaction approved list
  • getTransactionFromPending - Get transaction from pending pool
  • getTransactionListFromPending - Get all transactions from pending pool

Block Methods

  • getNowBlock - Get current block
  • getBlockByNum - Get block by number
  • getBlockById - Get block by ID
  • getBlockByLimitNext - Get blocks between start and end
  • getBlockByLatestNum - Get latest N blocks
  • getBlock - Get block by number with details option
  • getBlockBalanceTrace - Get block balance changes

Smart Contract Methods

  • getContract - Get contract code
  • getContractInfo - Get contract information
  • triggerContract - Trigger smart contract
  • triggerConstantContract - Trigger constant contract (view/pure)
  • estimateEnergy - Estimate energy cost for contract call
  • updateSetting - Update contract consume_user_resource_percent
  • updateEnergyLimit - Update contract origin_energy_limit
  • clearContractABI - Clear contract ABI
  • deployContract - Deploy new smart contract

Resource Methods

  • freezeBalanceV2 - Freeze TRX for resources (V2)
  • unfreezeBalance - Unfreeze TRX (legacy)
  • unfreezeBalanceV2 - Unfreeze TRX (V2)
  • withdrawExpireUnfreeze - Withdraw expired unfrozen TRX
  • getDelegatedResourceV2 - Get resource delegation info
  • delegateResource - Delegate resources to another account
  • unDelegateResource - Undelegate resources
  • cancelAllUnfreezeV2 - Cancel all unfreezing transactions
  • getDelegatedResourceAccountIndex - Get delegated resource index
  • getDelegatedResourceAccountIndexV2 - Get delegated resource index V2

Asset Methods

  • transferAsset - Transfer TRC10 tokens
  • updateAsset - Update TRC10 token parameters
  • getAssetIssueByAccount - Get account’s TRC10 tokens
  • createAssetIssue - Create new TRC10 token
  • participateAssetIssue - Participate in TRC10 token sale
  • getAssetIssueByName - Get TRC10 token by name
  • getAssetIssueListByName - Get TRC10 tokens by name
  • getAssetIssueById - Get TRC10 token by ID
  • getAssetIssueList - Get all TRC10 tokens
  • getPaginatedAssetIssueList - Get paginated TRC10 tokens

Witness (Super Representative) Methods

  • createWitness - Apply for Super Representative
  • updateWitness - Update SR URL
  • voteWitness - Vote for SR
  • getListWitnesses - Get all SR list
  • updateBrokerage - Update SR brokerage
  • getBrokerageInfo - Get SR brokerage info
  • getRewardInfo - Get SR rewards
  • withdrawBalance - Withdraw SR rewards

Network Methods

  • listNodes - List all nodes
  • getNodeInfo - Get node information
  • getBandwidthPrices - Get bandwidth prices
  • getEnergyPrices - Get energy prices
  • getMemoFee - Get memo fee
  • getBurnTrx - Get burned TRX amount
  • getChainParameters - Get chain parameters
  • totalTransaction - Get total transaction count
  • getNextMaintenanceTime - Get next maintenance time
  • getConnectedNodes - Get connected node list
  • getBlockProduction - Get block production stats
  • getNodeMetrics - Get node performance metrics
  • getNetworkResources - Get network resource status

Proposal Methods

  • getProposalList - Get all proposals
  • getPaginatedProposalList - Get paginated proposals
  • getProposalById - Get proposal by ID
  • createProposal - Create new network proposal
  • approveProposal - Approve network proposal
  • deleteProposal - Delete network proposal
  • getChainConfig - Get current chain configuration

Resource Query Methods

  • getCanDelegatedMaxSize - Get max delegatable size
  • getAvailableUnfreezeCount - Get available unfreeze count
  • getCanWithdrawUnfreezeAmount - Get withdrawable unfreeze amount

Market Methods

  • getMarketOrderById - Get market order by ID
  • getMarketOrderByAccount - Get market orders by account
  • getMarketPriceByPair - Get market price by pair
  • getMarketOrderListByPair - Get market orders by pair
  • getMarketPairList - Get all market pairs

Exchange Methods

  • getExchangeById - Get exchange by ID
  • getExchangeByAccount - Get exchanges by account
  • getExchangeList - Get all exchanges
  • getPaginatedExchangeList - Get paginated exchanges
  • createExchange - Create new exchange
  • injectExchange - Inject capital into exchange
  • withdrawExchange - Withdraw capital from exchange
  • tradeExchange - Trade on exchange

Tech Stack:

  • TypeScript
  • gRPC
  • Protocol Buffers
  • @grpc/grpc-js
  • @noble/hashes
  • @scure/base

Funding & Business Model

Revenue Model:

  • Open source infrastructure
  • Enterprise support and custom implementations
  • Integration consulting

Ecosystem Impact

Time on TRON: New project specifically built for TRON ecosystem

Project Benefits:

  1. Improved developer experience with TypeScript support
  2. Better performance through direct gRPC communication
  3. Reduced bundle size through optimization\
  4. Built-in utilities for common operations

Project Milestones

Current Features:

  • Full TypeScript support
  • Complete gRPC method coverage
  • Built-in utilities

Upcoming Features:

  • Optimized bundle size
  • Tree-shaking support
  • Fully support utility function like tronweb
  • Batch operation support
  • Automatic retry mechanisms
  • Rate limiting
  • Connection pooling
  • Enhanced error handling
  • More utility functions
  • Additional helper methods
  • Integration examples
  • Comprehensive documentation

Project in 5 Years:

  • Industry standard for TRON blockchain interaction
  • Extended protocol support
  • Enterprise-grade features
  • Comprehensive tooling ecosystem
  • Multiple language implementations
11 Likes

Awesome looking forward to following !

2 Likes

Thank you! We’ll keep you updated on TronGRPC news. Follow us to stay informed.

Welcome back Team.

Great, keep building

1 Like

Thank you. We hope you’ll like what we do!

1 Like

Excited to see how this develops!

1 Like

Update v0.0.3:
Release on NPM add simple fetch function

Update v0.0.4:
add dependencies: tslib and google-protobuf

1 Like

Great to see what you are building, welcome back :handshake:

1 Like

Welcome back, you’re an og that requires little or no introduction, your build this time around looks concrete at first instance but tedious to the eyes at the same time, I really have to take my time to study it.

1 Like

Yes we will improve docs. Thanks for comment

1 Like

Release v0.0.5: Add more block function

Very good to see that you have your 5yr vision plan out already, I will be following up

1 Like

We’re delighted you’re interested in our 5-year vision plan! We’ll be sure to keep you updated.

1 Like

Release v0.0.6 Updated:

  • Optimize gRPC client config for retry and reconnect
  • Add some account function: getAccount , getAccountBalance , getAccountNet , getAccountResource , getDelegatedResourceV2 …
2 Likes

Release v0.0.8 Updated:

  • Add console state connection change => Optimize reconnect logic
  • Add transaction hash function relative
2 Likes

Release v0.0.9 Support almost function

1 Like

Release v0.0.10: Support headers for Trongrid (TRON-PRO-API-KEY)

so excellent, welcome back.

Hey everyone,

Just checked out TronGRPC by Tronsave Team, and it’s awesome! Super handy for devs in the TRON ecosystem, especially Typescript fans like me.

What I love:

  • Runs fast with GRPC.

  • Easy to plug into Node.js/TS projects.

  • Clear, newbie-friendly docs.

Suggestions:

  • Add real-world examples.

  • Support Python, Java too.

  • Improve error handling for easier debugging.

Big thanks to the team! Excited for updates. Have a great workday!

4 Likes