Commit graph

158 commits

Author SHA1 Message Date
Boris Nagaev
8ea9adbd35
looprpc: map custom channel reason
Static autoloop testing surfaced a SuggestSwaps failure when the
planner disqualified a custom asset channel.

Add the missing AutoReason enum value and handle ReasonCustomChannelData.
2026-05-22 02:20:36 -05:00
Boris Nagaev
e467ac932b
looprpc: expose static autoloop output
Extend the public rpc surface for static autoloop integration
without turning the planner on yet. SuggestSwaps responses can
now carry static-address loop-in requests and the new planner
reason for missing static candidates is mapped over rpc.
2026-05-22 02:20:36 -05:00
Boris Nagaev
562416e99b
loopd: validate static loop-in labels at rpc
Move static loop-in label validation to the rpc boundary and
remove the same check from the internal manager path.

This keeps external requests aligned with the existing swap rpc
surface while allowing internal autoloop callers to keep using
reserved labels for automated swaps. The tests cover both sides of
that contract: rpc requests still reject reserved labels, and the
manager path accepts them.
2026-05-22 02:20:36 -05:00
Slyghtning
a10c741a26
lint: fix linter issues 2026-03-09 14:39:45 +01:00
Slyghtning
a9977dd5f4
godoc: address copy-paste errors accross the codebase 2026-03-09 14:39:44 +01:00
Slyghtning
b74dab8af4
loopd: instantiate static address open channel manager 2026-02-26 20:57:27 +01:00
Slyghtning
f47b611557
looprpc: extend client.proto with lnrpc.OutPoint and lnrpc.OpenChannelRequest
In this commit we import the lnd's lightning.proto into client.proto to
then be able to use lnrpc.OutPoint and lnrpc.OpenChannelRequest instead
of the looprpc.OutPoint type.
This is safe because the lnrpc and looprpc versions of OutPoint are the
same type.
2026-02-26 09:37:26 +01:00
Boris Nagaev
59140265ca
loopd: implement SweepHtlc RPC 2026-01-29 17:40:58 -05:00
Boris Nagaev
a4dc59099b
cli: add command "loop stop"
* add StopDaemon RPC with permissions + REST binding
* expose `loop stop` CLI (with optional --wait) and wait logic
* pass daemon shutdown callback + unit test and regenerate docs/protos
2025-11-19 23:42:48 -03:00
Boris Nagaev
325441bf47
loopd: fix crash in instant if no --experimental
Previously the daemon crashed with a panic. Now the CLI returns the following
message:

[loop] rpc error: code = Unimplemented desc = Restart loop with --experimental
2025-10-31 01:36:22 -03:00
Slyghtning
de2964efba
loopd: refactor blocks-until-expiry calculation 2025-10-09 09:14:43 +02:00
Slyghtning
0d3a4c8a19
loopd: more info in StaticAddressLoopInResponse 2025-10-08 21:34:48 +02:00
Slyghtning
68baebf478
loopd: return quoted amount in InQuoteResponse 2025-10-07 11:13:44 +02:00
Slyghtning
168420c28d
loopd: fast-flag in GetLoopInQuote and StaticAddressLoopIn 2025-10-07 09:12:38 +02:00
Slyghtning
55081cd8fe
staticaddr: ignoreUnknown flag for DepositsForOutpoints 2025-09-26 12:03:48 +02:00
Slyghtning
23f6c24c0c
staticaddr: fix swap amount in listswaps command 2025-09-25 11:13:34 +02:00
Slyghtning
95a456791b
loopd: deposit selection for GetLoopInQuote
If a quote request contains an amount and flag
SelectDeposits set to true the quoting coin-
selects the required deposits to meet the
swap amount in order to quote for the number
of deposits.
2025-09-25 11:13:34 +02:00
Slyghtning
d3a2badc8b
loopd: filter unavailable deposits in ListUnspentDeposits
ListUnspentRaw returns the unspent wallet view of the
backing lnd wallet. It might be that deposits show up
there that are actually not spendable because they
already have been used but not yet spent by the server.
We filter out such deposits in ListUnspentDeposits.
2025-08-22 15:54:19 +02:00
Slyghtning
b2a4d7af2d
staticaddr: show deposits as part of cli swap output 2025-08-20 17:07:29 +02:00
Slyghtning
a41334dd3d
staticaddr: add swap hash to deposit structs 2025-08-20 16:58:20 +02:00
Andras Banki-Horvath
d12dc0362d
loopd: avoid panic if asset client is not set 2025-06-24 14:55:42 +02:00
Slyghtning
614d61937e
loopd: retrieve historic withdrawal info 2025-06-10 17:07:32 +02:00
Viktor Tigerström
cdcacfe753
multi: update GetInfoResponse response
Update the output of the `commit_hash` field in the GetInfoResponse.
The `commit_hash` field will contain the most recent commit_hash that
the build was based on. If the build had uncommitted changes, this field
will contain the most recent commit hash, suffixed by "-dirty".

