Test Run Agent
Run an agent against a single sample record without deploying to Flink.
Synchronous, hard-capped at 15s wall-clock. Calls the LLM provider
directly and runs MCP and HTTP tools live; transform tools and memory
are not exercised (they exist only in the deployed Flink runtime).
Per-tenant rate limit: shares the validate-llm budget
(30 req/min/tenant) -> 429.
Provider failures (timeouts, schema errors, unsupported provider) are
returned as a structured error object on the response (HTTP still
200), alongside the partial timeline. Only exceeding the input-token cap
returns 422, because the run cannot start.
/agents/test-runAuthorizationBearer token · headerrequiredapplication/jsonconfigCreateAgentConfigRequestrequiredFull agent config under test
Show propertiesHide properties
namestringrequiredAgent display name
descriptionstring | nullHuman-readable context for the agent
Show propertiesHide properties
stringnullenabledbooleanKill 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.
agentTypeAgentTypeEnumAgent type — derived from the tool list post-validation; client-supplied value is overwritten
workflowreactinputAgentInputConfigrequiredInput configuration for the agent.
Show propertiesHide properties
topicPatternstringrequiredRegex pattern for input topics, e.g. '^(orders)$'
inputSerializationAgentSerializationEnumInput deserialization format
JsonConfluentAvroConfluentfieldsstring[] | nullColumn-level filter - only these fields sent to LLM
Show propertiesHide properties
stringstringnullcreateTableSQLstring | nullFlink SQL CREATE TABLE (required if filterSQL is set)
Show propertiesHide properties
stringnullfilterSQLstring | nullWHERE clause predicate for row-level filtering
Show propertiesHide properties
stringnulloutputAgentOutputConfigrequiredOutput configuration for the agent.
Show propertiesHide properties
topicstringrequiredFixed output topic name
deadLetterTopicstring | nullDLQ topic name
Show propertiesHide properties
stringnulloutputSerializationAgentSerializationEnumOutput serialization format
JsonConfluentAvroConfluentschemaobjectOutput schema: {field_name: TYPE_STRING}
llmAgentLlmConfigrequiredInline LLM configuration embedded on the agent.
Carries provider, credentials, model, and tuning controls as a single
object. Values can be copied from a saved AgentLlmConnection (which
carries default model, tuning and reasoning controls) and overridden per
agent; the object is stored as sent and used by the agent runtime at
deploy.
Two credential shapes (exactly one, same rule as ValidateLlmRequest):
- Inline -
apiKeyis filled directly. Streamkap encrypts it at rest and decrypts it only at deploy / test-run. - Linked -
llmConnectionIdreferences one of the tenant's saved LLM connections andapiKeyis left empty. Streamkap resolves the real key server-side at deploy and at test-run, so a client never needs to hold or re-send the stored key when editing an existing agent.
provider == ollama accepts an empty key without a link (the
runtime is local and unauthenticated).
Show propertiesHide properties
providerAgentLlmProviderEnumrequiredLLM provider
anthropicopenaiopenai-responsesollamaazureazure-openaibedrockqwenopenai-compatiblemodelstringrequiredModel name, e.g. claude-sonnet-4-20250514
apiKeystringAPI key - use '${SECRET:ENV_VAR_NAME}' for env var resolution. Empty when llmConnectionId is set.
llmConnectionIdstring | nullId of one of the tenant's saved LLM connections (llmConnections[].id in GET /agents/connections). When set with an empty apiKey, Streamkap resolves the real key server-side at deploy and at test-run.
Show propertiesHide properties
stringnullbaseUrlstring | nullBase URL for OpenAI-compatible proxies
Show propertiesHide properties
stringnulltemperaturenumber | nullSampling temperature (null = matrix-skipped)
Show propertiesHide properties
numbernullmaxTokensinteger | nullMax output tokens (null = matrix-skipped)
Show propertiesHide properties
integernulltimeoutinteger | nullRequest timeout in seconds (null = matrix-skipped)
Show propertiesHide properties
integernullreasoningEffortstring | nullOpenAI / GPT-5 reasoning effort. The accepted set is per-model; a value the chosen provider + model does not support is rejected with 422.
Show propertiesHide properties
stringnullthinkingBudgetTokensinteger | nullAnthropic Claude 4 extended-thinking budget (tokens). Non-null enables thinking.
Show propertiesHide properties
integernullollamaThinkboolean | nullOllama 'think' toggle for reasoning models
Show propertiesHide properties
booleannullmaxRetriesinteger | nullUniversal — max retry attempts on LLM call. Accepted by every provider.
Show propertiesHide properties
integernullregionstring | nullBedrock: AWS region (e.g. us-east-1). Ignored for non-bedrock providers.
Show propertiesHide properties
stringnullstrictboolean | nullopenai-responses: enable JSON-schema strict mode.
Show propertiesHide properties
booleannullstoreboolean | nullopenai-responses: server-side response storage flag.
Show propertiesHide properties
booleannullinstructionsstring | nullopenai-responses: system-level instructions passed as a top-level Responses param.
Show propertiesHide properties
stringnulladditionalKwargsobject | nullopenai-responses / azure-openai: free-form extra request params forwarded verbatim by the runtime.
Show propertiesHide properties
objectnullapiVersionstring | nullazure-openai: Azure OpenAI API version (e.g. '2024-02-01'). Required for azure-openai.
Show propertiesHide properties
stringnullazureEndpointstring | nullazure-openai: Azure resource endpoint (e.g. https://<resource>.openai.azure.com). Required.
Show propertiesHide properties
stringnullazureUrlPathModestring | nullazure-openai: URL path resolution — AUTO / LEGACY / UNIFIED. Optional.
Show propertiesHide properties
stringnullpromptsAgentPromptConfigrequiredPrompt configuration for the agent.
The final system prompt is assembled automatically from the agent type
template + output schema + tool descriptions + customInstructions.
The system field stores the assembled result (set by Streamkap, not the user).
Show propertiesHide properties
systemstringAssembled system prompt (generated by Streamkap)
customInstructionsstringUser-provided instructions appended to the auto-generated prompt
userstringUser prompt template - {input_json} is replaced with the input record
mcpServerAgentMcpServerConfig | nullShared MCP server config for all MCP tools
Show propertiesHide properties
projectKeyIdstring | nullID of an agentic-enabled Project Key. When set, deploy-time resolves the Streamkap MCP serverUrl + auth header from the PK row. Mutually exclusive with serverUrl - one or the other, never both.
Show propertiesHide properties
stringnullserverUrlstring | nullExternal MCP server URL. Required when projectKeyId is unset. Server-stamped from the PK row when projectKeyId is set.
Show propertiesHide properties
stringnullheadersobjectAuth headers for MCP server
nulltoolsAgentToolConfig[]Agent tools (MCP, HTTP, transform)
Show propertiesHide properties
AgentToolConfignamestringrequiredTool name (must be unique)
typeAgentToolTypeEnumrequiredTool type: http, transform, or mcp
httptransformmcpdescriptionstringTool description for the LLM
configobjectType-specific configuration
parametersAgentToolParameterConfig[]Tool parameters the LLM can provide
Show propertiesHide properties
AgentToolParameterConfignamestringrequiredParameter name
typestringParameter type (string, number, boolean)
descriptionstringParameter description for the LLM
memoryAgentMemoryConfig | nullMemory config (short-term + long-term)
Show propertiesHide properties
keyFieldstring | nullField to partition memory by (e.g. 'customer_id'). Default: topic key
Show propertiesHide properties
stringnullshortTermAgentShortTermMemoryConfigShort-term conversation memory
Show propertiesHide properties
enabledbooleanEnable short-term memory
ttlMsintegerTime-to-live in milliseconds (default: 1 hour)
maxEntriesintegerMax conversation entries per key
longTermAgentLongTermMemoryConfigLong-term vector store memory
Show propertiesHide properties
enabledbooleanEnable long-term memory
vectorStoreConnectionIdstring | nullReference to a saved AgentVectorStoreConnection. Resolved at deploy time.
Show propertiesHide properties
stringnullnamespacestring | nullPer-agent namespace override (falls back to connection's defaultNamespace)
Show propertiesHide properties
stringnulldestinationIdstring | null(Legacy) ObjectId of a Pinecone destination connector. Prefer vectorStoreConnectionId.
Show propertiesHide properties
stringnullnullknowledgeBasesAgentKnowledgeBaseRef[]Knowledge bases this agent can query at runtime for RAG
Show propertiesHide properties
AgentKnowledgeBaseRefidstringrequiredKnowledge base entity ID
namestringDisplay name (denormalized for UI)
processingAgentProcessingConfigProcessing configuration for the agent.
Show propertiesHide properties
parallelismintegerParallelism
checkpointIntervalMinintegerCheckpoint interval in minutes
maxIterationsintegerMax tool-call iterations per record (react type only)
maxTokensPerHourintegerPer-TaskManager rolling-hour token budget. 0 = unlimited. When exceeded, records pass through with a _budget_exceeded: true marker.
sampleRecordobjectrequiredOne Kafka-shaped record to feed the agent
agentIdstring | nullId of a saved agent. When set, an empty or masked apiKey in config is replaced server-side with that agent's stored key. Needed for agents saved with an inline key rather than an llmConnectionId.
Show propertiesHide properties
stringnullsavedConnectionIdstring | nullMirror of the ValidateLlmRequest.savedConnectionId path.
Show propertiesHide properties
stringnullskipToolsbooleanWhen true, every MCP / HTTP tool dispatch returns a canned {skipped: true} payload to the LLM. Use to iterate on prompt shape without burning real tool calls.
Successful Response
stepsTestRunStep[]requiredShow propertiesHide properties
TestRunStepkindstringrequiredllmtoolmodelstring | nullShow propertiesHide properties
stringnulltokensIninteger | nullShow propertiesHide properties
integernulltokensOutinteger | nullShow propertiesHide properties
integernullstopReasonstring | nullShow propertiesHide properties
stringnulltextstring | nullShow propertiesHide properties
stringnulltoolCallsobject[] | nullShow propertiesHide properties
objectobjectnulltoolNamestring | nullShow propertiesHide properties
stringnulltoolTypestring | nullShow propertiesHide properties
stringnullrequestobject | nullShow propertiesHide properties
objectnullresultobject | nullShow propertiesHide properties
objectnullskippedboolean | nullShow propertiesHide properties
booleannullskippedReasonstring | nullShow propertiesHide properties
stringnulldurationMsinteger | nullShow propertiesHide properties
integernullerrorstring | nullShow propertiesHide properties
stringnullfinalOutputanystoppedReasonstringrequiredcompletedmax_iterationserrortimeoutiterationsUsedintegerrequiredtokensInintegerrequiredtokensOutintegerrequireddurationMsintegerrequiredapproximationsstring[]Free-form list of caveats, e.g. 'memory_excluded', 'transforms_skipped'.
suggestionsTestRunSuggestion[]Deterministic hints (max 4) computed from the agent config + run result. Empty when the run produced a useful structured output. Each suggestion has a stable kind identifier.
Show propertiesHide properties
TestRunSuggestionkindstringrequiredmissing_output_schematools_not_invokednear_empty_responseskip_instruction_may_applymax_tokens_truncatedmessagestringrequiredwarningsTestRunWarning[]Static config-vs-record checks (e.g. memory keyField missing on the sample) that the Flink runtime would silently swallow at deploy. Empty when nothing is amiss.
Show propertiesHide properties
TestRunWarningkindstringrequiredmemory_key_field_missinginput_fields_not_in_recordmax_tokens_clampedmessagestringrequiredoutputSchemaCheckTestRunSchemaCheck | nullField-level diff between the declared output.schema and the LLM's finalOutput. Null when no schema was declared OR the run errored / produced a non-structured (text envelope) result. ok=true means every declared field is present with a compatible type.
Show propertiesHide properties
okbooleanrequiredmissingstring[]Fields declared in schema but absent from finalOutput
extrastring[]Fields present in finalOutput but not declared
typeMismatchesTestRunSchemaTypeMismatch[]Fields whose value types diverge from the declared schema
Show propertiesHide properties
TestRunSchemaTypeMismatchfieldstringrequiredexpectedstringrequiredDeclared schema type, e.g. STRING / DOUBLE
actualstringrequiredInferred type of the value the LLM returned
nullsystemPromptstring | nullComposed system prompt the LLM actually received - base template + auto-injected schema fields + tool descriptions + customInstructions. Identical to the prompt the deployed agent uses. Null when the run errored before reaching the LLM (e.g. llm_resolution_error).
Show propertiesHide properties
stringnulluserMessagestring | nullFirst user message dispatched to the LLM, after the prompts.user template wraps the (input-fields-filtered) sample record. Lets the test pane show the exact pair of strings the LLM saw on iteration 1. Null when the run errored before message construction.
Show propertiesHide properties
stringnullerrorTestRunError | nullShow propertiesHide properties
kindstringrequiredOne of: llm_resolution_error, llm_provider_error, timeout, unsupported_provider, http_connection_resolution_error, …
messagestringrequirednullValidation Error
detailValidationError[]Show propertiesHide properties
ValidationErrorlocstring | integer[]requiredShow propertiesHide properties
string | integerstringintegermsgstringrequiredtypestringrequiredinputanyctxobject