Rust · BOLT 8 · Core Lightning Commando
lnsocket.
Open an encrypted connection to any Lightning node, then call Core Lightning RPCs over it, from Rust or from your shell.
cargo add lnsocketcargo install --git https://github.com/jb55/lnsocket-rs --features cli$ lnrpc -n mynodemynode> getinfo{ "id": "02a1d3…c3f9", "alias": "mynode", "num_active_channels": 9, "blockheight": 921337, …}mynode> listinvoices {"label": "coffee for two"}{ "invoices": [ { "label": "coffee for two", "status": "paid", … } ]}mynode> nosuchmethoderror: nosuchmethod: Unknown command 'nosuchmethod' (code -32601)mynode> listfunds listpeerchannels… both results, sent together over the same socketmynode>
One connection, many calls. Output is illustrative and trimmed.