Skip to main content
POST
/
v2
/
invoicing
/
invoices
/
{invoice_id}
/
refunds
Record refund for invoice
curl --request POST \
  --url https://api-m.sandbox.paypal.com/v2/invoicing/invoices/{invoice_id}/refunds \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "method": "BANK_TRANSFER"
}'
{
  "refund_id": "<string>"
}

Authorizations

Authorization
string
header
required

Oauth 2.0 authentication

Path Parameters

invoice_id
string
required

The ID of the draft invoice to delete.

Maximum length: 2147483647

Body

application/json

The details of the refund to record against the invoice.

The refund details of the invoice. Includes the refund type, date, amount, and method.

method
enum<string>
required

The payment mode or method through which the invoicer can accept the payments.

Available options:
BANK_TRANSFER,
CASH,
CHECK,
CREDIT_CARD,
DEBIT_CARD,
PAYPAL,
WIRE_TRANSFER,
OTHER
type
enum<string>

The PayPal refund type. Indicates whether the refund was paid through PayPal or externally in the invoicing flow. The record refund method supports the EXTERNAL refund type. The PAYPAL refund type is supported for backward compatibility.

Available options:
PAYPAL,
EXTERNAL
refund_date
string<ppaas_date_notime_v2>

The date when the invoice was refunded, in Internet date format. For example, 2014-02-27.

Required string length: 10
amount
object

The amount to record as refunded. If you omit the amount, the total invoice paid amount is recorded as refunded.

Response

A successful request returns the HTTP 200 Created status code and a reference to the recorded refund.

The reference to the refund payment detail.

refund_id
string

The ID of the refund of an invoice payment.

Required string length: 1 - 22
I