I have seen several flavours of this question going around but nothing exactly specific nor answered so trying it myself.
I am trying to build a Facebook login experience via the browser into my Facebook-based app that will require the users to not remember their passwords as much as possible. This means that if
- they log in via their desktop browser and are already logged in, it will only ask them to 'OK' the permissions
- they log in from their mobile browser and are logged in via their respective native app (Android/iOS), it will simply redirect them to the native app, ask for the app permissions and redirect them back to the success page on the browser
- they log in from any browser and are not currently logged onto Facebook in any form, they have to enter their password and authenticate (whether natively or via browser this does not matter)
I know how the first can be done - that is pretty straightforward using the JS SDK. The second point is the tougher bit.
I am aware of existing custom URL schemes for Android and iOS but nothing specifically really mentions how that can be used for authentication and/or authorisation of Facebook apps. Does anyone have any ideas on how this can be done?
Thanks!