This guide will help you configure Twitter for your Firebase Auth app.
You will be required to provide a redirect URI, the URI should be similar to: https://my-app-12345.firebaseapp.com/__/auth/handler
You only need to change the project name in the beginning of the URI.
-
Register in the Twitter Developer portal. You may be asked to provide a valid cellphone number to complete your registration.
-
Once registered locate a button that says
Create New App
and click it. -
Fill all the fields as normally. Once you reach the Callback URL, provide the URL previously mentioned.
- Go to the Settings tab and make sure these two options are checked:
- Enable Callback Locking (It is recommended to enable callback locking to ensure apps cannot overwrite the callback url).
- Allow this application to be used to Sign in with Twitter.
- Go to the
Keys and Access Tokens
tab and copy down yourConsumer Key
andConsumer Secret
. - Go back to the Firebase console and select your project.
- Click the
Auth
option in the left side menu. - Click the
SIGN-IN METHOD
button in the top menu and then selectTwitter
from the providers list. - Click the
Enable
toggle button and set it toon
, you will be asked for theAPI Key
andAPI Secret
which are theConsumer Key
andConsumer Secret
respectively. - Once you have finished filling the form press the
Save
button.
The Twitter provider has been successfully enabled and configured.