80trust / 100

Accept Csv

by Mekler: CSV validation in Documents & files

x402 APIPassing, checked 4 h ago

Validate CSV before import using a fixed JSON column specification. Checks missing/extra columns, required cells, string/integer/decimal/boolean/date types, uniqueness, allowed values and numeric/row-count bounds. Returns pass/fail with row/column error codes. POST JSON with csv and spec.columns; schemas/examples attached. Full contract: /openapi.json. Max 2,000 rows, 50 columns, 256 KiB; first 50 failures. No formulas, cross-column rules, fact checking or data repair.

POST https://vme5zb7fll.execute-api.us-east-1.amazonaws.com/v1/accept/csv

Last 30 days

All checks passedSome failedAll failedNot checked
Uptime
100%
Response time
427 ms typical, 427 ms slowest 5%
Last check
4 h ago
Next check
any minute now

How to call it

# See the payment challenge (nothing is charged)
curl -i -X POST "https://vme5zb7fll.execute-api.us-east-1.amazonaws.com/v1/accept/csv" \
  -H "content-type: application/json" \
  -d '{"csv":"id,amount\na,12.50\na,-2.00\n","spec":{"columns":[{"name":"id","required":true,"type":"string","unique":true},{"max":"100","min":"0","name":"amount","required":true,"type":"decimal"}],"min_rows":1}}'
import { wrapFetchWithPayment } from "@x402/fetch";
import { x402Client } from "@x402/core/client";
import { ExactEvmScheme } from "@x402/evm/exact/client";
import { privateKeyToAccount } from "viem/accounts";

const client = new x402Client().register(
  "eip155:8453",
  new ExactEvmScheme(privateKeyToAccount(process.env.AGENT_KEY)),
);
const pay = wrapFetchWithPayment(fetch, client);

// Not sure it's safe to pay? Preflight it first for $0.03:
// GET https://toolvet.app/api/v1/check?url=https%3A%2F%2Fvme5zb7fll.execute-api.us-east-1.amazonaws.com%2Fv1%2Faccept%2Fcsv
const res = await pay("https://vme5zb7fll.execute-api.us-east-1.amazonaws.com/v1/accept/csv", {
  method: "POST",
  headers: { "content-type": "application/json" },
  body: JSON.stringify({"csv":"id,amount\na,12.50\na,-2.00\n","spec":{"columns":[{"name":"id","required":true,"type":"string","unique":true},{"max":"100","min":"0","name":"amount","required":true,"type":"decimal"}],"min_rows":1}}),
});
console.log(await res.json());

Example input

{
  "csv": "id,amount\na,12.50\na,-2.00\n",
  "spec": {
    "columns": [
      {
        "name": "id",
        "required": true,
        "type": "string",
        "unique": true
      },
      {
        "max": "100",
        "min": "0",
        "name": "amount",
        "required": true,
        "type": "decimal"
      }
    ],
    "min_rows": 1
  }
}

Example output

{
  "boundary": "Only supplied explicit criteria checked; no certification of truth or subjective quality.",
  "failure_count": 2,
  "failures": [
    {
      "code": "unique",
      "column": "id",
      "row": 2
    },
    {
      "code": "min",
      "column": "amount",
      "row": 2
    }
  ],
  "failures_truncated": false,
  "receipt_sha256": "32265ae46050fa0067b9adb0df085a5cf3d9fa3d47d91e9ea2f61135a382d8ac",
  "rows_checked": 2,
  "schema_version": 1,
  "verdict": "fail"
}

Security scan

  • Payment address changed recently in payment
    Payment address changed from 9mMDrHabSf73MPn1ANdANSmsNw2wKiqE7JZ7eD6EUSRc to 0xF6c6E2e530bb311c14a49C1a07C720fc232c07c5

Recent checks

WhenResultHTTPTimePrice
4 h agoPassed402427 ms$0.05

History

11 Oct 2026Payment address changed from 9mMDrHabSf73MPn1ANdANSmsNw2wKiqE7JZ7eD6EUSRc to 0xF6c6E2e530bb311c14a49C1a07C720fc232c07c5