Commit graph

68 commits

Author SHA1 Message Date
cyberguru1
6754acc17b
litcli: add payments command to accounts
Introduce the 'payments' subcommand under 'litcli accounts' to query
account payment history. Supports parameters for offset, page size
limits, and counting of total payments.
2026-07-22 14:06:26 -05:00
cyberguru1
04f06144bd litcli: add custom session permission unit tests
Add comprehensive unit tests for the parsing and validation logic of
the custom permissions parser (`parseCustomPermissions`) in `litcli`.
2026-06-22 01:50:56 -05:00
cyberguru1
0b8fd17457 litcli: add custom permissions to session add
Add support for the `--permission` flag (which takes `entity:action`
pairs), similar to `lncli bakemacaroon`, when creating custom sessions
with `litcli sessions add`. Supports repeated flags, comma-separated
lists, and mixed input.
2026-06-22 01:50:56 -05:00
cyberguru1
46c7495e41
litcli: default update expirationDate to -1 and make optional
Set expirationDate default to -1, update positional argument usage and
prepend "(optional)" to the flag usage string.
2026-05-14 19:53:27 -05:00
cyberguru1
ec5f353e12
litcli: remove deprecated new_balance flag from update command
This change removes the --new_balance flag from the CLI parser and sets the AccountBalance field explicitly to -1
2026-05-14 19:26:59 -05:00
cyberguru1
afe032a50d
accounts, litcli: address description for the command update and the space removal
This commit updates the account update command description and ArgsUsage
for better clarity.

Additionally, a formatting nit is fixed in the checkLabel error message
to ensure no line starts with a space character.
2026-05-05 13:39:14 -05:00
cyberguru1
06c018da98
litcli: add --new_label flag to accounts update 2026-05-05 13:39:14 -05:00
Dario Anongba Varela
dfcde88496
litcli: show asset information on payinvoice 2026-03-19 14:16:46 +01:00
ffranr
a0e63124c0
multi: reformat long lines for readability
- Replace occurrences of `// nolint:lll` with `// nolint:ll` across
  files for consistency.
- Reformat multiline strings, comments, and function parameters to
  improve clarity and adhere to style guidelines.
- Add `// nolint:ll` comments where necessary to prevent linter
  warnings.
