Table of Contents

Class DataLayerWallet

Namespace
chia.dotnet
Assembly
chia-dotnet.dll

Wraps a Data Layer Wallet

public sealed class DataLayerWallet : Wallet
Inheritance
DataLayerWallet
Inherited Members
Extension Methods

Remarks

ctor

Constructors

DataLayerWallet(uint, WalletProxy)

Wraps a Data Layer Wallet

public DataLayerWallet(uint walletId, WalletProxy walletProxy)

Parameters

walletId uint

The wallet_id to wrap

walletProxy WalletProxy

Wallet RPC proxy to use for communication

Remarks

ctor

Methods

DeleteMirror(string, ulong, CancellationToken)

Remove an existing mirror for a specific singleton.

public Task<IEnumerable<TransactionRecord>> DeleteMirror(string coinId, ulong fee = 0, CancellationToken cancellationToken = default)

Parameters

coinId string
fee ulong

Fee (in units of mojos)

cancellationToken CancellationToken

A token to allow the call to be cancelled

Returns

Task<IEnumerable<TransactionRecord>>

A list of TransactionRecord

GetMirrors(string, CancellationToken)

Get all of the mirrors for a specific singleton.

public Task<IEnumerable<Mirror>> GetMirrors(string launcherId, CancellationToken cancellationToken = default)

Parameters

launcherId string
cancellationToken CancellationToken

A token to allow the call to be cancelled

Returns

Task<IEnumerable<Mirror>>

A list of Mirror

History(string, uint?, uint?, uint?, CancellationToken)

Get the singleton record for the latest singleton of a launcher ID.

public Task<IEnumerable<SingletonRecord>> History(string launcherId, uint? minGeneration = null, uint? maxGeneration = null, uint? numResults = null, CancellationToken cancellationToken = default)

Parameters

launcherId string
minGeneration uint?
maxGeneration uint?
numResults uint?
cancellationToken CancellationToken

A token to allow the call to be cancelled

Returns

Task<IEnumerable<SingletonRecord>>

A list of SingletonRecord

LatestSingleton(string, string, CancellationToken)

Get the singleton records that contain the specified root.

public Task<LineageProof> LatestSingleton(string root, string launcherId, CancellationToken cancellationToken = default)

Parameters

root string
launcherId string
cancellationToken CancellationToken

A token to allow the call to be cancelled

Returns

Task<LineageProof>

LineageProof

NewMirror(string, ulong, IEnumerable<string>, ulong, CancellationToken)

Add a new on chain message for a specific singleton.

public Task<IEnumerable<TransactionRecord>> NewMirror(string launcherId, ulong amount, IEnumerable<string> urls, ulong fee = 0, CancellationToken cancellationToken = default)

Parameters

launcherId string
amount ulong
urls IEnumerable<string>
fee ulong

Fee (in units of mojos)

cancellationToken CancellationToken

A token to allow the call to be cancelled

Returns

Task<IEnumerable<TransactionRecord>>

A list of TransactionRecord

OwnedSingletons(CancellationToken)

Get all owned singleton records.

public Task<IEnumerable<SingletonRecord>> OwnedSingletons(CancellationToken cancellationToken = default)

Parameters

cancellationToken CancellationToken

A token to allow the call to be cancelled

Returns

Task<IEnumerable<SingletonRecord>>

A list of SingletonRecord

SingletonsByRoot(string, string, CancellationToken)

Get the singleton records that contain the specified root.

public Task<IEnumerable<SingletonRecord>> SingletonsByRoot(string root, string launcherId, CancellationToken cancellationToken = default)

Parameters

root string
launcherId string
cancellationToken CancellationToken

A token to allow the call to be cancelled

Returns

Task<IEnumerable<SingletonRecord>>

A list of SingletonRecord

StopTracking(string, CancellationToken)

Stop tracking the data layer wallets.

public Task StopTracking(string launcherId, CancellationToken cancellationToken = default)

Parameters

launcherId string
cancellationToken CancellationToken

A token to allow the call to be cancelled

Returns

Task

An awaitable Task

TrackNew(string, CancellationToken)

Track the new data layer wallet

public Task TrackNew(string launcherId, CancellationToken cancellationToken = default)

Parameters

launcherId string
cancellationToken CancellationToken

A token to allow the call to be cancelled

Returns

Task

An awaitable Task

UpdateMultiple(IEnumerable<SingletonInfo>, CancellationToken)

Update multiple singletons with new merkle roots

public Task<IEnumerable<TransactionRecord>> UpdateMultiple(IEnumerable<SingletonInfo> updates, CancellationToken cancellationToken = default)

Parameters

updates IEnumerable<SingletonInfo>
cancellationToken CancellationToken

A token to allow the call to be cancelled

Returns

Task<IEnumerable<TransactionRecord>>

A list of TransactionRecord

UpdateRoot(string, string, ulong, CancellationToken)

Update a data layer root.

public Task<(TransactionRecord txRecord, IEnumerable<TransactionRecord> transactions)> UpdateRoot(string newRoot, string launcherId, ulong fee = 0, CancellationToken cancellationToken = default)

Parameters

newRoot string
launcherId string
fee ulong

Fee (in units of mojos)

cancellationToken CancellationToken

A token to allow the call to be cancelled

Returns

Task<(TransactionRecord txRecord, IEnumerable<TransactionRecord> transactions)>

TransactionRecord and list of transactions

Validate(CancellationToken)

Validates that WalletId is a DATA_LAYER

public override Task Validate(CancellationToken cancellationToken = default)

Parameters

cancellationToken CancellationToken
Wraps a Data Layer Wallet

Returns

Task

True if the wallet is a Data Layer wallet