我尝试上传Facebook页面个人资料图片。
随着页面个人资料图片的更新,此调用看起来很有效:
curl -i -X POST "https://graph.facebook.com/v8.0/me/picture?access_token=[access_token]&picture=https://homepages.cae.wisc.edu/~ece533/images/fruits.png"
尽管令人惊讶地出现以下错误:
{"error":{"message":"Unsupported post request.","type":"GraphMethodException","code":100,"fbtrace_id":"ACYX59xl8QtGpvK6wozgxUb"}}
curl -i -X POST "https://graph.facebook.com/v8.0/me/picture?access_token=[access_token]&picture=https://fkesh.ngrok.io/profilePicture/pageProfilePic.png"
很遗憾,出现以下错误,并且图片无法上传:
{"error":{"message":"(#1) Could not fetch picture","type":"OAuthException","code":1,"fbtrace_id":"A841VXO47expQy08MWoN3uF"}}
curl -X POST -H "Content-Type:multipart/form-data" -d "@pool.png" "https://graph.facebook.com/v8.0/me/picture?access_token=[access_token]"
即将出现与第2点相同的错误:
{"error":{"message":"(#1) Could not fetch picture","type":"OAuthException","code":1,"fbtrace_id":"AT3MqnpHjGyqm1akujpOsEa"}}
如何使Point 2)或3)工作?