Skip to content

glcli: new commands to test payments#670

Merged
cdecker merged 7 commits intoBlockstream:mainfrom
Lagrang3:glcli-newaddr
Feb 25, 2026
Merged

glcli: new commands to test payments#670
cdecker merged 7 commits intoBlockstream:mainfrom
Lagrang3:glcli-newaddr

Conversation

@Lagrang3
Copy link
Copy Markdown
Collaborator

This PR adds simplified user commands to be able to get funds and open channels, as well as withdraw and close.

.await
.map_err(|e| Error::custom(e.message()))?
.into_inner();
println!("{:?}", res);
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you think it'd be possible to annotate the protobuf messages with a JSON serialization, allowing us to return a machine readable JSON object on stdout (and log to stderr) so that we can for example pipe it into jq for scripting? Just wondering if that's somethign that would be easy 🤔

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also, probably more of a follow-up than a blocker here.

@cdecker
Copy link
Copy Markdown
Collaborator

cdecker commented Feb 20, 2026

ACK 1fa46ea

(I know this is still a draft, but wanted to see what's changing :-) )

Replace call_raw with call_typed when creating a regular invoice in the
LSP invoice handler. This provides better type safety by using the
generated cln_rpc::model::requests::InvoiceRequest and
cln_rpc::model::responses::InvoiceResponse types.

Benefits:
- Compile-time type checking for request/response fields
- No manual hex decoding needed for payment_hash/payment_secret
- Access to created_index field from the response
- Cleaner code without custom request/response structs
@cdecker
Copy link
Copy Markdown
Collaborator

cdecker commented Feb 23, 2026

Actually, why is this in draft? Is there more to come or do you think we can just line this one up to be merged, and any followup work can be done in a followup PR?

@Lagrang3 Lagrang3 force-pushed the glcli-newaddr branch 2 times, most recently from 5e145ea to e9251a9 Compare February 24, 2026 11:43
@Lagrang3 Lagrang3 marked this pull request as ready for review February 24, 2026 11:49
@Lagrang3
Copy link
Copy Markdown
Collaborator Author

Actually, why is this in draft? Is there more to come or do you think we can just line this one up to be merged, and any followup work can be done in a followup PR?

Actually, why is this in draft? Is there more to come or do you think we can just line this one up to be merged, and any followup work can be done in a followup PR?

I wasn't sure about some things. I was also testing.
Now it's ready.

Signed-off-by: Lagrang3 <lagrang3@protonmail.com>
Signed-off-by: Lagrang3 <lagrang3@protonmail.com>
Signed-off-by: Lagrang3 <lagrang3@protonmail.com>
Signed-off-by: Lagrang3 <lagrang3@protonmail.com>
Signed-off-by: Lagrang3 <lagrang3@protonmail.com>
Signed-off-by: Lagrang3 <lagrang3@protonmail.com>
@ShahanaFarooqui ShahanaFarooqui force-pushed the main branch 3 times, most recently from 7185343 to 2fafe20 Compare February 24, 2026 18:53
@cdecker cdecker merged commit 699f48b into Blockstream:main Feb 25, 2026
16 checks passed
@Lagrang3 Lagrang3 deleted the glcli-newaddr branch February 25, 2026 17:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants