Skip to content

Commit e05a2ca

Browse files
committed
docs: update loop.md
1 parent 6ff3ac5 commit e05a2ca

File tree

2 files changed

+112
-5
lines changed

2 files changed

+112
-5
lines changed

docs/loop.1

Lines changed: 70 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -470,6 +470,8 @@ withdrawing
470470
withdrawn
471471
looping_in
472472
looped_in
473+
opening_channel
474+
channel_published
473475
publish_expired_deposit
474476
sweep_htlc_timeout
475477
htlc_timeout_swept
@@ -564,3 +566,71 @@ Loop in funds from static address deposits.
564566
.PP
565567
\fB--verbose, -v\fP: show expanded details
566568

569+
.SS openchannel
570+
.PP
571+
Open a channel to a an existing peer.
572+
573+
.PP
574+
\fB--base_fee_msat\fP="": the base fee in milli-satoshis that will be charged for each forwarded HTLC, regardless of payment size (default: 0)
575+
576+
.PP
577+
\fB--channel_type\fP="": (optional) the type of channel to propose to the remote peer ("tweakless", "anchors", "taproot")
578+
579+
.PP
580+
\fB--close_address\fP="": (optional) an address to enforce payout of our funds to on cooperative close. Note that if this value is set on channel open, you will \fInot\fP be able to cooperatively close to a different address.
581+
582+
.PP
583+
\fB--fee_rate_ppm\fP="": the fee rate ppm (parts per million) that will be charged proportionally based on the value of each forwarded HTLC, the lowest possible rate is 0 with a granularity of 0.000001 (millionths) (default: 0)
584+
585+
.PP
586+
\fB--fundmax\fP: if set, the wallet will attempt to commit the maximum possible local amount to the channel. This must not be set at the same time as local_amt
587+
588+
.PP
589+
\fB--help, -h\fP: show help
590+
591+
.PP
592+
\fB--local_amt\fP="": the number of satoshis the wallet should commit to the channel (default: 0)
593+
594+
.PP
595+
\fB--max_local_csv\fP="": (optional) the maximum number of blocks that we will allow the remote peer to require we wait before accessing our funds in the case of a unilateral close. (default: 0)
596+
597+
.PP
598+
\fB--memo\fP="": (optional) a note-to-self containing some useful
599+
information about the channel. This is stored
600+
locally only, and is purely for reference. It
601+
has no bearing on the channel's operation. Max
602+
allowed length is 500 characters
603+
604+
.PP
605+
\fB--min_htlc_msat\fP="": (optional) the minimum value we will require for incoming HTLCs on the channel (default: 0)
606+
607+
.PP
608+
\fB--node_key\fP="": the identity public key of the target node/peer serialized in compressed format
609+
610+
.PP
611+
\fB--private\fP: make the channel private, such that it won't be announced to the greater network, and nodes other than the two channel endpoints must be explicitly told about it to be able to route through it
612+
613+
.PP
614+
\fB--push_amt\fP="": the number of satoshis to give the remote side as part of the initial commitment state, this is equivalent to first opening a channel and sending the remote party funds, but done all in one step (default: 0)
615+
616+
.PP
617+
\fB--remote_csv_delay\fP="": (optional) the number of blocks we will require our channel counterparty to wait before accessing its funds in case of unilateral close. If this is not set, we will scale the value according to the channel size (default: 0)
618+
619+
.PP
620+
\fB--remote_max_value_in_flight_msat\fP="": (optional) the maximum value in msat that can be pending within the channel at any given time (default: 0)
621+
622+
.PP
623+
\fB--remote_reserve_sats\fP="": (optional) the minimum number of satoshis we require the remote node to keep as a direct payment. If not specified, a default of 1% of the channel capacity will be used. (default: 0)
624+
625+
.PP
626+
\fB--sat_per_vbyte\fP="": (optional) a manual fee expressed in sat/vbyte that should be used when crafting the transaction (default: 0)
627+
628+
.PP
629+
\fB--scid_alias\fP: (optional) whether a scid-alias channel type should be negotiated.
630+
631+
.PP
632+
\fB--utxo\fP="": a utxo specified as outpoint(tx:idx) which will be used to fund a channel. This flag can be repeatedly used to fund a channel with a selection of utxos. The selected funds can either be entirely spent by specifying the fundmax flag or partially by selecting a fraction of the sum of the outpoints in local_amt (default: [])
633+
634+
.PP
635+
\fB--zero_conf\fP: (optional) whether a zero-conf channel open should be attempted.
636+

docs/loop.md

Lines changed: 42 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -534,10 +534,10 @@ $ loop [GLOBAL FLAGS] static listdeposits [COMMAND FLAGS] [ARGUMENTS...]
534534

535535
The following flags are supported:
536536

537-
| Name | Description | Type | Default value |
538-
|-----------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|--------|:-------------:|
539-
| `--filter="…"` | specify a filter to only display deposits in the specified state. Leaving out the filter returns all deposits. The state can be one of the following: deposited withdrawing withdrawn looping_in looped_in publish_expired_deposit sweep_htlc_timeout htlc_timeout_swept wait_for_expiry_sweep expired failed | string |
540-
| `--help` (`-h`) | show help | bool | `false` |
537+
| Name | Description | Type | Default value |
538+
|-----------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|--------|:-------------:|
539+
| `--filter="…"` | specify a filter to only display deposits in the specified state. Leaving out the filter returns all deposits. The state can be one of the following: deposited withdrawing withdrawn looping_in looped_in opening_channel channel_published publish_expired_deposit sweep_htlc_timeout htlc_timeout_swept wait_for_expiry_sweep expired failed | string |
540+
| `--help` (`-h`) | show help | bool | `false` |
541541

