Confluence Knowledge Ingestion
Overview
This document is a brief overview of the functionality and the requirements of Aisera’s Confluence connector.
Create an Aisera Service Account
Use the Aisera Admin UI to create an Aisera Service Account User that can log into your Confluence system. This user only needs Read permissions (with Export ability) to transfer data to the Aisera platform DB. If you plan to use Ticket Concierge, Knowledge Generation, or other features that write back to your Confluence system, this user will need Read/Write permission (with Import/Export ability). This user does not need Execute or Delete permissions because all Aisera operations will be performed, tracked, and logged in the Aisera cloud.
How to obtain Confluence API credentials
Basic Authentication - This type of authorization requires a username and password to access the API endpoints.
To obtain Basic auth credentials for the Confluence API, you will need to have a Confluence account with administrative or API access permissions.
Once you have access, follow these steps:
Log in to your Confluence account.
Click on your profile picture or icon in the top right-hand corner of the screen and select Settings.
In the left-hand menu, select API Tokens.
Click on the Create API Token button.
Enter a label for your API token and select the permissions you want to grant to it.
Click on the Create button.
Your API token will be displayed on the screen. This is your basic auth credentials.
Note: Basic authentication uses your email address as the username and the API token as the password. Be sure to keep your API token secure as it provides access to your Confluence data.
OAuth 2.0 - Confluence supports the OAuth 2.0 protocol, which enables users to grant third-party applications access to their Confluence data without sharing their passwords. OAuth 2.0 supports several grant types, including authorization code grant, implicit grant, client credentials grant, and resource owner password credentials grant. To get OAuth 2.0 credentials for the Confluence API, you will need to follow these steps:
In the Developer Console, select Create App and choose Confluence as the product you want to develop for.
Enter the name and description of your app and select the authentication method you want to use, which should be OAuth 2.0 (3LO).
Fill out the required information for your app, such as the callback URL (
https://<tenant-url>/?id=aisera.oauth.oauthCommand
) and the scopes you want to request.Submit your app for review, which can take several days to complete.
Once your app is approved, you will receive your OAuth 2.0 credentials, which consist of a client ID and a client secret.
To use your credentials, you will need to authenticate your app with Confluence using the OAuth 2.0 authorization flow, which involves sending the user to the Confluence authorization page to grant access to their data and then exchanging the authorization code for an access token.
Source: https://developer.atlassian.com/cloud/confluence/oauth-2-3lo-apps/
Setup Confluence Integration
Follow the below steps to setup the integration with Aisera:
Login into Aisera with the Admin user credentials.
Navigate to Settings -> Integrations.
Click on + New Integration.
Search and Click on Confluence.
Apply the base URL and replace your domain with ‘your-domain’ & click Next.
Choose the authorization you want, fill in the credentials, and then click OK.
Setting up Data Source
Click on Settings > Data Source > + New Data Source.
Search for Confluence and Select.
Enter the General details:
Name - Enter the name to be given to the DataSource
Type - Enter the Type i.e. Downstream or Upstream.
Integration - Select the Integration created from the dropdown.
Functions - Knowledge Base Learning (default)
Schedule - Select the schedule of the DS you want it to run.
Data Retrieval - Incremaltal (ingests only delta) and Date Range ( ingests only for the selected date range)
Language - Select the preferred language
Premium - No mandetory
Public Domain - Enter the public domain. If a data source is marked with a public domain name, any KB ingested from DS will come up as a hint to a related question to the bot. Description - Enter the description you want to give to the DS.
Confluence-specific Space Parameter
The Data Sources Configuration includes entering a series of parameters in the configuration windows (that appear as Configuration tabs if you edit the configuration at a later time). For a Confluence data source, you MUST enter a value in the Space field, or you may receive an Out-of-Bounds error.

In this case, the word 'Spaces' refers to Confluence Spaces that you want to use as data sources. (This translates to SpaceKey=""
in the database column: input_params
in the data_sources
table).
Therefore you may see an error message similar to the following in the details of your Data Integration Job Execution:
java.lang.Exception: Test Connection failed for function: LearnKB, message: Status Code: 0 | Information: No spaceKey provided. Please provide a spaceKey
To eliminate this error, edit the Data Source configuration for your tenant (Settings > Data Source, choose Data Source, then click the pencil icon) and enter valid Confluence Spaces in the Spaces field of the Aisera Data Source Configuration parameters.
Getting the spaces and directories in Confluence
Visit the space directory – choose Spaces > Space Directory in the Confluence header.
Choose the spaces you'll use the most – there may be a space or two that you'll use on a regular basis. Click the star to the right of a space to make it appear under My Spaces on the dashboard.
Choose space categories – you'll see a list of all the spaces in your Confluence site. Choose the My Spaces category on the left to see only the spaces you marked with a star. Then choose all spaces again.
Filter the list of spaces – Type part of a space name in the Filter field at the top right. That'll quickly narrow down the list of spaces if there are a lot of them.
Click Next and OK.
Last updated