我正在开发一个桌面解决方案(c#),可以通过facebook sdk .NET访问facebook,实际上我无法理解如何使用facebook sdk或graph api获取访问令牌,任何建议?
提前谢谢
答案 0 :(得分:0)
我明白了,希望可以提供帮助:)
client = new FacebookClient();
try
{
dynamic getOuth = client.Get("oauth/access_token", new
{
client_id = "xxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
client_secret = "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
grant_type = "client_credentials",
redirect_uri="https://www.facebook.com/connect/login_success.html"
});
token = getOuth.access_token.ToString();
}