@arkade-os/swap 0.1.0-rc.21 → 0.1.0-rc.23

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (37) hide show
  1. package/README.md +7 -2
  2. package/dist/advanced.cjs +875 -129
  3. package/dist/advanced.d.cts +158 -14
  4. package/dist/advanced.d.ts +158 -14
  5. package/dist/advanced.js +255 -4
  6. package/dist/{chunk-ITFCQWPG.js → chunk-DQ2DY2L2.js} +223 -11
  7. package/dist/{chunk-HUQQVBC4.js → chunk-MZX62KMU.js} +220 -12
  8. package/dist/{chunk-PVB7EBAM.js → chunk-UFJEO4VV.js} +47 -21
  9. package/dist/{errors-hm7aqnRM.d.cts → errors-5q4e3PnH.d.cts} +48 -16
  10. package/dist/{errors-C3h8ANmE.d.ts → errors-DQ35FKJf.d.ts} +48 -16
  11. package/dist/index.cjs +670 -185
  12. package/dist/index.d.cts +5 -5
  13. package/dist/index.d.ts +5 -5
  14. package/dist/index.js +5 -3
  15. package/dist/node/index.d.cts +26 -4
  16. package/dist/node/index.d.ts +26 -4
  17. package/dist/nostr.cjs +12 -9
  18. package/dist/nostr.d.cts +1 -1
  19. package/dist/nostr.d.ts +1 -1
  20. package/dist/nostr.js +3 -1
  21. package/dist/{offer-Bd9Yvd8Z.d.ts → offer--IpfzhIm.d.ts} +1 -1
  22. package/dist/{offer-F88rtL_I.d.cts → offer-DqTXQeP1.d.cts} +1 -1
  23. package/dist/protocol.cjs +395 -156
  24. package/dist/protocol.d.cts +45 -8
  25. package/dist/protocol.d.ts +45 -8
  26. package/dist/protocol.js +10 -3
  27. package/dist/repositories/realm/index.d.cts +2 -2
  28. package/dist/repositories/realm/index.d.ts +2 -2
  29. package/dist/repositories/sqlite/index.d.cts +2 -2
  30. package/dist/repositories/sqlite/index.d.ts +2 -2
  31. package/dist/{repository-DYnRLPt-.d.ts → repository-B4rQWmS2.d.cts} +88 -20
  32. package/dist/{repository-BuYWGAKz.d.cts → repository-D_qvJk1S.d.ts} +88 -20
  33. package/dist/{rfq-60PGpQ_x.d.cts → rfq-BgdgO9OO.d.cts} +16 -7
  34. package/dist/{rfq-60PGpQ_x.d.ts → rfq-BgdgO9OO.d.ts} +16 -7
  35. package/dist/{watch-BTyiBLSd.d.ts → watch-BkPz0vf8.d.ts} +1 -1
  36. package/dist/{watch-M_KY-5ho.d.cts → watch-RRhKuBkh.d.cts} +1 -1
  37. package/package.json +3 -3
package/README.md CHANGED
@@ -54,8 +54,13 @@ artifact is an invoice whose claim secret has to be durable before a payer can a
54
54
  off it would show a payer an invoice this client could not yet claim; the verb removes the
55
55
  ordering from the caller.
56
56
 
57
- `onchain -> arkade` is not in the union. It resolves and quotes to `UnsupportedRoute` until the
58
- client owns the trader's L1 refund path end to end.
57
+ `onchain -> arkade` is a receive too: `client.receive({ via: "onchain", amount })` returns a
58
+ `deposit` artifact naming the L1 HTLC to fund, for exactly its `amount`, from any bitcoin wallet.
59
+ The client claims the solver's Arkade lockup once it is funded. If the solver never funds it, the
60
+ client takes the L1 funding back itself once the HTLC's refund leaf matures, paying a boarding
61
+ address of this wallet fixed at quote time and signing with the wallet key the HTLC was derived
62
+ with. The refund is built at the same `claimFeeRateSatVb` as the `arkade -> onchain` claim; wire
63
+ your own with `corridors: { onchain: { refund } }`.
59
64
 
60
65
  An `arkade -> onchain` withdrawal claims the solver's L1 HTLC itself, and that claim's miner fee
61
66
  comes out of the HTLC output — so the client grosses the take leg up by the claim's cost and the