# Agent Preflight Tool-Call Evaluator

> Agent Preflight Tool-Call Evaluator is a paid API for AI agents from api.agent-preflight.com, paid per call via x402, $0.002/call, status unknown (last checked 2026-10-13).

Evaluates whether an AI agent should proceed with a metered search or browse tool call, considering budget, history, and deduplication — without executing the external tool.

## Facts

- Endpoint: POST https://api.agent-preflight.com/v0.2/preflight/tool-call?utm_source=zero.xyz
- Price: $0.002/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-13
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/agent-preflight-tool-call-evaluator-ae295e7e
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_IXsY50AzzHDqI685sub-F

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability agent-preflight-tool-call-evaluator-ae295e7e -d '<json body>'
```

Example prompt: Before I run this web_search for 'best open source LLMs 2024' with an estimated cost of $0.01 and I have $0.50 remaining in budget, check whether I should proceed — my run ID is 'run-42' and this is step 3.

## When to prefer this

Use this endpoint when your AI agent is about to execute a metered external tool call (search or web browse) and you need a lightweight, fast pre-execution gate that checks budget sufficiency, deduplication against call history, and overall worthiness — before incurring real costs. Prefer this over executing blindly when running multi-step agentic workflows where tool call costs accumulate, when the same URL or query might be fetched multiple times across steps, or when you need auditable go/no-go decisions logged per step.

## Known failure modes

- Missing required fields (goalHash, provider, operation, estimatedExternalCostUsd, remainingUsd) returns validation error
- Unsupported provider or operation values return an error indicating unsupported tool
- Remaining budget of zero or below estimated cost likely returns a block decision
- Malformed history entries may cause the request to be rejected
- Payment not provided or x402 payment failure results in 402 response before evaluation occurs

## How this service works

Pre-execution decision for a metered search or browse tool call. Evaluates the proposal; does not execute the external tool.

## Output

A preflight verdict indicating whether the agent should proceed with the planned tool call, along with signals for deduplication (whether this call was already made), budget adequacy, and any blocking reasons — all without actually executing the external search or browse operation.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "task": {
   "type": "object",
   "required": [
    "goalHash"
   ],
   "properties": {
    "goalHash": {
     "type": "string",
     "description": "Opaque goal correlation token"
    }
   },
   "additionalProperties": false
  },
  "tool": {
   "type": "object",
   "required": [
    "provider",
    "operation",
    "request",
    "estimatedExternalCostUsd"
   ],
   "properties": {
    "request": {
     "type": "object",
     "properties": {
      "url": {
       "type": "string",
       "minLength": 1
      },
      "query": {
       "type": "string",
       "maxLength": 500,
       "minLength": 1
      },
      "max_results": {
       "type": "integer",
       "maximum": 10,
       "minimum": 1
      }
     },
     "description": "Provider-specific payload. search/web_search requires query (string 1..500) and optional max_results (1..10). browse/fetch requires url (http/https).",
     "additionalProperties": true
    },
    "provider": {
     "type": "string",
     "minLength": 1,
     "description": "Tool provider. Supported: search, browse"
    },
    "operation": {
     "type": "string",
     "minLength": 1,
     "description": "Tool operation. Supported: search:web_search, browse:fetch"
    },
    "estimatedModelCostUsd": {
     "type": "number",
     "minimum": 0,
     "description": "Optional estimated USD model cost for this step"
    },
    "estimatedExternalCostUsd": {
     "type": "number",
     "minimum": 0,
     "description": "Estimated USD cost of the external tool call"
    }
   },
   "additionalProperties": false
  },
  "runId": {
   "type": "string",
   "minLength": 1,
   "description": "Caller-scoped run identifier"
  },
  "budget": {
   "type": "object",
   "required": [
    "remainingUsd"
   ],
   "properties": {
    "reservedUsd": {
     "type": "number",
     "minimum": 0
    },
    "remainingUsd": {
     "type": "number",
     "minimum": 0
    },
    "maxToolCallsRemaining": {
     "type": "integer",
     "minimum": 0
    }
   },
   "additionalProperties": false
  },
  "stepId": {
   "type": "string",
   "minLength": 1,
   "description": "Caller-scoped step identifier within the run"
  },
  "history": {
   "type": "array",
   "items": {
    "type": "object",
    "required": [
     "toolCallId",
     "fingerprint",
     "outcome",
     "ageSeconds"
    ],
    "properties": {
     "outcome": {
      "enum": [
       "success",
       "terminal_failure",
       "transient_failure"
      ],
     
… (truncated)
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/agent-preflight-tool-call-evaluator-ae295e7e/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.agent-preflight.com](https://www.zero.xyz/host/api.agent-preflight.com/llms.txt)
