Skip to content

Releases: hiero-ledger/hiero-sdk-js

v2.69.0

22 Jul 12:09
71569e1
Compare
Choose a tag to compare

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

09 Jul 13:17
f69cd78
Compare
Choose a tag to compare

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.
  • Mirror Network Initialization:
    Introduced the WebClient.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 of grpc_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:
    If grpc_proxy_endpoint fields are missing or null 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

09 Jul 11:57
9d032cd
Compare
Choose a tag to compare

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 for AccountId, ContractId, ContractDelegateId, TopicId, TokenId, and FileId. 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 with fromEvmAddress().
  • toSolidityAddress() has been replaced with toEvmAddress().
  • EthereumFlow has been deprecated. With the introduction of jumbo transactions, it is now more cost-effective and efficient to use EthereumTransaction.

Full Changelog: v2.67.0...v2.68.0

v2.67.0

25 Jun 13:03
621aad9
Compare
Choose a tag to compare

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: The Client constructor now accepts shard and realm parameters directly. #3133
  • Client.forMirrorNetwork now supports two additional arguments: shard and realm. #3133
  • When a custom network is provided in the Client constructor, the shard and realm 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 and realm, enforcing consistency and preventing misconfiguration. #3133

Full Changelog: v2.66.0...v2.67.0

v2.66.0

09 Jun 11:50
7795b91
Compare
Choose a tag to compare

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

02 Jun 11:38
2eb1325
Compare
Choose a tag to compare

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) and getGrpcWebProxyEndpoint() to both NodeCreateTransaction and NodeUpdateTransaction. 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

29 May 11:47
b8e20e4
Compare
Choose a tag to compare

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 encapsulate nodeAccountId, transactionId, and canonical bodyBytes.
    • 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
  • 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

Bug Fixes

  • Transaction Regression Fixes:
    • Resolved regressions in ContractCreateTransaction and TokenCreateTransaction.
      #3125

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

29 May 10:30
ad35c2d
Compare
Choose a tag to compare

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 encapsulate nodeAccountId, transactionId, and canonical bodyBytes.
    • 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
  • 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

Bug Fixes

  • Transaction Regression Fixes:
    • Resolved regressions in ContractCreateTransaction and TokenCreateTransaction.
      #3125

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

14 May 10:02
ce932c0
Compare
Choose a tag to compare

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
  • 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

30 Apr 12:55
f11a803
Compare
Choose a tag to compare

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 of innerTransactions and innerTransactionIds.
    • 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.
  • Extend setKeyWithAlias funcs to support PublicKey. #3051
  • Enhancing the retry mechanism for the status code THROTTLED_AT_CONSENSUS using backoffs retry mechanism. #3065 #3076