tree hh
tree hh

Reputation: 269

Get photo from album ID facebook sdk

I user code as follow to get album id in facebook and i get album_id successfully..But when i use album id to get file JSON through URL https://graph.facebook.com/album_id but it return FALSE.I don't know why?

            String wallAlbumID = "";
            String response;
            response = mFacebook.request("me/albums");
            JSONObject json = Util.parseJson(response);
            JSONArray albums = json.getJSONArray("data");
            for (int i =0; i < albums.length(); i++) {
            JSONObject album = albums.getJSONObject(i);                     
                wallAlbumID = album.getString("id");
                Toast.makeText(getBaseContext(), wallAlbumID, Toast.LENGTH_LONG).show();
                Log.d("JSON", wallAlbumID);
                //break;
            }

Upvotes: 0

Views: 1083

Answers (1)

maaz
maaz

Reputation: 4493

Kindly Add access token in your request. Seems like you are missing it.

Upvotes: 3

Related Questions