Update a topic
Topic Properties
Field
Description
Constructor
Description
new ConsensusTopicUpdateTransaction()Method
Type
Requirements
//Create a transaction to add a submit key
ConsensusTopicUpdateTransaction transaction = new ConsensusTopicUpdateTransaction()
.setSubmitKey(submitKey);
//Sign the transaction with the admin key to authorize the update
ConsensusTopicUpdateTransaction signTx = transaction.build(client).sign(adminKey);
//Sign the transaction with the client operator, submit to a Hedera network, get the transaction ID
TransactionId txId = signTx.execute(client);
//Request the receipt of the transaction
TransactionReceipt receipt = txId.getReceipt(client);
//Get the transaction consensus status
Status transactionStatus = receipt.status;
System.out.println("The transaction consensus status is " +transactionStatus);
//v1.3.2Get transaction values
Method
Type
Requirements
Last updated