Setup Guide
You can find your app credentials in the Client Application you create in the eGain administration console, under Partition > Integration > Client Application. See eGain’s authentication guide for how to create a client application. Paragon supports two ways to connect eGain:- eGain User OAuth: Your users sign in to eGain, and Paragon calls the Knowledge Hub APIs as that user with delegated scopes.
- eGain Client Credentials: Paragon requests a client-credentials token for the client application, using application scopes (prefixed with
app.).
- Client ID
- Client Secret
- Scopes Requested
Add the Redirect URL to your eGain app
When you use eGain User OAuth, Paragon provides a redirect URL to send information to your eGain client application. To add the redirect URL to your eGain app:- Copy the link under “Redirect URL” in your integration settings in Paragon. The Redirect URL is:
- Add the redirect URL from Paragon as a redirect URL of your eGain client application.
Add your eGain app to Paragon
- Select eGain from the Integrations Catalog.
- Under Integrations > Connected Integrations > eGain > App Configuration > Configure, fill out your credentials in their respective sections:
- Client ID: The Client ID of your eGain client application.
- Client Secret: The client secret of your eGain client application. eGain shows it only once, when you create the client application.
- Scopes: Select the scopes granted on your client application. For eGain User OAuth, Paragon requests
knowledge.portalmgr.read,knowledge.contentmgr.readandcore.aiservices.readby default. For eGain Client Credentials, Paragon requestsapp.knowledge.portalmgr.read,app.knowledge.contentmgr.readandapp.core.aiservices.readby default. Add themanagescopes to create and update articles.
Connecting to eGain
Your users will need the following information from the eGain client application’s Metadata button to connect their eGain account with your integration built with Paragon Connect:- Authorization URL: The user authorization URL, for example
https://auth.egain.cloud/TENANT-U/oauth2/authorize. Required only for eGain User OAuth. - Token URL: The token URL for the client application.
- API Domain: The API host. Knowledge Hub uses
https://api.ai.egain.cloud. - Domain URL: The tenant console URL, which identifies the connected partition.
- Portal ID: The knowledge portal to search and sync, for example
PROD-1000. Required for eGain Client Credentials. With eGain User OAuth, Paragon uses the first portal the user can open when this is blank. - Department ID (optional): The department that owns knowledge folders. Required only to list folders.
- Language (optional): The knowledge language, for example
en-US. Defaults toen-US.
JavaScript
Building eGain workflows
Once your eGain account is connected, you can add steps to perform the following actions:- Articles: Search articles, get an article, list a topic’s articles, create and update articles, and check whether an article is readable
- Portals: Get a portal and list portals
- Topics: List topics
- Folders: Get a folder and list folders
- Answers: Get certified or generative answers and retrieve passages from Knowledge Hub
{{ to invoke the variable menu.
Using triggers
eGain triggers run your workflows when eGain sends a knowledge notification to Paragon. To receive events, copy the Paragon webhook URL and paste it into the eGain administration console. You can use the following triggers:- Article Created
- Article Updated
- Article Deleted