简体   繁体   English

Facebook Payments API-错误,无代码

[英]Facebook payments API - Error with no code

I am implementing the Facebook payments API and receiving an odd error dialog with no populated data, it basically looks as follows: 我正在实现Facebook Payments API,并收到一个没有填充数据的奇数错误对话框,它基本上如下所示:

An error occurred, Please try again later.
API Error Code:
API Error Description:

The javascript returns a null object in the callback. javascript在回调中返回空对象。

JS implementation: JS实现:

FB.ui({
    method: 'pay',
action: 'purchaseitem',
product: 'http://localhost:8000/PRODUCT_URL',
},
function(data) {
console.log(data);
});

Any help would be much appreciated. 任何帮助将非常感激。

Found the error: Seems like the product value was incorrect - whether thats because its hosted locally i'm not sure but it worked when I used a valid product from Facebook's 'Friend Smash' example. 发现错误:似乎产品值不正确-是否那是因为我不确定它是在本地托管的,但是当我使用来自Facebook的“ Friend Smash”示例中的有效产品时,它可以工作。

Hope this helps someone 希望这可以帮助某人

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM