Skip to main content
author: fiatjaf author: lafaire discussion: https://t.me/lnurl/9729

balanceNotify

This optional property works together with balanceCheck to make it instant. It works as follows:
  • If LN SERVICE supports balanceCheck, then LN WALLET may decide to send an query-string-encoded HTTP URL along with the payment request when first making a withdrawal.
  • LN SERVICE may store that URL and make a blank HTTP POST call to it the next time the given user has a balance in its account on the service.
  • Upon receiving that HTTP POST, the wallet may decide to perform a balance check and withdraw the funds immediately.
  • The scheme works for custodial wallets, Lightning nodes that have a domain name and an always-online online presence, and also for noncustodial mobile wallets that have a friendly server online that is able to receive that HTTP POST and notify them somehow.
The callback URL sent by the WALLET is modified as follows:
-<callback><?|&>k1=<k1>&pr=<lightning invoice>
+<callback><?|&>k1=<k1>&pr=<lightning invoice>&balanceNotify=<URL>