As part of our continuous effort to enhance the Bitpowr wallet experience, we are excited to introduce a stand-alone staking feature for TRON (TRX) blockchain. This feature empowers you to earn valuable resources, either bandwidth or energy, which can be used to pay for your Tron transaction fees, all by simply staking TRON assets within the Bitpowr ecosystem and still regaining their complete Tron asset value.
What is Tron
Tron is a popular blockchain-based operating system on which a user can create decentralized applications, and distribute media content. The TRX token on its own is used to gain access to certain features of the operating software that are available on the Tron Protocol. Therefore, the main purpose of the token is for use on the Tron network. However, it is still a store of value and it can be exchanged and traded on exchanges, so it can also be described. Learn how to send Feeless Transaction on Tron
Introduction to Bitpowr’s Staking API
Bitpowr’s Staking API is a powerful tool designed to enable developers to engage in staking operations on the TRON blockchain. Staking involves the process of locking up a certain amount of cryptocurrency to support the operations of a blockchain network, and in return, participants are rewarded for their contributions.
Making a POST Request
To initiate the creation of a new stake using Bitpowr’s API, developers need to craft a POST request directed toward the following endpoint:
HTTPCopy code POST https://developers.bitpowr.com/api/v1/staking
This endpoint serves as the entry point for developers looking to participate in staking operations on the TRON blockchain through Bitpowr’s API.
When creating your POST request, you must include several mandatory parameters within the request body. These essential parameters are as follows:
- fromAddress (string, required): This parameter specifies the address from which you intend to stake your cryptocurrency (In this case, a Tron address with the Tron asset you want to stake)
- amount (string, required): Indicate the precise amount you wish to stake or delegate. If your objective is to perform a withdrawFrozenAsset operation, ensure that this parameter is set to 0.
- chain (string, required): Clearly specify the blockchain on which you intend to execute your staking operation. Currently, Bitpowr exclusively supports TRON, so this parameter must be set to “TRON.”
- accountId (string, required): Provide the account or wallet ID that you wish to employ for the staking operation.
In addition to the mandatory parameters, Bitpowr’s Staking API offers a set of optional parameters to provide greater flexibility and customization for developers:
- operation (string): This parameter empowers developers to specify the precise staking operation they intend to perform. Bitpowr currently supports several operations, including freezeTron, unFreezeTron, withdrawFrozenAsset, delegateResource, and undelegateResource. Developers can choose the operation that aligns with their project’s requirements.
- resource (string): In cases where your staking operation involves obtaining a specific resource from the stake, this parameter allows you to specify your resource preference. Bitpowr currently supports two resource options: BANDWIDTH and ENERGY.
- receiverAddress (string): If your intent is to delegate your stake to another address, you can utilize this parameter to specify the recipient’s address.
Bitpowr’s Staking API simplifies the complex process of creating a new stake on the TRON blockchain, providing developers with a powerful tool to engage in staking and reap rewards. By following the guidelines outlined in this guide and referring to Bitpowr’s official documentation for any updates or changes, developers can seamlessly integrate staking functionality into their projects. Embrace Bitpowr’s API to unlock the full potential of staking in your blockchain development endeavors. Happy coding!
Start staking TRON Via Bitpowr API today.