Facebook authentication: app.json configuration question

I’m quite confused about this instruction from here: Use Facebook authentication - Expo Documentation

The number two Add scheme says:
For Android, you’ll need to add a scheme that contains the app ID as a prefix. Facebook requires this scheme to be able to redirect the user back to the app after the authentication process is complete.

For example, if your app ID is 1234567890, then the scheme will be fb1234567890. Modify the scheme in Expo config and convert it to an array if you have more than one custom scheme to add this scheme:

app.json:

{
  "expo": {
    "scheme": ["yourscheme", "fb1234567890"]
  }
}

Why do when I follow this format, I get a warning:

Linking found multiple possible URI schemes in your Expo config.
Using 'yourscheme". Ignoring: fb1234567890, com.your.app.
Please supply the preferred URI scheme to the Linking API.

Looks like multiple schemes functionality is unfinished (expo/Schemes.ts at ae642c8a5e02103d1edbf41d1550759001d0f414 · expo/expo · GitHub), because there is no options to set primary URI schema

Also issue with facebook authSession SDK 48 wont redirect. What is the template for an authorized redirect we should put in facebook dev portal?

It also becomes impossible to run eas update when you follow the documented example.

You’ll get an error such as the one below

✔ Exported bundle(s)
√ Uploaded 2 app bundles
√ Uploading assets skipped - no new assets found
√ Channel: staging pointed at branch: staging
✖ Failed to publish updates
Manifest Validation Error:
scheme:should be string
This is likely a problem with your app.json, or app.config.js

What is the recommended way to proceed? Only use the facebook id as scheme and forgo the second scheme? This might give problems in other area’s of the app.

1 Like

two schemes in a list should be supported. Just think its about building the correct redirect template to put into facebook dev console.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.