Skip to Content
Podcasting2.org’s content is now powered by Markdown and open for contributions!

The ‘lnaddress’ Recipient Type

The lnaddress recipient type refers to a “Lightning Address ”, which is an email-like address used to resolve a recipient’s lnurlp and keysend details from “well-known” URIs.

The username and domain of the Lightning Address is used to construct the well-known URI, for example:

LNURLp

Provides information to request a BOLT11 invoice as defined by the LUD-06: payRequest spec .

{ "tag": "payRequest", "status": "OK", "callback": "https://example.com/lnurlp/johndoe/", "minSendable": 1000, "maxSendable": 16000000000, "metadata": "[[\"text/plain\",\"Pay johndoe\"],[\"text/identifier\",\"[email protected]\"]]", "commentAllowed": 200 }

See LUD-06  and LUD-12  for more details.

Keysend

Provides public key and custom data fields needed to send a keysend payment.

{ "status": "OK", "tag": "keysend", "pubkey": "0123456789abcdeffedcba9876543210123456789abcdeffedcba9876543210123", "customData": [ { "customKey": "696969", "customValue": "1" } ] }

Fields

  • tag - Indicates a “keysend” response
  • status - Status of response (either “OK” or “ERROR” with reason field)
  • pubkey - The public address of the lightning node that will receive the keysend payment.
  • customData - An array that contains routing info for the receiving node:
    • customKey - A text value that defines a routing key for the receiving node.
    • customValue - A text value that defines a routing value for the receiving node.

The customData array is optional for cases where the receiving node is a front-end for a multi-wallet system. In this context, the customKey will be what the receiving system looks up inside the payment in order to retrieve the customValue which is a virtual wallet identifier.