AI Agent APIs
All AI agents configured on Rierino are automatically accessible as APIs and can be incorporated into any app for visual interaction
All runners which include GenAI base runner and have GenAI models assigned to them can service the following common APIs for describing and interacting with agents.
Returns sagas, states, systems and scripting languages an agent can utilize.
Id of agent to view
OK
Authorization information is missing or invalid.
User does not have the required role for access.
Server failed to process request due to internal errors.
Feature is not implemented by the server.
GET /api/request/{channel}/GetAIAgent HTTP/1.1
Host: gateway_server
Accept: */*
{
"id": "text",
"data": {
"name": "text",
"description": "text",
"states": [],
"systems": [],
"sagas": [],
"prompts": []
}
}
Makes a request to a specific AI agent with a message or prompt inputs.
Id of the agent to call
translator
Id of the ongoing chat with agent
123
Message/request to send to agent, required if prompt is not used
Please translate the following sentence...
Id of the agent prompt to be used, required if message is not used
multi_translate
Input parameters which are used by the selected prompt
{"text":"Hello world","source":"enUS","targets":["frFR","ptPT"],"instructions":"Please keep it short"}
OK
Authorization information is missing or invalid.
User does not have the required role for access.
Server failed to process request due to internal errors.
Feature is not implemented by the server.
POST /api/request/{channel}/CallAIAgent HTTP/1.1
Host: gateway_server
Content-Type: application/json
Accept: */*
Content-Length: 228
{
"agent": "translator",
"chat": "123",
"message": "Please translate the following sentence...",
"prompt": "multi_translate",
"input": {
"text": "Hello world",
"source": "enUS",
"targets": [
"frFR",
"ptPT"
],
"instructions": "Please keep it short"
}
}
{
"response": "text",
"chat": "text"
}
Last updated