makeInvoice
Request that the user creates an invoice to be used by the web app. This will return a BOLT-11 invoice. Invoices can be requested in a few forms:
By specifying an explicit
amount
, the user's provider should enforce that the user generate an invoice with a specific amountBy specifying a
minimumAmount
and / ormaximumAmount
, the user's provider should enforce that the user generate an invoice with an amount field constrained by that amountWhen an explicit
amount
is not set, the us
Amounts are denominated in satoshis. For large amounts, it's recommended you use a big number library such as bn.js or big.js as Javascript only supports 32 bit integers.
Method
Params
event
— requiredobject
amount
— optionalstring|number
the satoshis to senddefaultAmount
— optionalstring|number
minimumAmount
— optionalstring|number
maximumAmount
— optionalstring|number
defaultMemo
— optionalstring
Response
Example
Demo
Last updated