From 770e783293469300921357a9f9102d34733bb16e Mon Sep 17 00:00:00 2001 From: krystal <56278409+theekrystallee@users.noreply.github.com> Date: Wed, 4 Mar 2026 18:51:44 -0800 Subject: [PATCH 1/3] update docs with HIP-1313 high volume entity creation Signed-off-by: krystal <56278409+theekrystallee@users.noreply.github.com> --- docs.json | 4 + hedera/core-concepts.mdx | 1 + .../high-volume-entity-creation.mdx | 354 ++++++++++++++++++ .../smart-contracts/gas-and-fees.mdx | 10 + .../transactions-and-queries.mdx | 9 + hedera/faqs/network-governance.mdx | 14 + hedera/networks/mainnet.mdx | 25 +- hedera/networks/mainnet/fees.mdx | 36 +- hedera/networks/testnet.mdx | 23 ++ .../approve-an-allowance.mdx | 39 +- .../accounts-and-hbar/create-an-account.mdx | 196 ++++++---- .../transfer-cryptocurrency.mdx | 42 ++- .../sdks/consensus-service/create-a-topic.mdx | 24 +- .../sdks/file-service/append-to-a-file.mdx | 16 +- .../sdks/file-service/create-a-file.mdx | 18 +- .../create-a-schedule-transaction.mdx | 34 +- .../create-a-smart-contract.mdx | 78 ++-- .../sdks/token-service/airdrop-a-token.mdx | 18 +- .../associate-tokens-to-an-account.mdx | 35 +- .../sdks/token-service/claim-a-token.mdx | 13 +- .../sdks/token-service/define-a-token.mdx | 132 +++++-- .../sdks/token-service/mint-a-token.mdx | 35 +- .../modify-transaction-fields.mdx | 54 ++- 23 files changed, 982 insertions(+), 228 deletions(-) create mode 100644 hedera/core-concepts/high-volume-entity-creation.mdx diff --git a/docs.json b/docs.json index b7952aa1..4bd683aa 100644 --- a/docs.json +++ b/docs.json @@ -329,6 +329,7 @@ "group": "Core Concepts", "pages": [ "hedera/core-concepts", + { "group": "Accounts", "pages": [ @@ -441,6 +442,7 @@ "hedera/core-concepts/hashgraph-consensus-algorithms/virtual-voting" ] }, + "hedera/core-concepts/high-volume-entity-creation", { "group": "Transactions and Queries", "pages": [ @@ -1120,6 +1122,7 @@ } ] }, + { "group": "Support & Community", "pages": [ @@ -1176,6 +1179,7 @@ "hedera/faqs/community" ] } + ] } ] diff --git a/hedera/core-concepts.mdx b/hedera/core-concepts.mdx index 470a3e5f..aea5ebd9 100644 --- a/hedera/core-concepts.mdx +++ b/hedera/core-concepts.mdx @@ -60,6 +60,7 @@ sidebarTitle: Overview + diff --git a/hedera/core-concepts/high-volume-entity-creation.mdx b/hedera/core-concepts/high-volume-entity-creation.mdx new file mode 100644 index 00000000..9b93a218 --- /dev/null +++ b/hedera/core-concepts/high-volume-entity-creation.mdx @@ -0,0 +1,354 @@ +--- +title: "High-Volume Entity Creation" +sidebarTitle: "High-Volume Entity Creation" +description: "Understand how high-volume throttles work, how variable-rate pricing affects your transaction fees, and how to use the high_volume flag effectively." +--- + +Hedera's standard throttle system limits entity creation transactions (like `CryptoCreate`, +`TokenCreate`, and `TokenMint`) to relatively modest per-second rates. This protects the +network but can be a bottleneck for applications that need to create entities at scale — +for example, bulk user onboarding, large NFT drops, or automated token deployments. + +[HIP-1313](https://hips.hedera.com/hip/hip-1313) introduces a **high-volume throttle system** +that runs in parallel alongside the standard system. By setting `high_volume = true` on a +supported transaction, you opt into dedicated capacity with higher throughput limits. The +tradeoff: **fees are variable and increase with utilization.** + + +The standard throttle system is completely unaffected. Existing applications that do not +set the `high_volume` flag will work exactly as before — same capacity, same pricing. + + +--- + +## How It Works + +### Two Parallel Throttle Systems + +When you submit an entity creation transaction, the network routes it to one of two +independent throttle systems based on the `high_volume` flag: + +| | Standard Throttles | High-Volume Throttles | +|---|---|---| +| **Opt-in** | Default (no flag needed) | Set `high_volume = true` | +| **Capacity** | Current published limits | Dedicated high-volume buckets | +| **Pricing** | Fixed fee schedule | Variable-rate (scales with utilization) | +| **Priority** | Consensus order | Consensus order (no priority boost) | + +The two systems have completely separate capacity pools. Using one does not consume +capacity from the other. + +### Variable-Rate Pricing + +This is the most important thing to understand before using high-volume mode. + +Unlike standard transactions where fees are predictable from the +[fee schedule](/hedera/networks/mainnet/fees), high-volume fees change dynamically based on how +much of the high-volume capacity is currently in use: + + + + +The network calculates how much of the high-volume throttle capacity is currently being +consumed, expressed as a utilization percentage from 0% (idle) to 100% (saturated). + + + +A governance-configured **pricing curve** converts the utilization percentage into a fee +multiplier. The curve is defined as a piecewise linear function — a series of +(utilization, multiplier) breakpoints with linear interpolation between them. For +example, given points (0%, 1.0×), (50%, 2.0×), and (100%, 5.0×), a utilization of 75% +would produce a multiplier of 3.5×. + + + +The base transaction fee (from the normal fee schedule) is multiplied by the current +multiplier to produce the final fee. A `max_multiplier` caps how high the multiplier can +go, preventing extreme pricing even at 100% utilization. + + + +If the calculated fee exceeds the `maxTransactionFee` you set on the transaction, the +transaction fails with `INSUFFICIENT_TX_FEE` and you are **not** charged. This is your +primary cost-control mechanism. + + + + + +Depending on the governance-configured pricing curve, high-volume transactions **may** +cost more than the same transaction sent through the standard throttle — even when +there is no congestion. Always check the current multiplier before committing to a batch. + + +### Pricing Curve Example + +The actual curve values are set by network governance and may change. The HIP provides +this example of a piecewise linear curve with three breakpoints: + +| Utilization | Multiplier | Effect on a $0.05 Base Fee | +|---|---|---| +| 0% | 1.0× | $0.05 | +| 50% | 2.0× | $0.10 | +| 100% | 5.0× | $0.25 | + +Between breakpoints, the multiplier is linearly interpolated. For example, at 75% +utilization, the multiplier would be 3.5× (halfway between 2.0× and 5.0×). If no +pricing curve is explicitly configured, the multiplier defaults to linear interpolation +between 1.0× and `max_multiplier`. + + +These values are from the HIP specification as an example. Actual pricing curve +breakpoints will be configured by Hedera governance before launch. The `max_multiplier` +value (also governance-configured) caps how high the multiplier can go regardless of +the curve. Use the Mirror Node fee estimation endpoint to see the **current** multiplier +in effect. + + +--- + +## Supported Transaction Types + +The `high_volume` flag is supported on the following entity creation transactions: + + + +| Transaction Type | SDK Class | Notes | +|---|---|---| +| `ConsensusCreateTopic` | `TopicCreateTransaction` | | +| `ContractCreate` | `ContractCreateTransaction` | HAPI only, not EVM | +| `CryptoApproveAllowance` | `AccountAllowanceApproveTransaction` | | +| `CryptoCreate` | `AccountCreateTransaction` | | +| `CryptoTransfer` | `TransferTransaction` | Only the account-creation portion | +| `FileAppend` | `FileAppendTransaction` | | +| `FileCreate` | `FileCreateTransaction` | | +| `HookStore` | — | Future transaction type | +| `ScheduleCreate` | `ScheduleCreateTransaction` | | +| `TokenAirdrop` | `TokenAirdropTransaction` | | +| `TokenAssociateToAccount` | `TokenAssociateTransaction` | | +| `TokenClaimAirdrop` | `TokenClaimAirdropTransaction` | | +| `TokenCreate` | `TokenCreateTransaction` | | +| `TokenMint` | `TokenMintTransaction` | Fungible and NFT | + + + +Setting `high_volume = true` on any other transaction type has no effect — the flag +is silently ignored and the transaction processes through the standard system. + + +**EVM transactions are excluded.** Contract creations via `CREATE` / `CREATE2` opcodes +in the EVM do not participate in the high-volume system. A subsequent HIP will address +EVM-specific high-volume behavior. + + +--- + +## High-Volume Throttle Capacity + +The high-volume system uses a two-level throttle structure. The HIP provides the +following example configuration (actual mainnet values will be set by governance): + +| Throttle Bucket | Transaction Types | Example Capacity | +|---|---|---| +| HighVolumeCryptoThrottles | `CryptoCreate` + `ScheduleCreate` | 10,500 ops/sec | +| HighVolumeTotalThrottles | All 14 supported types combined | 31,500 ops/sec | + + +These values are from the HIP's example throttle configuration. Final mainnet and +testnet capacity values will be set by Hedera governance and may differ. + + +A transaction must pass **both** its per-type bucket and the total bucket to be accepted. +If either is exhausted, the transaction receives a `BUSY` response. + +For comparison, the current standard `AccountCreateTransaction` throttle is **2 tps** on +mainnet. The high-volume system offers orders-of-magnitude more capacity for applications +willing to pay the variable-rate fees. + +--- + +## How to Use High-Volume Mode + +### Step 1: Check Current Pricing + +Before submitting high-volume transactions, query the Mirror Node fee estimation endpoint +to see the current `high_volume_multiplier`. The HIP specifies that this field will be +added to the existing fee estimation response: + +```bash +curl "https://mainnet.mirrornode.hedera.com/api/v1/network/fees" +``` + +Look for the `high_volume_multiplier` field in the response. This value is divided by +1000 to produce the actual multiplier (e.g., a value of `1000` = 1.0×, `2000` = 2.0×). +The fee totals in the response are **not** pre-multiplied — multiply the fee total by +`high_volume_multiplier / 1000` to calculate the high-volume price. + +### Step 2: Set the Flag and a Fee Cap + + + + + +```java +// Create an account using high-volume throttles +AccountCreateTransaction tx = new AccountCreateTransaction() + .setKey(publicKey) + .setInitialBalance(Hbar.from(10)) + .setHighVolume(true) // Opt into high-volume throttles + .setMaxTransactionFee(Hbar.from(5)); // ALWAYS set a fee cap + +TransactionResponse response = tx.execute(client); +TransactionReceipt receipt = response.getReceipt(client); +AccountId newAccountId = receipt.accountId; + +System.out.println("Account created: " + newAccountId); +``` + + + + + +```javascript +// Create an account using high-volume throttles +const tx = new AccountCreateTransaction() + .setKey(publicKey) + .setInitialBalance(Hbar.from(10)) + .setHighVolume(true) + .setMaxTransactionFee(Hbar.from(5)); + +const response = await tx.execute(client); +const receipt = await response.getReceipt(client); +const newAccountId = receipt.accountId; + +console.log("Account created: " + newAccountId); +``` + + + + + +```go +// Create an account using high-volume throttles +tx := hedera.NewAccountCreateTransaction(). + SetKey(publicKey). + SetInitialBalance(hedera.HbarFrom(10, hedera.HbarUnits.Hbar)). + SetHighVolume(true). + SetMaxTransactionFee(hedera.HbarFrom(5, hedera.HbarUnits.Hbar)) + +response, err := tx.Execute(client) +if err != nil { + panic(err) +} + +receipt, err := response.GetReceipt(client) +if err != nil { + panic(err) +} + +fmt.Printf("Account created: %v\n", receipt.AccountID) +``` + + + + + +### Step 3: Handle Fee Failures Gracefully + +If the current multiplier pushes the fee above your `maxTransactionFee`, the transaction +will fail with `INSUFFICIENT_TX_FEE`. Your application should: + +1. Catch the error +2. Re-query the current multiplier +3. Decide whether to retry with a higher cap, wait for utilization to drop, or fall + back to the standard throttle system + +--- + +## Best Practices + + +**Always set `maxTransactionFee`.** This is not optional guidance — it is the only +mechanism protecting you from unexpectedly high fees during utilization spikes. + + + +**Check the multiplier before batches.** If you are about to submit 10,000 account +creations, query the fee estimation endpoint first. A multiplier of 5× on 10,000 +transactions is the difference between $500 and $2,500. + + + +**Implement adaptive fee caps.** For long-running batch jobs, periodically re-check +the multiplier and adjust your `maxTransactionFee` up or down. If the multiplier rises +above your acceptable threshold, pause and retry later. + + + +**Consider time-of-day patterns.** Like any shared resource, high-volume utilization +may follow patterns. Off-peak hours may offer lower multipliers. + + +--- + +## Verifying High-Volume Transactions + +After a high-volume transaction reaches consensus, you can confirm its status via the +Mirror Node REST API: + +```bash +curl "https://mainnet.mirrornode.hedera.com/api/v1/transactions/{transactionId}" +``` + +The response includes: + +- `high_volume`: `true` — confirms the transaction used the high-volume system +- `charged_tx_fee` — the actual fee charged (reflecting the variable-rate multiplier) + +The `TransactionResult` protobuf (exposed via block streams) includes a +`high_volume_pricing_multiplier` field (`uint64`, field number 13) showing the exact +multiplier that was applied. This value is divided by 1000 to get the actual multiplier. + +--- + +## What High-Volume Mode Does NOT Do + + +**No priority.** High-volume transactions are processed in the same consensus order as +all other transactions. Paying more does not make your transaction execute sooner. + + + +**No guaranteed throughput.** The high-volume throttle provides additional *capacity*, +but if that capacity is fully utilized by other users, your transaction will receive a +`BUSY` response just like the standard system. + + + +**No impact on standard users.** Applications that do not use the `high_volume` flag +are completely unaffected — same throttle limits, same fixed-fee pricing. + + +--- + +## Related Resources + + + + + Full technical specification including pricing curve protobuf definitions + + + + Standard fee schedule for all transaction types + + + + Current standard and high-volume throttle limits + + + + SDK reference for setHighVolume() and other TransactionBody fields + + + \ No newline at end of file diff --git a/hedera/core-concepts/smart-contracts/gas-and-fees.mdx b/hedera/core-concepts/smart-contracts/gas-and-fees.mdx index 7a43924b..df7d004d 100644 --- a/hedera/core-concepts/smart-contracts/gas-and-fees.mdx +++ b/hedera/core-concepts/smart-contracts/gas-and-fees.mdx @@ -31,6 +31,16 @@ Gas fees for EVM transactions consist of: - **EVM Opcode Gas**: The gas required to execute the defined opcodes for the smart contract call - **Hedera System Contract Gas**: The required gas associated with Hedera-defined transactions, such as using the Hedera Token Service system contract + + **High-volume contract creation.** `ContractCreateTransaction` supports the + `high_volume` flag ([HIP-1313](https://hips.hedera.com/hip/hip-1313)), which routes + the transaction through dedicated high-volume throttle capacity with variable-rate + pricing. This applies to **HAPI-based contract creation only** — contract deployments + via EVM `CREATE` / `CREATE2` opcodes are not included. See the + [High-Volume Entity Creation](/hedera/core-concepts/high-volume-entity-creation) guide + for details. + + ### Intrinsic Gas A transaction submitted to the smart contract service must be sent with enough gas to cover **intrinsic gas**. With the **Cancun fork** of the EVM update, intrinsic gas is calculated as: diff --git a/hedera/core-concepts/transactions-and-queries.mdx b/hedera/core-concepts/transactions-and-queries.mdx index 3141dbab..182cee1c 100644 --- a/hedera/core-concepts/transactions-and-queries.mdx +++ b/hedera/core-concepts/transactions-and-queries.mdx @@ -41,6 +41,15 @@ The receiving node validates (for instance, confirms the paying account has suff Every transaction on the Hedera network has an associated fee to compensate the network for processing and state storage. With the implementation of **[HIP-1259](https://hips.hedera.com/hip/hip-1259)**, the mechanism for handling these fees has been significantly streamlined to improve network efficiency and simplify transaction records for users. + + **Variable-rate pricing for high-volume transactions.** Entity creation transactions + (such as `CryptoCreate`, `TokenCreate`, and `TokenMint`) that set the `high_volume` + flag use a separate throttle pool with **variable-rate pricing** — fees scale with + current utilization of the high-volume capacity. See the + [High-Volume Entity Creation](/hedera/core-concepts/high-volume-entity-creation) + guide for details on how this affects your costs. + + ### Fee Collection and Distribution ([HIP-1259](https://hips.hedera.com/hip/hip-1259)) Previously, transaction fees were immediately split and distributed to multiple accounts with every transaction. This immediate distribution created challenges. For a simple crypto transfer between two accounts, the system must read and update up to six accounts: the sender, receiver, submitting node, `0.0.98`, `0.0.800`, and `0.0.801`. This increases processing overhead and slows performance. In the [block stream](/hedera/support-and-community/glossary#block-stream), every transaction must record balance changes for all these accounts, inflating data size and storage costs. Users viewing transactions on explorers like HashScan see a complex web of transfers, which can be confusing even with visualizations. diff --git a/hedera/faqs/network-governance.mdx b/hedera/faqs/network-governance.mdx index 885861bc..aac9167c 100644 --- a/hedera/faqs/network-governance.mdx +++ b/hedera/faqs/network-governance.mdx @@ -275,6 +275,20 @@ title: "Network Governance" Hedera council reviews pricing at every council meeting (once every three months), and approves all changes to the prices. The exchange rate that nodes use to determine the corresponding fees in hbars is updated frequently (currently every hour) . + + Yes. [High-volume entity creation](/hedera/core-concepts/high-volume-entity-creation) transactions + (introduced in [HIP-1313](https://hips.hedera.com/hip/hip-1313)) use a variable-rate + pricing model where fees change dynamically based on utilization of the dedicated + high-volume throttle capacity. The pricing curve parameters — including the breakpoints + and maximum multiplier — are configured by Hedera governance and subject to Council review. + + Standard transactions (those without the `high_volume` flag) continue to use the fixed + fee schedule set by the Hedera Governing Council. + + To check the current high-volume pricing multiplier for any transaction type, query the + Mirror Node fee estimation endpoint. + + Hedera transaction and query fees are denominated in USD and paid in HBAR. The network regularly updates the USD-to-HBAR exchange rate based on current market rates, subject to a defined minimum exchange rate. diff --git a/hedera/networks/mainnet.mdx b/hedera/networks/mainnet.mdx index d6c5df62..9f30a3d9 100644 --- a/hedera/networks/mainnet.mdx +++ b/hedera/networks/mainnet.mdx @@ -12,10 +12,33 @@ Any Hedera account can query data associated with Hedera's services and stored o If you're looking to test your application (or just experiment), please visit [Testnet Access](/hedera/networks/testnet/testnet-access). The Hedera testnet enables developers to prototype and test applications in a simulated mainnet environment that uses test *HBAR* for paying transaction fees. -**Transaction Throttles**\ +**Transaction Throttles** Transactions on the Hedera Mainnet are currently throttled. You will receive a `"BUSY"` response if the number of transactions submitted to the network exceeds the threshold value. ## Main Network Throttles
Network Request TypesThrottle (tps)
Cryptocurrency Transactions

AccountCreateTransaction: 2 tps

TransferTransaction (inc. tokens): 10,000 tps
Other: 10,000 tps

Consensus Transactions

TopicCreateTransaction: 5 tps

Other: 10,000 tps

Token Transactions

TokenMintTransaction:

  • 125 TPS for fungible mint
  • 50 TPS for NFT mint

TokenAssociateTransaction: 100 tps
TransferTransaction (inc. tokens): 10,000 tps

Other: 3,000 tps

Schedule TransactionsScheduleSignTransaction: 100 tps
ScheduleCreateTransaction: 100 tps
File Transactions10 tps
Smart Contract TransactionsContractExecuteTransaction: 15 million gas per second
ContractCreateTransaction: 15 million gas per second
Queries (per node)

AccountBalanceQuery: 1000 tps

ContractGetInfo: 700 tps
ContractGetBytecode: 700 tps
ContractCallLocal: 700 tps

FileGetInfo: 700 tps
FileGetContents: 700 tps

Other: 10,000 tps

Receiptsunlimited (no throttle)
+ +### High-Volume Throttles + +In addition to the standard throttles above, the network provides dedicated +**high-volume throttle capacity** for entity creation transactions that set +`high_volume = true`. These throttles run in parallel — they do not consume +capacity from the standard system, and the standard system does not consume +capacity from them. + +| **Throttle Bucket** | **Transaction Types** | **Capacity** | +|---|---|---| +| HighVolumeCryptoThrottles | `CryptoCreate`, `ScheduleCreate` | *Set by governance* | +| HighVolumeTotalThrottles | All 14 [supported types](/hedera/core-concepts/high-volume-entity-creation#supported-transaction-types) combined | *Set by governance* | + +A high-volume transaction must pass **both** its per-type bucket and the total +bucket to be accepted. If either is exhausted, the transaction receives a `BUSY` +response — the same behavior as the standard throttle system. + + + High-volume transactions use **variable-rate pricing** that scales with utilization. + See the [High-Volume Entity Creation](/hedera/core-concepts/high-volume-entity-creation) + guide to understand how this affects your transaction fees before opting in. + \ No newline at end of file diff --git a/hedera/networks/mainnet/fees.mdx b/hedera/networks/mainnet/fees.mdx index be5b99ca..406a52b3 100644 --- a/hedera/networks/mainnet/fees.mdx +++ b/hedera/networks/mainnet/fees.mdx @@ -8,13 +8,13 @@ The Hedera testnet fees tables found below offer a low-end estimate of transacti Fee estimates are based on assumptions about the details of a specific API call. For instance, the fee for an HBAR cryptocurrency transfer (CryptoTransfer) assumes a single signature on the transaction and the fee for storing a file assumes a 1,0000-byte sized file stored for 90 days. Transactions exceeding these base assumptions will be more expensive; we recommend increasing your maximum allowable fee to accommodate additional complexity. -### Mainnet Fees +## Mainnet Fees Mainnet transaction and query fees can be estimated using the [Hedera Fee Estimator](https://hedera.com/fees). The Fee Estimator allows you to determine fees (in both USD and HBAR, using the current exchange rate live on the mainnet) for individual transactions & queries based on their characteristics, as well as projected costs based on expected volume for those transactions. The estimations may not be 100% accurate and the underlying prices are subject to change without prior notice. ## HBAR Denominations and Abbreviations -| Denominations | Abbreviations | Amount of HBAR Cryptocurrency | +| **Denominations** | **Abbreviations** | **Amount of HBAR Cryptocurrency** | | ------------- | -------------- | ----------------------------- | | gigabar | 1 Gℏ | = 1,000,000,000 ℏ | | megabar | 1 Mℏ | = 1,000,000 ℏ | @@ -24,13 +24,31 @@ Mainnet transaction and query fees can be estimated using the [Hedera Fee Estima | microbar | 1,000,000 μℏ | = 1 ℏ | | tinybar | 100,000,000 tℏ | = 1 ℏ | + +## High-Volume Transaction Pricing + +The fee tables below reflect **standard** transaction pricing. If you set the +`high_volume` flag on a [supported entity creation transaction](/hedera/core-concepts/high-volume-entity-creation#supported-transaction-types), +a **variable-rate multiplier** is applied on top of the standard fee. The multiplier +scales with how much of the high-volume throttle capacity is currently in use — from +1.0× at idle to a governance-configured maximum at full utilization. + + + High-volume fees can be significantly higher than the standard fees listed in these + tables. Always check the current multiplier via the Mirror Node + [fee estimation endpoint](/hedera/sdks-and-apis/rest-api) and set `maxTransactionFee` + to cap your costs. See the + [High-Volume Entity Creation](/hedera/core-concepts/high-volume-entity-creation) guide + for full details on how variable-rate pricing works. + + ## Transaction and Query Fees All fees are subject to change. The fees below reflect a base price for the transaction or query. Transaction characteristics may increase the price from the base price shown below. Transaction characteristics include having more than one signature, a memo field, etc. Please reference the [Hedera fee estimator](https://hedera.com/fees) to estimate the transaction or query fee. ### Cryptocurrency Service -| Operations | USD ($) | +| **Operations** | **USD ($)** | | :--------------------------- | :------- | | CryptoCreate | $0.05 | | CryptoAccountAutoRenew | $0.00022 | @@ -50,7 +68,7 @@ All fees are subject to change. The fees below reflect a base price for the tran ### Consensus Service -| Operations | USD ($) | +| **Operations** | **USD ($)** | | ----------------------------------------- | -------- | | ConsensusCreateTopic | $0.01 | | ConsensusCreateTopic (with custom fees) | $2.00 | @@ -62,7 +80,7 @@ All fees are subject to change. The fees below reflect a base price for the tran ### Token Service Operations -| Operations | USD ($) | +| **Operations** | **USD ($)** | | ------------------------------------------------------- | ------------- | | TokenAirdrop (no prior association with token) | $0.10 | | TokenAssociate | $0.05 | @@ -96,7 +114,7 @@ All fees are subject to change. The fees below reflect a base price for the tran ### Schedule Transaction -| Operations | USD ($) | +| **Operations** | **USD ($)** | | --------------- | ------- | | ScheduleCreate | $0.01 | | ScheduleSign | $0.001 | @@ -105,7 +123,7 @@ All fees are subject to change. The fees below reflect a base price for the tran ### File Service -| Operations | USD ($) | +| **Operations** | **USD ($)** | | --------------- | ------- | | FileCreate | $0.05 | | FileUpdate | $0.05 | @@ -116,7 +134,7 @@ All fees are subject to change. The fees below reflect a base price for the tran ### Smart Contract Service -| Operations | USD ($) | +| **Operations** | **USD ($)** | | ------------------------------------------------------ | ------------------------------------------------------------------ | | ContractCreate | $1.00 | | ContractUpdate | $0.026 | @@ -134,7 +152,7 @@ All fees are subject to change. The fees below reflect a base price for the tran ### Miscellaneous -| Operations | USD ($) | +| **Operations** | **USD ($)** | | ----------------------------------------------------------------- | ------- | | BatchTransaction ([HIP-551](https://hips.hedera.com/hip/hip-551)) | $0.001 | | GetVersionInfo | $0.0001 | diff --git a/hedera/networks/testnet.mdx b/hedera/networks/testnet.mdx index 5623910d..115d56b0 100644 --- a/hedera/networks/testnet.mdx +++ b/hedera/networks/testnet.mdx @@ -81,3 +81,26 @@ Transactions are currently throttled for testnets. You will receive a **`BUSY`**
Network Request TypeThrottle (tps)
Cryptocurrency Transactions

AccountCreateTransaction: 2 tps
TransferTransaction (inc. tokens): 10,000 tps

Other: 10,000 tps

Consensus Transactions

TopicCreateTransaction: 5 tps

