1

我正在使用用户生成的照片将多张图片上传到 Facebook。当我上传 1 或 2 张图片时,一切都按预期工作。当我上传超过 2 个时,我收到以下异常:

2013-01-18 14:39:41.662 ByClick[4714:16a03] Error Domain=com.facebook.sdk Code=5 "The     
operation couldn’t be completed. (com.facebook.sdk error 5.)" UserInfo=0x86b5510 
{com.facebook.sdk:ParsedJSONResponseKey=<CFBasicHash 0x86b3ca0 [0x238fb48]>{type = 
mutable dict, count = 2,

entries =>
1 : <CFString 0x1304ac [0x238fb48]>{contents = "code"} = <CFNumber 0x86b3cd0 [0x238fb48]>{value = +400, type = kCFNumberSInt32Type}
2 : <CFString 0x1303ec [0x238fb48]>{contents = "body"} = <CFBasicHash 0x86b3e00 [0x238fb48]>{type = mutable dict, count = 1,

entries =>
11 : <CFString 0x86b4550 [0x238fb48]>{contents = "error"} = <CFBasicHash 0x86b3bf0 [0x238fb48]>{type = mutable dict, count = 3,

entries =>
2 : <CFString 0x86b3be0 [0x238fb48]>{contents = "type"} = <CFString 0x86b4020 [0x238fb48]>{contents = "OAuthException"}
3 : <CFString 0x86b3fc0 [0x238fb48]>{contents = "message"} = <CFString 0x86b3f50 [0x238fb48]>{contents = "(#3503) Missing required value for property "image:url"."}
6 : <CFString 0x86b4540 [0x238fb48]>{contents = "code"} = 3503

}
}
}
, com.facebook.sdk:HTTPStatusCode=400}

但是,在 Graph Explorer 上,即使有 5 张图像,一切都很好。

这是我的 Params 字典的示例:

{
"access_token" = BAAB1cz5RzQUBAGoD1LeExTtPp8GqdfB9HbwzTuNuVocqtuuDS4Xhz7U6RtgijzHobZAShxT3TzrlmQlf4HqPt08g27iIdss14vAKtYZBgj1ZCgyMaKO9Q4AHe2V1UjeAcVYflSdEwZDZD;
campaign = "http://www.appmobil.com/byclick/fbPost.php?fb:app_id=129137827237125&og:type=byclick:campaign&og:title=SteakIt&og:description=\U05e1\U05d8\U05d9\U05d9\U05e7 \U05d1\U05e4\U05d9\U05ea\U05d4 \U05d7\U05d3\U05e9 \U05dc\U05d9\U05d3 \U05d4\U05e9\U05e2\U05d5\U05df \U05d1\U05d9\U05e4\U05d5 \n\U05dc\U05e4\U05e8\U05d8\U05d9\U05dd:  www.steakit.co.il&og:image=http://www.appmobil.com/byclick/upload/2848824820.jpg&body=test";
"image[0][url]" = "http://www.appmobil.com/byclick/upload/2848824820.jpg";
"image[0][user_generated]" = true;
"image[1][url]" = "http://www.appmobil.com/byclick/upload/1455803044.jpg";
"image[1][user_generated]" = true;
"image[2][url]" = "http://www.appmobil.com/byclick/upload/3926035232.jpg";
"image[2][user_generated]" = true;
"image[3][url]" = "http://www.appmobil.com/byclick/upload/1691072699.jpg";
"image[3][user_generated]" = true;
"image[4][url]" = "http://www.appmobil.com/byclick/upload/1982850946.jpg";
"image[4][user_generated]" = true;
message = "\U05e1\U05d8\U05d9\U05d9\U05e7 \U05d1\U05e4\U05d9\U05ea\U05d4 \U05d7\U05d3\U05e9 \U05dc\U05d9\U05d3 \U05d4\U05e9\U05e2\U05d5\U05df \U05d1\U05d9\U05e4\U05d5 \n\U05dc\U05e4\U05e8\U05d8\U05d9\U05dd:  www.steakit.co.il";

 }
4

0 回答 0