{"uid":"cap_k0Nt--_fv6RFwYwAXNYub","slug":"mekler-ai-csv-data-validator-2bb5f592","name":"Mekler AI CSV Data Validator","description":"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.","url":"https://api.mekler.ai/v1/data/csv/validate-data?utm_source=zero.xyz","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"csv":{"type":"string","description":"UTF-8 comma-delimited CSV with header. No trimming. Data record numbers start at 1; quoted newlines are one record."},"spec":{"type":"object","required":["columns"],"properties":{"columns":{"type":"array","items":{"type":"object","required":["name","type"],"properties":{"max":{"oneOf":[{"type":"number"},{"type":"string"}],"description":"Inclusive numeric bound; allowed only for integer or decimal columns."},"min":{"oneOf":[{"type":"number"},{"type":"string"}],"description":"Inclusive numeric bound; allowed only for integer or decimal columns."},"enum":{"type":"array","items":{"type":"string","maxLength":1000},"maxItems":100,"minItems":1,"description":"Exact allowed cell strings, compared without trimming or normalization."},"name":{"type":"string","maxLength":100,"minLength":1},"type":{"enum":["string","integer","decimal","boolean","date"],"type":"string","description":"string: literal text; integer: base-10, no plus sign or leading zeros; decimal: plain decimal, no exponent; boolean: lowercase true/false; date: valid YYYY-MM-DD."},"unique":{"type":"boolean","default":false,"description":"Reject repeated nonempty values within this column; numeric values compare numerically."},"required":{"type":"boolean","default":false,"description":"Reject empty cells. Whitespace is not trimmed."}},"additionalProperties":false},"maxItems":50,"minItems":1,"description":"Fixed built-in checks. Every named column must exist, even when required is false."},"max_rows":{"type":"integer","default":2000,"maximum":2000,"minimum":0},"min_rows":{"type":"integer","default":0,"maximum":2000,"minimum":0},"allow_extra_columns":{"type":"boolean","default":false,"description":"If false, reject CSV headers not named in columns."}},"additionalProperties":false}}},"responseSchema":{"type":"json","example":{"verdict":"fail","boundary":"Only supplied explicit criteria checked; no certification of truth or subjective quality.","failures":[{"row":2,"code":"unique","column":"id"},{"row":2,"code":"min","column":"amount"}],"rows_checked":2,"failure_count":2,"receipt_sha256":"32265ae46050fa0067b9adb0df085a5cf3d9fa3d47d91e9ea2f61135a382d8ac","schema_version":1,"failures_truncated":false}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.05","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.05/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.05","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.05","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_IKYLf0usxRi6AmyAC4yHW","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.05","costPer":"request","priority":0,"asset":"EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Validates a CSV file against a fixed JSON column specification, checking types, required fields, uniqueness, allowed values, and numeric/row-count bounds, returning pass/fail with row/column error codes.","exampleAgentPrompt":"Before I import this CSV into the database, validate it against these column rules: id must be a unique integer and required, name must be a required string, amount must be a decimal between 0 and 10000, and status must be one of 'active' or 'inactive' — tell me exactly which rows and columns fail.","exampleUseCases":[{"title":"Pre-import data quality check","prompt":"I have a CSV of customer records I'm about to load into our CRM. Validate it against these rules: customer_id must be a required unique integer, email must be a required string, signup_date must be a valid YYYY-MM-DD date, and plan must be one of 'free', 'pro', or 'enterprise'. Show me every row that fails."},{"title":"ETL pipeline CSV gate","prompt":"Before our nightly ETL job runs, check this product inventory CSV against our spec: sku must be a unique required string, quantity must be a required integer with a minimum of 0, price must be a decimal, and we need at least 10 rows and no more than 2000. Flag any rows that don't comply."},{"title":"Submitted form data validation","prompt":"Users submitted a CSV of survey responses — validate it against these columns: respondent_id as a required unique integer, agreed as a required boolean (true or false), score as a required integer between 1 and 10, and submitted_at as a date. Tell me which rows have errors and what kind."}],"resultDescription":"Returns a JSON object with a 'verdict' of 'pass' or 'fail', a list of up to 50 failures each containing the row number, column name, and error code (e.g. 'unique', 'min', 'required', 'type'), the total number of rows checked, failure count, whether failures were truncated, a SHA256 receipt, and a boundary disclaimer about the scope of validation.","failureModes":["CSV exceeds 2,000 rows — request rejected","More than 50 columns in spec or CSV — request rejected","Payload exceeds 256 KiB — request rejected","Column named in spec is missing from CSV header — returns column-level error","Extra columns in CSV when allow_extra_columns is false — validation failure","Invalid spec JSON structure — malformed request error","Only first 50 failures returned if more exist (failures_truncated: true)","Non-UTF-8 CSV encoding causes parse failure"],"whenToPreferThis":"Choose this endpoint when you need a fast, deterministic, schema-driven gate before importing or processing CSV data — especially when you have a fixed column specification with known types, required fields, uniqueness constraints, or allowed value sets. It is ideal for ETL pipelines, form submission processing, and data handoff validation where you want row-level error codes without modifying the data. Do not use it for cross-column rules, formula evaluation, fact-checking, data repair, or fuzzy/semantic validation.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-10T12:34:53.186Z","isFirstParty":false,"canonicalSlug":"mekler-ai-csv-data-validator-2bb5f592"}