Identity Engine
This guide describes how to run the embedded Identity Engine SDK or Sign-In Widget sample app. Make sure to successfully create and set up your Okta org first. You also need to download and set up the SDK .
Learning outcomes Run the embedded Identity Engine SDK or Sign-In Widget sample app.
What you need Sample code In tandem with the embedded SDK, the widget integrates into your app by using a native language interface and communicates directly with the Okta APIs. The following diagram summarizes the flow.
Note: The Okta Java SDK embedded Sign-In Widget sample app uses the Spring Boot framework. See Spring Boot Getting Started (opens new window) .
Ensure that you've Set up your Okta org for a password factor only use case .
Obtain app-specific configuration values (such as {clientId}
, {clientSecret}
, {yourOktaDomain}
) from the app integration you've created in Okta.
From your command shell, locate the source files for the embedded Sign-In Widget sample apps in the cloned Java SDK project: ...\okta-idx-java\samples\embedded-sign-in-widget
.
Set the app-specific environment variables:
Execute mvn
from the ...\okta-idx-java\samples\embedded-sign-in-widget\
root directory, and then go to the sample app's home page on your browser: http://localhost:8080
. The Embedded Sign-In Widget + Spring Boot Example page appears.
Click Next , and then enter the Username and Password for the user that you used to create your Okta account .
Click Sign in . After you've successfully signed in, the app redirects you to the Embedded Sign-In Widget + Spring Boot Example home page. You can view your user profile by selecting My Profile in the upper-left corner of the page.
Click Logout in the upper-right corner when you finish.
Start your work with the use cases The next step is to build your integration using the sample app. See Load the widget to start using the widget and explore the available use cases.
The embedded SDK flow The SDK integrates into your app by using a native language interface and communicates directly with the Okta APIs by using a REST interface. The following diagram illustrates the SDK flow.
Run the embedded SDK sample app Note: The Okta Java SDK embedded authentication sample app uses the Spring Boot framework. See Spring Boot Getting Started (opens new window) .
Set up your Okta org for a password factor only use case .
Obtain app-specific configuration values (such as {clientId}
, {clientSecret}
, {yourOktaDomain}
) from the app integration that you created in Create an application .
From your command shell, locate the embedded authentication SDK sample app source files in the following path: ...\okta-idx-java\samples\embedded-auth-with-sdk
.
Set the app-specific environment variables:
Execute mvn
from the ...\okta-idx-java\samples\embedded-auth-with-sdk\
sample app root directory, and then go to the sample app's home page in your browser: http://localhost:8080
. The Welcome to the Okta Samples for Java page appears with your app's configuration values.
Click Login on the welcome page, and then enter the Username and Password for the user that you created in Create your Okta account .
Click Login . The app redirects you to a page that displays your basic user profile and security token information.
Click Logout in the upper-right corner of the page to sign out of the sample app.
Work with the use cases After you run the sample app, build an integration using the sample app. Explore use cases that are available with the SDK. Start with the Basic sign-in flow example with the password factor .