I am trying to implement Facebook log in and then allow the user to post status updates and share details to Facebook through the app. I (think) the user is not successfully able to log into Facebook. Below is the process the user goes through:
- User clicks Login button
- User logs in successfully
- Below window appears to user
- When the user hits the
Share
button, this error message appears:(#404) remote_app_id does not match stored id
I have gotten the Key Hashes for my debug keystore and release keystore using the below 2 command lines.
Debug Keystore
keytool -exportcert -alias androiddebugkey -keystore C:\Users\lyonsmg\.android\debug.keystore | C:\OpenSSL-Win64\bin\openssl.exe sha1 -binary | C:\OpenSSL-Win64\bin\openssl.exe base64
Release Keystore
keytool -exportcert -alias C:\Users\lyonsmg\matt\_keystores_and_passwords\BibleTriviaLite_keystore -keystore C:\Users\lyonsmg\matt\_keystores_and_passwords\BibleTriviaLite_keystore | C:\OpenSSL-Win64\bin\openssl.exe sha1 -binary | C:\OpenSSL-Win64\bin\openssl.exe
I used android
as the password for the debug keystore and my private password for the release keystore. I placed both of the resulting key hashes in Developers Settings on Facebook and also in Facebook App Dashboard. Its the 2 places that the Facebook Android SDK docs tell me to put it.
I have my app_id that is found in the Facebook App Dashboard in my Android Manifest
. Below is my Android Manifest and you can see the 2 spots where my app_id is found. You can find it in the code as @string/app_id
.
Android Manifest
<manifest
xmlns:android="http://schemas.android.com/apk/res/android"
package="matt.lyons.bibletrivia.lite"
android:versionCode="13"
android:versionName="2.1.0" >
<uses-sdk
android:minSdkVersion="8"
android:targetSdkVersion="17" />
<application
android:icon="@drawable/icon_blue_bg"
android:label="@string/app_name"
android:theme="@style/AppTheme" >
<meta-data
android:name="com.google.android.gms.games.APP_ID"
android:value="@string/app_id" />
<activity
android:name=".SplashScreen"
android:screenOrientation="portrait" >
<intent-filter>
<action
android:name="android.intent.action.MAIN" />
<category
android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name="com.google.ads.AdActivity"
android:configChanges="keyboard|keyboardHidden|orientation|screenLayout|uiMode|screenSize|smallestScreenSize" />
<activity
android:label="@string/app_name"
android:name=".About"
android:screenOrientation="portrait" />
<activity
android:label="@string/app_name"
android:name=".Categories"
android:screenOrientation="portrait" />
<activity
android:label="@string/app_name"
android:name=".Question"
android:screenOrientation="portrait" />
<activity
android:label="@string/app_name"
android:name=".Quiz"
android:screenOrientation="portrait" />
<activity
android:label="@string/app_name"
android:name=".QuestionView"
android:screenOrientation="portrait" />
<activity
android:label="@string/app_name"
android:name=".Results"
android:screenOrientation="portrait" />
<activity
android:label="@string/app_name"
android:name=".Highscores"
android:screenOrientation="portrait" />
<activity
android:label="@string/app_name"
android:name=".DatabaseHelper"
android:screenOrientation="portrait" />
<activity
android:label="@string/app_name"
android:name=".ComingSoon"
android:screenOrientation="portrait" />
<activity
android:label="@string/app_name"
android:name=".MainMenu"
android:screenOrientation="portrait" />
<activity
android:label="@string/app_name"
android:name=".MyApplication"
android:screenOrientation="portrait" />
<activity
android:label="@string/app_name"
android:name=".Levels"
android:screenOrientation="portrait" />
<activity
android:label="@string/app_name"
android:name=".GameType"
android:screenOrientation="portrait" />
<meta-data android:value="@string/app_id" android:name="com.facebook.sdk.ApplicationId"/>
<activity android:label="@string/app_name" android:name="com.facebook.LoginActivity"></activity>
</application>
<uses-permission
android:name="android.permission.INTERNET" />
<uses-permission
android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission
android:name="com.android.vending.BILLING" />
</manifest>
Sorry I wrote so much but I was just trying to cover all my bases and be thorough! My question is, what am I doing wrong? Why is it telling me that my "remote_app_id" does not match my "stored id"?
You're using the same
value="@string/app_id"
for bothcom.google.android.gms.games.APP_ID
andcom.facebook.sdk.ApplicationId
.Your Facebook app ID can't possibly be the same as your Google app ID. You need to get the Facebook app ID from the Facebook App Dashboard.