Class DeleteContractParams
Represents the parameters required to delete a contract from the hedera network.
Inherited Members
Namespace: Hiero
Assembly: Hiero.dll
Syntax
public sealed class DeleteContractParams : TransactionParams<TransactionReceipt>
Examples
Delete a contract, sending its remaining HBAR balance to another account. Requires the contract's Administrator key:
// Delete a contract and sweep its remaining HBAR balance to the
// specified recipient. Requires the contract's Administrator key.
var receipt = await client.DeleteContractAsync(new DeleteContractParams
{
Contract = contract,
FundsReceiver = fundsReceiver
});
Console.WriteLine($"Delete status: {receipt.Status}");
Properties
| Edit this page View SourceCancellationToken
Optional Cancellation token that can interrupt the contract deletion.
Declaration
public CancellationToken? CancellationToken { get; set; }
Property Value
| Type | Description |
|---|---|
| CancellationToken? |
Contract
The address of the contract to delete.
Declaration
public EntityId Contract { get; set; }
Property Value
| Type | Description |
|---|---|
| EntityId |
FundsReceiver
The address of the account that will receive any remaining crypto funds held by the contract.
Declaration
public EntityId FundsReceiver { get; set; }
Property Value
| Type | Description |
|---|---|
| EntityId |
Signatory
Additional private key, keys or signing callback method required to delete this contract.
Declaration
public Signatory? Signatory { get; set; }
Property Value
| Type | Description |
|---|---|
| Signatory |
Remarks
Keys/callbacks added here will be combined with those already identified in the client object's context when signing this transaction.