Table of Contents

Interface IDelegatorProvider

Namespace
NArk.Abstractions.Services
Assembly
NArk.Abstractions.dll

Provides communication with a delegator service (e.g. Fulmine) for automatic VTXO rollover. The client creates a partially signed intent and forfeit transactions, then sends them to the delegator which registers the intent and participates in batches on the owner's behalf.

public interface IDelegatorProvider

Methods

DelegateAsync(string, string, string[], bool, CancellationToken)

Delegates the refresh of VTXOs by sending a partially signed intent and forfeit transactions. The delegator will register the intent and participate in batches on behalf of the owner.

Task DelegateAsync(string intentMessage, string intentProof, string[] forfeitTxs, bool rejectReplace = false, CancellationToken cancellationToken = default)

Parameters

intentMessage string

The intent message in plain-text (stringified JSON).

intentProof string

The intent proof tx (PSBT in base64 format).

forfeitTxs string[]

Partially signed forfeit transactions (hex or base64).

rejectReplace bool

If true, the delegator will not replace an existing delegation that includes at least one VTXO from this request.

cancellationToken CancellationToken

Cancellation token.

Returns

Task

GetDelegatorInfoAsync(CancellationToken)

Returns information about the delegator including its public key, fee, and address. Use the pubkey when constructing delegate contract scripts.

Task<DelegatorInfo> GetDelegatorInfoAsync(CancellationToken cancellationToken = default)

Parameters

cancellationToken CancellationToken

Returns

Task<DelegatorInfo>