7

I download Hackbook example from git then, I create and run project. It show that Login failed: invalid_key(I didn't change anything) So, I try create my new own app and add Hash key that i got from keytool to facebook app setting (Android Native App) Then, I change this new Facebook("My_own_APP_ID"); It works!

The question:

  1. Do I need to add new key hash every time I change development computer(In case, there are many collaborators, Do they need to change Facebook_APP_ID everytime ?
  2. In case, I wanna launch this app to market. Do I need to change this keytool -exportcert -alias androiddebugkey -keystore ~/.android/debug.keystore | openssl sha1 -binary | openssl base64 when i ask for hash key ?
April Smith
  • 1,810
  • 2
  • 28
  • 52

1 Answers1

14

The answer based on my experience

Do I need to add new key hash every time I change development computer(In case, there are many collaborators, Do they need to change Facebook_APP_ID everytime ?

You don't need to change Facebook_APP_ID everytime. Once you created facebook app, you can add multiple key hash to it. If you have many collaborators, get keyhash from them and add the keyhash to your facebook app.

In case, I wanna launch this app to market. Do I need to change this keytool -exportcert -alias androiddebugkey -keystore ~/.android/debug.keystore | openssl sha1 -binary | openssl base64 when i ask for hash key ?

Yes. You replace ~/.android/debug.keystore with your own publishing keystore and again add that keyhash to facebook app.


Another alternative,

if you don't want to add a lot of keyhash to facebook app, you can always use one common debug key to sign your android app for all collaborators.

But of course, don't share your publishing key to everyone.

PH7
  • 3,926
  • 3
  • 24
  • 29
  • Once you created facebook app, you can add multiple key hash to it. If you have many collaborators, get keyhash from them and add the keyhash to your facebook app. : This is answer also valid for GOOGLE sign In – Sagar Devanga Jul 03 '15 at 12:23