简体   繁体   English

PayPal自适应付款 - 通过IPN / API检索发件人的帐单邮寄地址?

[英]PayPal Adaptive Payments - retrieving sender's billing address via IPN / API?

I'm using the Adaptive Payments API to redirect the user from my web-site to a PayPal page to finish the payment. 我正在使用Adaptive Payments API将用户从我的网站重定向到PayPal页面以完成付款。 I've hooked this up with a 3rd party Invoicing service which listens via IPN. 我已经把它与第三方进销存服务联系起来,该服务通过IPN进行监听。

For some reason, the Billing Address does not appear in the IPN data, and so does not appear on the invoice. 由于某种原因,帐单地址不会出现在IPN数据中,因此不会出现在发票上。 Is there any flag I need to pass to the Adaptive Payments API to tell it to pass along the Billing Address? 我是否需要传递给Adaptive Payments API以告知其传递结算地址?

Here's how I'm currently using the API: 以下是我目前使用API​​的方式:

    var receiverList = new ReceiverList
    {
        receiver = new List<Receiver>
                {
                    new Receiver(purchase.TotalPrice)
                        {                                   
                            email = _configurationReader.GetStringValue("PayPalEmail")
                        }
                }, 

    };

    var envelope = new RequestEnvelope("en_US");
    var payRequest = new PayRequest(envelope, ActionType.Pay.GetApiString(), cancelUrl, CurrencyCode.USDollar.GetApiString(), receiverList, returnUrl);

    var service = new AdaptivePaymentsService();
    var response = service.Pay(payRequest);
    purchase.PayPalPaymentId = response.payKey;

    return CreatePayPalRedirectUrl(response);

PayPal does not send billing addresses to sellers. PayPal不会向卖家发送帐单邮寄地址。 That's one of the advantages for buyers using the system...they don't have to share any billing info with all the different sellers they buy from. 这是使用该系统的买家的优势之一......他们不必与他们购买的所有不同卖家分享任何账单信息。

The only address you would ever get from PayPal (in an API response, IPN notification, etc.) would be a shipping address, and that would only be provided if included in the original transaction. 您从PayPal获得的唯一地址(在API响应,IPN通知等中)将是一个送货地址,并且只有在原始交易中包含时才会提供。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM