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"
}
]
}
... View more