A transaction that appends new file content to the end of an existing file. The contents of the file can be viewed by submitting a FileContentsQuery request. Transaction Signing RequirementsDocumentation Index
Fetch the complete documentation index at: https://hedera-0c6e0218-mintlify-enhance-hollow-account-docs-97196.mintlify.app/llms.txt
Use this file to discover all available pages before exploring further.
- The key on the file is required to sign the transaction if different than the client operator account key
- Please see the transaction and query fees table for base transaction fee
- Please use the Hedera fee estimator to estimate your transaction fee cost
| Constructor | Description |
|---|---|
FileAppendTransaction() | Initializes the FileAppendTransaction object |
The default max transaction fee (1 hbar) is not enough to create a file. Use
setMaxTransactionFee()to change the default max transaction fee from 1 hbar to 2 hbars. The default chunk size is 2,048 bytes.Methods
| Method | Type | Description | Requirement |
|---|---|---|---|
setFileId(<fileId>) | FileId | The ID of the file to append | Required |
setContents(<text>) | String | The content in String format | Optional |
setContents(<content>) | byte [ ] | The content in byte format | Optional |
setChunkSize(<chunkSize>) | int | The chunk size | Optional |
setMaxChunkSize(<maxChunks>) | int | The max chunk size | Optional |
Get transaction values
| Method | Type | Description | Requirement |
|---|---|---|---|
getFileId() | FileId | The file ID in the transaction | Optional |
getContents() | String | The content in the transaction | Optional |