Class ArkWalletInfo
- Namespace
- NArk.Abstractions.Wallets
- Assembly
- NArk.Abstractions.dll
Wallet information record used at the abstraction/interface boundary.
public record ArkWalletInfo : IEquatable<ArkWalletInfo>
- Inheritance
-
ArkWalletInfo
- Implements
- Inherited Members
Constructors
ArkWalletInfo(string, string?, string?, WalletType, string?, int, IReadOnlyDictionary<string, string>?)
Wallet information record used at the abstraction/interface boundary.
public ArkWalletInfo(string Id, string? Secret, string? Destination, WalletType WalletType, string? AccountDescriptor, int LastUsedIndex, IReadOnlyDictionary<string, string>? Metadata = null)
Parameters
IdstringWallet identifier.
SecretstringLocal signing material, when present, interpreted according to
WalletType: the nsec private key for SingleKey, the BIP-39 mnemonic for HD.Null/empty means the wallet has no local key — it is either watch-only or remote-signed, distinguished at runtime by whether GetSignerAsync(string, CancellationToken) can produce a signer (e.g. via a registered IRemoteSignerTransport). Capability lives on the signer-provider boundary; it is not encoded in the data type.
DestinationstringDestination address for swept funds.
WalletTypeWalletTypeKey-derivation flavour — see WalletType.
AccountDescriptorstringFor HD wallets: the account descriptor. For legacy:
tr(pubkey).LastUsedIndexintFor HD wallets: last used derivation index.
MetadataIReadOnlyDictionary<string, string>Generic per-wallet key-value store (persisted as a JSON column). Used for per-wallet bookkeeping that doesn't warrant a dedicated column — e.g.
"vtxo.lastFullPollAt"for the VTXO sync cursor. Use sparse-key updates viaIWalletStorage.SetMetadataValueso concurrent writers for different concerns don't clobber each other.
Properties
AccountDescriptor
For HD wallets: the account descriptor. For legacy: tr(pubkey).
public string? AccountDescriptor { get; init; }
Property Value
Destination
Destination address for swept funds.
public string? Destination { get; init; }
Property Value
Id
Wallet identifier.
public string Id { get; init; }
Property Value
LastUsedIndex
For HD wallets: last used derivation index.
public int LastUsedIndex { get; init; }
Property Value
Metadata
Generic per-wallet key-value store (persisted as a JSON column). Used for
per-wallet bookkeeping that doesn't warrant a dedicated column —
e.g. "vtxo.lastFullPollAt" for the VTXO sync cursor. Use sparse-key
updates via IWalletStorage.SetMetadataValue so concurrent writers
for different concerns don't clobber each other.
public IReadOnlyDictionary<string, string>? Metadata { get; init; }
Property Value
Secret
Local signing material, when present, interpreted according to WalletType:
the nsec private key for SingleKey, the BIP-39 mnemonic for
HD.
Null/empty means the wallet has no local key — it is either watch-only or remote-signed, distinguished at runtime by whether GetSignerAsync(string, CancellationToken) can produce a signer (e.g. via a registered IRemoteSignerTransport). Capability lives on the signer-provider boundary; it is not encoded in the data type.
public string? Secret { get; init; }
Property Value
WalletType
Key-derivation flavour — see WalletType.
public WalletType WalletType { get; init; }