2025-12-09 16:12:03 +00:00
George Tsagkarelis
dd90147d63
litcli: update payinvoice for multirfq
With the introduction of multi-rfq send in taproot assets (see related
PR https://github.com/lightninglabs/taproot-assets/pull/1613) we
extended the behavior of the SendPayment RPC slightly.

Now we may not specify an RFQ peer in order for a list of peers to be
created & used automatically. When that happens, we will return multiple
quotes over the RPC.

The content of this commit changes our client wrapper around the
handling of the payment result. Previously we'd expect for exactly a
single quote to be returned over the stream (for the single defined
peer). Now we read all of the quotes that are returned in the new quotes
array field of the RPC. To maintain backwards compatibility we also kept
the previous single-quote RPC field, which we make sure to only read
once now that we read both fields (avoid a duplicate quote from
appearing in the logs).
2025-10-30 10:52:45 +01:00
George Tsagkarelis
a2625731d0
litcli: update description for rfq pubkey field
With the latest version of tapd we no longer require the rfq field to be
set. If left unset then AddInvoice/SendPayment will automatically
acquire quotes in order for the operation to be carried out.
2025-10-30 10:51:01 +01:00
Oliver Gugger
d3e9d2782c
cmd/litcli: add payment flags back
Some flags that didn't make sense were removed when cleaning up the
keysend usecase, but some of them are still useful and we add them back.
2025-06-05 16:34:43 +02:00
George Tsagkarelis
17ab5e21dd
cmd: ln addinvoice supports sat/msat amount 2025-05-20 13:03:52 +02:00
Elle
329b939aa6
Merge pull request #1034 from ViktorTigerstrom/2025-04-include-commit-hash
Add `commit_hash`  field to `GetInfo` response
2025-05-16 12:26:02 +02:00
Oliver Gugger
04381c6484
cmd: add --group_key CLI flag to all channel commands 2025-05-15 12:01:57 +02:00
Viktor Tigerström
e30ac3d0a8
multi: update GetInfoResponse response
Add the `commit_hash` field to 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".

The semantics of the `version` field is also updated to always contain
the most recent semantic version of the litd node, following the
semantic versioning 2.0.0 spec (http://semver.org/).
2025-05-13 12:27:19 +02:00
Oliver Gugger
33bc532ce0
mod+subservers: use taprpc module 2025-05-02 11:05:12 +02:00
Elle
9e5578cf2d
Merge pull request #974 from ViktorTigerstrom/2025-02-credit-debit-accounts-impl
accounts: Add credit and debit account functionality
2025-04-01 13:13:43 +02:00
Viktor Tigerström
0c520cef18
multi: add accounts u --new_balance deprecation
This commit adds a deprecation notice regarding the
`accounts update --new_balance` flag. This flag will be removed in the
next major release of lit.
2025-03-31 02:45:53 +02:00
Viktor Tigerström
5a02019161
litcli: add accounts credit & debit commands
This commit implements the `credit` and `debit` commands in `litcli`,
allowing users to increase or decrease the balance of an existing
off-chain account, respectively.
2025-03-31 02:18:57 +02:00
gcaracuel
b2f2ea048a
litcli: Global flags to accept ENV vars overrides. 2025-03-24 09:23:14 +01:00
Elle Mouton
949c0bf7e2
multi: move macaroon helpers to macaroons dir
... and out of the `sessions` directory. This is to avoid import cycles
when we start explicitly linking accounts to sessions.
2025-02-09 10:37:40 +02:00
Elle Mouton
76250ca835
litcli: use cancellable contexts
In this commit, we use the signal.Interceptor to cancel the contexts we
use for our CLI calls.
2025-01-13 09:29:53 +02:00
Elle Mouton
1fc0e6f16d
terminal: use ctx instead of interceptor 2025-01-13 07:03:28 +02:00
Oliver Gugger
7ed8ff1a39
cmd/litcli: add ln sub commands for custom channels 2024-12-19 21:21:39 +01:00
Elle Mouton
b4f8224c54
multi: use ReadOnly param of BakeSuperMacaroon 2024-10-14 15:48:18 +02:00
bitromortac
c352fa08bd
litcli: add privacy flags to feature registration
Adds support for overriding defaul privacy flags for non-default feature
configurations.
2024-04-25 14:49:47 +02:00
Viktor Tigerström
6bc86e5425
Merge pull request #634 from bitromortac/per-feature-restrictions
autopilot: generic rules per feature
2024-02-12 15:54:32 +01:00
bitromortac
34eeb2ae05
litcli: session registration with generic rules
This commit adds generic feature rule flags. Legacy flags
`channel-restrict-list` and `peer-restrict-list` are deprecated.
2024-02-07 12:52:01 +01:00
Viktor Tigerström
e5737436cd
accounts + main: allow new accounts with 0 balance 2024-02-01 11:22:08 +02:00
Oliver Gugger
d3413ae637
accounts+cmd/litcli: fix formatting 2024-01-03 11:14:51 +01:00
Brian
c39cd3cde9
main: make cmd documentation coherent 2023-10-31 07:07:15 -06:00
Oliver Gugger
322a96133d
multi: fix linter issues 2023-10-03 19:52:02 +02:00
Oliver Gugger
b3c0d0e9b1
multi: bump lnd to v0.17.0-beta 2023-10-03 19:51:57 +02:00
Elle Mouton
4e2ec08767
cmd/litcli: commands for status server
Note that the client connection for these commands does not require a
macaroon.
2023-09-22 11:59:25 +02:00
Elle Mouton
143876d1ec
litcli: prepare for a client connection without a macaroon
In preparation for an upcoming commit where litcli commands for the
Status server are added, the `getClientConn` method is updated with a
`noMac` parameter. If true, them the connection will be made without a
macaroon.
2023-09-22 11:59:24 +02:00
bitromortac
6e30ecaa69
litcli+rpcserver: session registration with config
We add command line flags to litcli in order to be able to submit
feature configurations when registering a session.
2023-09-01 08:03:21 +02:00
Elle Mouton
5882a21df8
multi: allow client to link autopilot sessions 2023-08-30 12:34:29 +02:00
Elle Mouton
60c10bd91d
multi: use group ID for PrivacyMapConversion query 2023-08-30 12:34:29 +02:00
Elle Mouton
bd9a99c5d4
multi: allow querying actions by group ID 2023-08-30 12:34:29 +02:00
Oliver Gugger
cbc0e819c5
cmd/litcli: update account CLI with label changes 2023-07-26 18:37:49 +02:00
Elle Mouton
ec77c5483d
cmd/litcli: add bakesupermacaroon command 2023-06-20 08:10:54 +02:00
Elle Mouton
c5dc10ccab
cmd/litcli: add super macaroon helper commands
In this commit, a `supermacrootkey` helper command is added which lets a
user generate a random root key ID for a super macaroon along with an
`issupermacaroon` command that allows a users to easily confirm if a
macaroon is considered a super macaroon or not. Neither of these
commands require a connection to LiTd.
2023-06-20 08:10:53 +02:00
Elle Mouton
de3e492d41
cmd/litcli: improve autopilot docs and add list command 2023-03-20 12:14:24 +02:00
Elle Mouton
dbe62e074a
multi: add StopDaemon method to Lit
In this commit, a new Proxy service is added with a StopDaemon method.
This method can be used to stop the Litd service. This will be useful in
remote-mode itests where we want to restart Litd without also restarting
LND. It also provides a nice way of shutting down Litd in remote-mode.
A GetInfo method is also added to the service which for now just returns
the Litd version. The reason for adding this method now is so that
access to the new Proxy service can be tested in the itests withouth
actually shutting down Litd.
2023-03-17 11:14:24 +02:00
Elle Mouton
2c25ba48ca
multi: always use Lit's TLS cert
In this commit, we remove Lit's dependency on LND's tls cert in
integrated mode. With this commit, even if Lit is started in integrated
mode, it will create its own tls cert to use for serving the webserver.
2023-02-23 07:35:22 -08:00
Elle Mouton
d3cab70928
cmd/litcli: create account sessions
Create LNC account sessions through litcli
2023-02-13 19:33:55 +02:00
Elle Mouton
ab347dd6f1
multi: add privacy mapper conversion helper 2023-01-27 06:47:13 +02:00
Elle Mouton
6de34a89e2
litcli: add lit-autopilot commands 2023-01-27 06:47:13 +02:00
Elle Mouton
164ade0e8c
multi: expose Actions
This commit adds a Lit grpc service and uses it to expose a ListActions
method. Litcli is also updated to make use of this method.
2023-01-27 06:47:12 +02:00