API
Invoices
Update Invoice
1min
Update an invoice by ID, all invoice attributes can be updated when the status is "initiated"
, for any other status; you can update the metadata object only.
PUT
Request
Path Params
id
String
required
the invoices unique ID
Body Parameters
amount
String
optional
Amount intended to be collected by this payment. A positive integer represents how much to charge in the smallest currency unit (e.g., 100 Halala to charge 1.00 SAR or 100 to charge ¥100, a zero-decimal currency). The minimum amount is 1 SAR or equivalent in charge currency.
currency
String
optional
the currency of the amount
description
String
optional
Describe the goods or services you're selling
metadata
Object
optional
Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to metadata.
callback_url
String
optional
An endpoint on your server, for receiving notification about paid invoices.
back_url
String
optional
An endpoint on your site, that we will redirect to after the user clicks on the back button.
success_url
String
optional
An endpoint on your site, that we will redirect to after the user pays successfully.
expired_at
String
optional
The invoice will expire on this date