Requiring shipping address in PayPal adaptive payments using Rails
I want to set require customers to enter their shipping address when paying using PayPal adaptive payments. I've used PayPal's Rails SDK as my starting point. The setchainedpayment
controller is working fine. From my understanding I need to set senderOptions.requireShippingAddressSelection
to true in the setpaymentoptions
My question is, has anyone done this successfully using the PayPal's Rails SDK as a starting point? The SDK keeps the setchainedpayment
and setpaymentoptions
in separate controllers. I'm currently just calling setchainedpayment
. In order to use setpaymentoptions
, would i have to call setpa开发者_StackOverflowymentoptions
first and then set setpaymentoptions
to trigger setchainedpayment
?
Seems weird to have to make two consecutive calls just for this.
As far as I remember, yes. With Adaptive Payments you have two separate API calls; one for customizing the checkout, and one for calling the actually chained payment.
Disclaimer: It's been half a year since I last toyed with the Adaptive API's. :-)
精彩评论