Skip to main content
POST
Create Agent From Config

Authorizations

Authorization
string
header
required

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

Query Parameters

deploy
boolean
default:true

Body

application/json

Request body for POST /agents/config - create a config-based agent.

name
string
required

Agent display name

Required string length: 1 - 200
input
AgentInputConfig · object
required

Input configuration for the agent.

output
AgentOutputConfig · object
required

Output configuration for the agent.

llm
AgentLlmConfig · object
required

Inline LLM configuration embedded on the agent.

Carries provider, credentials, model, and tuning controls as a single blob. The FE prefills the form from a saved :class:AgentLlmConnection (which now carries default model + tuning + reasoning controls) and the user can override per-agent before save; the resulting blob is stored verbatim and shipped to the Flink runtime at deploy.

Two credential shapes (XOR, mirrors :class:ValidateLlmRequest):

  1. Inline - apiKey is filled directly. The BE KMS-encrypts it at save and decrypts it at deploy / test-run.
  2. Linked - llmConnectionId references a row in agent_connections.llmConnections and apiKey is left empty. The BE resolves the real key server-side at deploy and at test-run via :func:agents_service.resolve_saved_llm_credentials, so the browser never needs to hold (or re-paste) the stored plaintext when editing an existing agent.

provider == ollama accepts an empty key without a link (the runtime is local and unauthenticated).

prompts
AgentPromptConfig · object
required

Prompt configuration for the agent.

The final system prompt is auto-assembled by build_system_prompt() from the agent type template + output schema + tool descriptions + custom_instructions. The system field stores the assembled result (set by the backend, not the user).

description
string | null

Human-readable context for the agent

Maximum string length: 500
enabled
boolean
default:true

Kill switch. When false, the Flink runtime accepts the deploy but stops emitting output — used by support to disable a runaway tenant agent without a full cancel/redeploy.

agentType
enum<string>
default:workflow

Agent type — derived from the tool list post-validation; client-supplied value is overwritten

Available options:
workflow,
react
mcpServer
AgentMcpServerConfig · object | null

Shared MCP server config for all MCP tools

tools
AgentToolConfig · object[]

Agent tools (MCP, HTTP, transform)

memory
AgentMemoryConfig · object | null

Memory config (short-term + long-term)

knowledgeBases
AgentKnowledgeBaseRef · object[]

Knowledge bases this agent can query at runtime for RAG

Maximum array length: 10
processing
AgentProcessingConfig · object

Processing configuration for the agent.

Response

Successful Response

_id
string
required
name
string
required
job_type
enum<string>
required
Available options:
pyflink,
jar,
agent_config,
knowledge_base
status
enum<string>
required
Available options:
CREATED,
DEPLOYING,
RUNNING,
CANCELLING,
CANCELLED,
FAILED,
FINISHED
desired_status
enum<string> | null
Available options:
CREATED,
DEPLOYING,
RUNNING,
CANCELLING,
CANCELLED,
FAILED,
FINISHED
parallelism
integer
default:1
error_message
string | null
agent_config
Agent Config · object | null
created_by
string | null
created_timestamp
string<date-time> | null
updated_timestamp
string<date-time> | null