This topic describes how to register your application and generate credentials for your clients that are required to exchange messages between your application and the Kore.ai XO Platform.
When you register your app, you will need to select a security algorithm:
- HS256 – XO Platform generates and displays the Client ID and Client Secret necessary to generate the JWT token from your server.
- RS256 – You upload your public key to the platform and use the private key to generate the signature from your server.
To register an app:
- Open the assistant that you are working with.
- Select the Deploy tab from the top menu.
- From the left menu, click Channel > Web/Mobile Client.
- In the Select App drop-down list, select your existing app registration or click Create App to create a new app.
- In the Name field, enter the name for the app registration used in XO Platform, for example, Weather app.
- Select one of these scopes for the app:
- Allow anonymous users to chat with the assistant: enables anonymous users to interact with the assistant.
- Auto register new users on Kore.ai XO Platform: Select to control the auto-user registration in Kore.ai if the user assertion is unknown.
- In the JWT Signing Algorithms Used For Client App Authentication drop-down list, select one of the two available security algorithms. Refer here on how to generate the below keys. The algorithms are as follows:
- RS256: Select to enable the Public Key field. The Public Key is used by the Kore.ai XO Platform to authenticate the client application.
- HS256: Select to generate a Secret Key and a Client ID. The Client ID is required for SDK initialization, and the Secret Key used by the Kore.ai XO Platform to authenticate the client application.
- Optionally, In the Push Notifications section, click Enable and then specify a URL to send the notifications to.
- Click Create. The app registration details appear.
- To copy the app registration details to the clipboard for your application, you can click Copy for Bot Name, Bot ID, and Client ID. For Client Secret, click View, and then click Copy.
- In the Allow Alert Task Setup section, Select Yes to enable your application users to set up their own alert tasks using the web client. By default, this setting is disabled for web client users, but mobile client users can always set up their own alerts.
- In the Enable Channel section, select Yes to enable the channel immediately after saving.
- Click Save to save the settings and close the Web/Mobile Client Channel page.
The Channel Information updated successfully message is displayed on the top-right corner of the page.
Once the app is registered, you can implement it using one of the methods presented under App Details, as follows:
- Share the URL with the users to interact with your virtual assistant.
- Embed HTML: Copy and paste the HTML code before the end of the BODY tag on every page of the application where you want to display the chat widget. Know more