Table of Contents

Class ArkDelegateContract

Namespace
NArk.Core.Contracts
Assembly
NArk.Core.dll
public class ArkDelegateContract : ArkContract
Inheritance
ArkDelegateContract
Inherited Members

Constructors

ArkDelegateContract(OutputDescriptor, Sequence, OutputDescriptor, OutputDescriptor, LockTime?)

public ArkDelegateContract(OutputDescriptor server, Sequence exitDelay, OutputDescriptor user, OutputDescriptor @delegate, LockTime? cltvLocktime = null)

Parameters

server OutputDescriptor
exitDelay Sequence
user OutputDescriptor
delegate OutputDescriptor
cltvLocktime LockTime?

Fields

ContractType

public const string ContractType = "Delegate"

Field Value

string

Properties

CltvLocktime

public LockTime? CltvLocktime { get; }

Property Value

LockTime?

DefaultScope

Delegate funds live off-chain as a VTXO.

public override ContractScope DefaultScope { get; }

Property Value

ContractScope

Delegate

public OutputDescriptor Delegate { get; }

Property Value

OutputDescriptor

Type

Contract type discriminator string (e.g. "vtxo", "boarding").

public override string Type { get; }

Property Value

string

User

public OutputDescriptor User { get; }

Property Value

OutputDescriptor

Methods

CollaborativePath()

Collaborative path: user + server (2-of-2).

public ScriptBuilder CollaborativePath()

Returns

ScriptBuilder

DelegatePath()

Delegate path: user + delegate + server (3-of-3). When CltvLocktime is set, the path is gated by an absolute timelock that prevents the delegate from acting before a certain block height — giving the owner a safety window to collaboratively spend via the forfeit path. When null, the delegate can act immediately (plain multisig).

public ScriptBuilder DelegatePath()

Returns

ScriptBuilder

ExitPath()

Unilateral exit path: user only, after CSV delay.

public ScriptBuilder ExitPath()

Returns

ScriptBuilder

GetContractData()

Returns the key-value map of contract parameters used for serialization.

protected override Dictionary<string, string> GetContractData()

Returns

Dictionary<string, string>

GetScriptBuilders()

Leaf ordering follows canonical Arkade SDK convention: [forfeit, exit, delegate].

protected override IEnumerable<ScriptBuilder> GetScriptBuilders()

Returns

IEnumerable<ScriptBuilder>

Parse(Dictionary<string, string>, Network)

public static ArkContract Parse(Dictionary<string, string> contractData, Network network)

Parameters

contractData Dictionary<string, string>
network Network

Returns

ArkContract