我正在構建一個涉及paypal訂閱的asp.net web應用程序。我需要檢查用戶是否已經取消登錄是可能的,如果是的話如何?我已經看到關於這個主題的其他帖子,但我的情況是不同的,因爲我會檢查登錄。我在想,也許我可以每晚從PayPal批量轉儲數據,並檢查這些數據,以便爲取消的用戶設置標誌。不知道這是做什麼最好的辦法..檢測paypal訂閱取消登錄asp.net
2
A
回答
3
如果你想檢查用戶登錄到貝寶後是否接受或取消協議,那麼是的,你可以通過使用快速結賬令牌來檢查這一點。您需要在買方登錄PayPal賬戶並在響應中查找變量BILLINGAGREEMENTACCEPTEDSTATUS後,在令牌上的API上調用GetExpressCheckoutDetails。
BILLINGAGREEMENTACCEPTEDSTATUS = 0意味着買方不接受該協議或點擊登錄到支付寶賬戶後取消。
BILLINGAGREEMENTACCEPTEDSTATUS = 1,表示在登錄到PayPal後點擊「同意並繼續」。
我已經包含了一些示例響應。
拒絕後,日誌中:
NVP Response:
TOKEN=EC-0RC04801KU663840M
**BILLINGAGREEMENTACCEPTEDSTATUS=0**
CHECKOUTSTATUS=PaymentActionNotInitiated
TIMESTAMP=2014-09-14T14:54:43Z
CORRELATIONID=5cc68231a1b35
ACK=Success
VERSION=109.0
BUILD=12786467
EMAIL=XXXXXXXXXXXXXX
PAYERID=XXXXXXXXXXXX
PAYERSTATUS=verified
FIRSTNAME=Eshan Personal Test
LASTNAME=Account
COUNTRYCODE=US
CURRENCYCODE=USD
AMT=0.00
SHIPPINGAMT=0.00
HANDLINGAMT=0.00
TAXAMT=0.00
INSURANCEAMT=0.00
SHIPDISCAMT=0.00
PAYMENTREQUEST_0_CURRENCYCODE=USD
PAYMENTREQUEST_0_AMT=0.00
PAYMENTREQUEST_0_SHIPPINGAMT=0.00
PAYMENTREQUEST_0_HANDLINGAMT=0.00
PAYMENTREQUEST_0_TAXAMT=0.00
PAYMENTREQUEST_0_INSURANCEAMT=0.00
PAYMENTREQUEST_0_SHIPDISCAMT=0.00
PAYMENTREQUEST_0_INSURANCEOPTIONOFFERED=false
PAYMENTREQUEST_0_ADDRESSNORMALIZATIONSTATUS=None
PAYMENTREQUESTINFO_0_ERRORCODE=0
驗收登錄後:
NVP Response:
TOKEN=EC-1EX65013S71914041
PHONENUM=408-767-7151
**BILLINGAGREEMENTACCEPTEDSTATUS=1**
CHECKOUTSTATUS=PaymentActionNotInitiated
TIMESTAMP=2014-09-14T14:56:24Z
CORRELATIONID=aae4de7a4b356
ACK=Success
VERSION=109.0
BUILD=XXXXXXXXXXXXX
PAYERID=XXXXXXXXXXXXXX
PAYERSTATUS=verified
FIRSTNAME=Eshan Personal Test
LASTNAME=Account
COUNTRYCODE=US
SHIPTONAME=Eshan Personal Test Account
SHIPTOSTREET=cxas
SHIPTOSTREET2=asa
SHIPTOCITY=FL
SHIPTOSTATE=FL
SHIPTOZIP=95616
SHIPTOCOUNTRYCODE=US
SHIPTOCOUNTRYNAME=United States
ADDRESSSTATUS=Confirmed
CURRENCYCODE=USD
AMT=0.00
SHIPPINGAMT=0.00
HANDLINGAMT=0.00
TAXAMT=0.00
INSURANCEAMT=0.00
SHIPDISCAMT=0.00
PAYMENTREQUEST_0_CURRENCYCODE=USD
PAYMENTREQUEST_0_AMT=0.00
PAYMENTREQUEST_0_SHIPPINGAMT=0.00
PAYMENTREQUEST_0_HANDLINGAMT=0.00
PAYMENTREQUEST_0_TAXAMT=0.00
PAYMENTREQUEST_0_INSURANCEAMT=0.00
PAYMENTREQUEST_0_SHIPDISCAMT=0.00
PAYMENTREQUEST_0_INSURANCEOPTIONOFFERED=false
PAYMENTREQUEST_0_SHIPTONAME=Eshan Personal Test Account
PAYMENTREQUEST_0_SHIPTOSTREET=cxas
PAYMENTREQUEST_0_SHIPTOSTREET2=asa
PAYMENTREQUEST_0_SHIPTOCITY=FL
PAYMENTREQUEST_0_SHIPTOSTATE=FL
PAYMENTREQUEST_0_SHIPTOZIP=95616
PAYMENTREQUEST_0_SHIPTOCOUNTRYCODE=US
PAYMENTREQUEST_0_SHIPTOCOUNTRYNAME=United States
PAYMENTREQUEST_0_ADDRESSSTATUS=Confirmed
PAYMENTREQUEST_0_ADDRESSNORMALIZATIONSTATUS=None
PAYMENTREQUESTINFO_0_ERRORCODE=0
+0
感謝您的信息! – 2014-09-16 15:37:39
相關問題
- 1. 收取PayPal訂閱取消
- 2. PayPal IPN取消訂閱
- 3. Paypal IPN取消訂閱,發送新登錄信息?
- 4. 檢測訂閱是否自動取消
- 5. c#paypal取消訂閱服務器端
- 6. 如何取消使用asp.net PayPal的最後訂閱
- 7. 如何檢查PayPal訂閱還沒有被取消?
- 8. 訂閱取消訂閱()
- 9. 何時採取PayPal訂閱?
- 10. paypal訂閱
- 11. PayPal訂閱API
- 12. Django Paypal訂閱
- 13. 如何測試switchmap中的訂閱/取消訂閱?
- 14. 取消應用測試訂閱
- 15. 貝寶取消通過PayPal標準訂閱按鈕創建訂閱
- 16. 取消iOS訂閱
- 17. Android訂閱取消
- 18. 如何取消訂閱socket.io訂閱?
- 19. Rxjs - 重新訂閱取消訂閱Observable
- 20. 如何取消訂閱Weak訂閱MvvmCross
- 21. 訂閱/取消訂閱VS Create/TakeUntil?
- 22. 取消訂閱/訂閱活動危險?
- 23. 訂閱和取消訂閱活動
- 24. 如何取消訂閱NServiceBus訂閱?
- 25. 動態訂閱/取消訂閱活動
- 26. SerialPort.DataReceived重複訂閱/取消訂閱
- 27. 取消訂閱socket.io中的訂閱
- 28. PayPal PayFlow測試過期訂閱
- 29. PayPal訂閱升級
- 30. Paypal訂閱集成
你檢查貝寶IPN?即時付款通知 - 您會收到有關您的付款請求和訂閱操作的任何事件的通知。您需要一個回調網址,讓您的服務根據訊息監聽通知並進行處理。因此,您不需要在登錄時檢查訂閱狀態,因爲只要用戶取消該訂閱即可取消訂閱。這不是100%的解決方案,但非常接近。 https://developer.paypal.com/webapps/developer/docs/classic/products/instant-payment-notification/ – Biri 2014-09-13 08:10:43