POST
/
ai
/
{v}
/
message
/
kallm
Post message KaLLM
curl --request POST \
  --url https://platform.ai.gloo.com/ai/{v}/message/kallm \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "chat_id": "<string>",
  "query": "What is your name?",
  "character_limit": 123,
  "sources_limit": 123,
  "stream": true,
  "publishers": [
    "<string>"
  ]
}'
{
  "query_id": "q3c870f25-63fc-451f-a9ce-9a5abed55aa0",
  "message_id": "mbc51c1d8-29e7-416f-85fc-9f4209d9887b",
  "message": "My name is Gloo AI Chat, and I'm here to assist you!",
  "timestamp": "2025-02-04T23:55:03.573767"
}
By providing chat_id a new message will be added to the chat session. If no chat_id is provided, a new chat session will be created. Default behavior:
  • Gloo AI will perform a sentiment analysis on your prompt.
  • Gloo AI will provide suggestion follow ups
  • Depending on your prompt, Gloo AI will return sources that have influenced the response from our trusted partners.
You can choose to override the defaults with the query params: intent, enable_sources, enable_suggestions. Example 1: You want a rich answer that is based on trusted sources and provides you follow up suggestions. Omit all query params. Example 2: You know that your prompt is going to require trusted sources as a part of the answer. You also want to not have follow up suggestions. intent: 1, enable_suggestions: 0 Example 3: You know that your prompt is not going to require trusted sources. You also want to not have follow up suggestions. intent: 0, enable_suggestions: 0

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

v
enum<string>
required
Available options:
v1

Query Parameters

chat_id
string | null
default:""
intent
enum<integer> | null
Available options:
0,
1
enable_sources
enum<integer> | null
default:1
Available options:
0,
1,
2
enable_suggestions
enum<integer> | null
default:1
Available options:
0,
1

Body

application/json

Response

200
application/json

Successful response

The response is of type object.