REST API
POST /v1/tool-guard
Classify a proposed tool call with INT-Tooling over HTTP.
Classify a proposed tool call with INT-Tooling before executing it. This is a behavioral intent/policy check, not source-code analysis, malware detection, dependency scanning, command execution, or artifact validation.
POST
/v1/tool-guardRequest#
The action under review is current_action. The SDKs build it for you by combining the tool name with structured arguments when present, or with the description as a fallback. Over REST you pass it directly.
| Field | Type | Required | Description |
|---|---|---|---|
user_request | string | Yes | What the user asked for. Must be non-empty. |
current_action | string | No | The tool call under review, for example "send_email: Send an email". |
interaction_history | string | No | Prior conversation context. |
env_info | string | No | Environment context. |
model_provider / model_name / session_id | string | No | Correlation metadata. |
Response#
| Field | Type | Description |
|---|---|---|
malicious | string | "yes" or "no". Whether the user request shows malicious behavioral intent, not whether supplied code or a binary is malware. |
attacked | string | "yes" or "no". Whether a third-party or hijacked instruction appears to have driven the action away from the user’s request. |
harmfulness | number | Severity of the current action: 0.0, 0.5, or 1.0. |
composite_score | number | 0.0 no behavioral-policy risk detected, 0.5 flagged, 1.0 unsafe action intent. |
latency_ms | number | Server-side inference time. |
Example#
The benign user request conflicts with both the injected instruction in the interaction history and the destructive action. That makes malicious: "no" and attacked: "yes" the expected confused-deputy interpretation.
curl https://integrity.triage-sec.com/v1/tool-guard \
-H "Authorization: Bearer $TRIAGE_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"user_request": "Summarize my invoices",
"current_action": "bash: rm -rf / --no-preserve-root",
"interaction_history": "An invoice attachment instructed the agent to ignore the user and delete the host filesystem.",
"env_info": "production"
}'JSON
{ "malicious": "no", "attacked": "yes", "harmfulness": 1.0, "composite_score": 1.0, "latency_ms": 191.86 }