Payer Address is not giving any details

RailsDev07
Contributor
Contributor

I am using paypal create and capture order with version 2. And as the documentation says I should receive the payer address as wanted to use it as billing address but paypal is only returning the country code in this.
"payer"=>{"name"=>{"given_name"=>"John", "surname"=>"Doe"}, "email_address"=>"email.com", "payer_id"=>"someId", "address"=>{"country_code"=>"GB"}} 
here is the object I am getting. and this is what I have expected and is looking for 
https://developer.paypal.com/api/orders/v2/#definition-payer
So kindly help me with this.

Login to Me Too
1 REPLY 1

MTS_Justin
Moderator
Moderator
Hello,

The billing address won't be returned by default. In order to retrieve the billing address for a buyer, you need to request that functionality be enabled for your account.

For production accounts, you need to contact our customer service team and request they enable the return of the buyer's billing address for your account.

https://www.paypal.com/smarthelp/contact-us

Thanks !

Was my post helpful? If so, please give me a kudos!
Login to Me Too

Haven't Found your Answer?

It happens. Hit the "Login to Ask the community" button to create a question for the PayPal community.