Update a conversation

PUT /api/security_ai_assistant/current_user/conversations/{id}

Update an existing conversation using the conversation ID. This endpoint allows users to modify the details of an existing conversation.

Path parameters

  • id string(nonempty) Required

    The conversation's id value.

    Minimum length is 1.

application/json

Body Required

  • LLM API configuration.

    Hide apiConfig attributes Show apiConfig attributes object
  • category string

    The conversation category.

    Values are assistant or insights.

  • Exclude from last conversation storage.

  • id string(nonempty) Required

    The ID of the anonymization field.

    Minimum length is 1.

  • messages array[object]

    The conversation messages.

    AI assistant conversation message.

    Hide messages attributes Show messages attributes object
    • content string Required

      Message content.

    • isError boolean

      Is error message.

    • metadata object

      Metadata

      Hide metadata attribute Show metadata attribute object
    • reader object

      Message content.

      Additional properties are allowed.

    • role string Required

      Message role.

      Values are system, user, or assistant.

    • timestamp string(nonempty) Required

      Timestamp when the anonymization field was initially created.

      Minimum length is 1.

    • Trace data

      Hide traceData attributes Show traceData attributes object
      • traceId string

        Could be any string, not necessarily a UUID

      • Could be any string, not necessarily a UUID

  • Replacements object used to anonymize/deanonymize messages

    Hide replacements attribute Show replacements attribute object
    • * string Additional properties
  • summary object
    Hide summary attributes Show summary attributes object
    • How confident you are about this being a correct and useful learning.

      Values are low, medium, or high.

    • content string

      Summary text of the conversation over time.

    • public boolean

      Define if summary is marked as publicly available.

    • timestamp string(nonempty)

      Timestamp when the anonymization field was initially created.

      Minimum length is 1.

  • title string

    The conversation title.

Responses

  • 200 application/json

    Indicates a successful call. The conversation was updated successfully.

    Hide response attributes Show response attributes object
    • LLM API configuration.

      Hide apiConfig attributes Show apiConfig attributes object
    • category string Required

      The conversation category.

      Values are assistant or insights.

    • createdAt string Required

      The time conversation was created.

    • Exclude from last conversation storage.

    • id string(nonempty) Required

      The ID of the anonymization field.

      Minimum length is 1.

    • messages array[object]

      The conversation messages.

      AI assistant conversation message.

      Hide messages attributes Show messages attributes object
      • content string Required

        Message content.

      • isError boolean

        Is error message.

      • metadata object

        Metadata

        Hide metadata attribute Show metadata attribute object
      • reader object

        Message content.

        Additional properties are allowed.

      • role string Required

        Message role.

        Values are system, user, or assistant.

      • timestamp string(nonempty) Required

        Timestamp when the anonymization field was initially created.

        Minimum length is 1.

      • Trace data

        Hide traceData attributes Show traceData attributes object
        • traceId string

          Could be any string, not necessarily a UUID

        • Could be any string, not necessarily a UUID

    • namespace string Required

      Kibana space

    • Replacements object used to anonymize/deanonymize messages

      Hide replacements attribute Show replacements attribute object
      • * string Additional properties
    • summary object
      Hide summary attributes Show summary attributes object
      • How confident you are about this being a correct and useful learning.

        Values are low, medium, or high.

      • content string

        Summary text of the conversation over time.

      • public boolean

        Define if summary is marked as publicly available.

      • timestamp string(nonempty)

        Timestamp when the anonymization field was initially created.

        Minimum length is 1.

    • timestamp string(nonempty)

      Timestamp when the anonymization field was initially created.

      Minimum length is 1.

    • title string Required

      The conversation title.

    • The last time conversation was updated.

    • users array[object] Required

      Could be any string, not necessarily a UUID.

      Hide users attributes Show users attributes object
  • 400 application/json

    Generic Error. This response indicates an issue with the request, such as missing required parameters or incorrect data.

    Hide response attributes Show response attributes object
PUT /api/security_ai_assistant/current_user/conversations/{id}
curl \
 --request PUT 'https://localhost:5601/api/security_ai_assistant/current_user/conversations/abc123' \
 --header "Authorization: $API_KEY" \
 --header "Content-Type: application/json" \
 --data '{"title":"Updated Security Discussion","category":"insights","messages":[{"role":"assistant","content":"The issue was resolved.","timestamp":"2023-10-31T12:30:00Z"}],"apiConfig":{"connectorId":"54321","actionTypeId":"09876"},"replacements":{},"excludeFromLastConversationStorage":true}'
Request example
{
  "title": "Updated Security Discussion",
  "category": "insights",
  "messages": [
    {
      "role": "assistant",
      "content": "The issue was resolved.",
      "timestamp": "2023-10-31T12:30:00Z"
    }
  ],
  "apiConfig": {
    "connectorId": "54321",
    "actionTypeId": "09876"
  },
  "replacements": {},
  "excludeFromLastConversationStorage": true
}
Response examples (200)
{
  "id": "abc123",
  "title": "Updated Security Discussion",
  "users": [
    {
      "id": "user1",
      "name": "John Doe"
    }
  ],
  "category": "insights",
  "messages": [
    {
      "role": "assistant",
      "content": "The issue was resolved.",
      "timestamp": "2023-10-31T12:30:00Z"
    }
  ],
  "apiConfig": {
    "connectorId": "54321",
    "actionTypeId": "09876"
  },
  "createdAt": "2023-10-31T12:01:00Z",
  "updatedAt": "2023-10-31T12:31:00Z",
  "replacements": {},
  "excludeFromLastConversationStorage": true
}