Commit graph

19 commits

Author SHA1 Message Date
Adithya Vardhan
0c421375e5
chore: update to use sat/msat suffixes everywhere (#2271)
* chore: align internal models and methods to use sat/msat suffixes

* chore: update request structs to use sat/msat suffixes

* fix: default max amount to 0 during app creation

* fix: simplify helper functions

* chore: remove unused lnclient probing methods

* chore: remove unused json tags on swap struct

* chore: update frontend to use sat/msat suffixes everywhere

* chore: use request types in frontend

* fix: linting

* fix: remove deprecated sat and msat fields in frontend

* chore: further changes

* fix: avoid sat/msat resolver variable shadowing

* fix: validate Support Alby amounts
2026-05-01 15:41:56 +05:30
Adithya Vardhan
b1bd7c2587
feat: track last settled transaction time for apps (#2214)
* feat: track last settled transaction time for apps

* fix: use default subwallet ordering and app_id logging in event handler

* chore: rename to last_settled_transaction_at and remove last tx migration

* chore: split app settlement update and budget check

* chore: extract app display name helper into utils function
2026-04-09 16:26:45 +05:30
Roland
16eff34b8a
feat: track forwards to display on a home page widget (#1623)
* feat: track forwards to display on a home page widget

* fix: test

* chore: improve copy

* feat: configure PPM routing fees
2025-08-21 16:39:03 +05:30
fmar
fc5aa1853e
feat: autoswaps using xpubs (#1575)
* feat: autoswaps using xpubs

* fix: rollback hour to minute change

* fix: remove unused

* fix: cleanup

* fix: improve flow control

* fix: simplify checks

* fix: use usedXpubDerivation bol

* feat: bump xpub index only on successful swap (#1609)

- add bool used_xpub to swap table
- fix reading empty autoswap xpub index start from config

---------

Co-authored-by: Roland Bewick <roland.bewick@gmail.com>
Co-authored-by: Roland <33993199+rolznz@users.noreply.github.com>
2025-08-15 17:24:00 +07:00
Roland
fe2a345651
feat: add app last used time (#1498)
* feat: add app last used time

* chore: use app last used instead of fetching last event

* chore: rename last_used to last_used_at, remove unused code

* fix: prettier
2025-07-14 15:26:29 +07:00
Adithya Vardhan
a1eaa63eed
Swaps improvements (shifting to standalone page + one-time swaps) (#1371)
* chore: move out swaps from settings

* chore: link to swaps in wallet and node page

* chore: add frontend for swap ins

* chore: update all swap redirects

* chore: remove swap dialogs

* chore: remove auto swap-ins frontend

* feat: add support for one time swap outs

* chore: remove unused code

* chore: use separate endpoint for one off swap outs

* chore: further changes

* chore: separate one off and auto swaps

* chore: naming changes

* fix: tests

* feat: add one off swap in

* feat: add auto swap ins

* chore: remove comments

* fix: tests

* chore: further changes

* chore: further changes

* chore: rename to swap in and swap out

* chore: do not show swaps for non LDK/LND users

* chore: add receive limit checks for swap ins

* chore: remove probing

* chore: dark mode

* fix: swap link

* chore: add extra swap links

* fix: fee rates log

* fix: fee rates log

* chore: color changes

* Feat: swap out improvements (#1403)

* feat: swap out improvements

- add lockup transaction id to hold payment metadata
- return swap ID and payment hash in swap out response
- retries to get fee rates
- separate swap out success page with status

* chore: rename

* chore: show current balance on swap out form

* chore: add pulse animation to badge while pending

* chore: minor typo

* chore: update fee rate retry interval to 10 seconds

* chore: use icons instead of badges

---------

Co-authored-by: im-adithya <imadithyavardhan@gmail.com>

* chore: update comment

* chore: remove comment

* chore: update boltz client to v2.6.1

* feat: swap in improvements (WIP) (#1411)

* feat: swap in improvements (WIP)

* feat: new swap in status page

* fix: hide pay button when already paid

* chore: improve swap in UI

* chore: more swap in ui improvements

* chore: minor improvements and fixes

* fix: typo

* feat: add swap in refund logic in case of failure

* fix: tests

* chore: add swap expired case for refunds

---------

Co-authored-by: im-adithya <imadithyavardhan@gmail.com>

* feat: add swaps table (#1419)

* feat: add swaps table

* fix: test

* chore: bump LDK-node to v0.6.0 (#1418)

* [Freepilot] fix: startup error handling (#1413)

* fix: handle errors from service.NewService() in startup code

Previously, both HTTP and Wails startup code ignored errors from
service.NewService(ctx) using blank identifier (_), which could
cause panics later if NewService fails (e.g., unable to connect
to postgres database).

Now properly handle the error and exit gracefully with a fatal
log message when service initialization fails.

* fix: compile error

---------

Co-authored-by: Roland Bewick <roland.bewick@gmail.com>

* feat: add hd key derivation

* Chore: add albyhub region cookie to developer page (#1421)

* docs: add AlbyHub-Region cookie instructions to developer page

* fix: use region from alby api

---------

Co-authored-by: achaldps@gmail.com <achaldps@gmail.com>

* build(deps): bump golang.org/x/crypto from 0.38.0 to 0.39.0 (#1415)

Bumps [golang.org/x/crypto](https://github.com/golang/crypto) from 0.38.0 to 0.39.0.
- [Commits](https://github.com/golang/crypto/compare/v0.38.0...v0.39.0)

---
updated-dependencies:
- dependency-name: golang.org/x/crypto
  dependency-version: 0.39.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* build(deps): bump gorm.io/driver/sqlite from 1.5.7 to 1.6.0 (#1416)

Bumps [gorm.io/driver/sqlite](https://github.com/go-gorm/sqlite) from 1.5.7 to 1.6.0.
- [Commits](https://github.com/go-gorm/sqlite/compare/v1.5.7...v1.6.0)

---
updated-dependencies:
- dependency-name: gorm.io/driver/sqlite
  dependency-version: 1.6.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* build(deps): bump github.com/btcsuite/btcd/btcec/v2 from 2.3.4 to 2.3.5 (#1417)

Bumps [github.com/btcsuite/btcd/btcec/v2](https://github.com/btcsuite/btcd) from 2.3.4 to 2.3.5.
- [Release notes](https://github.com/btcsuite/btcd/releases)
- [Changelog](https://github.com/btcsuite/btcd/blob/master/CHANGES)
- [Commits](https://github.com/btcsuite/btcd/compare/btcec/v2.3.4...btcec/v2.3.5)

---
updated-dependencies:
- dependency-name: github.com/btcsuite/btcd/btcec/v2
  dependency-version: 2.3.5
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* feat: allow setting LDK node alias (#1398)

* feat: add node alias customization for LDK nodes with public channels

- Add new NodeAlias field to InfoResponse in API
- Add SetNodeAlias method to API with config storage
- Add HTTP endpoint POST /node/alias for setting node alias
- Add corresponding Wails endpoint support
- Create new Node settings page in frontend
- Add conditional navigation item for LDK nodes with public channels
- Include upgrade dialog and paid subscription check
- Display success message prompting node restart after alias change
- Show error toast for non-paid users attempting to change alias

* chore: use node alias from config in LDK init

* fix: make upgrade button non-absolute, remove disabled attribute

* chore: move node alias page to be consistent with other node management pages

* chore: remove redundant comment

* chore: show upgrade dialog when clicking node alias option, show also for private channels

---------

Co-authored-by: Roland Bewick <roland.bewick@gmail.com>

* fix: always pass in fee and handle mempool errors (#1408)

* fix: always pass in fee and handle mempool errors

* chore: improve withdraw on-chain funds UI

---------

Co-authored-by: Roland Bewick <roland.bewick@gmail.com>

* feat: derive keys from id and add fields to swap table

* feat: use bip 85 to derive swap mnemonic

* chore: mark swaps as failed if payment fails

* feat: add process refund method for swap ins

* chore: add process refund to swap service interface

* feat: add frontend

* fix: swap out failure message

* feat: add process refund button in swap in status screen

* chore: further improvements

* fix: wails routes

* feat: add frequency selector for ZapPlanner payments (#1312) (#1317)

* feat: add frequency selector for ZapPlanner payments (#1312)

* feat: add frequency selector for ZapPlanner payments (#1312) +corrections

* feat(zapplanner): add USD/BTC selector and frequency option

Budget renewal still has to be adjusted

* feat(zapplanner): set default frequency to 1 month

* feat(zapplanner): set default amount to usd and added (sats) to clarify BTC unit

* feat(zapplanner): convert months to days for subscriptions

* feat(zapplanner): add open to convertCurrency deps to allow consecutive subscriptions

* feat(Zapplanner freq&currency selector): added all currencies to the selector

* feat(Zapplanner freq&currency selector): removed bug about 2xBTC(sats) on the menu

* feat(zapplanner): frequency & currency all comments addressed

* chore: zapplanner fixes

- currency sorting
- sats currency usage for ZapPlanner
- force whole values for ZapPlanner
- pass correct currency to ZapPlanner
- rename field
- fix input width

---------

Co-authored-by: jpl-btc <>
Co-authored-by: Roland Bewick <roland.bewick@gmail.com>

* chore: add reconnection logic

* chore: specify fees while locking btc

* fix: do not use context background

* chore: improve auto swaps frontend

* chore: add boltz logo to tx item

* Updated Primal app connection (#1428)

* Updated Primal app connection

* fix: lint

---------

Co-authored-by: René Aaron <rene@twentyuno.net>

* chore: bump uniffi-bindgen-go and revert error handling in the LDK client (#1434)

* chore: revert error handling in the LDK client

* chore: update ldk-node-go dependency

---------

Co-authored-by: Roland Bewick <roland.bewick@gmail.com>

* Read.me adjustments (#1440)

* Update README.md

1) We spend a lot of time helping users to fix their problems with Raspi PIs.
2) Computers that are offline regularly create a bad UX because payments in external apps do not work and channels are closed earlier.

* Update README.md

* feat: add expired state to nip47 transactions (#1441)

* fix: use custom mempool url (#1431)

* fix: use custom mempool url

* chore: return mempool url in info endpoint

* chore: use mempool url from info response in frontend

* chore: remove default mempool url in frontend

* fix: tests

* feat: add LDK bitcoind rpc chain source (#1367)

* feat: add LDK bitcoind rpc chain source

* fix: crash in bitcoindrpc due to not enabling continuous sync

* chore: renaming

* chore: mark swap status as failed

* chore: use mempool url from info

* chore: poll balances on node page

* fix: when opening outbound channel, extract host part if full peer connection url is pasted

* chore: use mempool url from backend info endpoint

* docs: add boltz regtest setup instructions

* chore: separate swap in and out status pages

* fix: remove duplicate useInfo

* fix: mnemonic derivation logic

* chore: address comments

* chore: add tests for swap mnemonic generation

* chore: add refunded state

* chore: rename columns

* chore: simplify swap status frontend

* chore: mark swap out as successful after claim tx conf

* chore: add address to refund

* fix: wails

* feat: add resubscription

* chore: add logging

* chore: save refund address to db and use new address

* chore: add comment

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: Roland <33993199+rolznz@users.noreply.github.com>
Co-authored-by: Freepilot <215356755+freepilot-bot@users.noreply.github.com>
Co-authored-by: Roland Bewick <roland.bewick@gmail.com>
Co-authored-by: achaldps@gmail.com <achaldps@gmail.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Nodii <13803869+NodeDiver@users.noreply.github.com>
Co-authored-by: Moritz Kaminski <moritz.kaminski@gmail.com>
Co-authored-by: René Aaron <rene@twentyuno.net>
Co-authored-by: Roman D <roman@dmitrienko.com>

* chore: rename to receive_amount

* chore: remove auto swap success and add boltz link

* chore: use constant and rename variables

* fix: mark swaps as failed

* fix: show receive amount in swap in success screen

* chore: remove duplicate endpoint and reorder

* chore: add comment in wails handler

* chore: use markSwapState

* chore: add retries

* fix: use one websocket per swap

* chore: frontend fixes

* feat: add swap mnemonic to debug tools

* fix: tx list

* fix: tests

* chore: further changes

* chore: improve copy

* chore: improve copy

* chore: improve copy

* chore: rename, add autofocus on swap inputs

* fix: swap in failed state when no lockup tx exists

* chore: add interval note to active swap component

* chore: remove boltz image

* chore: use hasChannelManagement check

* chore: use link instead of navigate

* chore: mark swaps as failed in case of errors

* chore: add comment

* chore: only mark swaps as failed in defer function

* chore: improve copy

* chore: update boltz client to v2.7.2

* chore: use refundSwapRequest param

* fix: refund swap method

* chore: minor changes

* chore: add retries

* chore: add retries and use single ws connection for pending swaps

* fix: swap fee error message

* chore: remove sending partial signature in swap in

* chore: log error when update channel is not ok

* fix: add tx claimed state in swap in listener

* chore: add nwc_swap_succeeded to whitelist and readme

* feat: use single boltz ws connection

* chore: only check for tx claimed state

* chore: use lock while sending updates

* chore: handle boltz update error

* chore: remove swap id from success event

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: Roland Bewick <roland.bewick@gmail.com>
Co-authored-by: Roland <33993199+rolznz@users.noreply.github.com>
Co-authored-by: Freepilot <215356755+freepilot-bot@users.noreply.github.com>
Co-authored-by: achaldps@gmail.com <achaldps@gmail.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Nodii <13803869+NodeDiver@users.noreply.github.com>
Co-authored-by: Moritz Kaminski <moritz.kaminski@gmail.com>
Co-authored-by: René Aaron <rene@twentyuno.net>
Co-authored-by: Roman D <roman@dmitrienko.com>
2025-07-10 20:06:12 +07:00
frnandu
04fc9c90dc
feat: add hold invoices support for LND & LDK (#1298)
* feat: add LND hold invoices support

* fix: add HOLD_INVOICE_ACCEPTED_NOTIFICATION to notifications list returned by get_info

* fix: revert

* fix: remove unneeded null checks

* docs: add extra event type to README

* feat: add LND hold invoices support

* fix: add HOLD_INVOICE_ACCEPTED_NOTIFICATION to notifications list returned by get_info

* fix: revert

* fix: remove unneeded null checks

* docs: add extra event type to README

* fix: remove 0 expiry checking in the make_hold_invoice_controller

* fix: use JSON logging

* revert fly.toml

* fix: duplicated check

* fix: move publishing nwc_hold_invoice_accepted out of the transaction

* fix: move publishing nwc_hold_invoice_accepted out of the transaction

* fix: check the invoice state ACCEPTED before calling the lnClient.SettleHoldInvoice

* fix: check the invoice state ACCEPTED before calling the lnClient.SettleHoldInvoice

* fix: check the invoice state ACCEPTED before calling the lnClient.SettleHoldInvoice

* fix: check the invoice state ACCEPTED before calling the lnClient.SettleHoldInvoice

* fix: cancel hold invoice tests

* fix: make hold invoice tests

* fix: make hold invoice tests

* fix: settle hold invoice tests

* fix: resubscribe to pending hold invoices

* fix: missing WatchHoldInvoice
 in the mocks

* feat: add LDK impl

* fix: cleanup

* fix: payment_hash

* fix: remove unneeded update

* feat: add support for self payments for hold invoices (#1304)

Co-authored-by: frnandu <frnandu@gmail.com>

* fix: remove hold invoices scope

* fix: remove hold invoices scope

* fix: mock hold bolt11 expiry to 10 years

* fix: sleep 1 second to give a change of lookupinvoice to read cancelled

* fix: missing timeout param

* feat: add hold invoice settle deadline to transactions (#1324)

* chore: update mockery, remove unused hold invoice method

* chore: remove unnecessary comment

* chore: remove unused code

* fix: do not return hold transaction if lookup failed

* chore: remove unused code

* fix: return correct errors from nip47 controllers, remove unused code

* fix: failing test

* chore: remove unnecessary code

* fix: make error message more general

* chore: remove unused code

* fix: use correct context in lnd service

* fix: unstable hold payments test

---------

Co-authored-by: Roland Bewick <roland.bewick@gmail.com>
Co-authored-by: Roland <33993199+rolznz@users.noreply.github.com>
2025-05-26 16:51:23 +07:00
frnandu
5fdc803f7a
feat: app child key derived from wallet master key (#736)
* feat(appwalletKey): add GetBIP32ChildKey

* feat: fix interface

* feat: adding subscription WiP

* feat: handle nostr subscriptions for lifecycle of apps

* Delete .idea/.gitignore

* Delete .idea/hub.iml

* Delete .idea/modules.xml

* Delete .idea/vcs.xml

* fix: remove unnecessary

* fix: missing handling legacy app

* fix: review fixes

* fix: use app.ID for key calculation instead of passing in event

* fix: add TODO

* fix: remove unnecessary check

* fix: improve err handling and remove check

* chore: store master nostr key to avoid deriving each time

* chore: rename app nostr_pubkey to app_pubkey, extract app consumers into separate files

* chore: finish renaming

* fix: update app wallet pubkey on app creation

* fix: not NULL check

* fix: fix HandleEvent

* fix: error handling

* fix: error handling

* fix: move StartSubscription to start.go

* fix: remove duplicated error check

* fix: make tests use AppsService for creating apps

* chore: remove unused code

* chore: minor event handler improvements

- fix error code response when failing to update request event
- fix log content when failing to decrypt request event
- move logging of app to correct place

* fix: add event_handler tests for legacy app

* chore: add comment about legacy apps in deleteAppConsumer

* fix: remove unused app from tests

* fix: error handling in startAppWalletSubscription

* fix: only create event info and nostr subscription for master key if there are legacy apps

* fix: add legacy tests

* fix: move fetching of Nip47 event info to deleteAppConsumer

* fix: fixed arguments

* fix: use require instead of assert

* fix: adapt GetAppWalletKey to use DeriveKey with path 1'

* fix: for backends that don't use a mnemonic, create appKey from nostrSecretKey

* fix: cleanup eventPublisher Subscribers when relay reconnects

* fix: bip32.FirstHardenedChild + appID

* fix: remove unused env vars

* fix: generate new mnemonic if empty

* fix: add tests.CreateTestServiceWithMnemonic to fix TestEncryptedBackup

* fix: handle both relay and main ctx Done

* chore: add keys tests

* chore: add extra assertions to keys test

* chore: log when legacy app subscription is created

* chore: remove unnecessary break

* chore: add log when relay is successfully connected

* fix: only auto-start node if it has been started before

---------

Co-authored-by: Roland Bewick <roland.bewick@gmail.com>
2024-11-07 19:06:01 +07:00
Roland
731d248129
feat: increase isolated app balance (#710) 2024-10-28 13:29:34 +07:00
Roland
d257437919
feat: add uncle jim internal app (#557)
* feat: add uncle jim internal app

* fix: wrong number in instructions

* chore: simplify alby jim internal app copy

* Feat: app metadata (#570)

* chore: wg.Add() before go (#559)

* chore: code cleanup (#558)

* Update README.md

Add command to make the install script executable in the instructions.

* feat: add migration card in wallet screen (#555)

* feat: add migration card in wallet screen

* chore: transfer funds if channel exists

* chore: typo

* chore: improve copy

* chore: add transfer funds button

* fix: remove duplicate icon

---------

Co-authored-by: Roland Bewick <roland.bewick@gmail.com>

* chore: run extra workflows on PR (#563)

* chore: run extra workflows on PR

* fix: pull request workflows

* build(deps): bump github.com/nbd-wtf/go-nostr from 0.34.5 to 0.34.10 (#551)

Bumps [github.com/nbd-wtf/go-nostr](https://github.com/nbd-wtf/go-nostr) from 0.34.5 to 0.34.10.
- [Commits](https://github.com/nbd-wtf/go-nostr/compare/v0.34.5...v0.34.10)

---
updated-dependencies:
- dependency-name: github.com/nbd-wtf/go-nostr
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* build(deps): bump gopkg.in/DataDog/dd-trace-go.v1 from 1.66.0 to 1.67.0 (#552)

Bumps gopkg.in/DataDog/dd-trace-go.v1 from 1.66.0 to 1.67.0.

---
updated-dependencies:
- dependency-name: gopkg.in/DataDog/dd-trace-go.v1
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* fix: do not render 0 on withdraw onchain funds page when reserve balance is 0 (#549)

* chore: update fly default kill timeout to ensure app gracefully shuts down (#547)

* feat: app metadata

* fix(wails): parse max length in log output endpoint (#568)

* fix: alby account image and name on transaction list

* fix: vertically center transaction item content

* fix: use slashed zero on wallet balance

* chore: align app image with app name in transaction list

* fix: ensure auth with correct user if refresh token expires (#572)

* fix: do not allow editing name of Alby Account connection

* fix: change "Create Wallet" to "Create Subaccount"

* fix: subaccount copy

* chore: update friends and family app icon

* fix: update app store images (#574)

* fix: update app store images

* chore: update paper scissors hodl and zapplanner icons

* chore: update lume and habla news icons

* chore: resize and compress zapplanner and rps logos

---------

Co-authored-by: Roland Bewick <roland.bewick@gmail.com>

* feat: add new auto channel flow that works with existing channels (#556)

* feat: add new auto channel flow that works with existing channels

* chore: remove "first" from auto channel copy

* feat: new transaction list item design

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: Matjaž Lipuš <matjazl@gmail.com>
Co-authored-by: BtcPins <pardus79@gmail.com>
Co-authored-by: Michael Bumann <hello@michaelbumann.com>
Co-authored-by: Adithya Vardhan <imadithyavardhan@gmail.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* fix: copy

* fix: less detailed icon for uncle jim app

* fix: shorten app description

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: Matjaž Lipuš <matjazl@gmail.com>
Co-authored-by: BtcPins <pardus79@gmail.com>
Co-authored-by: Michael Bumann <hello@michaelbumann.com>
Co-authored-by: Adithya Vardhan <imadithyavardhan@gmail.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: René Aaron <rene@twentyuno.net>
Co-authored-by: René Aaron <100827540+reneaaron@users.noreply.github.com>
2024-09-02 17:40:34 +07:00
Roland
5f1b0decdf
feat: move events to transactions service (#510)
* feat: move events to transactions service (WIP)

* fix: tests

* chore: improve quota exceeded error message

* fix: list transactions offset

* fix: add nwc_permission_denied events in transactions service

* fix: check for duplicate payment

* fix: unstable test

* chore: add payment settled tests

* fix: tests race condition

* fix: internal keysend support

* chore: add tests for check unsettled transactions fallback

* chore: add extra tests

* chore: extra tests

* fix: pass metadata in keysend self payments

* fix: throw error if transaction is already marked as sent

* fix: mark transaction settled

* fix: consume events in alby oauth service

* chore: add TODOs

* fix: do not fire duplicate failed payment events

* docs: add basic architecture docs to readme
2024-08-23 11:52:47 +07:00
Adithya Vardhan
67ca173261
feat: show tlv records in transaction popup (#365)
* feat: show tlv records in transaction popup

* chore: add podcastinginfo component

* chore: remove ? in podcasting info component

* chore: decode tlv record values in backend

* chore: add backup for tx description

* feat: add boostagram column and use jsonb in metadata

* chore: do not modify metadata while parsing

* chore: combine boostagram and metadata migration

* feat: extract description from custom records

* chore: fix keysend tests

* chore: change metadata param type in makeinvoice

* chore: fix make invoice tests

* chore: metadata fixes

* fix: boostragram and metadata migration

- only migrate values that are non-empty
- wrap in db transaction

* chore: set metadata json column to null if empty

* fix: remove jsonb from migration

* chore: code cleanup, rename api models, fix metadata usage

* fix: metadata format

* chore: remove unused contant

* fix: tests

* chore: improve tests

---------

Co-authored-by: Roland Bewick <roland.bewick@gmail.com>
2024-08-09 22:30:49 +07:00
Roland
f63429f5e5
chore: add transaction indexes, make fees non-nullable (#305) 2024-07-22 11:45:11 +07:00
Roland
1391119eb9
Feat: dynamic budgets (#226)
* feat: add transactions table

* feat: add transactions service with makeinvoice method

* feat: use internal transactions WIP

* feat: check unsettled transactions

* feat: use transactions service in nip47 package WIP

* feat: use transactions service in NIP-47 handlers

* fix: transaction list colors

* fix: tests

* chore: remove old payments table

* fix: return budget usage as sats

* feat: use internal transactions table for keysend payments

* feat: consume nwc_payment_received event in transaction service (WIP)

* feat: update existing transaction from nwc_payment_received event in transactions service

* feat: update existing transaction from nwc_payment_sent event in transactions service

* feat: handle async payment failed events in transactions service

* fix: tests

* feat: correctly implement NIP-47 NOT_FOUND error code

* feat: intercept self payments

* feat: isolated balance and visibility

* feat: validate keysend payment does not exceed app internal balance

* feat: budget check in transactions service, correctly pass payment errors to NIP-47 response

also reduce query duplication

* fix: order transactions when looking up transaction

* feat: add fee reserves to unsettled outgoing transactions

* chore: rename app permissions max amount field

* chore: rename transaction amount values to be clearly millisats

* chore: merge balance type and visibility into isolated property on apps table

* chore: move duplicated permission check from nip-47 controllers to handler

* fix: app name in transaction list

* Feat: permissions revamp v2 (#273)

* feat: revamp permissions component

* chore: changes

* chore: changes

* chore: add view mode for show app screen

* chore: further changes

* feat: new illustration for linking account (#254)

* feat: new illustration for linking account

* fix: update paths

* fix: icon props (#256)

* fix: use date from frontend

* chore: add expiryselect component

* chore: further changes

* chore: further changes

* chore: add date-fns for date picker

* chore: further changes

* chore: further changes

* fix: add central LDK gossip node to help gossip new public channels (#262)

* fix: make dialog responsive (#258)

* chore: further changes

* typo

* chore: spacing issues

* chore: use scopes from capabilities

* chore: change scope type descriptions

* chore: styling fixes

* chore: fix typings

* chore: budget renewal component

* fix: LDK mark channel as inactive and show error if counterparty forwarding info missing (#267)

fix: mark channel as inactive and show error if counterparty forwarding info missing

* chore: remove unnecessary dark classes (#255)

* fix: links to open first channel in sidebar and onboarding checklist (#268)

* feat: improve migrate node UI (#269)

* fix: migrate node copy (#270)

* fix: stop nostr when app is shutdown and use context to stop lnclient (#271)

* fix: permissions revamp WIP

* feat: basic isolated apps UI

* fix: new app connection, edit app connection, deep linking

---------

Co-authored-by: im-adithya <imadithyavardhan@gmail.com>
Co-authored-by: René Aaron <100827540+reneaaron@users.noreply.github.com>
Co-authored-by: Michael Bumann <hello@michaelbumann.com>

* fix: make transactions table ID autoincrement

* fix: do not send unrelated notifications to isolated apps

* fix: nip-47 notifications not receiving updated transaction state

* fix: migrate existing tables to have autoincrementing primary keys (#274)

* fix: migrate existing tables to have autoincrementing primary keys

* fix: recreate request and response event tables after apps

* fix: remove null from request_events app_id

* fix: do not crash when reloading app created page

* chore: update pragma commands, add busy_timeout

* fix: remove unnecessary migration of user_configs table

* chore: update comment on autoincrement migration

* feat: sqlite database config improvements

* fix: autoincrement migration to delete unlinked app permissions

* chore: update tests for dynamic budgets (WIP)

* fix: get balance tests

* chore: add extra event handler tests

* chore: add extra event handler test

* chore: add extra multi_pay_invoice tests

* chore: transactions service tests (WIP)

* chore: add transactions service payment tests

* chore: add tests for self payments

* fix: notifications tests

* chore: add notifications tests for transactions service

* chore: add fee reserve tests for transactions service

* chore: add list transactions tests

* chore: add keysend tests for transactions service

* feat: subscribe for payments and invoices (#281)

* fix: db transaction should be passed as pointer

* feat(lnd): subscribe for payments and invoices

* chore: rearrange check for settled

* chore: remove TODO

* chore: retry on error and add select

* chore: publish payment failed event

* chore: use json logging

* feat: add lnd notification types

* chore: remove sleep

* fix: incorrect key on transaction list items

* fix: test

* fix: disable isolated app type on non-supported backends

---------

Co-authored-by: im-adithya <imadithyavardhan@gmail.com>
Co-authored-by: René Aaron <100827540+reneaaron@users.noreply.github.com>
Co-authored-by: Michael Bumann <hello@michaelbumann.com>
2024-07-19 23:30:22 +07:00
Roland
12412ff399
feat: backend-specific capabilities (#508)
Co-authored-by: Adithya Vardhan <imadithyavardhan@gmail.com>
2024-07-01 20:30:40 +07:00
Roland
d06b421769
Split service into packages (#435) 2024-06-17 19:42:09 +07:00
Adithya Vardhan
8bc5539585
chore: add migration to remove content (#392)
Co-authored-by: Roland Bewick <roland.bewick@gmail.com>
2024-06-06 16:35:59 +07:00
Michael Bumann
36fe4f5490
Store decrypted request method and content data (#359) 2024-06-04 17:30:56 +03:00
Roland
073d669e03
Refactor: API cleanup (#338) 2024-05-30 00:06:06 +07:00