Add the Live Experience Widget to your Web Page

Display the widget in your HTML page.

To display the widget in your HTML page, call the controller.addComponent method after you've initialized context variables:
<script type="text/javascript">
 require(["oracle.live.api"], function(liveApi) {
 const getAuthToken = (callback) => {
 fetch(new Request("/my_server_path/auth.cgi"))
 .then(response => { return response.json(); })
 .then(auth => { callback(auth.access_token, auth.expires_in); });
 };
 getAuthToken((myAuthToken, myTokenExpiry) => {
 liveApi.controller.service.userID = "bob@example.com";
 liveApi.controller.service.tenantID = "MyTenant";
 liveApi.controller.service.authToken = myAuthToken;
 liveApi.controller.service.authRefresh(myTokenExpiry, () => {
 app.getAuthToken((jwt) => { 
 liveApi.controller.service.authToken = jwt; });
 });
 liveApi.controller.contextAttributes.set("appLocation", 
 "Scenario Name");
 liveApi.controller.addComponent();
 });
 });
</script>

What to do next

Next, see Additional Configuration Options for your Web Pages.