post https://api-sandbox.poweredbyibex.io/v2/invoice/add
Add invoice.
Fiat AmountIn some rare cases you will not be credited by the exact fiat amount inputted.
The fiat amount credited to your account will be the market value of the sats, calculated at the settlement time.
WebhookA best practice is to set a WebHookUrl and WebhookSecret when you create an Invoice.
This will allow us to notify you when the invoice is paid.The secret is used to make sure that we are triggering your WebHook.
When you receive the WebHook, make sure that the secret matches the one you gave us when creating the invoice.
Webhook BodyIf you set a WebHookUrl, this url will be called via a POST request with the following json body:
{
"hash": string,
"settledAtUtc": string,
"receivedMsat": int,
"webhookSecret": string,
"transaction": {
"id": string,
"createdAt": string,
"accountId": string,
"amount": float,
"networkFee": float,
"exchangeRateCurrencySats": float,
"currencyID": int,
"transactionTypeId": int,
"invoice": {
"hash": string,
"bolt11": string,
"preImage": string,
"memo": string,
"creationDateUtc": string,
"expiryDateUtc": string,
"settleDateUtc": string,
"amountMsat": int,
"receiveMsat": int,
"stateId": 1,
"state": {
"id": int,
"name": sting,
"description": string
}
}
}
}
Date example: "2022-11-09T21:33:47.48778Z"
Invoice stateCheck the invoice state table: invoice-states-table