Enum OnchainHtlcPhase
- Namespace
- NArk.ArkadeIntents.Onchain
- Assembly
- NArk.ArkadeIntents.dll
Where an L1 HTLC stands, as the chain reports it.
public enum OnchainHtlcPhase
Fields
AwaitingConfirmations = 1Funded, but short of the confirmations the swap was quoted at.
Claimable = 2Funded, confirmed, and there is still room to claim before the refund leaf opens.
Empty = 0Nothing is at the address — and which of the two reasons that is cannot be decided from here.
An HTLC that was never funded and one that was funded and already spent give an address UTXO query exactly the same answer, and IBitcoinBlockchain exposes no address history to separate them. So this is named for what is known rather than for either guess. It replaces a pair that claimed more than the query supports: an
Unfundednothing ever produced, and aSettledthat told a caller somebody had taken the money over a swap that may simply never have been funded.A caller needing the distinction has it elsewhere. Its own row knows whether it ever funded, and where a spend is suspected ExtractPreimage(Transaction, uint256) against the spending transaction turns "gone" into proof of which leaf took it. On an on-board a settled HTLC is the solver collecting with the preimage our own claim published, which is the ordinary end — but the proof is in that witness, never in this absence.
Refundable = 3The refund leaf has matured, which means the claim window is closed.
A recovery caller reading this must not try to claim. Reaching it on a swap you expected to claim means the claim was missed, not that it is still available — the correct move is the refund on whichever rail is yours, and on an off-board that is the Arkade covenant rather than anything here.