How can I void authorized payment?
ilinojse
Contributor
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Posted on
Feb-20-2019
04:58 AM
I use Java SDK and sandbox. And I can't void authorized payment because I don't know authorizationId.
When I making a payment with intent as "authorize" I get response without authorisationId. I know only paymentId and payerId.
Can anybody tell me how can I get authorizationId or void/cancel payment by other way?
My Payment JSON example:
{ "id": "PAY-XXXXXXXXXXXXXXXXXXXXXXXXXX", "intent": "authorize", "payer": { "payment_method": "paypal", "status": "VERIFIED", "payer_info": { "email": "xxxxxxxx", "first_name": "TestName", "last_name": "TestName", "payer_id": "XXXXXXXXXXX", "country_code": "US", "shipping_address": { "recipient_name": "TestName", "line1": "1 Main St", "city": "San Jose", "country_code": "US", "postal_code": "95131", "state": "CA" } } }, "cart": "XXXXXXXXXXXXX", "transactions": [ { "related_resources": [], "amount": { "currency": "USD", "total": "11.11", "details": { "subtotal": "11.11", "shipping": "0.00", "tax": "0.00" } }, "payee": { "email": "XXXXXX", "merchant_id": "XXXXXXXXXXX" }, "description": "Sale transaction", "item_list": { "shipping_address": { "recipient_name": "TestName", "line1": "1 Main St", "city": "San Jose", "country_code": "US", "postal_code": "95131", "state": "CA" } } } ], "state": "created", "redirect_urls": { "return_url": "http://localhost:8080/api/v0/payment/accept/...........", "cancel_url": "http://localhost:8080/api/v0/payment/reject/..........." }, "create_time": "2019-02-20T11:22:34Z", "update_time": "2019-02-20T11:29:28Z", "links": [ { "href": "https://api.sandbox.paypal.com/v1/payments/payment/PAY-XXXXXXXXXXXXXXXXXXX", "rel": "self", "method": "GET" }, { "href": "https://api.sandbox.paypal.com/v1/payments/payment/PAY-XXXXXXXXXXXXXXXXXXX/execute", "rel": "execute", "method": "POST" }, { "href": "https://www.sandbox.paypal.com/cgi-bin/webscr?cmd\u003d_express-checkout\u0026token\u003dXX-XXXXXXXXXXXXXXXXXX", "rel": "approval_url", "method": "REDIRECT" } ] }
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
- v2/payments/authorizations/{authorization_id} Request failed with status code 404 in REST APIs
- Shopify PayPal integration, customer authorized multiple times in PayPal Payments Standard
- Payment Authorization Error in PayPal Payments Standard
- v2/vault/payment-tokens API error "Authorization failed due to insufficient permissions." in REST APIs
- Possible to use the Authorize & Capture payments function for a marketplace in the UAE? in PayPal Payments Standard