开发者

Create photo album in facebook using android and Graph api

We have a problem creating photo album in facebook using andro开发者_StackOverflow中文版id and graph API. We already have been able to upload photos to facebook using Graph API. We are using following for uploading a photo to facebook.

Bundle params = new Bundle(); params.putString("method", "photos.upload"); params.putString("title", uploadFile.getName()); params.putString("privacy", "{'value':'EVERYONE'}");

facebook.request("https://api.facebook.com/restserver.php?method=photos.upload",params,"POST");

Please let us know if anybody aware of. We have searched a


I have found the working solution for the above problem.

Bundle params = new Bundle();
params.putString("name", albumName);
String response = mFacebook.request("https://graph.facebook.com/me/albums",params,"POST");
String albumId=Util.parseJson(response).getString("id");

Above code will help create a new photo album with the albumName and return the album id generated by facebook.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