# CSV Cleaner – Fix Delimiters, Encodings & Formatting Issues

> CSV Cleaner – Fix Delimiters, Encodings & Formatting Issues is a paid API for AI agents from api.strale.io, paid per call via x402, $0.0216/call, status unknown (last checked 2026-09-14).

Cleans messy CSV strings by fixing inconsistent delimiters, mixed encodings, BOM markers, trailing commas, and malformed quoted fields, returning a clean CSV plus an issues report.

## Facts

- Endpoint: GET https://api.strale.io/x402/csv-clean
- Price: $0.0216/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/api-strale-io-a658f013
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_P35iOM2EJFyb2S6vPxC8T

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 api-strale-io-a658f013
```

Example prompt: Can you clean up this CSV for me — it has inconsistent delimiters, some BOM characters, and a few malformed quoted fields? Here's the raw string: 'name,age,,city\r\nAlice,"30,New York\nBob;25;"Los Angeles"'

## When to prefer this

Choose this endpoint when you have raw, dirty CSV data that needs normalization before ingestion, parsing, or storage — especially when dealing with files exported from multiple sources with inconsistent formatting, encoding issues, or BOM markers that break standard CSV parsers.

## Known failure modes

- Empty or missing 'csv' query parameter returns an error
- Extremely large CSV strings may hit request size limits
- Ambiguous delimiter cases may be resolved incorrectly if multiple delimiter types are equally distributed
- Non-CSV binary data passed as input may produce unexpected output
- Payment failure (402) if USDC balance is insufficient

## How this service works

Clean messy CSV: fix inconsistent delimiters, mixed encodings, BOM, trailing commas, quoted fields. Returns clean CSV with issues report.

## Output

Returns a cleaned CSV string with all formatting issues resolved, along with a structured issues report detailing what problems were found and fixed (e.g. BOM removed, delimiters normalized, encoding corrected, trailing commas stripped).

## Example request

```json
{
 "csv": "name,age,city\r\nAlice,30,New York\r\nBob,25,Los Angeles\r\nCharlie,35,Chicago"
}
```

## 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",
      "HEAD",
      "DELETE"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "csv"
     ],
     "properties": {
      "csv": {
       "type": "string",
       "description": "Messy CSV string to clean"
      }
     }
    }
   },
   "additionalProperties": false
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/api-strale-io-a658f013/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.strale.io](https://www.zero.xyz/host/api.strale.io/llms.txt)
