FBInstant.shareAsync( ) failed with 500



我正在我的小游戏中进行分享。 我正在从游戏中触发下一个请求:

FBInstant.shareAsync(
{
intent: 'REQUEST',
image: 'image-encoded-here',
text: 'Edgar just played BASH for 9 points!',
data: { myReplayData: 'message sent' },
}
).then( function()
{
console.log("sharing is done");
})
.catch( function(err)
{
console.log('failed to share: ' + err.code + " :: " + err.message);
});

但我收到 500 错误:

https://www.facebook.com/games/quicksilver/share_score/?dpr=2 500 (( 分享失败: NETWORK_FAILURE ::

====

===================================在我的特殊情况下,问题与编码图像有关。 我记得,要共享的图像应该包括所有编码的图像内容,并带有"data:image/jpeg;base64,/"在前面。

在 shareAsync(( 中查看您的 "image" 参数。您必须发送 Base64 网址,否则会出错。

尝试从行中删除",">

data: { myReplayData: 'message sent' },
data: { myReplayData: 'message sent' }

相关内容

最新更新