Other: 10,000 tps

Token Transactions

TokenMintTransaction:

  • 125 TPS for fungible mint
  • 50 TPS for NFT mint

TokenAssociateTransaction: 100 tps
TransferTransaction (inc. tokens): 10,000 tps

Other: 3,000 tps

Schedule TransactionsScheduleSignTransaction: 100 tps
ScheduleCreateTransaction: 100 tps
File Transactions10 tps
Smart Contract TransactionsContractExecuteTransaction: 350 tps
ContractCreateTransaction: 350 tps
Queries (per node)

AccountBalanceQuery: 1000 tps

ContractGetInfo: 700 tps
ContractGetBytecode: 700 tps
ContractCallLocal: 700 tps

FileGetInfo: 700 tps
FileGetContents: 700 tps

Other: 10,000 tps

Receiptsunlimited (no throttle)
+ +### High-Volume Throttles + +In addition to the standard throttles above, the testnet provides dedicated +**high-volume throttle capacity** for entity creation transactions that set +`high_volume = true`. These throttles run in parallel — they do not consume +capacity from the standard system, and the standard system does not consume +capacity from them. + +| **Throttle Bucket** | **Transaction Types** | **Capacity** | +|---|---|---| +| HighVolumeCryptoThrottles | `CryptoCreate`, `ScheduleCreate` | *Set by governance* | +| HighVolumeTotalThrottles | All 14 [supported types](/hedera/core-concepts/high-volume-entity-creation#supported-transaction-types) combined | *Set by governance* | + +A high-volume transaction must pass **both** its per-type bucket and the total +bucket to be accepted. If either is exhausted, the transaction receives a `BUSY` +response. + + + High-volume transactions use **variable-rate pricing** that scales with utilization. + See the [High-Volume Entity Creation](/hedera/core-concepts/high-volume-entity-creation) + guide to understand how this affects your transaction fees before opting in. + \ No newline at end of file diff --git a/hedera/sdks-and-apis/sdks/accounts-and-hbar/approve-an-allowance.mdx b/hedera/sdks-and-apis/sdks/accounts-and-hbar/approve-an-allowance.mdx index 394a0f9c..d46052e6 100644 --- a/hedera/sdks-and-apis/sdks/accounts-and-hbar/approve-an-allowance.mdx +++ b/hedera/sdks-and-apis/sdks/accounts-and-hbar/approve-an-allowance.mdx @@ -32,14 +32,38 @@ Only when a spender is set on an explicit NFT ID of a token, do we return the sp **Reference:** [HIP-336](https://github.com/hashgraph/hedera-improvement-proposal/blob/master/HIP/hip-336.md) -### Methods +## Constructor -| **Type** | **Description** | **Method** | -| --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------ | -| [AccountId](/hedera/sdks-and-apis/sdks/specialized-types#accountid), [AccountId](/hedera/sdks-and-apis/sdks/specialized-types#accountid), [Hbar](/hedera/sdks-and-apis/sdks/hbars) | The owner account ID that is authorizing the allowance, the spender account ID to authorize, the amount of hbar the owner account is authorizing the spender account to use. | `approveHbarAllowance(,, )` | -|

TokenId,
AccountId,

AccountId, long

| The token ID of the token being granted an allowance by the spender account, the account ID of the owner account, the account ID of the spender account. | `approveTokenAllowance(,,, )` | -|

nftId, AccountId,
AccountId

| The NFT ID of the NFT being granted an allowance by the owner account, the account ID of the owner account, the account ID of the spender account. | `approveTokenNftAllowance(,, )` | -|

TokenId,
AccountId,
AccountId,

