invalid app id when logging into facebook from custom app - android

I used facebook sdk and created app in facebook couple of months back. Also, I was able to access and authenticate to the app.
But not sure what happened all of a sudden I am getting invalid App ID : app_id.
the only difference from last time to now is ... i created new emulator now.
so what are the check list to debug this issue.
I could see many threads asking the invalid app id but none of them ended with answer.

Check whether your app is still listed in your facebook developer account. Check the ID of the app in the facebook page with that you are having now.

Related

Android application: Unable to Login with Facebook in Development mode

I am using ParseFacebookUtils to provide log in feature in my Android Application. I have successfully integrated Facebook and Parse SDK's. I do not want to make the application created on Facebook live to public yet, because it is still under development.
ISSUE:
I am unable to Login to the app when I provide any Facebook Log in credentials EXCEPT for the application administrator's credentials. If I provide any other credentials, I get the following error shown right after Facebook Log in Screen:
App not setup: the developers of this app have not set up this app properly for Facebook .
How can I enable many users to log in to the app without assigning them any role through the Facebook dashboard?
check Hemang answer here, it well explained.You need provide valid email address and make the app available to general public on facebook developer page though it is in testing mode.
Solution 1
Check your keystore is proper.Verify it.
Solution 2
what type of permissions you requested. If some permissions needed to be approved then you have to upload the apk and get approved.
Solution 3
Try to use SimpleFacebook Library. Its quite simple.

Android Facebook SDK SSO "the page you requested cannot be displayed"

I've been stuck on this very frustrating problem all day and through Google I've found many people with the same problem with no answers that relate to the new Facebook API for Android. I have followed the steps listed here exactly :
https://developers.facebook.com/docs/getting-started/facebook-sdk-for-android/3.0/
When I run the sample app on my device I get this:
When I run it on the emulator it works. I understand this to be because of Facebook's SSO implementation. The emulator does not have facebook installed so it signs in for the first time successfully, but the device launches the facebook app and for some reason gives this error and when I travel back, it is as if I am not logged into facebook at all and there is no active session (though I am because when it launches the facebook app I can browse friends, etc.)
I cannot uninstall facebook on my device and even if I could that would be unacceptable for the app users. If possible, I'd like to retain the SSO feature, but somehow make it work!
I have spent all day going back and forth with my Hash Keys, and generated them through my device+code and with the keytool and they match so the problem is not related to that. Besides, the sample app runs on the emulator which surely means its an SSO problem. Thanks in advance.
After 8 hours of scanning through my code and the facebook docs, I simply decided to update my facebook app on my tablet ( I never use it and so never bothered to update it ) and now it all works.
I guess the Facebook app on my tablet was pre-SSO of Facebook on Android, but my created app was expecting it to be supported and giving the error.
Just to be a bit more clear, if you are either running on your device or on the simulator, make sure you have the latest Facebook APK installed. Facebook changed their permissions a while ago, and you may have to manually go to the Google Play store in order to download the updated version of Facebook (it may not auto-update for you given the permission changes).
Disabling Facebook did the trick for me. It forces the app to launch the browser and surf to Facebook that way

Corona Facebook Login

I had implemented Facebook Single Sign On in my app. Then I discovered it did not work if the user already had the fb app installed on their phone. I resolved this by generating a key hash for facebook, everything worked again. Since then I upgraded my Corona account from trial to the pro version. Now my facebook is not working again. I am still using the Android Debug key when building the apk file, and I have tried the original Hash Key which I had and made another one, but I can't get it to work. Any solutions?
Hy, we had the same.
Steps : Make a tutorial facebook login example with corona.
Try, thats will work with installed facebook app.
After implement facebook login into your app like in example.
That was the resolution for us.
But i cant say nothing exact, i got that app by another developer for some update/bugfixes.
For some reason the reason unknown to me, my Facebook Hash Key changed. I ran "adb logcat" when using my app on the device. In the logcat Facebook will tell you what Hash Key was expected. Copy/paste this into your Facebook Developer page and it works.

Unable to run sample Facebook App

I have been working on this all day. I have followed multiple tutorials including the one on facebooks developers site and the one on mybringback.com. I am just trying to get the sample application working.
So far it works on the emulator. it allows me to sign in. Granted i have not installed the facebook apk on the emulator. On my phone i just get 'An error has occured.' message. The stack trace only gives an error message when the app crashes upon exiting. Error is Unable to resume activity... caused by Failure delivering result ResultInfo.... its a null pointer exception when the application tried to resume from attempting facebook login.
I have my facebook app id in the hackbook sample application from facebook sdk.
I have generated a keyhash with the command that the facebook sdk instructs you to use.
I have also used this tool from easyfacebookandroidsdk to somehow get a second keyhash. I did not know which one would be the correct one so i put both of them in the dashboard.
I have updated the facebook application on my testing device.
I entered the package name and class name.
com.facebook.android
com.facebook.android.HackBook
Is there anything else that i need to do with the sample application besides replace the app_id?
Is there anything else that might affect my application from logging into facebook?
Just trying to get a new direction on this because i feel like i have exhausted my brain resources.
So..... I feel a little stupid but i cannot believe that i did not stumble on this info in my searches.
My application was not working because i had facebook already installed on my phone and i was logged in as a different user than i develop with. Once i logged out in the actual facebook application everything worked flawlessly.
Not an error in settings. Thanks for all your help Viewers there was actually not much to go on since everything was actually setup correctly.

Android Facebook app: access token expiry ( expires_in ) is always 0

I am developing an app which uses facebook integration. I am trying to receive the access_token and expires_in tokens from the facebook library classes. Once i am logged in I get the access_token correctly but i always get expires_in token always 0. And because of that I isSessionValid() method always returns false. Kindly let me know if anyone has faced this issue and solved it.
My code runs perfectly fine when i do not have the Facebook app installed in the emulator. I get the webview and I can log in and update status. But when I install Facebook app, clicking on the update status menu option opens the Facebook app, I get redirected to the permissions page and then I get an error saying " Failed to receive access token". This is infact because of the expires_in token being 0.
i do not want to ask the users of the app to uninstall the Facebook app if they have installed. kindly let me the solution to this problem.
Thanks,
Punit
If you put permission offline_access, the token expiry is 0.
For any one else having this issue (if you had put offline_access permission and later removed) follow the steps:
Go to your facebook profile setting and remove your app.
and then do login again.
Give permission to your app again.
Alternately you can do this:
Go to your facebook profile setting > Apps > Your_App and remove "Access my data any time" permission.
Save changes made.
Re-run Your_App(i.e. with no offline_access permission now).
Have you mentioned Key Hash in the app that you created on facebook? If not, create a valid one and mention it. This usually occurs because of the new update features of facebook, However, older versions of facebook work well each time. You can check this by uninstalling updates on your facebook app, and run your code. It still works fine. Learn more from here

Categories

Resources