Add Invoice Restfully with a web hook

Changed on

Pay invoice.

post/invoice/rest/webhook

Request

  • Base URL
    https://ibexpay-api.ibexmercado.com
  • URL
    https://ibexpay-api.ibexmercado.com/invoice/rest/webhook
  • Auth
    API key in header Authorization

Request body

amountMsatinteger required

The account that will pay the invoice.bolt11

bptIdstring required
webhookUrlstring required

A POST will be made at this Url when the invoice is paid. { "secret":"", "transaction": { { id: 6125, invoiceHash: "", createdAtUtc: "", settledAtUtc: "", amountMsat: 3000, receivedMsat: 2985, feeProcessMsat: 15, tag: null, accountId: "", bptId:"", isPaid:false, splitBitcoinPercentage:100 } } }

webhookSecretstring

Secure the web hook call with a secret (optional)

memostring

(Optional) Maximum 50 chars

expirationinteger

(Optional) Expiration time in seconds. Default 900 seconds. The expiration time has to be between 30 and 900 seconds, if it's not in this range the closest limit is used.

Response

200

bolt11string
hashstring
expirationUtcinteger

Example response

{
  "bolt11": "lnbc30n1p3g9nnupp5wc2rajylggck2xrr07mxkecgh4nnh5ychcaa2fsek4xjapthhl3sdqqcqzpgxqzuysp569ghfxsztc8xwz2vl8vakulzz3ylntav59rd730fle5xs5v05yws9qyyssqkf2zka8a2l74zapl9vnawdf0qrgd8r973ume5za6a5enegrke4az53ze9tln57vj82fse38s3a9vvsk85aytr7de024pwut4cqxmdecprhs452",
  "hash": "76143ec89f42316518637fb66b6708bd673bd098be3bd52619b54d2e8577bfe3",
  "expirationUtc": 1652740608
}

Changes