# Agent Buyer Identity Preflight | x402 Purchase Governance

> Agent Buyer Identity Preflight | x402 Purchase Governance is a paid API for AI agents from base-agent-preflight.bytoken2023.workers.dev, paid per call via x402, $0.005/call, status unknown (last checked 2026-09-14).

Validates whether an AI agent's buyer identity, role, and budget are appropriate before it purchases an x402-gated API, dataset, or tool.

## Facts

- Endpoint: GET https://base-agent-preflight.bytoken2023.workers.dev/v1/x402/agent/rpc-preflight
- Price: $0.005/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/agent-buyer-identity-preflight-x402-purchase-governance-c5379fca
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_GP9vavbXgRnWKSv4zYGRK

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-buyer-identity-preflight-x402-purchase-governance-c5379fca
```

Example prompt: Before you buy that x402 API at https://data.example.com/v1/prices, run a preflight check on chain eip155:8453 for the GET method to make sure my agent identity is cleared and the price won't exceed $0.10 USDC given my $2.00 session budget.

## When to prefer this

Use this endpoint before any x402-protocol purchase where agent identity governance, budget enforcement, or product-category compliance matters — especially when the buying agent operates autonomously and must self-validate authorization. Prefer this over skipping preflight when purchases involve sensitive data, high prices, or strict approval policies, and when you need a risk score to log or gate downstream actions.

## Known failure modes

- Invalid or unreachable endpoint_url returns an error or elevated risk flag
- Malformed chain identifier (not matching CAIP-2 pattern) causes validation rejection
- Missing required query parameters (endpoint_url, chain, method) returns a 400-level error
- Session budget below the product price triggers a budget-exceeded flag in assessment
- Unknown or unsupported RPC method pattern may return an unresolvable identity warning
- Service itself is a Cloudflare Worker with no guaranteed uptime SLA — may return 5xx under load

## How this service works

Machine-payable service intelligence for discovering, verifying, and monitoring identity, risk, authorization, execution-preflight, and evidence APIs before autonomous agents spend.

## Output

Returns a JSON object with a risk_level (e.g. 'low', 'medium', 'high'), a numeric risk_score, an array of assessment flags, the resolved network identifier, product metadata, and provenance details — giving the agent a clear go/no-go signal before committing to an x402 payment.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "endpoint_url",
      "chain",
      "method"
     ],
     "properties": {
      "chain": {
       "type": "string",
       "pattern": "^[A-Za-z0-9:_ -]{2,80}$",
       "description": "Requested chain or CAIP-2 network label."
      },
      "method": {
       "type": "string",
       "pattern": "^[A-Za-z0-9_.:-]{2,80}$",
       "description": "RPC method, REST operation, or query action."
      },
      "endpoint_url": {
       "type": "string",
       "pattern": "^https?://",
       "maxLength": 2048,
       "description": "RPC, x402, REST, or indexed chain-data endpoint URL."
      },
      "max_price_usdc": {
       "type": "string",
       "pattern": "^[0-9]+(?:\\.[0-9]{1,6})?$",
       "description": "Maximum acceptable price for this request."
      },
      "session_budget_usdc": {
       "type": "string",
       "pattern": "^[0-9]+(?:\\.[0-9]{1,6})?$",
       "description": "Remaining session budget available to the agent."
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object",
     "properties": {
      "network": {
       "type": "string"
      },
      "product": {
       "type": "string"
      },
      "activity": {
       "type": "object"
      },
      "identity": {
       "type": "object"
      },
      "assessment": {
       "type": "object"
      },
      "provenance": {
       "type": "object"
      }
     }
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "network": "eip155:8453",
  "product": "agent-rpc-preflight",
  "assessment": {
   "flags": [],
   "risk_level": "low",
   "risk_score": 0
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/agent-buyer-identity-preflight-x402-purchase-governance-c5379fca/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from base-agent-preflight.bytoken2023.workers.dev](https://www.zero.xyz/host/base-agent-preflight.bytoken2023.workers.dev/llms.txt)
