cancel
Showing results for 
Search instead for 
Did you mean: 

How can i get the authorization_id

SOLVED
Contributor

How can i get the authorization_id

I want to get that id to know all the information that client made by the trasaction
This code is what a i got but the only things that i can get is the orderID and the payerID:
 
$venta = curl_init("https://api.sandbox.paypal.com/v2/payments/authorizations/here it goes the authorization_id");
curl_setopt($venta,CURLOPT_HEADER,array("Content-Type: application/json","Authorization: Bearer ".$AccessToken));
curl_setopt($venta,CURLOPT_RETURNTRANSFER,TRUE);
$respuestaVenta = curl_exec($venta);
 
I want to get this information:
 
{ "id": "authorization_id", "status": "AUTHORIZED", "amount": { "total": "10.99", "currency": "USD" }, "invoice_id": "INVOICE-123", "seller_protection": { "status": "ELIGIBLE", "dispute_categories": [ "ITEM_NOT_RECEIVED", "UNAUTHORIZED_TRANSACTION" ] }, "expiration_time": "2017-10-10T23:23:45Z", "create_time": "2017-09-11T23:23:45Z", "update_time": "2017-09-11T23:23:45Z", "links": [ { "rel": "self", "method": "GET", "href": "https://api.paypal.com/v2/payments/authorizations/0VF52814937998046" }, { "rel": "capture", "method": "POST", "href": "https://api.paypal.com/v2/payments/authorizations/0VF52814937998046/capture" }, { "rel": "void", "method": "POST", "href": "https://api.paypal.com/v2/payments/authorizations/0VF52814937998046/void" }, { "rel": "reauthorize", "method": "POST", "href": "https://api.paypal.com/v2/payments/authorizations/0VF52814937998046/reauthorize" } ] }
1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
PayPal Employee

Re: How can i get the authorization_id

I presume you have use v2/checkout/orders and v2/payments.

 

To get authorization_id you just need to do a GET v2/checkout/orders/{id}

 

Senior Product Manager - PayPal Checkout API Product
1 REPLY 1
Highlighted
PayPal Employee

Re: How can i get the authorization_id

I presume you have use v2/checkout/orders and v2/payments.

 

To get authorization_id you just need to do a GET v2/checkout/orders/{id}

 

Senior Product Manager - PayPal Checkout API Product