Skip to main content

Create lightning payment quote

Endpoint accepts idempotency-key header to prevent the same quote from being created twice. In case of a duplicate request, the error code DUPLICATE_PAYMENT_QUOTE containing the id of the original quote (paymentQuoteId) will be returned. The key should be a random v4 UUID to avoid false collisions.

Required scopes:

  • partner.payment-quote.lightning.create

Header Parameters
idempotency-key uuid
Request Body REQUIRED
lnInvoice string REQUIRED

Possible values: 1 ≤ length

LN invoice to pay.

sourceCurrency string

Possible values: [BTC, USD, EUR, USDT]

Currency to send from. Defaults to the user's default currency. If BTC is specified then amount.currency must also be BTC.

amount object

Amount to send if using zero amount invoice. Must be omitted otherwise. FeePolicy defaults to EXCLUSIVE.

amount string REQUIRED

Currency amount in decimal format

currency string REQUIRED

Possible values: [BTC, USD, EUR, USDT]

Currency code

feePolicy string

Possible values: [INCLUSIVE, EXCLUSIVE]

Should the fee be included in the amount or added on top of it.

Responses
200

Success

Schema OPTIONAL
lightningNetworkFee object OPTIONAL

The fee required by LN network

amount string

Currency amount in decimal format

currency string

Possible values: [BTC, USD, EUR, USDT]

Currency code

paymentQuoteId uuid

The payment quote's ID

description string OPTIONAL

The description forwarded from the related invoice

validUntil date-time OPTIONAL

The expiry timestamp

conversionRate object OPTIONAL

The conversion rate details

amount string

Currency amount in decimal format

sourceCurrency string

Possible values: [BTC, USD, EUR, USDT]

Source currency code

targetCurrency string

Possible values: [BTC, USD, EUR, USDT]

Target currency code

amount object

The amount that the receiver will receive in sender’s currency

amount string

Currency amount in decimal format

currency string

Possible values: [BTC, USD, EUR, USDT]

Currency code

totalFee object OPTIONAL

The total of all fees

amount string

Currency amount in decimal format

currency string

Possible values: [BTC, USD, EUR, USDT]

Currency code

totalAmount object

The amount that the sender will spend

amount string

Currency amount in decimal format

currency string

Possible values: [BTC, USD, EUR, USDT]

Currency code

reward object OPTIONAL

The reward that the sender might receive, if applicable

amount string

Currency amount in decimal format

currency string

Possible values: [BTC, USD, EUR, USDT]

Currency code