Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ export type Tool = {
};
```

See [typescript/src/shared/tools.ts](../typescript/src/shared/tools.ts) for the full definition.
See [packages/core/src/shared/tools.ts](https://github.com/hashgraph/hedera-agent-kit-js/blob/main/packages/core/src/shared/tools.ts) for the full definition.

#### BaseTool (Recommended for v4)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ title: "Create an account"

## 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/) 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.
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](/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.

<Info>
When creating a **new account** using the `AccountCreateTransaction()` API you will need an existing account to pay for the associated transaction fee.
Expand All @@ -15,7 +15,7 @@ When creating a **new account** using the `AccountCreateTransaction()` API you w
## Transaction Fees and Signing

- 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.
- See the transaction and query [fees](/hedera/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.

Expand All @@ -38,11 +38,6 @@ Accounts have a property, `maxAutoAssociations`, and the property's value determ
| `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](../../../core-concepts/accounts/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. |
| `> 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. |
| 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. |

<Info>
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.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,8 @@ With [HIP-904](https://hips.hedera.com/hip/hip-904), contracts now support Admin
| **Automatic Token Associations** | The maximum number of tokens that this contract can be automatically associated with (i.e., receive air-drops from). |
| **Constructor Parameters** | The constructor parameters to pass. |
| **Memo** | The memo to be associated with this contract. (max 100 bytes) |
| **Hooks** | Details of [Hiero Hooks](/hedera/core-concepts/accounts/hiero-hooks) to attach immediately after creating this contract. See [Create and Manage Hooks](/hedera/sdks-and-apis/sdks/accounts-and-hbar/create-and-manage-hooks). |
| **Hooks** | Details of [Hiero Hooks](/hedera/core-concepts/accounts/hiero-hooks) to attach immediately after creating this contract. |
Comment thread
theekrystallee marked this conversation as resolved.
{/* TODO: Restore link to "Create and Manage Hooks" SDK page once that page is published — see https://hips.hedera.com/hip/hip-1195 */}

## `ContractCreateFlow()`

Expand Down Expand Up @@ -198,8 +199,9 @@ Creates a smart contract instance using the file ID of the contract bytecode.
| `setAutoRenewAccountId(<accountId)` | AccountId | Optional |
| `setAutoRenewPeriod(<autoRenewPeriod>)` | Duration | Optional |
| `setMaxAutomaticTokenAssociations()` | int | Optional |
| `addHook(<hook>)` | [HookCreationDetails](/hedera/sdks-and-apis/sdks/accounts-and-hbar/create-and-manage-hooks) | Optional |
| `setHooks(<hooks>)` | list\<[HookCreationDetails](/hedera/sdks-and-apis/sdks/accounts-and-hbar/create-and-manage-hooks)> | Optional |
| `addHook(<hook>)` | HookCreationDetails | Optional |
Comment thread
theekrystallee marked this conversation as resolved.
| `setHooks(<hooks>)` | list\<HookCreationDetails> | Optional |
Comment thread
theekrystallee marked this conversation as resolved.
{/* TODO: Restore links to "Create and Manage Hooks" SDK page (HookCreationDetails) once that page is published. */}

<CodeGroup>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,8 @@ A transaction that allows you to modify the smart contract entity state like adm
| **Auto Renew Account ID** | Indicates the account that will pay the contract's auto-renew fee. If the Auto Renew account id is cleared, then the smart contract's account will be charged the auto-renew fee. |
| **Automatic Token Associations** | The maximum number of tokens that this contract can be automatically associated with (i.e., receive air-drops from). |
| **Memo** | The new memo to be associated with this contract. |
| **Hooks** | Add or remove [Hiero Hooks](/hedera/core-concepts/accounts/hiero-hooks) from the contract. Deletions are processed before creations, enabling atomic hook replacement. See [Create and Manage Hooks](/hedera/sdks-and-apis/sdks/accounts-and-hbar/create-and-manage-hooks). |
| **Hooks** | Add or remove [Hiero Hooks](/hedera/core-concepts/accounts/hiero-hooks) from the contract. Deletions are processed before creations, enabling atomic hook replacement. |
Comment thread
theekrystallee marked this conversation as resolved.
{/* TODO: Restore link to "Create and Manage Hooks" SDK page once that page is published — see https://hips.hedera.com/hip/hip-1195 */}

### Methods

Expand All @@ -45,10 +46,11 @@ A transaction that allows you to modify the smart contract entity state like adm
| `setAutoRenewPeriod(<autoRenewPeriod>)` | Duration | Optional |
| `setAutoRenewAccountId(<accountId>)` | [AccountId](/hedera/sdks-and-apis/sdks/specialized-types#accountid) | Optional |
| `clearAutoRenewAccountId()` | | Optional |
| `addHookToCreate(<hook>)` | [HookCreationDetails](/hedera/sdks-and-apis/sdks/accounts-and-hbar/create-and-manage-hooks) | Optional |
| `setHooksToCreate(<hooks>)` | list\<[HookCreationDetails](/hedera/sdks-and-apis/sdks/accounts-and-hbar/create-and-manage-hooks)> | Optional |
| `addHookToCreate(<hook>)` | HookCreationDetails | Optional |
| `setHooksToCreate(<hooks>)` | list\<HookCreationDetails> | Optional |
| `addHookToDelete(<hookId>)` | long | Optional |
| `setHooksToDelete(<hookIds>)` | list\<long> | Optional |
{/* TODO: Restore links to "Create and Manage Hooks" SDK page (HookCreationDetails) once that page is published. */}

<Info>
***Note:** The new expiration time must be an instance of type **`Timestamp`**, thus, the **`Timestamp`** object has to be imported from the SDK package. The new expiration time has to be initialized as a new instance of that type.*
Expand Down Expand Up @@ -225,7 +227,8 @@ fmt.Printf("Hook added to contract: %v\n", receipt.Status)

#### Delete hooks from an existing contract

This example removes a hook by its ID. A hook must have zero storage slots before it can be deleted — clear storage first using [`HookStoreTransaction`](/hedera/sdks-and-apis/sdks/accounts-and-hbar/create-a-hookstore-transaction).
{/* TODO: Restore link to "Create a HookStore Transaction" SDK page once that page is published. */}
This example removes a hook by its ID. A hook must have zero storage slots before it can be deleted — clear storage first using `HookStoreTransaction`.

<CodeGroup>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ There is currently no limit on the number of token IDs that can be associated wi
|--------|------|-------------|
| `getAccountId()` | AccountId | Returns the account to be associated |
| `getTokenIds()` | List&lt;TokenId&gt; | Returns the list of tokens to be associated |
| `getHighVolume()` | boolean | Returns whether this transaction uses [high-volume throttles](/core-concepts/high-volume-entity-creation) |
| `getHighVolume()` | boolean | Returns whether this transaction uses [high-volume throttles](/hedera/core-concepts/high-volume-entity-creation) |


<Note>
Expand Down
4 changes: 2 additions & 2 deletions hedera/sdks-and-apis/sdks/token-service/define-a-token.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -101,10 +101,10 @@ For non-fungible tokens, the token ID represents an NFT class. Once the token is
| `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) |
| `getHighVolume()` | boolean | Returns whether this transaction uses [high-volume throttles](/hedera/core-concepts/high-volume-entity-creation) |

<Info>
This transaction supports [high-volume entity creation](/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.
Expand Down
Loading