Obed Eugene
Posts: 0
Joined: Wed Jul 03, 2013 5:37 pm

Issues with Facebook data mapping

Great. It worked when I created a fresh page. But, Im still having to reload the page before the data gets propogated. Is there a way to automatically show the data the first time the page is loaded?

Also, Im having issues getting the profile picture to show. How can I do this?

Maryna Brodina
Posts: 0
Joined: Thu Apr 05, 2012 7:27 am

Issues with Facebook data mapping

Hello!
[quote:]Is there a way to automatically show the data the first time the page is loaded[/quote] on page Load invoke GetToken service. On complete GetToken service event (after you set localStorage variable access_token) run GetData service. Don't invoke these services at the same time on Load/Show events. GetData should be invoked only after GetToken and after you set localStorage variable access_token.
[quote:]The URL of the user's profile pic (only returned if you explicitly specify a 'fields=picture' param)[/quote] see https://developers.facebook.com/docs/...

Make a request with URL like this one codehttps://graph.facebook.com/me?fields=picture&access_token=xxxxxxxxxxxxxxxx/code you'll get in responce something like code{
"id": "xxxxxxxxxxxxxx",
"picture": {
"data": {
"url": "https://fbcdn-profile-a.akamaihd.net/hprofile-ak-prn2/xxxxxxxxxxxxxxxx.jpg",
"is_silhouette": false
}
}
}/code
map URL parameter to inage asset

Michael Brandon
Posts: 0
Joined: Mon Apr 21, 2014 9:17 pm

Issues with Facebook data mapping

Hi Maryna,

Could you explain this part a little more in detail?

"The URL of the user's profile pic (only returned if you explicitly specify a 'fields=picture' param)
see https://developers.facebook.com/docs/...

Make a request with URL like this one https://graph.facebook.com/me?fields=... you'll get in responce something like {
"id": "xxxxxxxxxxxxxx",
"picture": {
"data": {
"url": "https://fbcdn-profile-a.akamaihd.net/...",
"is_silhouette": false
}
}
}
map URL parameter to inage asset"

Do I make these additions in the FacebookMe_services within the Requests? Am I to add "fields=picture" in the "add new parameter" input?

Thanks,

Alena Prykhodko
Posts: 0
Joined: Tue Apr 09, 2013 7:36 am

Issues with Facebook data mapping

Hello Michael,

Yes you should add fields=picture to the service parameters.

Open "Facebook_MeService" service.

Select "Request" tab.

Add "fields" parameters with value "picture".

Michael Brandon
Posts: 0
Joined: Mon Apr 21, 2014 9:17 pm

Issues with Facebook data mapping

Thank you for the quick response. Could you throw up a screen shot for reference?

Kateryna Grynko
Posts: 0
Joined: Thu Nov 15, 2012 9:13 am

Issues with Facebook data mapping

Hi Michael,

Here is how to add a request parameter: http://docs.appery.io/documentation/r...

Michael Brandon
Posts: 0
Joined: Mon Apr 21, 2014 9:17 pm

Issues with Facebook data mapping

Thanks for that. Although, I'm still a little lost. In your above post you mentioned making a request to this URL (https://graph.facebook.com/me?fields=...). Is this intended to be set up as a separate Service (not within the Facebook_MeService) but with peram fields and value picture? And if so, do I need to manually enter the Token where you listed "xxxxxxxxxxxxxxxx" ?

Currently, in my Facebook_MeService it points to https://graph.facebook.com/me. So I simply added the new peram and value within the Request, tested and got this (see image). Is my access_token not mapped currently in the Request? (see 2nd image)

Thanks again for your help here. I apologize for the extra time. Image Image

Alena Prykhodko
Posts: 0
Joined: Tue Apr 09, 2013 7:36 am

Issues with Facebook data mapping

Hi Michael.

Please see the following screen shots:

1 urls is "https://graph.facebook.com/me"

Image

2 adding a parameter

Image

Michael Brandon
Posts: 0
Joined: Mon Apr 21, 2014 9:17 pm

Issues with Facebook data mapping

That is exactly what I have. And as show earlier, here is the error I get. Image

Kateryna Grynko
Posts: 0
Joined: Thu Nov 15, 2012 9:13 am

Issues with Facebook data mapping

Hi Michael,

What session token do you pass? How did you get it from Facebook?

Return to “Issues”