View Custom Harnesses
You can view existing custom Harnesses by navigating to Harnesses in the left sidebar. To view the prompts, Personas and Policies in a custom Harness, click on its row in the Harnesses table.Create a Custom Harness
- In the left sidebar, navigate to Harnesses and press Create Harness.
- Enter a Harness name and a description.
- Select an Agent
- Optional Select one or more Persona(s).
- Optional Select one or more Policies
Create a Custom Harness Programmatically
Create Personas and Policies
Personas define who interacts with your Agent, and Policies define the rules it must follow. Both are optional inputs to custom Harness creation: pass their IDs (persona_ids and policy_ids) in the next step, and Vijil generates Probes that combine each Persona’s behavior with each Policy’s constraints. Create them first, then reference their IDs when you create the Harness.
- MCP
- REST API
- SDK
With the Vijil MCP server configured, ask Claude Code in natural language:Claude creates the Persona and Policy and returns their IDs.
Create an adversarial 'Frustrated Customer' persona and a privacy policy that forbids storing personal data
Create a Harness
Pass the Persona and Policy IDs from the previous step aspersona_ids and policy_ids. Both are optional — omit them to generate a Harness from the Agent description alone.
To structure a Harness around approved policy rules, follow the policy rule extraction workflow, then pass rule_policy_ids or rule_ids to client.harnesses.create(). The policy_ids argument supplies policy context and does not select approved rules.
- MCP
- REST API
- SDK
With the Vijil MCP server configured, ask Claude Code in natural language:Claude creates the Harness and returns the ID.
Create a custom Harness called 'Customer Support Harness' for agent a1b2c3d4-… with the GDPR policy
Custom Harnesses are immutable once created. To change the configuration, delete the Harness and create a new one.
Check Generation Status
Harness generation is asynchronous. Poll untilstatus is active.
Get Harness Prompts
Retrieve the generated Probes for a completed Harness.draft status. The SDK has no dedicated prompts method yet, so the example above calls the endpoint through client._http, the same transport the high-level methods use.
List Custom Harnesses
agent_id and status, with limit and offset for pagination. The SDK’s client.harnesses.list() returns standard and custom Harnesses together.
Cancel Generation
Stop a Harness that is still generating.cancel method yet, so the example above calls the endpoint through client._http, the same transport the high-level methods use.
Delete a Harness
Next Steps
Run Evaluations
Execute custom Harness evaluations
Understand Results
Analyze custom Harness results
Personas
Learn more about personas
Policies
Learn more about policies