2014-10-06 122 views
0

我用paypal標準訂閱按鈕,在我的網站 管理的訂閱系統,我配置IPN我得到2 IPN通知,txn_type subscr_signupsubscr_payment和我有subscr_id PARAM那裏也有。 所以我有幾個問題:貝寶取消通過PayPal標準訂閱按鈕創建訂閱

1)我怎麼能通過subscr_id訂閱狀態(活動,掛起,取消等)? (我嘗試了GetRecurringPaymentsProfileDetails,但只有在通過快速結帳創建訂閱時才能使用它)。我收到錯誤'訂閱配置文件不支持定期付款API'。

2)如何通過subscr_id管理訂閱狀態? (也試過ManageRecurringPaymentsProfileStatus,但得到錯誤「的個人資料ID無效」所有的時間)

回答

0

您可以使用「TransactionSearch」 API來獲取詳細信息任何配置文件(即使是一個使用PayPal的訂閱按鈕創建) 。有了這個,你可以得到如配置文件被創建,更新,暫停等信息。我已經包括示例請求和響應,可能是它可以幫助你:

NVP請求:

USER=XXXXXXXXXX&PWD=XXXXXXXXXXXX&SIGNATURE=XXXXXX&VERSION=109.0&METHOD=TransactionSearch&STARTDATE=2014-01-24T00:00:00Z&TRANSACTIONCLASS=SUBSCRIPTION&PROFILEID=I-FXMKNUUEP6XL 

NVP響應:

L_TIMESTAMP0=2014-02-17T16:19:50Z 
L_TIMESTAMP1=2014-02-17T16:19:51Z 
L_TIMESTAMP2=2014-03-17T14:02:39Z 
L_TIMESTAMP3=2014-04-17T15:26:44Z 
L_TIMESTAMP4=2014-05-09T17:18:37Z 
L_TIMESTAMP5=2014-05-09T17:19:15Z 
L_TIMESTAMP6=2014-05-09T17:19:40Z 
L_TIMESTAMP7=2014-05-17T15:26:31Z 
L_TIMESTAMP8=2014-06-17T15:55:14Z 
L_TIMESTAMP9=2014-07-17T16:14:01Z 
L_TIMESTAMP10=2014-08-17T16:06:44Z 
L_TIMESTAMP11=2014-09-17T15:55:04Z 
L_TIMEZONE0=GMT 
L_TIMEZONE1=GMT 
L_TIMEZONE2=GMT 
L_TIMEZONE3=GMT 
L_TIMEZONE4=GMT 
L_TIMEZONE5=GMT 
L_TIMEZONE6=GMT 
L_TIMEZONE7=GMT 
L_TIMEZONE8=GMT 
L_TIMEZONE9=GMT 
L_TIMEZONE10=GMT 
L_TIMEZONE11=GMT 
L_TYPE0=Recurring Payment 
L_TYPE1=Recurring Payment 
L_TYPE2=Recurring Payment 
L_TYPE3=Recurring Payment 
L_TYPE4=Recurring Payment 
L_TYPE5=Recurring Payment 
L_TYPE6=Recurring Payment 
L_TYPE7=Recurring Payment 
L_TYPE8=Recurring Payment 
L_TYPE9=Recurring Payment 
L_TYPE10=Recurring Payment 
L_TYPE11=Recurring Payment 
L_EMAIL1=XXXXXXXXXXXXXXXX 
L_EMAIL2=XXXXXXXXXXXXXXXX 
L_EMAIL3=XXXXXXXXXXXXXXXX 
L_EMAIL7=XXXXXXXXXXXXXXXX 
L_EMAIL8=XXXXXXXXXXXXXXXX 
L_EMAIL9=XXXXXXXXXXXXXXXX 
L_EMAIL10=XXXXXXXXXXXXXXXX 
L_EMAIL11=XXXXXXXXXXXXXXXX 
L_NAME0=Eshan Personal Test Account 
L_NAME1=Eshan Personal Test Account 
L_NAME2=Eshan Personal Test Account 
L_NAME3=Eshan Personal Test Account 
L_NAME4=Eshan Personal Test Account 
L_NAME5=Eshan Personal Test Account 
L_NAME6=Eshan Personal Test Account 
L_NAME7=Eshan Personal Test Account 
L_NAME8=Eshan Personal Test Account 
L_NAME9=Eshan Personal Test Account 
L_NAME10=Eshan Personal Test Account 
L_NAME11=Eshan Personal Test Account 
L_TRANSACTIONID0=I-FXMKNUUEP6XL 
L_TRANSACTIONID1=0AR10991U1333214W 
L_TRANSACTIONID2=1GX902663D9811358 
L_TRANSACTIONID3=0K568033VD746381F 
L_TRANSACTIONID4=I-FXMKNUUEP6XL 
L_TRANSACTIONID5=I-FXMKNUUEP6XL 
L_TRANSACTIONID6=I-FXMKNUUEP6XL 
L_TRANSACTIONID7=4A4539330Y180244M 
L_TRANSACTIONID8=94165672XW4156934 
L_TRANSACTIONID9=12791760JH4394641 
L_TRANSACTIONID10=36E095146V2526231 
L_TRANSACTIONID11=5ED26578AA878723D 
L_STATUS0=Created 
L_STATUS1=Completed 
L_STATUS2=Completed 
L_STATUS3=Completed 
L_STATUS4=Updated 
L_STATUS5=Updated 
L_STATUS6=Updated 
L_STATUS7=Completed 
L_STATUS8=Completed 
L_STATUS9=Completed 
L_STATUS10=Completed 
L_STATUS11=Pending 
L_AMT1=50.00 
L_AMT2=50.00 
L_AMT3=50.00 
L_AMT7=50.00 
L_AMT8=50.00 
L_AMT9=50.00 
L_AMT10=50.00 
L_AMT11=50.00 
L_CURRENCYCODE1=USD 
L_CURRENCYCODE2=USD 
L_CURRENCYCODE3=USD 
L_CURRENCYCODE7=USD 
L_CURRENCYCODE8=USD 
L_CURRENCYCODE9=USD 
L_CURRENCYCODE10=USD 
L_CURRENCYCODE11=USD 
L_FEEAMT1=-1.75 
L_FEEAMT2=-1.75 
L_FEEAMT3=-1.75 
L_FEEAMT7=-1.75 
L_FEEAMT8=-1.75 
L_FEEAMT9=-1.75 
L_FEEAMT10=-1.75 
L_FEEAMT11=0.00 
L_NETAMT1=48.25 
L_NETAMT2=48.25 
L_NETAMT3=48.25 
L_NETAMT7=48.25 
L_NETAMT8=48.25 
L_NETAMT9=48.25 
L_NETAMT10=48.25 
L_NETAMT11=50.00 
TIMESTAMP=2014-10-07T11:05:34Z 
CORRELATIONID=5bb22082c58de 
ACK=Success 
VERSION=109.0 
BUILD=000000 
+0

THX,但如何管理個人文件如果可能的話? – user2728827 2014-10-10 08:21:35

+0

管理配置文件意味着,您想要使用API​​更改配置文件的詳細信息? – Eshan 2014-10-12 20:17:49

+0

我的網站中的用戶通過按鈕(標準訂閱按鈕)訂閱服務。是否有可能允許用戶通過配置文件中的界面取消他的訂閱(例如)? – user2728827 2014-10-13 11:18:25