Step 10. Test authentication
-
Run the application.
-
Click the Login button and enter the credentials of an existing AM user.
If you set up your server settings properly, you should have one user,
demo
, with passwordCh4ng3it!
. Enter these details, and click Next.The SDK submits the node information to the server. In the application output, notice the following:
-
The request redirects to the
redirectURI
. The SDK validates that information against theredirectURI
from the configuration file, and intercepts the authorization code. -
The SDK then invokes the
accessToken
endpoint with the authorization code, and sends the required information to the server. -
The server returns an access token, scopes, and an ID token.
-
To log out, use
FRUser.currentUser?.logout()
.
-
You have now created an app that can successfully authenticate using your own UI components.