Skip to main content

ToBTCSwapState

Defined in: atomiq-sdk/src/swaps/escrow_swaps/tobtc/IToBTCSwap.ts:53

State enum for escrow-based Smart chain -> Bitcoin (on-chain & lightning) swaps

Enumeration Members

REFUNDED

REFUNDED: -3;

Defined in: atomiq-sdk/src/swaps/escrow_swaps/tobtc/IToBTCSwap.ts:58

Intermediary (LP) was unable to process the swap and the funds were refunded on the source chain


QUOTE_EXPIRED

QUOTE_EXPIRED: -2;

Defined in: atomiq-sdk/src/swaps/escrow_swaps/tobtc/IToBTCSwap.ts:62

Swap has expired for good and there is no way how it can be executed anymore


QUOTE_SOFT_EXPIRED

QUOTE_SOFT_EXPIRED: -1;

Defined in: atomiq-sdk/src/swaps/escrow_swaps/tobtc/IToBTCSwap.ts:67

A swap is almost expired, and it should be presented to the user as expired, though there is still a chance that it will be processed


CREATED

CREATED: 0;

Defined in: atomiq-sdk/src/swaps/escrow_swaps/tobtc/IToBTCSwap.ts:72

Swap was created, use the IToBTCSwap.commit or IToBTCSwap.txsCommit to initiate it by creating the swap escrow on the source chain


COMMITED

COMMITED: 1;

Defined in: atomiq-sdk/src/swaps/escrow_swaps/tobtc/IToBTCSwap.ts:78

Swap escrow was initiated (committed) on the source chain, the intermediary (LP) will now process the swap. You can wait till that happens with the IToBTCSwap.waitForPayment function.


SOFT_CLAIMED

SOFT_CLAIMED: 2;

Defined in: atomiq-sdk/src/swaps/escrow_swaps/tobtc/IToBTCSwap.ts:83

The intermediary (LP) has processed the transaction and sent out the funds on the destination chain, but hasn't yet settled the escrow on the source chain.


CLAIMED

CLAIMED: 3;

Defined in: atomiq-sdk/src/swaps/escrow_swaps/tobtc/IToBTCSwap.ts:87

Swap was successfully settled by the intermediary (LP) on the source chain


REFUNDABLE

REFUNDABLE: 4;

Defined in: atomiq-sdk/src/swaps/escrow_swaps/tobtc/IToBTCSwap.ts:92

Intermediary (LP) was unable to process the swap and the swap escrow on the source chain is refundable, call IToBTCSwap.refund or IToBTCSwap.txsRefund to refund