Releases: hiero-ledger/hiero-sdk-js
v2.69.0
What's Changed
Summary
This release improves transaction safety and network identification:
Transactions that modify or delete nodes now require explicit nodeId to prevent unintended actions.
The SDK's X-User-Agent header is now correctly formatted to ensure accurate classification by the Consensus Node.
Enhancements
- Added validation to NodeUpdateTransaction and NodeDeleteTransaction to ensure that nodeId is explicitly set before execution.
This prevents accidental updates to node 0.0.3 due to protobuf's default uint64 = 0 behavior.
#3228
Fixed
- Fixed the formatting of the X-User-Agent header in the JavaScript SDK to ensure proper identification by the Consensus Node. The header now follows the format:
X-User-Agent: hiero-sdk-js/<version>
(e.g., hiero-sdk-js/1.2.3), preventing misclassification as unknown/unspecified usage.
#3216
Full Changelog: v2.68.0...v2.69.0
v2.69.0-beta.1
What's Changed
This release introduces robust support for dynamic network configuration in browser environments. These enhancements improve SDK reliability, support evolving node infrastructure, and ensure compatibility with mirror node-based discovery mechanisms.
Enhancements
-
Dynamic Address Book Updates in Browser:
WebClient
now supports both manual and automatic updates to the network configuration using data from the Mirror Node API:- Use
updateNetwork()
to manually refresh the list of nodes. - Enable
scheduleNetworkUpdate: true
to automatically refresh the address book on a recurring basis.
- Use
-
Mirror Network Initialization:
Introduced theWebClient.forMirrorNetwork()
factory method to initialize clients based on mirror-provided network information. The address book is loaded during initialization for accurate node discovery. -
Browser-Side Support for AddressBookQuery:
AddressBookQuery
can now be executed in browser contexts, enabling mirror node discovery ofgrpc_proxy_endpoint
values. -
Browser-Side Support for Smart Contract Queries:
The following mirror node-based contract queries are now supported in browser environments:MirrorNodeContractCallQuery
MirrorNodeContractEstimateQuery
#3092
-
Fallback Behavior for Production Networks:
When using Mainnet, Testnet, or Previewnet, the SDK now supports a fallback mechanism:
Ifgrpc_proxy_endpoint
fields are missing ornull
in the mirror node's address book response, the client will retain and use the hardcoded gRPC web proxy endpoints from the SDK. This ensures stable operation even if the mirror node is misconfigured or incomplete.
Full Changelog: v2.68.0...v2.69.0-beta.1
v2.68.0
What's Changed
This release refines EVM-compatible address handling and introduces a clear migration path to the new SDK package. Developers targeting Hedera's EVM integration should take note of the new method for address translation and the associated deprecations.
Enhancements
<EntityId>.toEvmAddress()
:
Now available forAccountId
,ContractId
,ContractDelegateId
,TopicId
,TokenId
, andFileId
. This provides a standardized way to obtain EVM-compatible 20-byte addresses from Hedera entity IDs.<EntityId>.fromEvmAddress(shard, realm, evmAddress)
:
Shard and realm are no longer encoded into the EVM address. They must be passed explicitly when constructing an EntityId from an EVM address.
Documentation
- Migration guide to
@hiero/sdk
v3:
Includes comprehensive documentation, automated scripts for Unix and Windows, supported file types, and a template for migration-related issues.
Deprecations
fromSolidityAddress()
has been replaced withfromEvmAddress()
.toSolidityAddress()
has been replaced withtoEvmAddress()
.EthereumFlow
has been deprecated. With the introduction of jumbo transactions, it is now more cost-effective and efficient to useEthereumTransaction
.
Full Changelog: v2.67.0...v2.68.0
v2.67.0
What's Changed
This release adds getter methods for accessing the shard and realm values set in the client. The Client constructor and Client.forMirrorNetwork now support shard and realm as parameters, improving configurability. When using a custom network, shard and realm are automatically inferred, and validation ensures all nodes share the same values, preventing misconfiguration.
Added
- Getter for
shard
set in the client - Getter for
realm
set in the client
Changed
ClientConfiguration
type updated: TheClient
constructor now acceptsshard
andrealm
parameters directly. #3133Client.forMirrorNetwork
now supports two additional arguments:shard
andrealm
. #3133- When a custom network is provided in the
Client
constructor, theshard
andrealm
values are now automatically inferred from the specified network. #3133 - An error is now thrown if the nodes defined in a custom network are not all in the same
shard
andrealm
, enforcing consistency and preventing misconfiguration. #3133
Full Changelog: v2.66.0...v2.67.0
v2.66.0
What's changed
This release extends the ContractExecuteTransaction.setPayableAmount function to accept an optional HbarUnit parameter, providing greater flexibility when specifying payable amounts. Additionally, it prevents unintended removal of transaction type registrations by disabling tree shaking for modules with critical side effects, ensuring correct runtime behavior.
Added
- Extended
setPayableAmount
function in ContractExecuteTransaction, by allowing the user to pass a HbarUnit as optional second parameter. #3129
Fixed
- Prevented unintended removal of transaction type registrations by disabling tree shaking for modules with critical side effects, ensuring proper runtime functionality. #3149
v2.66.0-beta.1
What's Changed
This release introduces new API support in NodeCreateTransaction
and NodeUpdateTransaction
for setting a grpcWebProxyEndpoint
, allowing gRPC communication via a web proxy from non-gRPC clients. This enhancement enables greater flexibility for node configurations across diverse environments.
Enhancements
- Web Proxy Endpoint Support for Nodes: Added
setGrpcWebProxyEndpoint(Endpoint)
andgetGrpcWebProxyEndpoint()
to bothNodeCreateTransaction
andNodeUpdateTransaction
. This enables the configuration of a web proxy for gRPC, supporting communication from non-gRPC clients. [#1234](link to the PR)
Documentation
- Additional documentation on the usage of
grpcWebProxyEndpoint
will is provided in the SDK examples.
Full Changelog: v2.65.1...v2.66.0-beta.1
v2.65.1
What's Changed
This release introduces robust support for external transaction signing via Hardware Security Modules (HSMs), enabling secure workflows for enterprise and regulated environments. It also includes several enhancements and bug fixes aimed at improving SDK reliability and developer experience.
Upgrading
For detailed guidance on implementing HSM-based signing and transaction size tracking, refer to the updated SDK documentation and examples provided.
Enhancements
-
HSM Support for External Signing:
- Introduced
SignableNodeTransactionBodyBytes
to encapsulatenodeAccountId
,transactionId
, and canonicalbodyBytes
. - Added
Transaction.signableNodeBodyBytesList()
to return node-specific, signable transaction bytes for HSM workflows. - Enables secure external signing (e.g., via HSM or KMS) and injection of signatures back into the transaction.
#3119
Usage Example:
const bytesList = transaction.signableNodeBodyBytesList; // Sign bytesList[i] externally and append signature back to the transaction
- Introduced
-
Key Type Detection Enhancement:
- Added a utility library to determine key types.
- Updated existing logic to use the centralized utility for consistent behavior.
#3068
-
Transaction Size Tracking:
- Introduced getters for transaction size, including support for chunked transactions such as
FileAppendTransaction
.
#2961
- Introduced getters for transaction size, including support for chunked transactions such as
Bug Fixes
- Transaction Regression Fixes:
- Resolved regressions in
ContractCreateTransaction
andTokenCreateTransaction
.
#3125
- Resolved regressions in
Documentation
- Added usage documentation and examples for the HSM signing API.
#3119 - Documented local code coverage command to improve developer workflow.
#3116
Full Changelog: v2.64.5...v2.65.0
Full Changelog: v2.64.5...v2.65.1
v2.65.0
What's Changed
This release introduces robust support for external transaction signing via Hardware Security Modules (HSMs), enabling secure workflows for enterprise and regulated environments. It also includes several enhancements and bug fixes aimed at improving SDK reliability and developer experience.
Upgrading
For detailed guidance on implementing HSM-based signing and transaction size tracking, refer to the updated SDK documentation and examples provided.
Enhancements
-
HSM Support for External Signing:
- Introduced
SignableNodeTransactionBodyBytes
to encapsulatenodeAccountId
,transactionId
, and canonicalbodyBytes
. - Added
Transaction.signableNodeBodyBytesList()
to return node-specific, signable transaction bytes for HSM workflows. - Enables secure external signing (e.g., via HSM or KMS) and injection of signatures back into the transaction.
#3119
Usage Example:
const bytesList = transaction.signableNodeBodyBytesList; // Sign bytesList[i] externally and append signature back to the transaction
- Introduced
-
Key Type Detection Enhancement:
- Added a utility library to determine key types.
- Updated existing logic to use the centralized utility for consistent behavior.
#3068
-
Transaction Size Tracking:
- Introduced getters for transaction size, including support for chunked transactions such as
FileAppendTransaction
.
#2961
- Introduced getters for transaction size, including support for chunked transactions such as
Bug Fixes
- Transaction Regression Fixes:
- Resolved regressions in
ContractCreateTransaction
andTokenCreateTransaction
.
#3125
- Resolved regressions in
Documentation
- Added usage documentation and examples for the HSM signing API.
#3119 - Documented local code coverage command to improve developer workflow.
#3116
Full Changelog: v2.64.5...v2.65.0
v2.64.5
What's changed
This release adds support for HIP-1064 Daily Rewards For Active Nodes, introducing a reward mechanism to incentivize nodes to stay active. New declineReward and setDeclineReward methods have been added to NodeCreateTransaction for managing reward preferences. Additionally, the x-user-agent header is now included in all gRPC calls to enable SDK version tracking. The release also includes new examples demonstrating robust error handling and network resilience when interacting with a single node.
Added
- Support for HIP-1064 Daily Rewards For Active Nodes https://hips.hedera.com/hip/hip-1064 This HIP proposes a reward mechanism that will incentivize nodes to remain active on the network. #3099
- NodeCreateTransaction
declineReward
: whether the node declines rewards - NodeCreateTransaction
setDeclineReward
: update whether the node declines reward
- NodeCreateTransaction
- Added the
x-user-agent
header to all gRPC calls to enable SDK version tracking, following the approach outlined in #3089 - Included examples that demonstrate proper error handling in realistic, real-world scenarios, including how to manage network connectivity issues when interacting with a single node. #3064
v2.64.0-beta.1
What's changed
This release adds support for HIP-551 Batch Transaction, enabling execution of a series of dependent transactions as a single atomic batch, ensuring ACID compliance. It introduces a new BatchTransaction struct, a batchKey field in the Transaction class, and a batchify method to streamline batch creation and signing. Additionally, setKeyWithAlias functions now support PublicKey. The retry mechanism for the THROTTLED_AT_CONSENSUS status code has also been enhanced with a backoff strategy for improved reliability.
Added
- Support for HIP-551 Batch Transaction https://hips.hedera.com/hip/hip-551 It defines a mechanism to execute batch transactions such that a series of transactions (HAPI calls) depending on each other can be rolled into one transaction that passes the ACID test (atomicity, consistency, isolation, and durability). #3039
- New
BatchTransaction
struct that has a list ofinnerTransactions
andinnerTransactionIds
. - New
batchKey
field in Transaction class that must sign the BatchTransaction - New
batchify
method that sets the batch key and marks a transaction as part of a batch transaction (inner transaction). The transaction is signed by the client of the operator and frozen.
- New
- Extend
setKeyWithAlias
funcs to support PublicKey. #3051 - Enhancing the retry mechanism for the status code
THROTTLED_AT_CONSENSUS
using backoffs retry mechanism. #3065 #3076