542542
### `static listwithdrawals` subcommand
543543

@@ -598,7 +598,7 @@ The following flags are supported:
598598

599599
Display a summary of static address related information.
600600

601-
Displays various static address related information about deposits, withdrawals and swaps.
601+
Displays various static address related information about deposits, withdrawals, swaps and channel openings.
602602

603603
Usage:
604604

@@ -641,3 +641,40 @@ The following flags are supported:
641641
| `--verbose` (`-v`) | show expanded details | bool | `false` |
642642
| `--help` (`-h`) | show help | bool | `false` |
643643

644+
### `static openchannel` subcommand
645+
646+
Open a channel to a an existing peer.
647+
648+
Attempt to open a new channel to an existing peer with the key node-key. The channel will be initialized with local-amt satoshis locally and push-amt satoshis for the remote node. Note that the push-amt is deducted from the specified local-amt which implies that the local-amt must be greater than the push-amt. Also note that specifying push-amt means you give that amount to the remote node as part of the channel opening. Once the channel is open, a channelPoint (txid:vout) of the funding output is returned. If the remote peer supports the option upfront shutdown feature bit (query listpeers to see their supported feature bits), an address to enforce payout of funds on cooperative close can optionally be provided. Note that if you set this value, you will not be able to cooperatively close out to another address. One can also specify a short string memo to record some useful information about the channel using the --memo argument. This is stored locally only, and is purely for reference. It has no bearing on the channel's operation. Max allowed length is 500 characters.
649+
650+
Usage:
651+
652+
```bash
653+
$ loop [GLOBAL FLAGS] static openchannel [COMMAND FLAGS] [ARGUMENTS...]
654+
```
655+
656+
The following flags are supported:
657+
658+
| Name | Description | Type | Default value |
659+
|-----------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|--------|:-------------:|
660+
| `--node_key="…"` | the identity public key of the target node/peer serialized in compressed format | string |
661+
| `--local_amt="…"` | the number of satoshis the wallet should commit to the channel | int | `0` |
662+
| `--base_fee_msat="…"` | the base fee in milli-satoshis that will be charged for each forwarded HTLC, regardless of payment size | uint | `0` |
663+
| `--fee_rate_ppm="…"` | the fee rate ppm (parts per million) that will be charged proportionally based on the value of each forwarded HTLC, the lowest possible rate is 0 with a granularity of 0.000001 (millionths) | uint | `0` |
664+
| `--push_amt="…"` | the number of satoshis to give the remote side as part of the initial commitment state, this is equivalent to first opening a channel and sending the remote party funds, but done all in one step | int | `0` |
665+
| `--sat_per_vbyte="…"` | (optional) a manual fee expressed in sat/vbyte that should be used when crafting the transaction | int | `0` |
666+
| `--private` | make the channel private, such that it won't be announced to the greater network, and nodes other than the two channel endpoints must be explicitly told about it to be able to route through it | bool | `false` |
667+
| `--min_htlc_msat="…"` | (optional) the minimum value we will require for incoming HTLCs on the channel | int | `0` |
668+
| `--remote_csv_delay="…"` | (optional) the number of blocks we will require our channel counterparty to wait before accessing its funds in case of unilateral close. If this is not set, we will scale the value according to the channel size | uint | `0` |
669+
| `--max_local_csv="…"` | (optional) the maximum number of blocks that we will allow the remote peer to require we wait before accessing our funds in the case of a unilateral close | uint | `0` |
670+
| `--close_address="…"` | (optional) an address to enforce payout of our funds to on cooperative close. Note that if this value is set on channel open, you will *not* be able to cooperatively close to a different address | string |
671+
| `--remote_max_value_in_flight_msat="…"` | (optional) the maximum value in msat that can be pending within the channel at any given time | uint | `0` |
672+
| `--channel_type="…"` | (optional) the type of channel to propose to the remote peer ("tweakless", "anchors", "taproot") | string |
673+
| `--zero_conf` | (optional) whether a zero-conf channel open should be attempted | bool | `false` |
674+
| `--scid_alias` | (optional) whether a scid-alias channel type should be negotiated | bool | `false` |
675+
| `--remote_reserve_sats="…"` | (optional) the minimum number of satoshis we require the remote node to keep as a direct payment. If not specified, a default of 1% of the channel capacity will be used | uint | `0` |
676+
| `--memo="…"` | (optional) a note-to-self containing some useful information about the channel. This is stored locally only, and is purely for reference. It has no bearing on the channel's operation. Max allowed length is 500 characters | string |
677+
| `--fundmax` | if set, the wallet will attempt to commit the maximum possible local amount to the channel. This must not be set at the same time as local_amt | bool | `false` |
678+
| `--utxo="…"` | a utxo specified as outpoint(tx:idx) which will be used to fund a channel. This flag can be repeatedly used to fund a channel with a selection of utxos. The selected funds can either be entirely spent by specifying the fundmax flag or partially by selecting a fraction of the sum of the outpoints in local_amt | string | `[]` |
679+
| `--help` (`-h`) | show help | bool | `false` |
680+

0 commit comments

Comments
 (0)