是否有可能在Parse云代码上访问Paypal

时间:2014-03-05 17:54:06

标签: android paypal parse-platform

因为我尝试验证云代码上的Paypal付款

下面是我在云代码中的代码

Parse.Cloud.define("verify", function(request, response) {

Parse.Cloud.httpRequest({
    method: 'POST',
    url: 'https://api.sandbox.paypal.com/v1/payments/payment',
    body: {
        'xx'
    },
    headers: {
        'Content-Type': 'application/json',
        'Authorization': 'Bearer xx'
    },
    success: function(httpResponse) {
        response.success("success");
    },
    error: function(httpResponse) {
        response.success(httpResponse.text);
    }
});
});

响应是

  

您无权访问   “https://api.sandbox.paypal.com/v1/payments/payment”在此服务器上。

我做错了什么或者我不能这样做?

如果我没有通过Parse.com访问Paypal的权限,而且我没有自己的服务器

如何验证付款?

如果我要验证移动设备上的付款会有什么问题?

0 个答案:

没有答案
相关问题