Refund Payment
Refunds a partially or fully captured payment.
More information can be found in our Documentation.
Path
POST /api/v3/orders/{orderNumber}/refunds Request Parameters
orderNumber
required
string
Order number
Request Body
application/json
captureNumber
required
string
Max length: 50
Capture number to refund. This is the capture number which comes from Capture response. Required for Partial Refund
required
array
Order items to refund. Required for Partial Refund. Maximum allowed 500 items.
refundType
string
Enum:
- Refund
- Return
productId
required
string
Max length: 100
Merchant Product identification number.
groupId
string
Max length: 255
Item group ID. The group this item belongs to. Provided by the merchant. Everything over 255 characters will be truncated.
description
required
string
Product name. For example "Black music player 64GB". Everything over 255 characters will be truncated.
type
string
Enum:
- PhysicalArticle
- DigitalArticle
- GiftCard
- Discount
- ShippingFee
- Surcharge
- Info
- Subscription
netUnitPrice
required
number
Net unit price.
grossUnitPrice
required
number
Gross price per item.
quantity
required
number
Quantity. Use of integer is strongly proposed. If you want to use decimal, please contact your integration manager.
unitCode
string
Max length: 50
Unit code (for example pieces, liters, kilograms, etc.).
vatCategory
string
Enum:
- HighCategory
- LowCategory
- NullCategory
- NoCategory
- MiddleCategory
- OtherCategory
Vat category
vatPercent
required
number
Tax percent.
vatAmount
required
number
Tax amount per item.
imageUrl
string
Max length: 2048
URL for the image of this product. It will be turned into a thumbnail and displayed in Riverty, on the invoice line next to the order item.
The linked image must be a rectangle or square, width between 100 pixels and 1280 pixels.
Supported image formats are: gif, jpeg (jpg), png, webp.
googleProductCategoryId
integer
Google product category ID.
googleProductCategory
string
Max length: 255
Indicates the category of the item based on the Google product taxonomy. Categorizing the product helps ensure that the ad is shown with the right search results.
merchantProductType
string
Max length: 255
Categorization used by Merchant as a complement to Google Taxonomy.
lineNumber
integer
Line number. The merchant may add a line number to each order item, to sort them in a particular order.
productUrl
string
Max length: 2048
URL to the product.
marketPlaceSellerId
string
Max length: 32
ID of an individual seller on a marketplace. If this field is used, an entry in the element additionalData -> marketplace must also be provided.
parentTransactionReference
string
Max length: 128
A unique reference provided to Riverty by a third party (merchant or Payment Service Provider). Identifies an entire order.
additionalInformation
string
Max length: 4096
Extended description of the order item.
specification
object
Specification.
serviceStart
string
yyyy-MM-ddTHH:mm:ss.fffffffzzz
Capture start time.
serviceEnd
string
yyyy-MM-ddTHH:mm:ss.fffffffzzz
Capture end time.
refundType
string
Enum:
- Refund
- Return
parentTransactionReference
string
Max length: 128
A unique reference provided to Riverty by a third party (merchant or Payment Service Provider). Identifies an entire order.
transactionReference
string
Max length: 100
A unique reference for each transaction (separate for transactions within an order), generated and provided to Riverty by a third party (merchant or Payment Service Provider).
It is used to identify transactions during back-end settlement between Core systems and the PSP.
creditNoteNumber
string
Max length: 19
Credit note number. The merchant may want to use internal credit note numbers, or let the Riverty generate one based on invoice to be credited.
merchantId
string
Max length: 50
Optional field. Used only in specific setups where merchant-specific profiles are required. Most integrations do not need this field.
object
object
These fields can be used to include implementation-specific reference information when other reference fields are not applicable.
Usage of these fields needs to be aligned during implementation.
udf1
string
udf2
string
udf3
string
udf4
string
udf5
string
Responses
-
totalCapturedAmountnumberThe total captured amount done with either a full capture, partial capture, or multiple partial capturestotalAuthorizedAmountnumberTotal authorized amountarrayRefundNumber is assigned to an invoice that has been refunded. For one Authorization you can have multiple invoices and refundNumberstotalRefundedAmountnumberTotal refunded amount for this orderremainingAuthorizedAmountnumberRemaining authorized amount
-
typestringEnum:
- BusinessError
- TechnicalError
- NotificationMessage
codestringMax length: 100Confirmation or error codemessagestringMax length: 4096Message contentcustomerFacingMessagestringMax length: 4096Message to display to customeractionCodestringEnum:- Unavailable
- AskConsumerToConfirm
- AskConsumerToReEnterData
- OfferSecurePaymentMethods
- RequiresSsn
- AskConsumerToIdentify
- ManualReview
Action codesfieldReferencestringMax length: 100Reference to field that caused an error -
-
-
-
Request Example
null
Response Example
{
"refundNumbers": [
"800090092"
],
"totalCapturedAmount": 185,
"totalRefundedAmount": 185,
"totalAuthorizedAmount": 185,
"remainingAuthorizedAmount": 0
}