我想让Facebook分享我的网址时自动将其取消 而不是通过此页面手动创建
https://developers.facebook.com/tools/debug/og/object/
我用齐射来实现它
但是它没有用,给我一个错误
所以代码是
String fbLink = "https://graph.facebook.com/";
StringRequest postRequest = new StringRequest(Request.Method.POST, fbLink,
new Response.Listener<String>()
{
@Override
public void onResponse(String response) {
// response
Log.d("Response", response);
}
},
new Response.ErrorListener()
{
@Override
public void onErrorResponse(VolleyError error) {
// error
Log.d("Error.Response", error.toString());
}
}
) {
@Override
protected Map<String, String> getParams()
{
Map<String, String> params = new HashMap<String, String>();
params.put("id", Link);
params.put("scrape", "true");
params.put("access_token", "53423443434234534");
return params;
}
};
queue.add(postRequest);
而来的错误是
E/Volley: [819] BasicNetwork.performRequest: Unexpected response code 400 for https://graph.facebook.com/
已更新
错误是
{"error":{"message":"Invalid OAuth access token.","type":"OAuthException","code":190,"fbtrace_id":"DNqMWPkaAy5"}}
更新2
修复了当我知道错误是由于访问令牌引起的
这是对我有帮助的话题
Android Volley - BasicNetwork.performRequest: Unexpected response code 400 谢谢你
答案 0 :(得分:0)
修复了当我知道错误是由于访问令牌引起的
这是对我有帮助的话题
Android Volley - BasicNetwork.performRequest: Unexpected response code 400