Skip to content

Integrate and adjust POST /conversations endpoint #3602

@chriskari

Description

@chriskari

Description
The Kyma Companion frontend needs to make API calls to the POST /conversations endpoint in the Kyma Companion backend. This endpoint initializes a conversation by:

  1. Receiving information about the currently opened resource.
  2. Returning a list of suggestions for initial questions to start the conversation.
  3. Providing a session ID for subsequent interactions.

The POC version already includes a similar API call in the file KymaCompanion/api/getPromptSuggestions.js. However, since the development of the POC, the API structure and requirements have been updated. This API call must be adjusted accordingly to reflect the latest backend implementation.

For detailed information on the updated API structure, refer to the API documentation.

Tasks:
The necessary adjustments include, but may not be limited to

  • Endpoint and URL have changed
  • Cluster authorization should already be properly added to the headers, but take a second look
  • Format of request body has changed
  • Format of response body has changed
  • Response header now contains a session ID that needs to be used for subsequent API calls and must be securely stored on the frontened side
  • Previously the session ID was created on the client side, so this flow probably needs to be adjusted

Metadata

Metadata

Assignees

Labels

kind/featureCategorizes issue or PR as related to a new feature.kyma companionRelated to all activities around the Kyma Companion

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions