Cant refund payment with API
n0oB
Contributor
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Posted on
Apr-01-2021
08:43 AM
So I have the capture ID.
But when I try to refund the order I get an error.
I have tried with the node.js SDK and also with the web API.
Node.js code:
const request = new paypal.payments.CapturesRefundRequest(orderId);
request.requestBody({
"amount": {
"value": "9.37",
"currency_code": "EUR"
}
});
const response = await client.execute(request);
Through Web API:
(
method: "POST",
data: {
"amount": {
"value": "9.37",
"currency_code": "EUR"
}
},
headers: {
'Content-Type': 'application/json',
'Authorization': 'Bearer ' + token
}
)
And here my error info (its long so I put some of it):
...
response: {
status: 404,
statusText: 'Not Found',
...
status: 404,
statusText: 'Not Found',
...
data: {
name: 'RESOURCE_NOT_FOUND',
message: 'The specified resource does not exist.',
debug_id: 'b7b872481d61',
details: [Array],
links: [Array]
}
name: 'RESOURCE_NOT_FOUND',
message: 'The specified resource does not exist.',
debug_id: 'b7b872481d61',
details: [Array],
links: [Array]
}
...
},
},
Labels:
- Labels:
-
Payments REST APIs
0 REPLIES 0

Haven't Found your Answer?
It happens. Hit the "Login to Ask the community" button to create a question for the PayPal community.
Related Content
- where does paypal payments go to if there is no linked phone or email to the seller ? in PayPal Payments Standard
- Couldn't receive International payment in PayPal Payments Standard
- Is it possible to make payments in RON (Romanian Leu) through PayPal? in REST APIs
- No way to contact company and I want a refund! Please help. in PayPal Reporting
- My PayPal is not allowing me to receive or send requests. in PayPal Payments Standard