Note that this change also changes the output of `commit` field in the
`--version` command. The `Commit` field will now contain most recent git
commit tag.
2025-05-22 18:01:36 +02:00
Slyghtning
cf0651af38
staticaddr: add expiry to NewAddress response 2025-05-15 14:56:49 +02:00
sputn1ck
1ce9bdd0d3
multi: use reservation ids in instant out quote 2025-04-30 15:35:25 +02:00
Boris Nagaev
6d3f65a0f2
looprpc: rename field in WithdrawDepositsResponse
It returns an address, but the field was called pk_script, which was confusing.
Also renamed it in the code.
2025-04-24 11:19:59 -03:00
Sam Korn
b55521cb41
looprpc: add simple pagination to the ListSwaps command
This commit adds the ability to set a max_swaps and an index_offset
flag to the ListSwaps command. These new fields are applied AFTER
the initial filtering step. The response also now passes additional
information about the index count and total swaps filtered.
2025-04-19 22:31:45 -06:00
Andras Banki-Horvath
9a6266f9f7
loop: add the commit_hash to GetInfoResponse, change version semantics
With this commit we extend GetinfoResponse with the strict commit hash
(which also includes whether the build tree was clean or dirty).
2025-04-04 12:47:30 +02:00
Boris Nagaev
e0e66a9b38
loopd: fix data races of logger 2025-03-19 15:00:30 +01:00
Oliver Gugger
65251e8821
multi: update linter, fix issues 2025-03-10 22:59:50 +01:00
Slyghtning
c7cc47bdc3
loopd: arbitrary withdrawal amount for static address deposits 2025-02-09 15:57:26 +01:00
sputn1ck
95aae0e800
loopout/asset: add asset rate 2025-01-22 15:40:57 +01:00
sputn1ck
fddad8a964
looprpc: rename assetamt to max amt 2025-01-22 15:40:57 +01:00
sputn1ck
3e3c863819
loopout: add asset accounting 2025-01-21 18:26:20 +01:00
sputn1ck
1440b6bb1d
loopout: add asset loop out payment flow 2025-01-21 18:26:19 +01:00
sputn1ck
8451f29f8f
loopd: add asset client to swap config 2025-01-21 14:38:02 +01:00
Slyghtning
042b513d50
staticaddr: dest addr and fee rate for withdrawals 2024-12-12 18:31:10 +01:00
sputn1ck
a98e16184e
loopd/staticaddr: add ntfn manager 2024-12-12 18:31:09 +01:00
Slyghtning
439d178b96
staticaddr: cmd listdeposits and listswaps 2024-12-12 18:31:08 +01:00
Slyghtning
21c37a910a
loopd: static address loop-in support 2024-12-12 18:31:08 +01:00
Slyghtning
c11e90138b
staticaddr: enable deposits for swaps
The static address state machine adds states
to reflect the state of a deposit during a
loop-in swap.
2024-12-12 18:31:06 +01:00
Slyghtning
b9e5875f4e
looprpc: static address loop-ins 2024-12-12 18:31:06 +01:00
Slyghtning
82b95798ab
loopd: quoting for static address loop-ins 2024-12-12 18:31:06 +01:00
Slyghtning
8595c4ac6e
loopd: static address summary 2024-12-12 18:31:05 +01:00
Slyghtning
a7f2f2d8c8
loopd: static address withdrawals support 2024-12-12 18:31:05 +01:00
Slyghtning
3914ab840f
staticaddr: deposits for server and daemon 2024-12-12 18:31:03 +01:00
sputn1ck
830220af66
looprpc: add FetchL402 rpc
This commit adds the FetchL402 rpc to the client proto, which will allow
users to force fetching an L402 without doing a loop out or in.
2024-10-30 17:18:34 +01:00
Slyghtning
caa8cc850d
loopout: trace logs for hasBandwidth mpp check 2024-10-15 10:08:31 +02:00
Boris Nagaev
8447f58ff9
multi: do not rename swapserverrpc to looprpc
Many imports renamed it, but it was not needed.
2024-09-10 09:54:17 -03:00
Andras Banki-Horvath
0d0af5bf24
loopout: use the request defined payment timeout 2024-05-23 17:17:21 +02:00