Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat: lookup invoice (Alby + LND) #124

Merged
merged 8 commits into from
Aug 31, 2023
Merged

Feat: lookup invoice (Alby + LND) #124

merged 8 commits into from
Aug 31, 2023

Conversation

rolznz
Copy link
Contributor

@rolznz rolznz commented Aug 21, 2023

alby currently returns 404 for unsettled invoices

@bumi bumi requested a review from kiwiidb August 24, 2023 15:02
alby.go Outdated Show resolved Hide resolved
@rolznz rolznz changed the title Feat: lookup invoice (Alby API) Feat: lookup invoice (Alby + LND) Aug 29, 2023
Copy link
Contributor

@kiwiidb kiwiidb left a comment

Choose a reason for hiding this comment

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

Some minor improvements requested. Mainly I would not treat 404 in a special way unless there is reason to do this.

alby.go Outdated Show resolved Hide resolved
alby.go Outdated Show resolved Hide resolved
handle_lookup_invoice_request.go Outdated Show resolved Hide resolved

paymentHash := lookupInvoiceParams.PaymentHash

if (paymentHash == "") {
Copy link
Contributor

Choose a reason for hiding this comment

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

If I was the author of the NIP PR I would drop the payment_request parameter and mandate payment_hash. But not really related to this PR so OK.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Should we give feedback? this is the time to do it

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I think the user always has access to the payment hash, as long as the invoice was generated through NWC.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I asked in the PR.

handle_lookup_invoice_request.go Show resolved Hide resolved
handle_lookup_invoice_request.go Outdated Show resolved Hide resolved
@kiwiidb kiwiidb merged commit 7031614 into main Aug 31, 2023
2 checks passed
@kiwiidb kiwiidb deleted the feat/lookup-invoice branch August 31, 2023 08:54
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.

3 participants