Commit graph

253 commits

Author SHA1 Message Date
ab19685a2a feat: implement automatic crediting of new accounts with 1 million satoshis
- Modified the user account creation process to automatically credit new
accounts with 1,000,000 satoshis upon creation.
- Updated the `create_user_account_no_ckeck` function to include error
handling and logging for the credit operation.
- Enhanced tests to verify the balance for newly registered users,
ensuring the correct credit amount is applied.
- Documented affected account creation paths and testing instructions in
the new `AUTO_CREDIT_CHANGES.md` file.

fix: pass db connection to update_wallet_balance to prevent SQLite deadlock

The auto-credit feature was causing a deadlock on SQLite because
update_wallet_balance was opening a new database connection while
already inside a transaction. By passing conn=conn, we reuse the
existing connection and avoid the deadlock.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-11 13:02:14 +01:00
Patrick Mulligan
8657e221c6 feat: add support for paying amountless BOLT11 invoices
Some checks are pending
LNbits CI / lint (push) Waiting to run
LNbits CI / test-api (, 3.10) (push) Blocked by required conditions
LNbits CI / migration (3.11) (push) Blocked by required conditions
LNbits CI / test-api (, 3.11) (push) Blocked by required conditions
LNbits CI / test-api (, 3.12) (push) Blocked by required conditions
LNbits CI / test-api (postgres://lnbits:lnbits@0.0.0.0:5432/lnbits, 3.10) (push) Blocked by required conditions
LNbits CI / test-api (postgres://lnbits:lnbits@0.0.0.0:5432/lnbits, 3.11) (push) Blocked by required conditions
LNbits CI / test-api (postgres://lnbits:lnbits@0.0.0.0:5432/lnbits, 3.12) (push) Blocked by required conditions
LNbits CI / test-wallets (, 3.10) (push) Blocked by required conditions
LNbits CI / test-wallets (, 3.11) (push) Blocked by required conditions
LNbits CI / test-wallets (, 3.12) (push) Blocked by required conditions
LNbits CI / test-wallets (postgres://lnbits:lnbits@0.0.0.0:5432/lnbits, 3.10) (push) Blocked by required conditions
LNbits CI / test-wallets (postgres://lnbits:lnbits@0.0.0.0:5432/lnbits, 3.11) (push) Blocked by required conditions
LNbits CI / test-wallets (postgres://lnbits:lnbits@0.0.0.0:5432/lnbits, 3.12) (push) Blocked by required conditions
LNbits CI / test-unit (, 3.10) (push) Blocked by required conditions
LNbits CI / test-unit (, 3.11) (push) Blocked by required conditions
LNbits CI / test-unit (, 3.12) (push) Blocked by required conditions
LNbits CI / test-unit (postgres://lnbits:lnbits@0.0.0.0:5432/lnbits, 3.10) (push) Blocked by required conditions
LNbits CI / test-unit (postgres://lnbits:lnbits@0.0.0.0:5432/lnbits, 3.11) (push) Blocked by required conditions
LNbits CI / test-unit (postgres://lnbits:lnbits@0.0.0.0:5432/lnbits, 3.12) (push) Blocked by required conditions
LNbits CI / migration (3.10) (push) Blocked by required conditions
LNbits CI / regtest (BoltzWallet, 3.10) (push) Blocked by required conditions
LNbits CI / regtest (CoreLightningRestWallet, 3.10) (push) Blocked by required conditions
LNbits CI / regtest (CoreLightningWallet, 3.10) (push) Blocked by required conditions
LNbits CI / regtest (EclairWallet, 3.10) (push) Blocked by required conditions
LNbits CI / regtest (LNbitsWallet, 3.10) (push) Blocked by required conditions
LNbits CI / regtest (LndRestWallet, 3.10) (push) Blocked by required conditions
LNbits CI / regtest (LndWallet, 3.10) (push) Blocked by required conditions
LNbits CI / jmeter (3.10) (push) Blocked by required conditions
codeql / analyze (push) Waiting to run
Add ability to pay BOLT11 invoices that don't have an embedded amount
by specifying the amount at payment time via the `amount_msat` parameter.

Changes:
- Add `Feature.amountless_invoice` to wallet base class for capability detection
- Update `Wallet.pay_invoice()` signature with optional `amount_msat` parameter
- Implement amountless invoice support in LND REST and LND gRPC wallets
- Update payment service layer to validate and pass through amount_msat
- Add `amount_msat` field to CreateInvoice API model
- Update all wallet implementations with new method signature
- Add tests for amountless invoice payment flow

Usage: POST /api/v1/payments with `amount_msat` when paying amountless invoices

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-09 19:43:50 +01:00
dni ⚡
132192bc94
test: add boltz fundingsource to regtest (#3677)
Co-authored-by: Vlad Stan <stan.v.vlad@gmail.com>
2025-12-22 09:23:46 +01:00
dni ⚡
5f86627eae
feat: improve on create wallet frontend and api. (BREAKING CHANGE) (#3635) 2025-12-08 11:09:43 +01:00
Vlad Stan
850087a8ec
[perf] Faster require invoice key (#3603) 2025-12-05 10:03:51 +02:00
Vlad Stan
5f1cfc0e37
[perf] send payment notifications in background (#3588) 2025-11-26 18:53:10 +01:00
dni ⚡
0f4ae5da86
feat: create wallet if user does not have one (#3566) 2025-11-25 16:18:45 +01:00
Vlad Stan
0910687328
[perf] pending payments check (#3565)
Co-authored-by: dni  <office@dnilabs.com>
2025-11-25 14:09:57 +02:00
dni ⚡
33e2fc2ea8
feat: move wallet.html to vue component. FINAL DynamicComponent pr (#3559) 2025-11-25 11:45:53 +01:00
Vlad Stan
d55e2a0e1f
[fix] user sorting performance (#3561) 2025-11-25 09:16:35 +02:00
Vlad Stan
7c7a04da9d
[feat] Payment labels (#3537) 2025-11-21 10:33:53 +02:00
Vlad Stan
39c33699af
[feat] user assets (#3504) 2025-11-12 14:30:27 +02:00
dni ⚡
e038ceb9be
refactor: lndrest get_payment_status and pay_invoice use api v2 (#3470)
Co-authored-by: Vlad Stan <stan.v.vlad@gmail.com>
2025-11-10 16:26:14 +01:00
dni ⚡
691b7ad055
refactor: lndgrpc, update grpcs file, use types and enums, LookupInvoiceV2 (#3469) 2025-11-10 15:07:00 +01:00
Vlad Stan
8755984bd8
[test] admin paths (#3494) 2025-11-10 12:00:55 +02:00
Ben Weeks
b54eedee84
feat: Shared Wallets/Joint Accounts (Issue #3297) (#3376) 2025-11-07 22:25:03 +02:00
dni ⚡
39ca9da870
feat: NWC use coincurve instead of secp (#3455) 2025-10-30 08:06:31 +01:00
dni ⚡
2b603bdc48
fix: add dependency-groups get rid of warning (#3454) 2025-10-29 15:59:31 +01:00
Vlad Stan
b9de754598
fix: exclude (soft) deleted wallets when creating an invoice (#3439) 2025-10-21 14:59:04 +03:00
dni ⚡
c312d70e63
fix: properly check outgoing payments in phoenixd (#3355) 2025-09-12 11:26:32 +02:00
dni ⚡
672a5b3a4d
fix: pay with nfc endpoint + add perform_withdraw (#3352) 2025-09-10 14:52:47 +02:00
Tiago Vasconcelos
ef371e303c
feat: allow creating/update user with nostr npub1 pubkey (#3298) 2025-08-21 16:35:23 +02:00
dni ⚡
5ba06d42d0
feat: use uv instead of poetry for CI, docker and development (#3325)
Co-authored-by: arcbtc <ben@arc.wales>
2025-08-21 16:17:19 +02:00
dni ⚡
ae6cf47244
feat: lud11 disposable and storeable payRequests. (#3317) 2025-08-19 11:33:57 +02:00
dni ⚡
c24d2f24cf
fix: bump lnurl its not callback_url now, its just url (#3312) 2025-08-18 09:18:11 +02:00
dni ⚡
a36ab2d408
feat: update lnurl lib refactor lnurl endpoints (#3271) 2025-07-17 17:03:44 +03:00
dni ⚡
65864cb216
chore: use modern websockets instead of legacy (#3278) 2025-07-17 15:02:29 +03:00
ziggieXXX
f91c933919
feat: HodlInvoices (Rebase) (#2869)
Co-authored-by: pseudozach <git@pseudozach.com>
Co-authored-by: dni  <office@dnilabs.com>
Co-authored-by: Vlad Stan <stan.v.vlad@gmail.com>
2025-07-15 11:15:14 +02:00
dni ⚡
256a8098c6
chore: get rid of mypy notes and typecheck more functions (#3257) 2025-07-15 11:15:12 +02:00
dni ⚡
35e2c4b0a7
fix: update success status (#3244)
Co-authored-by: Vlad Stan <stan.v.vlad@gmail.com>
2025-07-15 11:14:25 +02:00
dni ⚡
90ab642dcd
fix: phoenixd pending payments (#3075)
Co-authored-by: Vlad Stan <stan.v.vlad@gmail.com>
2025-07-15 11:14:16 +02:00
dni ⚡
ba0f7a01ef
chore: reduce max complexity lint (#3230) 2025-07-15 11:14:03 +02:00
dni ⚡
a16078a6ba
chore: update python packages + formatting + cleanup (#3221) 2025-07-08 10:17:27 +02:00
dni ⚡
c4c03d96a3
test: add regtest testcase for no route failure (#3189) 2025-07-08 10:17:25 +02:00
dni ⚡
b4b37cd733
fix: circular import on handle_fiat_payments (#3226) 2025-07-08 10:17:23 +02:00
Vlad Stan
695e9b6471
[feat] Add stripe payments (#3184) 2025-07-08 10:17:19 +02:00
Vlad Stan
c7b7832a88
feat: add external id for users (#3219) 2025-07-08 10:17:16 +02:00
blackcoffeexbt
edb7d66efc
feat: Add trimmed mean filtering for exchange rate outlier detection (#3206)
Co-authored-by: Vlad Stan <stan.v.vlad@gmail.com>
2025-06-25 13:16:00 +03:00
dni ⚡
6d2f39d390
fix: rounding errors on eclair total balance (#3196) 2025-06-24 16:09:53 +02:00
Vlad Stan
375b95c004
fix: allow ports for domains (#3171) 2025-05-26 11:35:02 +03:00
dni ⚡
34b8490a2d
test: conftest smaller funding amounts (#3167) 2025-05-20 11:25:08 +03:00
dni ⚡
cbbba5c4c7
fix: regtest nodemanager lndrest issue (#3166) 2025-05-20 09:23:59 +02:00
Vlad Stan
39e4fa724a
test: additional cases for internal payments (#3155)
Co-authored-by: dni  <office@dnilabs.com>
2025-05-13 13:48:47 +03:00
dni ⚡
3b350858c7
refactor: untangle lnd's macaroon encryption with AESCipher class (#3152) 2025-05-13 12:07:38 +02:00
Vlad Stan
3529f9152f
fix: better differentiation between UNAUTHORIZED and FORBIDDEN (#3139) 2025-05-05 10:55:58 +02:00
PatMulligan
51bf344d65
[FIX] Fix database compatibility issue in search query builder for payments filter (#3090)
Co-authored-by: dni  <office@dnilabs.com>
Co-authored-by: Vlad Stan <stan.v.vlad@gmail.com>
2025-05-02 10:45:35 +03:00
dni ⚡
c4d0540e76
feat: preimages for incoming payments, fundingsource saves preimage on create_invoice (#3085)
Co-authored-by: Vlad Stan <stan.v.vlad@gmail.com>
2025-04-30 11:03:19 +02:00
Vlad Stan
e339bb6181
[feat] fetch all payments for user (#3132) 2025-04-29 13:52:07 +03:00
Vlad Stan
6c2b312c92
fix: webhook call on invoice pay (#3119) 2025-04-28 12:28:27 +03:00
dni ⚡
883d52c303
fix: phoenixd uses sat instead of msat for pay_invoice (#3083) 2025-04-02 16:49:59 +03:00