invarium_upload_blueprint
invarium_upload_blueprintUpload an agent blueprint to the Invarium dashboard. Takes a JSON string describing your agent's tools, workflows, and constraints. Use the agent blueprint template to generate this JSON from your codebase.
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
blueprint | string | required | JSON string of the agent blueprint. |
agent_name | string | null | default: null | Agent name. If not provided, extracted from the blueprint. |
Returns
Confirmation with tool count, workflow chains, confidence level, and dashboard link.
Example
Blueprint uploaded successfully
Agent: customer-support-agent
Tools: 3 detected
Workflow chains: 2 identified
Confidence: high
Dashboard: https://app.invarium.dev/agents/customer-support-agentUsage
Pass your agent blueprint as a JSON string. The blueprint must include at minimum an agent_name (or pass it as the second parameter) and at least one tool.
invarium_upload_blueprint(
blueprint='{"agent_name": "my-agent", "tools": [{"name": "search", ...}]}',
agent_name='my-agent'
)If a blueprint already exists for the given agent name, it will be replaced with the new version. Previous test runs are preserved.
See the Blueprint Schema for the full list of supported fields, and Blueprint Examples for practical templates.
Validation rules
The blueprint is validated on upload. The following rules apply:
agent_nameis required (either in the blueprint JSON or as theagent_nameparameter)- At least one tool must be defined in the
toolsarray - Each tool must have a
nameanddescription frameworkmust be one of:langchain,crewai,autogen,openai_agents,openai,customside_effectson tools must be one of:none,read,write,deleteerror_handlingon tools must be one of:retry,fallback,fail,ignore
If validation fails, the error message will indicate which field is invalid and what values are accepted.
Confidence scoring
After uploading, Invarium analyzes the blueprint and assigns a confidence level that indicates how well the blueprint describes the agent:
| Confidence | Meaning |
|---|---|
| High | Blueprint includes tools with parameters, return types, constraints, and workflow chains. Invarium can generate highly targeted tests. |
| Medium | Blueprint includes tools and some constraints, but is missing details like parameters, side effects, or workflow chains. Tests will be generated but may be less targeted. |
| Low | Blueprint is minimal — only agent name and basic tool names. Invarium will generate generic behavioral tests. Adding more detail will improve test quality. |
Error responses
| Error | Cause | Fix |
|---|---|---|
Validation error: agent_name is required | No agent name in blueprint or parameter. | Add agent_name to the blueprint JSON or pass it as a parameter. |
Validation error: at least one tool is required | The tools array is empty or missing. | Add at least one tool definition. |
Validation error: invalid framework value | The framework field contains an unsupported value. | Use one of: langchain, crewai, autogen, openai_agents, openai, custom. |
Blueprint too large | The blueprint JSON exceeds the maximum size (500 KB). | Reduce the blueprint size — consider splitting into multiple agents if needed. |