|
|
|
|
|
|
|
|
A CLN plugin that runs an lnurl server so you can receive via lnurl (LUD-06) or ln-addresses (LUD-16) with optional Zap (NIP-57) support.
Check out payany if you want to be able to pay to an LNURL or ln-address from the CLI.
For general plugin installation instructions see the plugins repo README.md
Release binaries for
- x86_64-linux
- armv7-linux (Raspberry Pi 32bit)
- aarch64-linux (Raspberry Pi 64bit)
can be found on the release page. If you are unsure about your architecture you can run uname -m
.
They require glibc>=2.31
, which you can check with ldd --version
.
You can build the plugin yourself instead of using the release binaries. First clone the repo:
git clone https://github.com/daywalker90/clnaddress.git
Install a recent rust version (rustup is recommended) and in the clnaddress
folder run:
cargo build --release
After that the binary will be here: target/release/clnaddress
Note: Release binaries are built using cross
and the optimized
profile.
clnaddress-min-receivable
: Minimum receivable amount in msat, defaults to0
(any amount allowed)clnaddress-max-receivable
: Maximum receivable amount in msat, defaults to100000000000
clnaddress-description
: Description shown in wallets, defaults toThank you :)
clnaddress-listen
: Listen address for the LNURL web server. Use[::]
to bind to everything. Defaults tolocalhost:9797
clnaddress-base-url
: Base URL of you lnaddress service, e.g.https://sub.domain.org/path/
, no default and must be setclnaddress-nostr-privkey
: Nostr private key for signing zap receipts, no default and optional, but required for zap support. It is recommended to create another key for this and not use your usual nostr key.
- clnaddress-adduser user [is_email] [description]
- adds a user for your ln-address server
- user: username part of the lightning address
- is_email: optional boolean if the lightning address is also an email, which would change the metadata slightly, defaults to
false
- description: optional user-specific description, defaults to the description from the
clnaddress-description
option
- clnaddress-deluser user
- deletes a previously added user
- user: username part of the lightning address
- clnaddress-listuser [user]
- lists previously added user(s)
- user: optional username part of the lightning address
For any of this to work you must configure your reverse proxy to point to the lnurl web server hosted under clnaddress-listen
With nginx
:
For LNURL you can choose any location e.g. lnurl
:
location /lnurl/ {
proxy_pass http://localhost:9797/;
add_header 'Access-Control-Allow-Origin' '*';
}
To support all ln-address users you add another location like this:
location ~* ^/\.well-known/lnurlp/([^/]+) {
proxy_pass http://localhost:9797$request_uri;
add_header 'Access-Control-Allow-Origin' '*';
}
Make sure to use the correct proxy_pass
address, usually it's just http://
+ clnaddress-listen
+ /
Your LNURL gets printed to log on plugin start, watch out for the line starting with LNURL:
clnaddress
supports multiple ln-addresses at the same time and you can add or remove users with the clnaddress-adduser
and clnaddress-deluser
methods.
In order for zap receipts to be send you must specify a clnaddress-nostr-privkey
that will sign the receipts. It is recommended to create another key for this and not use your usual nostr key.