getting “INTERNAL_SERVICE_ERROR” with paypal refund operation
illusionist__
Contributor
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Posted on
Aug-16-2018
04:32 AM
I'm trying to execute a refund with PayPal's API in sandbox. I'm getting another internal service error. I am trying to run the following code :
pays.PAYID = _useDoc.client_doc_ref; //pays.OPERATION = Request["OPERATION"]; if (!string.IsNullOrEmpty(pays.PAYID)) { RefundRequest refreq = new RefundRequest() { //invoice_number = _useDoc.document, amount = new Amount() { currency = "EUR", total = pays.AMOUNT } }; var payment = Payment.Get(apiContext, pays.PAYID); var transactionId = payment.transactions[0].related_resources[0].sale.id; var response = Sale.Refund(apiContext, transactionId, refreq);
I am getting the following error:
{"name":"INTERNAL_SERVICE_ERROR","message":"An internal service error occurred.","information_link":"https://developer.paypal.com/docs/api/payments/#errors","debug_id":"fc27b41e6b6aa"}
It will be very appreciated if someone helps me in this regard.
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
- Refunding an order via HATEOAS URL failing with NOT_AUTHORIZED error in Sandbox Environment
- Is identity API available for sandbox? in Sandbox Environment
- Internal Server Error 500 in SDKs
- Webhooks stopped working two days ago... and I don't understand why in REST APIs
- 500 INTERNAL_SERVICE_ERROR on /v2/checkout/orders using vault_id as payment_source in REST APIs