Create a lightning invoice


This API call is used to create a new lightning invoice which can be used for requesting and receiving payments over the lightning network.

Path Parameters

  • walletIdstringRequired
    Example: "59cd72485007a239fb00282ed480da1f"
    Pattern: ^[0-9a-f]{32}$

Request Body

value number required
The value of the invoice in satoshis
Example: 50000
memo string
A memo or description to include in the invoice
Example: Latte macchiato
expiry number
The number of seconds before the invoice expires
Default: 3600

200 Response

invoice string
The BOLT \#11 encoded invoice
Example: lnbc500n1p3zv5vkpp5x0thcaz8wep54clc2xt5895azjdzmthyskzzh9yslggy74qtvl6sdpdg3hkuct5d9hkugrxdaezqjn0dphk2fmnypkk2mtsdahkccqzpgxqyz5vqsp5v80q4vq4pwakq2l0hcqgtelgajsymv4ud4jdcrqtnzhvet55qlus9qyyssquqh2wl2m866qs5n72c5vg6wmqx9vzwhs5ypualq4mcu76h2tdkcq3jtjwtggfff7xwtdqxlnwqk8cxpzryjghrmmq3syraswp9vjr7cqry9l96
paymentHash string
The payment hash of the invoice
Example: 63d9ce82e09d16761a85116ed8b65407db4fb22f85d03573de09c480f2c6d175
value number
The value of the invoice in satoshis
Example: 50000
memo string
A memo or description for the invoice
Example: Latte macchiato
expiresAt string
ISO-8601 string representing when the invoice will expire
Example: 2022-04-01T18:46:24.677Z
status string
The status of the invoice
Allowed values: open settled canceled
walletId string
The wallet to which this invoice belongs
Example: 59cd72485007a239fb00282ed480da1f
Match pattern: ^[0-9a-f]{32}$

400 Response

One of
error string required
Human-readable error message
requestId string required
Client request id
context object
Properties that apply to a specific error name
name string required
Error code