尝试通过paypal REST API验证付款时INTERNAL_SERVICE_ERROR

时间:2015-02-20 06:19:56

标签: php rest paypal

我试图通过合作伙伴服务验证付款。合作伙伴正在向我发送付款ID,并且我正在使用REST API进行查找。到目前为止,所有使用payments/payment/<Payment-Id>的尝试都抛出了INTERNAL_SERVICE_ERROR。 (我还在使用沙箱和演示用户。)

获得令牌似乎工作正常:

curl -v https://api.sandbox.paypal.com/v1/oauth2/token  -H "Accept: application/json" -H "Accept-Language: en_US" -u "EOJ2S-Z6OoN_le_KS1d75wsZ6y0SFdVsY9183IvxFyZp:EClusMEUk8e9ihI7ZdVLF5cZ6y0SFdVsY9183IvxFyZp" -d "grant_type=client_credentials"

响应:

{"scope":"https://api.paypal.com/v1/developer/.* https://api.paypal.com/v1/payments/.* https://api.paypal.com/v1/vault/credit-card https://api.paypal.com/v1/vault/credit-card/.*","access_token":"A015GzttpnOSOPfcqtfAaq1kdgqow5W.IXSe6TJ9Cpbesr4","token_type":"Bearer","app_id":"APP-8KK24973T6066201W","expires_in":28800}

取得该令牌并加入付款申请:

curl -v -X GET https://api.sandbox.paypal.com/v1/payments/payment/PAY-8UD377151U702286RKOQ3DTQ -H "Content-Type:application/json" -H "Authorization: Bearer A015GzttpnOSOPfcqtfAaq1kdgqow5W.IXSe6TJ9Cpbesr4"

返回错误:

{"name":"INTERNAL_SERVICE_ERROR","message":"An internal service error has occurred","information_link":"https://developer.paypal.com/webapps/developer/docs/api/#INTERNAL_SERVICE_ERROR","debug_id":"ca33c7679121d"}

更新:基本上我尝试按照此处列出的步骤进行操作:https://developer.paypal.com/webapps/developer/docs/integration/mobile/verify-mobile-payment/

0 个答案:

没有答案