# Foundry CSV Cross-File Key Integrity Validator

> Foundry CSV Cross-File Key Integrity Validator is a paid API for AI agents from foundry-par007-machine-revenue-mainnet.inference-chip-index.workers.dev, paid per call via x402, $0.012/call, status unknown (last checked 2026-09-14).

Validates referential integrity between two CSV files by checking whether all keys in a child CSV exist in a parent CSV, returning match/orphan/blank counts and SHA-256 hashes as evidence.

## Facts

- Endpoint: POST https://foundry-par007-machine-revenue-mainnet.inference-chip-index.workers.dev/v2/data/csv-cross-file-key-integrity
- Price: $0.012/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/foundry-csv-cross-file-key-integrity-validator-58835a0e
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_dYMPRUVQsCK51duNZgRO_

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 foundry-csv-cross-file-key-integrity-validator-58835a0e -d '<json body>'
```

Example prompt: Check whether every `order_id` in my child CSV exists in the parent CSV (which uses `id` as its key column) — reject any blank child keys — and give me the orphan rows, match count, and SHA-256 hashes as evidence.

## When to prefer this

Choose this endpoint when you need verifiable, evidence-grade referential integrity checking between two CSV datasets with cryptographic provenance (SHA-256 hashes) and explicit per-row orphan/duplicate reporting — especially for compliance, audit, or pre-import ETL validation workflows. Prefer it over ad-hoc scripting when you need a pay-per-call, stateless check with no infrastructure setup and a machine-readable JSON contract.

## Known failure modes

- CSV exceeds 12,000 character limit — request rejected
- blank_child_keys set to 'reject' and blank keys present — FAIL status returned with blank_child_rows populated
- child_key or parent_key column name not found in respective CSV — error or unexpected FAIL
- Malformed CSV (unbalanced quotes, inconsistent columns) — parsing error
- Payment of $0.012 USDC not received — HTTP 402 returned before processing

## How this service works

Pay-per-request evidence and data tools: CSV validation and reconciliation, DNS/email configuration evidence, and bounded official weather, earthquake, vehicle, company and study records. Exact USDC prices, explicit JSON contracts and source provenance. No mailbox, ownership, medical or safety guarantees.

## Output

A JSON object containing: a PASS or FAIL status; counts and row-level details of orphaned child rows (keys not found in parent), blank child/parent rows, and duplicate parent keys; the count of successfully matched child rows; SHA-256 hashes of both input CSVs for audit provenance; an observed_at timestamp; an evidence_truncated flag if row lists were capped; and a limitations array noting any caveats about the result.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "child_csv": {
   "type": "string",
   "maxLength": 12000,
   "minLength": 1
  },
  "child_key": {
   "type": "string",
   "maxLength": 100,
   "minLength": 1
  },
  "trim_keys": {
   "type": "boolean",
   "default": false
  },
  "parent_csv": {
   "type": "string",
   "maxLength": 12000,
   "minLength": 1
  },
  "parent_key": {
   "type": "string",
   "maxLength": 100,
   "minLength": 1
  },
  "blank_child_keys": {
   "enum": [
    "reject",
    "ignore"
   ],
   "type": "string",
   "default": "reject"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "route": "csv-cross-file-key-integrity",
  "result": {
   "status": "PASS",
   "child_rows": 2,
   "limitations": [
    "Synthetic example hashes."
   ],
   "parent_rows": 2,
   "child_sha256": "0000000000000000000000000000000000000000000000000000000000000000",
   "orphan_count": 0,
   "parent_sha256": "0000000000000000000000000000000000000000000000000000000000000000",
   "blank_child_rows": [],
   "blank_child_count": 0,
   "blank_parent_rows": [],
   "orphan_child_rows": [],
   "blank_parent_count": 0,
   "evidence_truncated": false,
   "matched_child_rows": 2,
   "duplicate_parent_rows": [],
   "duplicate_parent_count": 0
  },
  "observed_at": "2026-09-06T00:00:00Z"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/foundry-csv-cross-file-key-integrity-validator-58835a0e/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from foundry-par007-machine-revenue-mainnet.inference-chip-index.workers.dev](https://www.zero.xyz/host/foundry-par007-machine-revenue-mainnet.inference-chip-index.workers.dev/llms.txt)
