Android 在哪里可以找到 Facebook 的 API 密钥和 API 秘密?
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/2289712/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Where do I find API key and API secret for Facebook?
提问by Sara
Trying to connect to Facebook to make a statusupdate through my Android application. Got the whole thing running but I need API key + secret. Where can I create/get a hold of these?
尝试连接到 Facebook 以通过我的 Android 应用程序进行状态更新。整个事情都在运行,但我需要 API 密钥 + 秘密。我在哪里可以创建/获得这些?
private static final String apiKey = "<YOUR API KEY>";
private static final String apiSecret = "<YOUR SECRET KEY>";
Tried the same thing with Twitter and then I just "created" an application and recieved "ConsumerKEY" and "ConsumerSECRET", but what is the deal with Facebook?
在 Twitter 上尝试了同样的事情,然后我只是“创建”了一个应用程序并收到了“ConsumerKEY”和“ConsumerSECRET”,但是与 Facebook 有什么关系?
采纳答案by PanJanek
You have to log on to facebook (with any valid account), go to Account -> Application settings -> Developer -> Set up new application (button at the top right). After creating application you will see the key and secret at application settings page.
您必须登录 facebook(使用任何有效帐户),转到帐户 -> 应用程序设置 -> 开发人员 -> 设置新应用程序(右上角的按钮)。创建应用程序后,您将在应用程序设置页面看到密钥和秘密。
回答by Ulug'bek Ro'zimboyev
Nowaday, facebook developers page and creating API process was changed. now you must to open developers.facebook.com/apps. If you have registrated as a facebook developer you will see in top of the right create new app, otherwise you have to do registration. After than create a app. I use the site as a helperand the urlhelpful too, but the site is a few older.
现在,Facebook 开发者页面和创建 API 的流程发生了变化。现在您必须打开developer.facebook.com/apps。如果您已注册为 facebook 开发者,您将在右侧看到创建新应用程序,否则您必须进行注册。之后创建一个应用程序。我使用该网站作为助手,网址也很有帮助,但该网站有些旧。
Here is docsyou can get all information about creating new app
回答by ceejayoz
You'll need to create an application at http://www.facebook.com/developers/. This will give you an API key and secret specific to your app.
您需要在http://www.facebook.com/developers/创建一个应用程序。这将为您提供特定于您的应用程序的 API 密钥和秘密。