On this page
No Headings
Oauth 2.0 authentication
Client CredentialsToken URLhttps://api-m.sandbox.paypal.com/v1/oauth2/tokenInheaderScopes
https://uri.paypal.com/services/invoicing/invoices/readwriteThe ID of the invoice to mark as refunded.
^.*$0 <= length <= 2147483647Holds authorization information for external API calls.
^.*$1 <= length <= 16000application/json
TypeScript Definitions
Use the request body type in TypeScript.
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://api-m.sandbox.paypal.com/v2/invoicing/invoices/INV2-Z56S-5LLA-Q52L-CPZ5/refunds" \ -H "Authorization: Bearer A21AAGHr9qtiRRXH4oYcQokQgV99rGqEIfgrr8xHCclP0OzmD9KVgg5ppIIg1jzJgQkV4wd02svIvBJyg6cLFJjFow_SjBhxQ" \ -H "Content-Type: application/json" \ -d '{ "method": "BANK_TRANSFER", "refund_date": "2018-05-21", "amount": { "currency_code": "USD", "value": "5.00" } }'{
"refund_id": "EXTR-2LG703375E477444T"
}{
"name": "string",
"message": "string",
"debug_id": "string",
"details": [],
"links": []
}{
"name": "AUTHENTICATION_FAILURE",
"debug_id": "b1d1f06c7246c",
"message": "Authentication failed due to missing Authorization header, or invalid authentication credentials."
}{
"name": "NOT_AUTHORIZED",
"debug_id": "b1d1f06c7246c",
"message": "Authorization failed due to insufficient permissions."
}{
"debug_id": "d20c2b8d8f41c",
"links": [
{
"href": "https://developer.paypal.com/docs/limited-release/invoicing/#errors",
"rel": "information_link"
}
],
"message": "The specified resource does not exist.",
"name": "RESOURCE_NOT_FOUND"
}{
"name": "string",
"message": "string",
"debug_id": "string",
"details": [],
"links": []
}{
"name": "INTERNAL_SERVER_ERROR",
"debug_id": "b1d1f06c7246c",
"message": "An internal server error has occurred."
}{
"name": "INTERNAL_SERVER_ERROR",
"debug_id": "b1d1f06c7246c",
"message": "An internal server error has occurred."
}"PAYPAL" | "EXTERNAL"^[0-9]{4}-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])$10 <= length <= 10The payment mode or method through which the invoicer can accept the payments.
"BANK_TRANSFER" | "CASH" | "CHECK" | "CREDIT_CARD" | "DEBIT_CARD" | "PAYPAL" | "WIRE_TRANSFER" | "OTHER"