Facebook graph API - OAuth Token

后端 未结 11 1956
小鲜肉
小鲜肉 2021-01-30 09:16

I\'m trying to retrieve data using the new graph API, however the token I\'m retriving from OAuth doesn\'t appear to be working.

The call I\'m making is as follows;

11条回答
  •  灰色年华
    2021-01-30 10:03

    Don't use type=client_cred, this is not the access token that a user grants for your app to use. You don't need redirect_uri or code or any approval to get the client_cred type access token.

    Facebook implements an early draft of OAuth 2 at this time. So there is not support for "state" yet.

    But it is nice that you can suffix your state to the redirect_uri, the important point to note here is that the site url that you specified (which is the redirect_uri)

    should not have a

    question mark at the end or anywhere in what you suffix as client state, encoded or not. If you did, you will get the dreaded "Error validating verification code"

    Don't use like that

    http://www.Redirect.com?

    Correct Url is http://www.Redirect.com/

    Hope it helps.

提交回复
热议问题