javascript - Facebook - what is the current access token? -
after logging in {scope:'publish_actions,manage_pages'}
, request list of pages using graph api
fb.api('/me/accounts', function(response) { ..... ..... gives me list of pages , page tokens }
now question access token or page token future "/me" translated to?
for example, refer
1) fb.api("/me",............)
me refer user id or of page id's retrieved above?
2) fb.api("/platform",........)
again page api read here? (i confused because don't see page-id being passed explicitly api function.
fb.api( "/me",... .........) me refer user id or of page id's retrieved above?
that depends of course on access token used make request – if it’s user access token, refer user, , if it’s page access token, refer page. (and if it’s app access token, result in error.)
fb.api( "/platform", ........) again page api read here ?
the 1 has username platform
set of course.
( confused because don't see page-id being passed explicitly api function.
it not have id, usernames of users or pages work well. (well, expect fact field username
has been removed in api v2.0.)
Comments
Post a Comment