PayPal Grant Permission API重定向到仪表板,而不是回到我的网站

时间:2018-09-26 19:43:08

标签: paypal permissions

我一直在使用PayPal GrantPermission API,到目前为止,它的工作情况还不错。但是今天,当我尝试使用它时,我总是被重定向到商家信息中心,并且无法返回网站

请求

   curl https://svcs.sandbox.paypal.com/Permissions/RequestPermissions \
   -s \
   --insecure \
      -H "X-PAYPAL-SECURITY-USERID: <user id>" \
      -H "X-PAYPAL-SECURITY-PASSWORD: <password>" \
      -H "X-PAYPAL-SECURITY-SIGNATURE: <signature>" \
      -H "X-PAYPAL-REQUEST-DATA-FORMAT: NV" \
      -H "X-PAYPAL-RESPONSE-DATA-FORMAT: NV" \
      -H "X-PAYPAL-APPLICATION-ID: APP-80W284485P519543T" \
      -d requestEnvelope.errorLanguage=en_US \
      -d scope=EXPRESS_CHECKOUT \
      -d callback=https://0f88fc8c.ngrok.io

然后我致电Paypal网站

https://www.sandbox.paypal.com/cgi-bin/webscr?cmd=_grant-permission&request_token=

但是随后我被重定向到此页面https://www.sandbox.paypal.com/mep/dashboard ...我已经检查了网络,URL(https://www.sandbox.paypal.com/cgi-bin/webscr?cmd=_grant-permission&request_token=)的响应状态为301永久移动

如果收到令牌后要调用的网址有所变化,请给我任何指导

非常感谢

0 个答案:

没有答案