简体   繁体   中英

Facebook Graph API - Tagged Places in version 2.0

I used the Graph API with javascript to fetch all of my data contained locations in v1.0. ( I used FB.api("/v1.0/me/locations", function (response) { ... }); )

I know that the updated version is 2.2 and the "locations" node is replaced by "tagged_places" node in v2.0 and above.

I also use the Graph API Explorer to test my results. I try this, GET: /v2.2/me?fields=tagged_places and the results are exactly what I want.

However, in my js code, I try: FB.api("/v2.2/me?fields=tagged_places", function (response) { ... }); and there is NO any results!

Besides, I set version: 'v2.2' in Parse.FacebookUtils.init(); I also ask the permissions :user_tagged_places,user_photos,user_status,user_friends,user_about_me,user_birthday,read_stream in Parse.FacebookUtils.logIn();

I need almost all of the data of my checkins(aka locations in v1.0/tagged_places in v2.0) to add into my database. I try to fetch /me/photos, but the results are not satisfied. So I still need to use maybe this: FB.api("/v2.2/me?fields=tagged_places", function (response) { ... });

So... can anyone help me? please....

I went through permissions in groups testing them out and I figured out what the problem was. You need to have the permission of the item you were tagged in. So in my case I was tagged in photos, so I needed user_photos permission to gain access to user_tagged_places . It actually creates quite an issue because you need to know how a user was tagged to retrieve their tagged_places.

If a user was tagged at a place in a post you need a different permission than if they were tagged in a photo.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM