Skip to main content
Skip table of contents

Configuration of the AI Assistant for Web Client

Installation Instructions

PLANTA AI Assistant is available in a separate container and must be installed beforehand.

Configuration Basics

There are different ways to apply the configuration, namely in the following order, from lowest to highest priority. If a variable has been defined at more than one position, that with the highest priority applies:

  1. appsettings.json: Main configuration (default), it is not recommended to change it

  2. appsettings.[Environment].json: Environment-specific configuration (e.g. production)

  3. Environment variables: set at an arbitrary position in the host operating system (e.g. passed on with the -e flag in a docker container)

Example format for a setting in an environment variable, use __ to separate sections.

ConfluenceSettings__BaseUrl=https://help.planta.de

Settings

Confluence Settings

Are required to update the context for the AI-assistant.

Key

Description

Example value

BaseUrl

Base URL for the Confluence API

https://help.planta.de

ApiToken

API token for the Confluence API

token

OpenAI Settings

Key

Description

Example value

ApiKey

API Key for OpenAI

key

Assistant Settings

Key

Description

Example value

ID

ID of the Open AI assistant

asst_7UPm2TZbgwbvefdenCa2h

VectorStoreId

Vector store ID, the store in which the Confluence context is saved

vs_i8DeIabvrefdsQMUcfT1Rm0B

Streaming

Flag that enables streaming

true

Authentication Settings

Key

Description

Example value

ApiKey

API key for authentication, this key is required if the API is used to update the Confluence context.

apikey123

ReviewLink Settings

Is used by the assistant to ask the user for a rating after a conversation.

Warning

  • This setting is only intended for internal use and should not be altered by the customer.

Key

Description

Example value

ReviewMessage

Message for ReviewLinks

You are welcome to rate us on the following platforms:

ReviewLinks

List of ReviewLinks

[{"name": "Linkedin", "link": "https://de.linkedin.com/company/planta-projektmanagement-systeme-gmbh ", "icon": "/icons/LI-Logo.png"}, {"name": "Trusted", "link": "https://trusted.de/planta-project-bewertung ", "icon": "/icons/trusted_logo.png"}]

Logging

See https://learn.microsoft.com/en-us/aspnet/core/fundamentals/logging/?view=aspnetcore-9.0#configure-logging

Configure Ports

The port can be configured using the default aspnet core configuration. The default port is 5000

Example

CODE
{
  "ConfluenceSettings": {
    "BaseUrl": "https://help.planta.de",
    "ApiToken": "token"
  },
  "OpenAISettings": {
    "ApiKey": "key"
  },
  "AssistantSettings": {
    "Id": "asst_7UPmbafdawegonCa2h",
    "VectorStoreId": "vs_i8DavbdfRreeqrfLQMUgh1Rm0B",
    "Streaming": true
  },
  "AuthenticationSettings": {
    "ApiKey": "apikey123"
  },
  "ReviewLinkSettings": {
    "ReviewMessage": "Gerne können Sie uns auf folgenden Plattformen bewerten:",
    "ReviewLinks":[{
      "name": "Linkedin",
      "link": "https://de.linkedin.com/company/planta-projektmanagement-systeme-gmbh",
      "icon": "/icons/LI-Logo.png"},
      {
        "name": "Trusted",
        "link": "https://trusted.de/planta-project-bewertung",
        "icon": "/icons/trusted_logo.png"}]
  },
  "Logging": {
    "LogLevel": {
      "Default": "Information",
      "Microsoft.AspNetCore": "Warning"
    }
  },
  "AllowedHosts": "*"
}

Endpoint Documentation

POST/embeddings/Create

This endpoint is used to create embeds by updating and retrieving outdated pages from Confluence, converting them to files and uploading them to OpenAI.

Queries
  • URL: /embeddings/Create

  • Method: POST

  • Authorization: Requires API key authentication via bearer token.

Request Body

The request body should be a JSON object with the following properties:

property

Type

Description

SpaceKey

string

Key of the Confluence space

Language

string

Language in which the pages are displayed.

Example:

CODE
{
  "SpaceKey": "exampleSpace",
  "Language": "en"
}
Responses
  • 200 OK: The embeddings were created successfully.

  • 400 Bad Request: The request body is invalid or missing.

Example

Queries

CODE
POST /embeddings/Create HTTP/1.1
Host: example.com
Content-Type: application/json
Authorization: Bearer YOUR_API_KEY

{
  "SpaceKey": "exampleSpace",
  "Language": "de"
}

Response:

CODE
HTTP/1.1 200 OK

Response (invalid query):

CODE
HTTP/1.1 400 Bad Request
Content-Type: application/json
 
{
  "error": "Invalid request body"
}
JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.