2016-02-05 51 views
0

呼籲授權支付我使用PayPal.1.6.0\lib\net45\PayPal.dllINVALID_RESOURCE_ID當Authorization.Capture使用沙盒帳戶

我創建了authorize意圖付款,並有成功授權authIDPayment.Cart)和PayPal.APi.Payment.id

當我嘗試調用Authorization.Capture(apiContext, Capture)authID,我得到

{ 
    "name":"INVALID_RESOURCE_ID", 
    "message":"The requested resource ID was not found", 
    "information_link":"https://developer.paypal.com/webapps/developer/docs/api/#INVALID_RESOURCE_ID", 
    "debug_id":"d73f6a0c1b8bc" 
} 

我該使用我的沙盒帳戶進行測試。

嘗試鏈接讓我得到'找不到頁面錯誤'。任何線索?

回答

0

我意識到我在查看錯誤的授權碼。它不是((支付)executionPayment).cart作爲張貼在我原來的問題,但((Payment)executionPayment).transactions.FirstOrDefault()。authorization.id

我能夠使用正確的authCode,並能捕捉我的授權。 executedPayment是Payment.Execute方法的返回值。