| Grant a spender account access to all NFTs in a given token class/collection. The token ID of the NFT collection, the account ID of the owner account, the account ID of the spender account. | `approveTokenNftAllowanceAllSerials(,, )` | +| Constructor | **Description** | +|-------------|-------------| +| `new AccountAllowanceApproveTransaction()` | Initializes the AccountAllowanceApproveTransaction object | + +## Transaction Properties + +| **Method** | **Type** | Requirement | +|--------|------|-------------| +| `approveHbarAllowance()` | AccountId, AccountId, Hbar | Optional | +| `approveTokenAllowance()` | TokenId, AccountId, AccountId, long | Optional | +| `approveTokenNftAllowance()` | NftId, AccountId, AccountId | Optional | +| `approveTokenNftAllowanceAllSerials()` | TokenId, AccountId, AccountId | Optional | +| `setHighVolume()` | boolean | Optional | + +## Get Transaction Values + +| **Method** | **Type** | **Description** | +|--------|------|-------------| +| `getHbarApprovals()` | List<HbarAllowance> | Returns the HBAR allowances | +| `getTokenApprovals()` | List<TokenAllowance> | Returns the fungible token allowances | +| `getTokenNftApprovals()` | List<TokenNftAllowance> | Returns the NFT allowances | +| `getHighVolume()` | boolean | Returns whether this transaction uses [high-volume throttles](/hedera/core-concepts/high-volume-entity-creation) | + + + + This transaction supports [high-volume entity creation](/hedera/core-concepts/high-volume-entity-creation) + (HIP-1313). Setting `setHighVolume(true)` routes the transaction through dedicated + high-volume throttle capacity with variable-rate pricing. Always pair this with + `setMaxTransactionFee()` to cap your costs. + @@ -137,3 +161,4 @@ println!("The transaction consensus status is {:?}", status); ``` + diff --git a/hedera/sdks-and-apis/sdks/accounts-and-hbar/create-an-account.mdx b/hedera/sdks-and-apis/sdks/accounts-and-hbar/create-an-account.mdx index 15667a75..ef29bf45 100644 --- a/hedera/sdks-and-apis/sdks/accounts-and-hbar/create-an-account.mdx +++ b/hedera/sdks-and-apis/sdks/accounts-and-hbar/create-an-account.mdx @@ -2,37 +2,42 @@ title: "Create an account" --- +## Create an account using the account create API -### **Create an account using the account create API** - -A transaction that creates a Hedera account. A Hedera account is required to interact with any of the Hedera network services as you need an account to pay for all associated transaction/query fees. You can visit the [Hedera Developer Portal](https://portal.hedera.com/register) to create a previewnet or testnet account. You can also use third-party wallets to generate free [mainnet accounts](/hedera/networks/mainnet/mainnet-access). To process an account create transaction, you will need an existing account to pay for the transaction fee. To obtain the new account ID, request the [receipt](/hedera/sdks-and-apis/sdks/transactions/get-a-transaction-receipt) of the transaction. +A transaction that creates a Hedera account. A Hedera account is required to interact with any of the Hedera network services as you need an account to pay for all associated transaction/query fees. You can visit the [Hedera Developer Portal](https://portal.hedera.com/) to create a previewnet or testnet account. You can also use third-party wallets to generate free [mainnet accounts](/networks/mainnet/mainnet-access). To process an account create transaction, you will need an existing account to pay for the transaction fee. To obtain the new account ID, request the [receipt](/hedera/sdks-and-apis/sdks/transactions/get-a-transaction-receipt) of the transaction. -When creating a **new account** using the`AccountCreateTransaction()`API you will need an existing account to pay for the associated transaction fee. +When creating a **new account** using the `AccountCreateTransaction()` API you will need an existing account to pay for the associated transaction fee. -**Account Properties** +--- - +## Transaction Fees and Signing -**Transaction Fees** +- The sender pays for the token association fee and the rent for the first auto-renewal period. +- See the transaction and query [fees](/networks/mainnet/fees) table for the base transaction fee. +- Use the [Hedera fee estimator](https://hedera.com/fees) to estimate your transaction fee cost. +- The account paying for the transaction fee is required to sign the transaction. -* The sender pays for the token association fee and the rent for the first auto-renewal period. -* Please see the transaction and query [fees](/hedera/networks/mainnet/fees#transaction-and-query-fees) table for the base transaction fee. -* Please use the [Hedera fee estimator](https://hedera.com/fees) to estimate your transaction fee cost. +--- -**Transaction Signing Requirements** +## Account Properties -* The account paying for the transaction fee is required to sign the transaction. + +For a complete list of account properties, see the [accounts overview](/hedera/sdks-and-apis/sdks/accounts-and-hbar). + + +--- -#### Maximum Auto-Associations and Fees +## Maximum Auto-Associations and Fees Accounts have a property, `maxAutoAssociations`, and the property's value determines the maximum number of automatic token associations allowed. -
Property ValueDescription
0Automatic token associations or token airdrops are not allowed, and the account must be manually associated with a token. This also applies if the value is less than or equal to usedAutoAssociations.
-1Unlimited automatic token associations are allowed, and this is the default for accounts created via auto account creation and for accounts that began as hollow accounts and are now complete. Accounts with -1 can receive new tokens without manually associating them. The sender still pays the maxAutoAssociations fee and initial rent for each association.
> 0If the value is a positive number (number greater than 0), the number of automatic token associations an account can have is limited to that number.
+| Property Value | Description | +|---|---| +| `0` | Automatic token associations or **token airdrops** are not allowed, and the account must be manually associated with a token. This also applies if the value is less than or equal to `usedAutoAssociations`. | +| `-1` | Unlimited automatic token associations are allowed, and this is the default for accounts created via [auto account creation](/sdks-and-apis/sdks/accounts-and-hbar/create-an-account) and for accounts that began as hollow accounts and are now complete. Accounts with `-1` can receive new tokens without manually associating them. The sender still pays the `maxAutoAssociations` fee and initial rent for each association. | +| `> 0` | If the value is a positive number (number greater than 0), the number of automatic token associations an account can have is limited to that number. | The sender pays the `maxAutoAssociations` fee and the rent for the first auto-renewal period for the association. This is in addition to the typical transfer fees. This ensures the receiver can receive tokens without association and makes it a smoother transfer process. @@ -40,93 +45,111 @@ The sender pays the `maxAutoAssociations` fee and the rent for the first auto-re **Reference**: [HIP-904](https://hips.hedera.com/hip/hip-904) -#### Methods +--- -
MethodTypeRequirement
setKey(<key>)KeyRequired
setAlias(<alias>)EvmAddressOptional
setInitialBalance(<initialBalance>)HBarOptional
setReceiverSignatureRequired(<booleanValue>)booleanOptional
setMaxAutomaticTokenAssociations(<amount>)intOptional
setStakedAccountId(<stakedAccountId>)AccountIdOptional
setStakedNodeId(<stakedNodeId>)longOptional
setDeclineStakingReward(<declineStakingReward>)booleanOptional
setAccountMemo(<memo>)StringOptional
setAutoRenewPeriod(<autoRenewPeriod>)DurationDisabled
+## Constructor + +| Constructor | Description | +|---|---| +| `new AccountCreateTransaction()` | Initializes the AccountCreateTransaction object | + +## Transaction Properties + +| **Method** | **Type** | Requirement | +|---|---|---| +| `setKey()` | Key | Required | +| `setInitialBalance()` | Hbar | Optional | +| `setReceiverSignatureRequired()` | boolean | Optional | +| `setAutoRenewPeriod()` | Duration | Optional | +| `setAccountMemo()` | String | Optional | +| `setMaxAutomaticTokenAssociations()` | int | Optional | +| `setStakedAccountId()` | AccountId | Optional | +| `setStakedNodeId()` | long | Optional | +| `setDeclineStakingReward()` | boolean | Optional | +| `setHighVolume()` | boolean | Optional | + + + This transaction supports [high-volume entity creation](/hedera/core-concepts/high-volume-entity-creation) + (HIP-1313). Setting `setHighVolume(true)` routes the transaction through dedicated + high-volume throttle capacity with variable-rate pricing. Always pair this with + `setMaxTransactionFee()` to cap your costs. + - -**Account Alias** + -If an alias is set during account creation, it becomes [immutable](/hedera/support-and-community/glossary#immutability), meaning it cannot be changed. If you plan to update or rotate keys in the future, do not set the alias at the time of initial account creation. The alias can be set after finalizing all key updates. - - +```javascript JavaScript +//Create new ECDSA key +const ecdsaPublicKey = PrivateKey.generateECDSA().publicKey -```java Java //Create the transaction -AccountCreateTransaction transaction = new AccountCreateTransaction() +const transaction = new AccountCreateTransaction() .setKeyWithAlias(ecdsaPublicKey) - // DO NOT set an alias with your key if you plan to update/rotate keys in the future, Use .setKeyWithoutAlias instead + // DO NOT set an alias with your key if you plan to update/rotate keys in the future, Use .setKeyWithoutAlias instead // .setKeyWithoutAlias(ecdsaPublicKey) .setInitialBalance(new Hbar(1)); -//Submit the transaction to a Hedera network -TransactionResponse txResponse = transaction.execute(client); +//Sign the transaction with the client operator private key and submit to a Hedera network +const txResponse = await transaction.execute(client); //Request the receipt of the transaction -TransactionReceipt receipt = txResponse.getReceipt(client); +const receipt = await txResponse.getReceipt(client); //Get the account ID -AccountId newAccountId = receipt.accountId; +const newAccountId = receipt.accountId; -System.out.println("The new account ID is " +newAccountId); +console.log("The new account ID is " + newAccountId); -//Version 2.0.0 +//v2.0.5 ``` -```javascript JavaScript +```java Java //Create new ECDSA key -const ecdsaPublicKey = PrivateKey.generateECDSA().publicKey +PublicKey ecdsaPublicKey = PrivateKey.generateECDSA().getPublicKey(); //Create the transaction -const transaction = new AccountCreateTransaction() +AccountCreateTransaction transaction = new AccountCreateTransaction() .setKeyWithAlias(ecdsaPublicKey) - // DO NOT set an alias with your key if you plan to update/rotate keys in the future, Use .setKeyWithoutAlias instead + // DO NOT set an alias with your key if you plan to update/rotate keys in the future, Use .setKeyWithoutAlias instead // .setKeyWithoutAlias(ecdsaPublicKey) .setInitialBalance(new Hbar(1)); //Sign the transaction with the client operator private key and submit to a Hedera network -const txResponse = await transaction.execute(client); +TransactionResponse txResponse = transaction.execute(client); //Request the receipt of the transaction -const receipt = await txResponse.getReceipt(client); +TransactionReceipt receipt = txResponse.getReceipt(client); //Get the account ID -const newAccountId = receipt.accountId; - -console.log("The new account ID is " +newAccountId); +AccountId newAccountId = receipt.accountId; -//v2.0.5 +System.out.println("The new account ID is " + newAccountId); ``` ```go Go +//Create new ECDSA key +ecdsaPrivateKey, _ := hedera.PrivateKeyGenerateECDSA() +ecdsaPublicKey := ecdsaPrivateKey.PublicKey() + //Create the transaction transaction := hedera.NewAccountCreateTransaction(). - SetKeyWithAlias(ecdsaPublicKey). - //do not set if you need to rotate keys in the future - // SetKeyWithoutAlias(ecdsaPublicKey). - SetInitialBalance(hedera.NewHbar(1)) + SetKeyWithAlias(ecdsaPublicKey). + // DO NOT set an alias with your key if you plan to update/rotate keys in the future, Use .SetKeyWithoutAlias instead + // SetKeyWithoutAlias(ecdsaPublicKey). + SetInitialBalance(hedera.NewHbar(1)) //Sign the transaction with the client operator private key and submit to a Hedera network -txResponse, err := AccountCreateTransaction.Execute(client) -if err != nil { - panic(err) -} +txResponse, err := transaction.Execute(client) //Request the receipt of the transaction receipt, err := txResponse.GetReceipt(client) -if err != nil { - panic(err) -} //Get the account ID newAccountId := *receipt.AccountID fmt.Printf("The new account ID is %v\n", newAccountId) - -//Version 2.0.0 ``` @@ -156,61 +179,74 @@ println!("The new account ID is {}", new_account_id); // v0.34.0 ``` - -#### Get transaction values -| Method | Type | Description | -| -------------------------------- | --------- | --------------------------------------------------------- | -| `getKey()` | Key | Returns the public key on the account | -| `getInitialBalance()` | Hbar | Returns the initial balance of the account | -| `getAutoRenewPeriod()` | Duration | Returns the auto renew period on the account | -| `getDeclineStakingReward()` | boolean | Returns whether or not the account declined rewards | -| `getStakedNodeId()` | long | Returns the node ID | -| `getStakedAccountId()` | AccountId | Returns the node account ID | -| `getReceiverSignatureRequired()` | boolean | Returns whether the receiver signature is required or not | +## Get Transaction Values + +| **Method** | **Type** | Description | +|---|---|---| +| `getKey()` | Key | Returns the public key on the account | +| `getInitialBalance()` | Hbar | Returns the initial balance of the account | +| `getAutoRenewPeriod()` | Duration | Returns the auto renew period on the account | +| `getDeclineStakingReward()` | boolean | Returns whether or not the account declined rewards | +| `getStakedNodeId()` | long | Returns the node ID | +| `getStakedAccountId()` | AccountId | Returns the node account ID | +| `getReceiverSignatureRequired()` | boolean | Returns whether the receiver signature is required or not | +| `getHighVolume()` | boolean | Returns whether this transaction uses [high-volume throttles](/hedera/core-concepts/high-volume-entity-creation) | + + +This transaction supports [high-volume entity creation](/hedera/core-concepts/high-volume-entity-creation) (HIP-1313). Setting `setHighVolume(true)` routes the transaction through dedicated high-volume throttle capacity with variable-rate pricing. Always pair this with `setMaxTransactionFee()` to cap your costs. + + + +#### **Account Alias** +If an alias is set during account creation, it becomes [immutable](/hedera/support-and-community/glossary#immutable), meaning it cannot be changed. If you plan to update or rotate keys in the future, do not set the alias at the time of initial account creation. The alias can be set after finalizing all key updates. + -```java Java -//Create an account with 1 hbar -AccountCreateTransaction transaction = new AccountCreateTransaction() +```javascript JavaScript +//Create an account with 1 HBAR +const transaction = new AccountCreateTransaction() // The only _required_ property here is `key` .setKeyWithAlias(newPublicKey) - // DO NOT set an alias with your key if you plan to update/rotate keys in the future, Use .setKeyWithoutAlias instead + // Do NOT set an alias if you need to rotate keys in the future. Use .setKeyWithoutAlias instead // .setKeyWithoutAlias(newPublicKey) .setInitialBalance(new Hbar(1)); //Return the key on the account -Key accountKey = transaction.getKey(); +const accountKey = transaction.getKey(); ``` -```javascript JavaScript -//Create an account with 1 HBAR -const transaction = new AccountCreateTransaction() +```java Java +//Create an account with 1 hbar +AccountCreateTransaction transaction = new AccountCreateTransaction() // The only _required_ property here is `key` .setKeyWithAlias(newPublicKey) - // Do NOT set an alias if you need to rotate keys in the future. Use .setKeyWithoutAlias instead + // DO NOT set an alias with your key if you plan to update/rotate keys in the future, Use .setKeyWithoutAlias instead // .setKeyWithoutAlias(newPublicKey) .setInitialBalance(new Hbar(1)); //Return the key on the account -const accountKey = transaction.getKey(); +Key accountKey = transaction.getKey(); ``` - ```go Go //Create an account with 1 hbar AccountCreateTransaction := hedera.NewAccountCreateTransaction(). SetKeyWithAlias(newPublicKey). - // DO NOT set an alias with your key if you plan to update/rotate keys in the future, Use .SetKeyWithoutAlias instead + // DO NOT set an alias with your key if you plan to update/rotate keys in the future, Use .SetKeyWithoutAlias instead // SetKeyWithoutAlias(newPublicKey). SetInitialBalance(hedera.NewHbar(1)) //Return the key on the account accountKey, err := AccountCreateTransaction.GetKey() ``` - + + + + + diff --git a/hedera/sdks-and-apis/sdks/accounts-and-hbar/transfer-cryptocurrency.mdx b/hedera/sdks-and-apis/sdks/accounts-and-hbar/transfer-cryptocurrency.mdx index 99cf100d..b7a58064 100644 --- a/hedera/sdks-and-apis/sdks/accounts-and-hbar/transfer-cryptocurrency.mdx +++ b/hedera/sdks-and-apis/sdks/accounts-and-hbar/transfer-cryptocurrency.mdx @@ -42,9 +42,34 @@ The debiting account is the owner's account when using this feature. * If an authorized spender account is spending on behalf of the account that owns the tokens then the spending account is required to sign * The transaction fee-paying account is required to sign the transaction -### Methods +## Constructor -
MethodTypeDescription
addHbarTransfer(<accountId>, <evmAddress>, <value>)AccountId, string, HBARThe account involved in the transfer and the number of HBAR.

The sender and recipient values must net zero.
addTokenTransfer(<tokenId>, <accountId>, <evmAddress>, <value>)TokenId, AccountId, string, longThe ID of the token, the account ID involved in the transfer, and the number of tokens to transfer.

The sender and recipient values must net zero.
addNftTransfer(<nftId>, <sender>, <receiver>)NftId, AcountId, AccountIdThe NFT ID (token + serial number), the sending account, and receiving account.
addTokenTransferWithDecimals(<tokenId>, <accountId>, <value>, <int>)TokenId, AccountId, long, decimalsThe ID of the token, the account ID involved in the transfer, the number of tokens to transfer, the decimals of the token.

The sender and recipient values must net zero.
addApprovedHbarTransfer(<ownerAccountId>,<amount>)AccountId, HbarThe owner account ID the spender is authorized to transfer from and the amount.
Applicable to allowance transfers only.
addApprovedTokenTransfer(<tokenId>, <accountId>, <value>)TokenId, AccountId, longThe owner account ID and token the spender is authorized to transfer from. The debiting account is the owner account.
Applicable to allowance transfers only.
addApprovedTokenTransferWithDecimals(<tokenId>, <accountId>, <value>, <decimals>)TokenId, AccountId, long, intThe owner account ID and token ID (with decimals) the spender is authorized to transfer from. The debit account is the account ID of the sender.
Applicable to allowance transfers only.
addApprovedNftTransfer(<nftId>,<sender>, <receiver>)NftId, AcountId, AccountIdThe NFT ID the spender is authorized to transfer. The sender is the owner account and receiver is the receiving account.
Applicable to allowance transfers only.
+| **Constructor** | **Description** | +|-------------|-------------| +| `new TransferTransaction()` | Initializes the TransferTransaction object | + +## Transaction Properties + +| **Method** | **Type** | **Requirement** | +|--------|------|-------------| +| `addHbarTransfer()` | AccountId, Hbar | Required | +| `addTokenTransfer()` | TokenId, AccountId, long | Optional | +| `addNftTransfer()` | NftId, AccountId, AccountId | Optional | +| `addTokenTransferWithDecimals()` | TokenId, AccountId, long, int | Optional | +| `addApprovedHbarTransfer()` | AccountId, Hbar | Optional | +| `addApprovedTokenTransfer()` | TokenId, AccountId, long | Optional | +| `addApprovedNftTransfer()` | NftId, AccountId, AccountId | Optional | +| `addApprovedTokenTransferWithDecimals()` | TokenId, AccountId, long, int | Optional | +| `setHighVolume()` | boolean | Optional | + + + +This transaction supports [high-volume entity creation](/hedera/core-concepts/high-volume-entity-creation) +(HIP-1313) when the transfer **auto-creates new accounts**. Setting `setHighVolume(true)` +routes the account-creation portion of the transfer through dedicated high-volume throttle +capacity with variable-rate pricing. The transfer portion itself uses standard throttles +regardless of this flag. Always pair this with `setMaxTransactionFee()` to cap your costs. + @@ -144,12 +169,15 @@ println!("The transaction consensus status is {:?}", status); -## Get transaction values -| Method | Type | Description | -| --------------------- | ------------------------------------ | -------------------------------------------------------- | -| `getHbarTransfers()` | Map\ | Returns a list of the hbar transfers in this transaction | -| `getTokenTransfers()` | Map\> | Returns the list of token transfers in the transaction | +## Get Transaction Values + +| **Method** | **Type** | **Description** | +|--------|------|-------------| +| `getHbarTransfers()` | Map<AccountId, Hbar> | Returns the HBAR transfers | +| `getTokenTransfers()` | Map<TokenId, Map<AccountId, long>> | Returns the token transfers | +| `getTokenNftTransfers()` | Map<TokenId, List<TokenNftTransfer>> | Returns the NFT transfers | +| `getHighVolume()` | boolean | Returns whether this transaction uses [high-volume throttles](/hedera/core-concepts/high-volume-entity-creation) | diff --git a/hedera/sdks-and-apis/sdks/consensus-service/create-a-topic.mdx b/hedera/sdks-and-apis/sdks/consensus-service/create-a-topic.mdx index 92e3f77a..65a81dbe 100644 --- a/hedera/sdks-and-apis/sdks/consensus-service/create-a-topic.mdx +++ b/hedera/sdks-and-apis/sdks/consensus-service/create-a-topic.mdx @@ -46,8 +46,19 @@ You can also create a private topic where only authorized parties can submit mes #### Methods -
MethodTypeRequirements
setAdminKey(<adminKey>)KeyOptional
setSubmitKey(<submitKey>)KeyOptional
setTopicMemo(<memo>)StringOptional
setAutoRenewAccountId(<accountId>)AccountIdOptional
setAutoRenewPeriod(<autoRenewPeriod>)DurationOptional
setFeeScheduleKey()KeyOptional
setFeeExemptKeys()List<Key>Optional
setCustomFees()List<CustomFixedFee>Optional
addCustomFee()CustomFixedFeeOptional
addFeeExemptKey()KeyOptional
- +| **Method** | **Type** | **Requirements** | +|---|---|---| +| `setAdminKey()` | Key | Optional | +| `setSubmitKey()` | Key | Optional | +| `setTopicMemo()` | String | Optional | +| `setAutoRenewAccountId()` | AccountId | Optional | +| `setAutoRenewPeriod()` | Duration | Optional | +| `setFeeScheduleKey()` | Key | Optional | +| `setFeeExemptKeys()` | List\ | Optional | +| `setCustomFees()` | List\ | Optional | +| `addCustomFee()` | CustomFixedFee | Optional | +| `addFeeExemptKey()` | Key | Optional | +| `setHighVolume()` | boolean | Optional | ```java Java @@ -150,7 +161,7 @@ println!("The new topic ID is {:?}", topic_id); ## Get transaction values -
MethodTypeRequirements
getAdminKey(<adminKey>)KeyOptional
getSubmitKey(<submitKey>)KeyOptional
getTopicMemo(<memo>)StringOptional
getAutoRenewAccountId()AccountIdRequired
getAutoRenewPeriod()DurationRequired
getFeeScheduleKey()KeyOptional
getFeeExemptKeys()ListOptional
getCustomFees()ListOptional
+
**Method****Type****Requirements**
getAdminKey(<adminKey>)KeyOptional
getSubmitKey(<submitKey>)KeyOptional
getTopicMemo(<memo>)StringOptional
getAutoRenewAccountId()AccountIdRequired
getAutoRenewPeriod()DurationRequired
getFeeScheduleKey()KeyOptional
getFeeExemptKeys()ListOptional
getCustomFees()ListOptional
@@ -188,3 +199,10 @@ getFeeScheduleKey := transaction.GetFeeScheduleKey() ``` + + + This transaction supports [high-volume entity creation](/hedera/core-concepts/high-volume-entity-creation) + (HIP-1313). Setting `setHighVolume(true)` routes the transaction through dedicated + high-volume throttle capacity with variable-rate pricing. Always pair this with + `setMaxTransactionFee()` to cap your costs. + \ No newline at end of file diff --git a/hedera/sdks-and-apis/sdks/file-service/append-to-a-file.mdx b/hedera/sdks-and-apis/sdks/file-service/append-to-a-file.mdx index 52b63b72..7202666e 100644 --- a/hedera/sdks-and-apis/sdks/file-service/append-to-a-file.mdx +++ b/hedera/sdks-and-apis/sdks/file-service/append-to-a-file.mdx @@ -14,7 +14,7 @@ A transaction that appends new file content to the end of an existing file. The * Please see the transaction and query [fees](/hedera/networks/mainnet/fees#transaction-and-query-fees) table for base transaction fee * Please use the [Hedera fee estimator](https://hedera.com/fees) to estimate your transaction fee cost -| Constructor | Description | +| **Constructor** | **Description** | | ------------------------- | -------------------------------------------- | | `FileAppendTransaction()` | Initializes the FileAppendTransaction object | @@ -28,13 +28,14 @@ The default max transaction fee (1 hbar) is not enough to create a file. Use `se ### Methods -| Method | Type | Description | Requirement | +| **Method** | **Type** | **Description** | **Requirement** | | ------------------------------ | --------- | ---------------------------- | ----------- | | `setFileId()` | FileId | The ID of the file to append | Required | | `setContents()` | String | The content in String format | Optional | | `setContents()` | byte \[ ] | The content in byte format | Optional | | `setChunkSize()` | int | The chunk size | Optional | | `setMaxChunkSize()` | int | The max chunk size | Optional | +| `setHighVolume()` | boolean | The high-volume flag | Optional | @@ -152,7 +153,7 @@ println!("The transaction consensus status is {:?}", status); ## Get transaction values -| Method | Type | Description | Requirement | +| **Method** | **Type** | **Description** | **Requirement** | | --------------- | ------ | ------------------------------ | ----------- | | `getFileId()` | FileId | The file ID in the transaction | Optional | | `getContents()` | String | The content in the transaction | Optional | @@ -194,5 +195,12 @@ getContents2 := transaction2.GetContents() //v2.0.0 ``` - + + + + This transaction supports [high-volume entity creation](/hedera/core-concepts/high-volume-entity-creation) + (HIP-1313). Setting `setHighVolume(true)` routes the transaction through dedicated + high-volume throttle capacity with variable-rate pricing. Always pair this with + `setMaxTransactionFee()` to cap your costs. + \ No newline at end of file diff --git a/hedera/sdks-and-apis/sdks/file-service/create-a-file.mdx b/hedera/sdks-and-apis/sdks/file-service/create-a-file.mdx index 319b27eb..168d122e 100644 --- a/hedera/sdks-and-apis/sdks/file-service/create-a-file.mdx +++ b/hedera/sdks-and-apis/sdks/file-service/create-a-file.mdx @@ -20,7 +20,7 @@ The maximum file size is 1,024 kB. #### File Properties -| Field | Description | +| **Field** | **Description** | | ------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | | **Key(s)** | Set the keys which must sign any transactions modifying this file (the owner(s) of the file). All keys must sign to modify the file's contents or keys. No key is required to sign for extending the expiration time (except the one for the operator account paying for the transaction). The network currently requires a file to have at least one key (or key list or threshold key) but this requirement may be lifted in the future. | | **Contents** | The contents of the file. The file contents can be recovered from requesting the FileContentsQuery. Note that the total size for a given transaction is limited to 6KiB (as of March 2020) by the network; if you exceed this you may receive a TRANSACTION\_OVERSIZE error. | @@ -29,7 +29,7 @@ The maximum file size is 1,024 kB. ### Methods -| Constructor | Description | +| **Constructor** | **Description** | | ----------------------------- | -------------------------------------------- | | `new FileCreateTransaction()` | Initializes the FileCreateTransaction object | @@ -41,13 +41,15 @@ new FileCreateTransaction() The default max transaction fee (1 hbar) is not enough to create a a file. Use `setDefaultMaxTransactionFee()`to change the default max transaction fee from 1 hbar to 2 hbars.
-| Method | Type | Requirement | +| **Method** | **Type** | **Requirement** | | ------------------------------------- | ---------- | ----------- | | `setKeys()` | Key | Required | | `setContents()` | String | Optional | | `setContents()` | bytes \[ ] | Optional | | `setExpirationTime()` | Instant | Optional | | `setFileMemo()` | String | Optional | +| `setHighVolume()` | boolean | Optional | + @@ -162,7 +164,7 @@ println!("The new file ID is {:?}", file_id); ## Get transaction values -| Method | Type | Requirement | +| **Method** | **Type** | **Requirement** | | --------------------- | ---------- | ----------- | | `getKeys()` | Key | Optional | | `getContents()` | ByteString | Optional | @@ -202,5 +204,11 @@ transaction := hedera.NewFileCreateTransaction(). //Get the file contents getContents := transaction.GetContents() ``` - + + + This transaction supports [high-volume entity creation](/hedera/core-concepts/high-volume-entity-creation) + (HIP-1313). Setting `setHighVolume(true)` routes the transaction through dedicated + high-volume throttle capacity with variable-rate pricing. Always pair this with + `setMaxTransactionFee()` to cap your costs. + \ No newline at end of file diff --git a/hedera/sdks-and-apis/sdks/schedule-transaction/create-a-schedule-transaction.mdx b/hedera/sdks-and-apis/sdks/schedule-transaction/create-a-schedule-transaction.mdx index 7c9c52ee..111a4931 100644 --- a/hedera/sdks-and-apis/sdks/schedule-transaction/create-a-schedule-transaction.mdx +++ b/hedera/sdks-and-apis/sdks/schedule-transaction/create-a-schedule-transaction.mdx @@ -2,21 +2,19 @@ title: "Create a schedule transaction" --- - A `ScheduleCreateTransaction` is a consensus node transaction that creates a schedule entity on the Hedera network. The entity ID for a schedule transaction is called a `ScheduleID`. After successfully executing a schedule create transaction, you can retrieve the network assigned `ScheduleID` by requesting the transaction receipt. The receipt also includes the scheduled transaction ID, which can be used to request the record of the scheduled transaction after its successful execution. When creating a transaction to schedule you do not need to use `.freezeWith(client)` method. Example: - -```java +```java Java TransferTransaction transactionToSchedule = new TransferTransaction() .addHbarTransfer(newAccountId, Hbar.fromTinybars(-1)) .addHbarTransfer(operatorId, Hbar.fromTinybars(1)); ``` -Refer to this [page](/hedera/core-concepts/scheduled-transaction#overview) to view the types of transactions that can be scheduled. + Refer to this [page](/hedera/core-concepts/scheduled-transaction#overview) to view the types of transactions that can be scheduled. ### **Schedule Transaction Duplicate** @@ -38,7 +36,7 @@ To retain the ability to delete a schedule transaction, you will need to set the ### **Transaction Properties** -| Field | Description | +| **Field** | **Description** | | -------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | **Schedulable Transaction Body** | The transaction body of the transaction that is being scheduled. Ex. Transfer Transaction | | **Admin Key** | A key that can delete the schedule transaction prior to execution or expiration | @@ -49,10 +47,28 @@ To retain the ability to delete a schedule transaction, you will need to set the ### Methods -
MethodTypeRequirement
setScheduledTransaction(<transaction>)Transaction<?>Required
setAdminKey(<key>)KeyOptional
setPayerAccountId(<id>)AccountIdOptional
setScheduleMemo(<memo>)StringOptional
setExpirationTime(expirationTime)InstantOptional
setWaitForExpiry()booleanOptional
getAdminKey()KeyOptional
getPayerAccountId()AccountIdOptional
getScheduleMemo()StringOptional
+| **Method** | **Type** | **Requirement** | +|---|---|---| +| `setScheduledTransaction()` | Transaction | Required | +| `setAdminKey()` | Key | Optional | +| `setPayerAccountId()` | AccountId | Optional | +| `setScheduleMemo()` | String | Optional | +| `setExpirationTime(expirationTime)` | Instant | Optional | +| `setWaitForExpiry()` | boolean | Optional | +| `setHighVolume()` | boolean | Optional | +| `getAdminKey()` | Key | Optional | +| `getPayerAccountId()` | AccountId | Optional | +| `getScheduleMemo()` | String | Optional | +| `getHighVolume()` | boolean | Optional | + + + This transaction supports [high-volume entity creation](/hedera/core-concepts/high-volume-entity-creation) + (HIP-1313). Setting `setHighVolume(true)` routes the transaction through dedicated + high-volume throttle capacity with variable-rate pricing. Always pair this with + `setMaxTransactionFee()` to cap your costs. + - ```java Java //Create a schedule transaction ScheduleCreateTransaction transaction = new ScheduleCreateTransaction() @@ -69,7 +85,6 @@ ScheduleId scheduleId = receipt.scheduleId; System.out.println("The schedule ID of the schedule transaction is " +scheduleId); ``` - ```javascript JavaScript //Create a schedule transaction const transaction = new ScheduleCreateTransaction() @@ -86,7 +101,6 @@ const scheduleId = receipt.scheduleId; console.log("The schedule ID of the schedule transaction is " +scheduleId); ``` - ```go Go //Create a schedule transaction transaction, err := transactionToSchedule.Schedule() @@ -114,7 +128,6 @@ scheduleId := *receipt.ScheduleID fmt.Printf("The new token ID is %v\n", scheduleId) ``` - ```rust Rust // Create a schedule transaction let transaction = ScheduleCreateTransaction::new() @@ -132,5 +145,4 @@ println!("The schedule ID of the schedule transaction is {:?}", schedule_id); // v0.34.0 ``` - diff --git a/hedera/sdks-and-apis/sdks/smart-contracts/create-a-smart-contract.mdx b/hedera/sdks-and-apis/sdks/smart-contracts/create-a-smart-contract.mdx index 838cb5cb..4dea0ffe 100644 --- a/hedera/sdks-and-apis/sdks/smart-contracts/create-a-smart-contract.mdx +++ b/hedera/sdks-and-apis/sdks/smart-contracts/create-a-smart-contract.mdx @@ -40,7 +40,7 @@ With [HIP-904](https://hips.hedera.com/hip/hip-904), contracts now support Admin **Smart Contract Properties** -| Field | Description | +| **Field** | **Description** | | -------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | **Admin Key** | Sets the state of the instance and its fields can be modified arbitrarily if this key signs a transaction to modify it. If this is null, then such modifications are not possible, and there is no administrator that can override the normal operation of this smart contract instance. Note that if it is created with no admin keys, then there is no administrator to authorize changing the admin keys, so there can never be any admin keys for that instance. | | **Gas** | The gas to run the constructor. | @@ -68,7 +68,7 @@ The response will return the contract create transaction information like the ne **Note:** Please refer to [ContractCreateTransaction()](#contractcreatetransaction) for a complete list of applicable methods. -| Method | Type | +| **Method** | **Type** | | -------------------------- | ---------- | | `setBytecode()` | byte | | `setBytecode()` | String | @@ -176,27 +176,30 @@ println!("The new contract ID is {:?}", new_contract_id); Creates a smart contract instance using the file ID of the contract bytecode. -| Constructor | Description | -| --------------------------------- | -------------------------------------------------- | +### Constructor + +| **Constructor** | **Description** | +|---|---| | `new ContractCreateTransaction()` | Initializes the ContractCreateTransaction() object | ### Methods -| Method | Type | Requirement | -| --------------------------------------------------- | ------------------------------------------------------------------------------- | ----------- | -| `setGas()` | long | Required | -| `setBytecodeFileId()` | [FileId](/hedera/sdks-and-apis/sdks/specialized-types#fileid) | Required | -| `setInitialBalance()` | Hbar | Optional | -| `setAdminKey()` | Key | Optional | -| `setConstructorParameters()` | byte \[ ] | Optional | -| `setConstructorParameters()` | ContractFunctionParameters | Optional | -| `setContractMemo()` | String | Optional | -| `setStakedNodeId()` | long | Optional | -| `setStakedAccountId()` | AccountId | Optional | -| `setDeclineStakingReward()` | boolean | Optional | -| `setAutoRenewAccountId()` | Duration | Optional | -| `setMaxAutomaticTokenAssociations()` | int | Optional | +| **Method** | **Type** | **Requirement** | +|---|---|---| +| `setGas()` | long | Required | +| `setBytecodeFileId()` | [FileId](/sdks-and-apis/sdks/file-service/create-a-file) | Required | +| `setInitialBalance()` | Hbar | Optional | +| `setAdminKey()` | Key | Optional | +| `setConstructorParameters()` | byte [ ] | Optional | +| `setConstructorParameters()` | ContractFunctionParameters | Optional | +| `setContractMemo()` | String | Optional | +| `setStakedNodeId()` | long | Optional | +| `setStakedAccountId()` | AccountId | Optional | +| `setDeclineStakingReward()` | boolean | Optional | +| `setAutoRenewAccountId()` | AccountId | Optional | +| `setAutoRenewPeriod()` | Duration | Optional | +| `setMaxAutomaticTokenAssociations()` | int | Optional | +| `setHighVolume()` | boolean | Optional | @@ -272,22 +275,27 @@ fmt.Printf("The new topic ID is %v\n", newContractId) -## Get transaction values - -| Method | Type | Requirement | -| --------------------------------------------------- | ---------- | ----------- | -| `getAdminKey()` | Key | Optional | -| `getGas()` | long | Optional | -| `getInitialBalance()` | Hbar | Optional | -| `getBytecodeFileId()` | FileId | Optional | -| `getProxyAccountId(`) | AccountId | Optional | -| `getConstructorParameters()` | ByteString | Optional | -| `getContractMemo()` | String | Optional | -| `getDeclineStakingReward()` | boolean | Optional | -| `getStakedNodeId()` | long | Optional | -| `getStakedAccountId()` | AccountId | Optional | -| `getAutoRenewAccountId()` | AccountId | Required | -| `getAutoRenewPeriod()` | Duration | Required | +### Get Transaction Values + +| **Method** | **Type** | **Requirement** | +|---|---|---| +| `getAdminKey()` | Key | Optional | +| `getGas()` | long | Optional | +| `getInitialBalance()` | Hbar | Optional | +| `getBytecodeFileId()` | FileId | Optional | +| `getProxyAccountId()` | AccountId | Optional | +| `getConstructorParameters()` | ByteString | Optional | +| `getContractMemo()` | String | Optional | +| `getDeclineStakingReward()` | boolean | Optional | +| `getStakedNodeId()` | long | Optional | +| `getStakedAccountId()` | AccountId | Optional | +| `getAutoRenewAccountId()` | AccountId | Required | +| `getAutoRenewPeriod()` | Duration | Required | +| `getHighVolume()` | boolean | Optional | + + +This transaction supports [high-volume entity creation](/hedera/core-concepts/high-volume-entity-creation) (HIP-1313) for **HAPI-based contract creation only**. Setting `setHighVolume(true)` routes the transaction through dedicated high-volume throttle capacity with variable-rate pricing. Contract deployments via EVM `CREATE` / `CREATE2` opcodes are **not** included — a subsequent HIP will address EVM-specific high-volume behavior. Always pair with `setMaxTransactionFee()` to cap your costs. + diff --git a/hedera/sdks-and-apis/sdks/token-service/airdrop-a-token.mdx b/hedera/sdks-and-apis/sdks/token-service/airdrop-a-token.mdx index aa88f906..1a8f7a23 100644 --- a/hedera/sdks-and-apis/sdks/token-service/airdrop-a-token.mdx +++ b/hedera/sdks-and-apis/sdks/token-service/airdrop-a-token.mdx @@ -25,7 +25,16 @@ Restrictions on transfer lists and aggregation in `TokenAirdrop` are consistent * Please see the transaction and query [fees](/hedera/networks/mainnet/fees#transaction-and-query-fees) table for the base transaction fee. * Please use the [Hedera fee estimator](https://hedera.com/fees) to estimate the cost of your transaction fee. -
MethodTypeDescription
addTokenTransfer(<tokenId>, <accountId>, <amount>)TokenId, AccountId, int64Add the from (sender) and to (receiver) account to transfer tokens. You will need to use this method twice. One will specify the the account sending the airdrop and the second will specify the account receiving the airdrop. The sending account must sign the transaction. The sender and recipient values must net zero.
addNftTransfer(<nftId>, <sender>, <receiver>)NftId, AccountId, AccountIdAdds an NFT transfer to the transaction, specifying the NFT ID, the sender's account, and the receiver's account.
addTokenTransferWithDecimals(<tokenId>, <accountId>, <amount>, <decimals>)TokenId, AccountId, int64, uint32Adds a token transfer to the transaction with specified decimal precision, detailing the token ID, account, amount, and decimal places.
addApprovedTokenTransfer(<tokenId>, <accountId>, <amount>)TokenId, AccountId, int64The owner account ID and token the spender is authorized to transfer from. The debiting account is the owner account. Applicable to allowance transfers only.
addApprovedNftTransfer(<nftId>, <sender>, <receiver>)NftId, AccountId, AccountIdThe NFT ID the spender is authorized to transfer. The sender is the owner account and receiver is the receiving account. Applicable to allowance transfers only.
addApprovedTokenTransferWithDecimals(<tokenId>, <accountId>, <amount>, <decimals>)TokenId, AccountId, int64, uint32Adds an approved token transfer with decimal precision, specifying the owner account ID, token ID, and sender's account. Applicable to allowance transfers only.
+| **Method** | **Type** | **Description** | +|---|---|---| +| `addTokenTransfer(, , )` | TokenId, AccountId, int64 | Add the from (sender) and to (receiver) account to transfer tokens. You will need to use this method twice. One will specify the account sending the airdrop and the second will specify the account receiving the airdrop. The sending account must sign the transaction. The sender and recipient values must net zero. | +| `addNftTransfer(, , )` | NftId, AccountId, AccountId | Adds an NFT transfer to the transaction, specifying the NFT ID, the sender's account, and the receiver's account. | +| `addTokenTransferWithDecimals(, , , )` | TokenId, AccountId, int64, uint32 | Adds a token transfer to the transaction with specified decimal precision, detailing the token ID, account, amount, and decimal places. | +| `addApprovedTokenTransfer(, , )` | TokenId, AccountId, int64 | The owner account ID and token the spender is authorized to transfer from. The debiting account is the owner account. Applicable to allowance transfers only. | +| `addApprovedNftTransfer(, , )` | NftId, AccountId, AccountId | The NFT ID the spender is authorized to transfer. The sender is the owner account and receiver is the receiving account. Applicable to allowance transfers only. | +| `addApprovedTokenTransferWithDecimals(, , , )` | TokenId, AccountId, int64, uint32 | Adds an approved token transfer with decimal precision, specifying the owner account ID, token ID, and sender's account. Applicable to allowance transfers only. | +| `setHighVolume()` | boolean | Opt into [high-volume throttles](/hedera/core-concepts/high-volume-entity-creation) with variable-rate pricing. | + @@ -137,3 +146,10 @@ println!("The transaction consensus status: {:?}", transaction_status); ``` + + + This transaction supports [high-volume entity creation](/hedera/core-concepts/high-volume-entity-creation) + (HIP-1313). Setting `setHighVolume(true)` routes the transaction through dedicated + high-volume throttle capacity with variable-rate pricing. Always pair this with + `setMaxTransactionFee()` to cap your costs. + diff --git a/hedera/sdks-and-apis/sdks/token-service/associate-tokens-to-an-account.mdx b/hedera/sdks-and-apis/sdks/token-service/associate-tokens-to-an-account.mdx index 7d4387b7..43fc1718 100644 --- a/hedera/sdks-and-apis/sdks/token-service/associate-tokens-to-an-account.mdx +++ b/hedera/sdks-and-apis/sdks/token-service/associate-tokens-to-an-account.mdx @@ -3,7 +3,7 @@ title: "Associate tokens to an account" --- -Associates the provided Hedera account with the provided Hedera token(s). Hedera accounts must be associated with a fungible or non-fungible token first before you can transfer tokens to that account. When you transfer a custom fungible or non-fungible token to the alias account ID, the token association step is skipped and the account will automatically be associated with the token upon creation. In the case of NON\_FUNGIBLE Type, once an account is associated, it can hold any number of NFTs (serial numbers) of that token type. The Hedera account that is associated with a token is required to sign the transaction. +Associates the provided Hedera account with the provided Hedera token(s). Hedera accounts must be associated with a fungible or non-fungible token first before you can transfer tokens to that account. When you transfer a custom fungible or non-fungible token to the alias account ID, the token association step is skipped and the account will automatically be associated with the token upon creation. In the case of NON\_FUNGIBLE **Type**, once an account is associated, it can hold any number of NFTs (serial numbers) of that token type. The Hedera account that is associated with a token is required to sign the transaction. * If the provided account is not found, the transaction will resolve to `INVALID_ACCOUNT_ID`. * If the provided account has been deleted, the transaction will resolve to `ACCOUNT_DELETED`. @@ -27,12 +27,35 @@ There is currently no limit on the number of token IDs that can be associated wi * Please see the transaction and query [fees](/hedera/networks/mainnet/fees#transaction-and-query-fees) table for the base transaction fee * Please use the [Hedera fee estimator](https://hedera.com/fees) to estimate your transaction fee cost -## Methods +## Constructor -| Method | Type | Description | Requirement | -| --------------------------- | --------------- | ----------------------------------------------------- | ----------- | -| `setAccountId()` | AccountId | The account to be associated with the provided tokens | Required | -| `setTokenIds()` | List \ | The tokens to be associated with the provided account | Required | +| Constructor | Description | +|-------------|-------------| +| `new TokenAssociateTransaction()` | Initializes the TokenAssociateTransaction object | + +## Transaction Properties + +| Method | **Type** | Requirement | +|--------|------|-------------| +| `setAccountId()` | AccountId | Required | +| `setTokenIds()` | List<TokenId> | Required | +| `setHighVolume()` | boolean | Optional | + +## Get Transaction Values + +| Method | **Type** | Description | +|--------|------|-------------| +| `getAccountId()` | AccountId | Returns the account to be associated | +| `getTokenIds()` | List<TokenId> | Returns the list of tokens to be associated | +| `getHighVolume()` | boolean | Returns whether this transaction uses [high-volume throttles](/core-concepts/high-volume-entity-creation) | + + + + This transaction supports [high-volume entity creation](/hedera/core-concepts/high-volume-entity-creation) + (HIP-1313). Setting `setHighVolume(true)` routes the transaction through dedicated + high-volume throttle capacity with variable-rate pricing for both fungible and NFT mints. + Always pair this with `setMaxTransactionFee()` to cap your costs. + diff --git a/hedera/sdks-and-apis/sdks/token-service/claim-a-token.mdx b/hedera/sdks-and-apis/sdks/token-service/claim-a-token.mdx index 620087b7..31ce008a 100644 --- a/hedera/sdks-and-apis/sdks/token-service/claim-a-token.mdx +++ b/hedera/sdks-and-apis/sdks/token-service/claim-a-token.mdx @@ -20,8 +20,10 @@ The `TokenClaimAirdropTransaction` allows an intended airdrop recipient to claim * Please see the transaction and query [fees](/hedera/networks/mainnet/fees#transaction-and-query-fees) table for the base transaction fee. * Please use the [Hedera fee estimator](https://hedera.com/fees) to estimate the cost of your transaction fee. -
MethodTypeDescription
addPendingAirdropId(<pendingAirdropId)List<PendingAirdropId>Adds the ID of a pending airdrop to the transaction, indicating which specific airdrop the receiver wants to claim. This method is used to reference and claim one or more pending airdrops by their unique identifiers. The transaction can have up to 10 entries and must no have any duplicates.
- +| **Method** | **Type** | **Description** | +|---|---|---| +| `addPendingAirdropId()` | List\ | Adds the ID of a pending airdrop to the transaction, indicating which specific airdrop the receiver wants to claim. This method is used to reference and claim one or more pending airdrops by their unique identifiers. The transaction can have up to 10 entries and must not have any duplicates. | +| `setHighVolume()` | boolean | Opt into [high-volume throttles](/hedera/core-concepts/high-volume-entity-creation) with variable-rate pricing. | ```java Java wrap @@ -121,3 +123,10 @@ println!("The transaction consensus status: {:?}", transaction_status); **Reference:** [**Token Airdrop Example**](https://github.com/hashgraph/hedera-sdk-js/blob/main/examples/token-airdrop-example.js) + + + This transaction supports [high-volume entity creation](/hedera/core-concepts/high-volume-entity-creation) + (HIP-1313). Setting `setHighVolume(true)` routes the transaction through dedicated + high-volume throttle capacity with variable-rate pricing. Always pair this with + `setMaxTransactionFee()` to cap your costs. + \ No newline at end of file diff --git a/hedera/sdks-and-apis/sdks/token-service/define-a-token.mdx b/hedera/sdks-and-apis/sdks/token-service/define-a-token.mdx index 44531d41..5ebfcbcc 100644 --- a/hedera/sdks-and-apis/sdks/token-service/define-a-token.mdx +++ b/hedera/sdks-and-apis/sdks/token-service/define-a-token.mdx @@ -45,12 +45,69 @@ For non-fungible tokens, the token ID represents an NFT class. Once the token is * Please see the transaction and query [fees](/hedera/networks/mainnet/fees#transaction-and-query-fees) table for the base transaction fee * Please use the [Hedera fee estimator](https://hedera.com/fees) to estimate your transaction fee cost -## Methods - -
MethodTypeRequirement
setTokenName(<name>)StringRequired
setTokenType(<tokenType>)TokenTypeOptional
setTokenSymbol(<symbol>)StringRequired
setDecimals(<decimal>)intOptional
setInitialSupply(<initialSupply>)intOptional
setTreasuryAccountId(<treasury>)AccountIdRequired
setAdminKey(<key>)KeyOptional
setKycKey(<key>)KeyOptional
setFreezeKey(<key>)KeyOptional
setWipeKey(<key>)KeyOptional
setSupplyKey(<key>)KeyOptional
setPauseKey(<key>)KeyOptional
setFreezeDefault(<freeze>)booleanOptional
setExpirationTime(<expirationTime>)InstantOptional
setFeeScheduleKey(<key>)KeyOptional
setCustomFees(<customFees>)List<CustomFee>Optional
setSupplyType(<supplyType>)TokenSupplyTypeOptional
setMaxSupply(<maxSupply>)longOptional
setTokenMemo(<memo>)StringOptional
setAutoRenewAccountId(<account>)AccountIdOptional
setAutoRenewPeriod(<period>)DurationOptional
setMetadataKey(<key>)KeyOptional
setMetadata(<bytes>)bytesOptional
+## Constructor + +| **Constructor** | **Description** | +|-------------|-------------| +| `new TokenCreateTransaction()` | Initializes the TokenCreateTransaction object | + +## Transaction Properties + +| **Method** | ****Type**** | **Requirement** | +|--------|------|-------------| +| `setTokenName()` | String | Required | +| `setTokenSymbol()` | String | Required | +| `setDecimals()` | int | Optional | +| `setInitialSupply()` | long | Optional | +| `setTreasuryAccountId()` | AccountId | Required | +| `setAdminKey()` | Key | Optional | +| `setKycKey()` | Key | Optional | +| `setFreezeKey()` | Key | Optional | +| `setWipeKey()` | Key | Optional | +| `setSupplyKey()` | Key | Optional | +| `setPauseKey()` | Key | Optional | +| `setFeeScheduleKey()` | Key | Optional | +| `setMetadataKey()` | Key | Optional | +| `setFreezeDefault()` | boolean | Optional | +| `setExpirationTime()` | Instant | Optional | +| `setAutoRenewAccountId()` | AccountId | Optional | +| `setAutoRenewPeriod()` | Duration | Optional | +| `setTokenMemo()` | String | Optional | +| `setTokenType()` | TokenType | Optional | +| `setSupplyType()` | TokenSupplyType | Optional | +| `setMaxSupply()` | long | Optional | +| `setCustomFees()` | List<CustomFee> | Optional | +| `setMetadata()` | byte[] | Optional | +| `setHighVolume()` | boolean | Optional | + +## Get Transaction Values + +| **Method** | ****Type**** | **Description** | +|--------|------|-------------| +| `getTokenName()` | String | Returns the name of the token | +| `getTokenSymbol()` | String | Returns the symbol of the token | +| `getDecimals()` | int | Returns the number of decimals | +| `getInitialSupply()` | long | Returns the initial supply of tokens | +| `getTreasuryAccountId()` | AccountId | Returns the treasury account ID | +| `getAdminKey()` | Key | Returns the admin key | +| `getKycKey()` | Key | Returns the KYC key | +| `getFreezeKey()` | Key | Returns the freeze key | +| `getWipeKey()` | Key | Returns the wipe key | +| `getSupplyKey()` | Key | Returns the supply key | +| `getPauseKey()` | Key | Returns the pause key | +| `getFeeScheduleKey()` | Key | Returns the fee schedule key | +| `getMetadataKey()` | Key | Returns the metadata key | +| `getFreezeDefault()` | boolean | Returns the freeze default value | +| `getTokenType()` | TokenType | Returns the token type | +| `getSupplyType()` | TokenSupplyType | Returns the supply type | +| `getMaxSupply()` | long | Returns the max supply | +| `getHighVolume()` | boolean | Returns whether this transaction uses [high-volume throttles](/core-concepts/high-volume-entity-creation) | -**Note**: Where the Admin, Pause, Freeze, and Wipe keys are left blank, the Supply key will be required as a minimum. +This transaction supports [high-volume entity creation](/core-concepts/high-volume-entity-creation) +(HIP-1313). Setting `setHighVolume(true)` routes the transaction through dedicated +high-volume throttle capacity with variable-rate pricing. Always pair this with +`setMaxTransactionFee()` to cap your costs. @@ -58,14 +115,14 @@ For non-fungible tokens, the token ID represents an NFT class. Once the token is ```java Java //Create the transaction TokenCreateTransaction transaction = new TokenCreateTransaction() - .setTokenName("Your Token Name") - .setTokenSymbol("F") - .setTreasuryAccountId(treasuryAccountId) - .setInitialSupply(5000) - .setAdminKey(adminKey.getPublicKey()) - .setMetadataKey(metadataKey) - .setMetadata(metadata) - .setMaxTransactionFee(new Hbar(30)); //Change the default max transaction fee + .setTokenName("Your Token Name") + .setTokenSymbol("F") + .setTreasuryAccountId(treasuryAccountId) + .setInitialSupply(5000) + .setAdminKey(adminKey.getPublicKey()) + .setMetadataKey(metadataKey) + .setMetadata(metadata) + .setMaxTransactionFee(new Hbar(30)); //Change the default max transaction fee //Build the unsigned transaction, sign with admin private key of the token, sign with the token treasury private key, submit the transaction to a Hedera network TransactionResponse txResponse = transaction.freezeWith(client).sign(adminKey).sign(treasuryKey).execute(client); @@ -77,7 +134,6 @@ TransactionReceipt receipt = txResponse.getReceipt(client); TokenId tokenId = receipt.tokenId; System.out.println("The new token ID is " + tokenId); - //v2.0.1 ``` @@ -85,18 +141,18 @@ System.out.println("The new token ID is " + tokenId); ```javascript JavaScript //Create the transaction and freeze for manual signing const transaction = await new TokenCreateTransaction() - .setTokenName("Your Token Name") - .setTokenSymbol("F") - .setTreasuryAccountId(treasuryAccountId) - .setInitialSupply(5000) - .setAdminKey(adminPublicKey) - .setMetadataKey(metadataKey) - .setMetadata(metadata) - .setMaxTransactionFee(new Hbar(30)) //Change the default max transaction fee - .freezeWith(client); + .setTokenName("Your Token Name") + .setTokenSymbol("F") + .setTreasuryAccountId(treasuryAccountId) + .setInitialSupply(5000) + .setAdminKey(adminKey.publicKey) + .setMetadataKey(metadataKey) + .setMetadata(metadata) + .setMaxTransactionFee(new Hbar(30)) //Change the default max transaction fee + .freezeWith(client); //Sign the transaction with the token adminKey and the token treasury account private key -const signTx = await (await transaction.sign(adminKey)).sign(treasuryKey); +const signTx = await (await transaction.sign(adminKey)).sign(treasuryKey); //Sign the transaction with the client operator private key and submit to a Hedera network const txResponse = await signTx.execute(client); @@ -108,23 +164,23 @@ const receipt = await txResponse.getReceipt(client); const tokenId = receipt.tokenId; console.log("The new token ID is " + tokenId); - -//v2.0.5 +//v2.0.28 ``` + ```go Go //Create the transaction and freeze the unsigned transaction tokenCreateTransaction, err := hedera.NewTokenCreateTransaction(). - SetTokenName("Your Token Name"). - SetTokenSymbol("F"). - SetTreasuryAccountID(treasuryAccountId). - SetInitialSupply(1000). - SetAdminKey(adminKey). - SetMetadataKey(metadataKey). - SetMetadata(metadata) - SetMaxTransactionFee(hedera.NewHbar(30)). //Change the default max transaction fee - FreezeWith(client) + SetTokenName("Your Token Name"). + SetTokenSymbol("F"). + SetTreasuryAccountId(treasuryAccountId). + SetInitialSupply(5000). + SetAdminKey(adminKey.PublicKey()). + SetMetadataKey(metadataKey). + SetTokenMetadata(metadata). + SetMaxTransactionFee(hedera.HbarFrom(30, hedera.HbarUnits.Hbar)). + FreezeWith(client) if err != nil { panic(err) @@ -139,19 +195,21 @@ if err != nil { //Request the receipt of the transaction receipt, err := txResponse.GetReceipt(client) + if err != nil { panic(err) } //Get the token ID from the receipt -tokenId := *receipt.TokenID +tokenId := receipt.TokenID fmt.Printf("The new token ID is %v\n", tokenId) - //v2.1.0 ``` + + ```rust Rust // Create the transaction let transaction = TokenCreateTransaction::new() @@ -182,4 +240,4 @@ println!("The new token ID is {:?}", token_id); // v0.34.0 ``` - +
\ No newline at end of file diff --git a/hedera/sdks-and-apis/sdks/token-service/mint-a-token.mdx b/hedera/sdks-and-apis/sdks/token-service/mint-a-token.mdx index 92cfde34..63a23e61 100644 --- a/hedera/sdks-and-apis/sdks/token-service/mint-a-token.mdx +++ b/hedera/sdks-and-apis/sdks/token-service/mint-a-token.mdx @@ -5,7 +5,7 @@ title: "Mint a token" Minting fungible token allows you to increase the total supply of the token. Minting a non-fungible token creates an NFT with its unique metadata for the class of NFTs defined by the token ID. The Supply Key must sign the transaction. -* If no Supply Key is defined, the transaction will resolve to TOKEN\_HAS\_NO\_SUPPLY\_KEY. The maximum total supply a token can have is 2^63-1. +* If no Supply Key is defined, the transaction will resolve to `TOKEN\_HAS\_NO\_SUPPLY\_KEY`. The maximum total supply a token can have is `2^63-1`. * The amount provided must be in the lowest denomination possible. * Example: Token A has 2 decimals. In order to mint 100 tokens, one must provide an amount of 10000. In order to mint 100.55 tokens, one must provide an amount of 10055. * The metadata field is specific to NFTs. Once an NFT is minted, the metadata cannot be changed and is immutable. @@ -24,9 +24,38 @@ Minting fungible token allows you to increase the total supply of the token. Min * Please see the transaction and query [fees](/hedera/networks/mainnet/fees#transaction-and-query-fees) table for the base transaction fee. * Please use the [Hedera fee estimator](https://hedera.com/fees) to estimate your transaction fee cost. -### Methods +## Constructor -
MethodTypeDescriptionRequirement
setTokenId(<tokenId>)TokenIdThe token ID for which to mint additional tokensRequired
setAmount(<amount>)longApplicable to tokens of type FUNGIBLE_COMMON.The amount to mint to the Treasury Account. The amount must be a positive non-zero number represented in the lowest denomination of the token. The new supply must be lower than 2^63-1.Optional
setMetadata(<metaDatas>)List<byte[]>Applicable to tokens of type NON_FUNGIBLE_UNIQUE. A list of metadata that are being created. The maximum allowed size of each metadata is 100 bytes and is immutable.Optional
addMetadata(<metaData>)byte []Applicable to tokens of type NON_FUNGIBLE_UNIQUE. A list of metadata that are being created. The maximum allowed size of each metadata is 100 bytes and is immutable.Optional
+| Constructor | Description | +|-------------|-------------| +| `new TokenMintTransaction()` | Initializes the TokenMintTransaction object | + +## Transaction Properties + +| **Method** | **Type** | **Requirement** | +|--------|------|-------------| +| `setTokenId()` | TokenId | Required | +| `setAmount()` | long | Optional (fungible) | +| `addMetadata()` | byte[] | Optional (NFT) | +| `setMetadata()` | List<byte[]> | Optional (NFT) | +| `setHighVolume()` | boolean | Optional | + +## Get Transaction Values + +| **Method** | **Type** | **Description** | +|--------|------|-------------| +| `getTokenId()` | TokenId | Returns the token ID | +| `getAmount()` | long | Returns the amount to mint (fungible) | +| `getMetadata()` | List<byte[]> | Returns the metadata list (NFT) | +| `getHighVolume()` | boolean | Returns whether this transaction uses [high-volume throttles](/hedera/core-concepts/high-volume-entity-creation) | + + + + This transaction supports [high-volume entity creation](/hedera/core-concepts/high-volume-entity-creation) + (HIP-1313). Setting `setHighVolume(true)` routes the transaction through dedicated + high-volume throttle capacity with variable-rate pricing for both fungible and NFT mints. + Always pair this with `setMaxTransactionFee()` to cap your costs. + diff --git a/hedera/sdks-and-apis/sdks/transactions/modify-transaction-fields.mdx b/hedera/sdks-and-apis/sdks/transactions/modify-transaction-fields.mdx index 97684df7..30449d03 100644 --- a/hedera/sdks-and-apis/sdks/transactions/modify-transaction-fields.mdx +++ b/hedera/sdks-and-apis/sdks/transactions/modify-transaction-fields.mdx @@ -2,26 +2,37 @@ title: "Modify transaction fields" --- - When submitting a transaction to the Hedera network, various fields can be modified, such as the transaction ID, consensus time, memo field, account ID of the node, and the maximum fee. These values can be set using methods provided by the SDKs. However, they are not required as the SDK can automatically create or use default values. - -***Note:** The total size for a given transaction is limited to 6KiB.* - + +The total size for a given transaction is limited to 6KiB. + + -| **Fields** | **Description** | -| ----------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| **Transaction ID** |

Set the ID for this transaction. The transaction ID includes the operator's account ( the account paying the transaction fee). If two transactions have the same transaction ID, they won't both have an effect. One will complete normally and the other will fail with a duplicate transaction status.


Normally, you should not use this method. Just before a transaction is executed, a
transaction ID will be generated from the operator on the client.

| -| **Valid Duration** |

Set the duration that this transaction is valid for

Note: Max network valid duration is 180 seconds. SDK default value is 120 seconds. The minium valid duration period is 15 seconds.

| -| **Memo** | Set a note or description that should be recorded in the transaction record (maximum length of 100 characters). Anyone can view this memo on the network | -| **Node ID** | Set the account ID of the node that this transaction will be submitted to. | -| **Max transaction fee** |

Set the max transaction fee for the operator (transaction fee payer account) is willing to pay

Default: 2 hbar

| +| **Field** | **Description** | +|-------|-------------| +| **Transaction ID** | Set the ID for this transaction. The transaction ID includes the operator's account (the account paying the transaction fee). If two transactions have the same transaction ID, they won't both have an effect. One will complete normally and the other will fail with a duplicate transaction status. Normally, you should not use this method. Just before a transaction is executed, a transaction ID will be generated from the operator on the client. | +| **Valid Duration** | Set the duration that this transaction is valid for. Max network valid duration is 180 seconds. SDK default value is 120 seconds. The minimum valid duration period is 15 seconds. | +| **Memo** | Set a note or description that should be recorded in the transaction record (maximum length of 100 characters). Anyone can view this memo on the network. | +| **Node ID** | Set the account ID of the node that this transaction will be submitted to. | +| **Max transaction fee** | Set the max transaction fee the operator (transaction fee payer account) is willing to pay. Default: 2 hbar. | +| **High Volume** | If set to `true`, opts this transaction into the [high-volume throttle system](/hedera/core-concepts/high-volume-entity-creation) with variable-rate pricing for entity creation. Only affects [supported transaction types](/hedera/core-concepts/high-volume-entity-creation#supported-transaction-types); otherwise ignored. Default: `false`. See [HIP-1313](https://hips.hedera.com/hip/hip-1313). | - -***Note:** The SDKs do not require you to set these fields when submitting a transaction to a Hedera network. All methods below are optional and can be used to modify any fields.* - + +The SDKs do not require you to set these fields when submitting a transaction to a Hedera network. All methods below are optional and can be used to modify any fields. + -
MethodType
setTransactionID(<transactionId>)TransactionID
setTransactionValidDuration(<validDuration>)Duration
setTransactionMemo(<memo>)String
setNodeAccountIds(<nodeAccountIds>)List<AccountId>
setMaxTransactionFee(<maxTransactionFee>)Hbar
setGrpcDeadline(<grpcDeadline>)Duration
setRegenerateTransactionId(<regenerateTransactionId>)boolean
+ +| **Method** | **Type** | +|--------|------| +| `setTransactionID()` | TransactionID | +| `setTransactionValidDuration()` | Duration | +| `setTransactionMemo()` | String | +| `setNodeAccountIds()` | List\ | +| `setMaxTransactionFee()` | Hbar | +| `setGrpcDeadline()` | Duration | +| `setRegenerateTransactionId()` | boolean | +| `setHighVolume()` | boolean | **Account Alias** @@ -88,7 +99,16 @@ let transaction = AccountCreateTransaction::new() // Any transaction can be appl ## Get transaction properties -
MethodType
getTransactionID()TransactionID
getTransactionValidDuration()Duration
getTransactionMemo()String
getNodeAccountId()AccountID
getMaxTransactionFee()Hbar
getTransactionHash()byte[ ]
getTransactionHashPerNode()Map<AccountId, byte [ ]>
getSignatures()Map<AccountId, Map<PublicKey, byte [ ]>>
+| **Method** | **Type** | +|---|---| +| `getTransactionID()` | TransactionID | +| `getTransactionValidDuration()` | Duration | +| `getTransactionMemo()` | String | +| `getNodeAccountId()` | AccountID | +| `getMaxTransactionFee()` | Hbar | +| `getTransactionHash()` | byte[ ] | +| `getTransactionHashPerNode()` | Map\ | +| `getSignatures()` | Map\> | @@ -146,4 +166,4 @@ let max_transaction_fee = transaction.max_transaction_fee(); // v0.34.0 ``` - +
\ No newline at end of file From 7e788e5615bb793aa26eca1f08333074d9d330cd Mon Sep 17 00:00:00 2001 From: krystal <56278409+theekrystallee@users.noreply.github.com> Date: Wed, 4 Mar 2026 21:19:22 -0800 Subject: [PATCH 2/3] updates from PR review Signed-off-by: krystal <56278409+theekrystallee@users.noreply.github.com> --- hedera/faqs/network-governance.mdx | 2 +- .../sdks/consensus-service/create-a-topic.mdx | 11 ++++++++++- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/hedera/faqs/network-governance.mdx b/hedera/faqs/network-governance.mdx index aac9167c..dffe3d9f 100644 --- a/hedera/faqs/network-governance.mdx +++ b/hedera/faqs/network-governance.mdx @@ -276,7 +276,7 @@ title: "Network Governance"
- Yes. [High-volume entity creation](/hedera/core-concepts/high-volume-entity-creation) transactions + In some cases. [High-volume entity creation](/hedera/core-concepts/high-volume-entity-creation) transactions (introduced in [HIP-1313](https://hips.hedera.com/hip/hip-1313)) use a variable-rate pricing model where fees change dynamically based on utilization of the dedicated high-volume throttle capacity. The pricing curve parameters — including the breakpoints diff --git a/hedera/sdks-and-apis/sdks/consensus-service/create-a-topic.mdx b/hedera/sdks-and-apis/sdks/consensus-service/create-a-topic.mdx index 65a81dbe..017e292e 100644 --- a/hedera/sdks-and-apis/sdks/consensus-service/create-a-topic.mdx +++ b/hedera/sdks-and-apis/sdks/consensus-service/create-a-topic.mdx @@ -161,7 +161,16 @@ println!("The new topic ID is {:?}", topic_id); ## Get transaction values -
**Method****Type****Requirements**
getAdminKey(<adminKey>)KeyOptional
getSubmitKey(<submitKey>)KeyOptional
getTopicMemo(<memo>)StringOptional
getAutoRenewAccountId()AccountIdRequired
getAutoRenewPeriod()DurationRequired
getFeeScheduleKey()KeyOptional
getFeeExemptKeys()ListOptional
getCustomFees()ListOptional
+| **Method** | **Type** | **Requirements** | +|------------|----------|------------------| +| `getAdminKey(adminKey)` | Key | Optional | +| `getSubmitKey(submitKey)` | Key | Optional | +| `getTopicMemo(memo)` | String | Optional | +| `getAutoRenewAccountId()` | AccountId | Required | +| `getAutoRenewPeriod()` | Duration | Required | +| `getFeeScheduleKey()` | Key | Optional | +| `getFeeExemptKeys()` | List | Optional | +| `getCustomFees()` | List | Optional | From 251d676f9443eaf16085f0047378cef4a679e48b Mon Sep 17 00:00:00 2001 From: krystal <56278409+theekrystallee@users.noreply.github.com> Date: Fri, 6 Mar 2026 07:25:39 -0800 Subject: [PATCH 3/3] updates from PR review Signed-off-by: krystal <56278409+theekrystallee@users.noreply.github.com> --- .../high-volume-entity-creation.mdx | 124 +++++++++++------- 1 file changed, 75 insertions(+), 49 deletions(-) diff --git a/hedera/core-concepts/high-volume-entity-creation.mdx b/hedera/core-concepts/high-volume-entity-creation.mdx index 9b93a218..d977c4de 100644 --- a/hedera/core-concepts/high-volume-entity-creation.mdx +++ b/hedera/core-concepts/high-volume-entity-creation.mdx @@ -15,8 +15,8 @@ supported transaction, you opt into dedicated capacity with higher throughput li tradeoff: **fees are variable and increase with utilization.** -The standard throttle system is completely unaffected. Existing applications that do not -set the `high_volume` flag will work exactly as before — same capacity, same pricing. + The standard throttle system is completely unaffected. Existing applications that do not + set the `high_volume` flag will work exactly as before — same capacity, same pricing. --- @@ -81,28 +81,43 @@ cost more than the same transaction sent through the standard throttle — even there is no congestion. Always check the current multiplier before committing to a batch. -### Pricing Curve Example +### Pricing Curve + +The base curve below is set by Hedera governance and defines how the fee +multiplier scales with throughput in the high-volume lane. The multiplier is +expressed relative to the standard base fee, and the throughput rate is +expressed as a multiplier of the base entity creation rate. + +| **High-Volume Throughput (× base create rate)** | **Fee Multiplier (× base price)** | +|---|---| +| 1 | 4× | +| 1.5 | 8× | +| 2.5 | 10× | +| 3.5 | 15× | +| 5 | 20× | +| 7.5 | 30× | +| 10 | 40× | +| 25 | 60× | +| 50 | 80× | +| 100 | 100× | +| 250 | 150× | +| 500 | 200× | +| 5,000 | 200× | + +Between breakpoints, the multiplier is linearly interpolated. The curve +assumes the standard (low-throughput) lane is running at its maximum rate +concurrently. -The actual curve values are set by network governance and may change. The HIP provides -this example of a piecewise linear curve with three breakpoints: - -| Utilization | Multiplier | Effect on a $0.05 Base Fee | -|---|---|---| -| 0% | 1.0× | $0.05 | -| 50% | 2.0× | $0.10 | -| 100% | 5.0× | $0.25 | - -Between breakpoints, the multiplier is linearly interpolated. For example, at 75% -utilization, the multiplier would be 3.5× (halfway between 2.0× and 5.0×). If no -pricing curve is explicitly configured, the multiplier defaults to linear interpolation -between 1.0× and `max_multiplier`. + + At the base create rate (1×), high-volume transactions already cost **4× the + standard fee**. At 100× throughput, the multiplier reaches **100×**. The curve + caps at **200×** regardless of how much higher throughput goes. Always set + `maxTransactionFee` to protect against unexpected costs. + -These values are from the HIP specification as an example. Actual pricing curve -breakpoints will be configured by Hedera governance before launch. The `max_multiplier` -value (also governance-configured) caps how high the multiplier can go regardless of -the curve. Use the Mirror Node fee estimation endpoint to see the **current** multiplier -in effect. + This curve may be updated by Hedera governance. Use the Mirror Node fee + estimation endpoint to see the **current** multiplier in effect. --- @@ -113,8 +128,8 @@ The `high_volume` flag is supported on the following entity creation transaction -| Transaction Type | SDK Class | Notes | -|---|---|---| +| **Transaction Type** | **SDK Class** | **Notes** | +|----|---|---| | `ConsensusCreateTopic` | `TopicCreateTransaction` | | | `ContractCreate` | `ContractCreateTransaction` | HAPI only, not EVM | | `CryptoApproveAllowance` | `AccountAllowanceApproveTransaction` | | @@ -132,13 +147,17 @@ The `high_volume` flag is supported on the following entity creation transaction -Setting `high_volume = true` on any other transaction type has no effect — the flag -is silently ignored and the transaction processes through the standard system. +The official Hedera SDKs expose `setHighVolume()` only on the transaction types +listed above. If you are using a custom SDK or constructing protobuf transactions +directly and set `high_volume = true` on a transaction type not in this list, the +transaction **will not fail**. The flag is silently ignored and the transaction +processes through the standard throttle system at standard pricing. -**EVM transactions are excluded.** Contract creations via `CREATE` / `CREATE2` opcodes -in the EVM do not participate in the high-volume system. A subsequent HIP will address -EVM-specific high-volume behavior. + #### **EVM transactions are excluded** + Contract creations via `CREATE` / `CREATE2` opcodes + in the EVM do not participate in the high-volume system. A subsequent HIP will address + EVM-specific high-volume behavior. --- @@ -154,8 +173,8 @@ following example configuration (actual mainnet values will be set by governance | HighVolumeTotalThrottles | All 14 supported types combined | 31,500 ops/sec | -These values are from the HIP's example throttle configuration. Final mainnet and -testnet capacity values will be set by Hedera governance and may differ. + These values are from the HIP's example throttle configuration. Final mainnet and + testnet capacity values will be set by Hedera governance and may differ. A transaction must pass **both** its per-type bucket and the total bucket to be accepted. @@ -175,7 +194,7 @@ Before submitting high-volume transactions, query the Mirror Node fee estimation to see the current `high_volume_multiplier`. The HIP specifies that this field will be added to the existing fee estimation response: -```bash +```bash wrap curl "https://mainnet.mirrornode.hedera.com/api/v1/network/fees" ``` @@ -186,17 +205,15 @@ The fee totals in the response are **not** pre-multiplied — multiply the fee t ### Step 2: Set the Flag and a Fee Cap - + - - -```java +```java Java wrap // Create an account using high-volume throttles AccountCreateTransaction tx = new AccountCreateTransaction() .setKey(publicKey) .setInitialBalance(Hbar.from(10)) - .setHighVolume(true) // Opt into high-volume throttles - .setMaxTransactionFee(Hbar.from(5)); // ALWAYS set a fee cap + .setHighVolume(true) // Opt into high-volume throttles + .setMaxTransactionFee(Hbar.from(5)); // ALWAYS set a fee cap TransactionResponse response = tx.execute(client); TransactionReceipt receipt = response.getReceipt(client); @@ -205,11 +222,8 @@ AccountId newAccountId = receipt.accountId; System.out.println("Account created: " + newAccountId); ``` - - - -```javascript +```javascript JavaScript wrap // Create an account using high-volume throttles const tx = new AccountCreateTransaction() .setKey(publicKey) @@ -224,11 +238,7 @@ const newAccountId = receipt.accountId; console.log("Account created: " + newAccountId); ``` - - - - -```go +```go Go wrap // Create an account using high-volume throttles tx := hedera.NewAccountCreateTransaction(). SetKey(publicKey). @@ -249,9 +259,25 @@ if err != nil { fmt.Printf("Account created: %v\n", receipt.AccountID) ``` - +```rust Rust wrap +// Create an account using high-volume throttle +let tx = AccountCreateTransaction::new() + .key(public_key) + .initial_balance(Hbar::new(10)) + .high_volume(true) // Opt into high-volume throttles + .max_transaction_fee(Hbar::new(5)) // ALWAYS set a fee cap + .freeze_with(&client)?; + +let response = tx.execute(&client).await?; +let receipt = response.get_receipt(&client).await?; +let new_account_id = receipt.account_id.unwrap(); + +println!("Account created: {:?}", new_account_id); + +``` + + - ### Step 3: Handle Fee Failures Gracefully @@ -296,7 +322,7 @@ may follow patterns. Off-peak hours may offer lower multipliers. After a high-volume transaction reaches consensus, you can confirm its status via the Mirror Node REST API: -```bash +```bash wrap curl "https://mainnet.mirrornode.hedera.com/api/v1/transactions/{transactionId}" ```