async createNewTopic({ memo, enable_private_submit_key }) {
		const client = this.#client
		const transactionResponse = {}
		const operatorPrivateKey = PrivateKey.fromString(Config.privateKey)
		const transaction = new TopicCreateTransaction()

		transaction
			.setAdminKey(operatorPrivateKey.publicKey)
			.setMaxTransactionFee(new Hbar(100, HbarUnit.Hbar))

		if (memo) {
			transactionResponse.memo = memo
			transaction.setTopicMemo(memo)
		}

		if (enable_private_submit_key) {
			transaction.setSubmitKey(operatorPrivateKey.publicKey)
		}

		const transactionId = await transaction.execute(client)
		const receipt = await transactionId.getReceipt(client)

		await sleep(3000)

		return {
			...transactionResponse,
			topic: receipt.topicId.toString()
		}
	}
/**
	 * Skipping the admin signing of the transaction as this API is accessed through an authKey
	 **/
Skipping the admin signing of the transaction as this API is accessed through an authKey
Skipping the admin signing of the transaction as this API is accessed through an authKey
async createNewTopic({ memo, enable_private_submit_key }) {
		const client = this.#client
		const transactionResponse = {}
		const operatorPrivateKey = PrivateKey.fromString(Config.privateKey)
		const transaction = new TopicCreateTransaction()
		transaction
			.setAdminKey(operatorPrivateKey.publicKey)
			.setMaxTransactionFee(new Hbar(100, HbarUnit.Hbar))
		if (memo) {
			transactionResponse.memo = memo
			transaction.setTopicMemo(memo)
		}
		if (enable_private_submit_key) {
			transaction.setSubmitKey(operatorPrivateKey.publicKey)
		}
		const transactionId = await transaction.execute(client)
		const receipt = await transactionId.getReceipt(client)
		await sleep(3000)
		return {
			...transactionResponse,
			topic: receipt.topicId.toString()
		}
	}
async createNewTopic ( { memo , enable_private_submit_key } ) { const client = this . #client const transactionResponse = { } const operatorPrivateKey = PrivateKey . fromString ( Config . privateKey ) const transaction = new TopicCreateTransaction ( ) transaction . setAdminKey ( operatorPrivateKey . publicKey ) . setMaxTransactionFee ( new Hbar ( 100 , HbarUnit . Hbar ) ) if ( memo ) { transactionResponse . memo = memo transaction . setTopicMemo ( memo ) } if ( enable_private_submit_key ) { transaction . setSubmitKey ( operatorPrivateKey . publicKey ) } const transactionId = await transaction . execute ( client ) const receipt = await transactionId . getReceipt ( client ) await sleep ( 3000 ) return { ... transactionResponse , topic : receipt . topicId . toString ( ) } }
Skipping the admin signing of the transaction as this API is accessed through an authKey
Skipping the admin signing of the transaction as this API is accessed through an authKey