# BRAINIAC Response Normalize API

> BRAINIAC Response Normalize API is a paid API for AI agents from www.brainiac.software, paid per call via x402, $0.03/call, status unknown (last checked 2026-11-12).

Normalizes, transforms, and validates JSON API request/response payloads by applying structural operations like rename, cast, pick, omit, and schema compliance checks.

## Facts

- Endpoint: POST https://www.brainiac.software/api/v1/integration/response-normalize?utm_source=zero.xyz
- Price: $0.03/call
- Payment: x402
- Status: unknown
- Last checked: 2026-11-12
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/brainiac-response-normalize-api-696024a8
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_fRhSZWl80xI6chcsxrEs-

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 brainiac-response-normalize-api-696024a8 -d '<json body>'
```

Example prompt: Take this JSON response from our payment API and normalize it — rename the field 'usr_id' to 'userId', omit 'internal_debug', cast 'amount' to a number, and validate it against this schema: {"type":"object","required":["userId","amount"]}. Return the cleaned result and list what changed.

## When to prefer this

Choose this endpoint when you need to programmatically normalize, reshape, or validate a JSON payload without executing user code or making external calls. It is especially useful for API integration pipelines where field names, types, or structures differ between providers. Prefer it over generic LLM transformation when you need deterministic, auditable change logs and schema compliance guarantees.

## Known failure modes

- Invalid base64 encoding in file input returns a parsing error
- JSON payload exceeding 200,000 character limit is rejected
- Unsupported operation type in operations array causes validation failure
- Schema keyword not supported (only type, properties, required, additionalProperties, items, enum, const, length, range, email/date/date-time formats) — unsupported keywords are reported but not applied
- Field mapping proposed only when path or field name matches one field on each side — ambiguous mappings may be omitted
- Payment not received or insufficient USDC balance returns 402 response

## How this service works

Pay-per-call APIs for AI agents: OFAC sanctions screening, compliance checks, token security, and Base chain data via x402. No account. Fixed USDC price. MCP-ready.

## Output

Returns a normalized JSON object (result), a list of changes applied (path, rule, original, normalized values), issue list, schema compliance flag, change count, and metadata flags confirming no external calls or invented values were made.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "file": {
   "type": "object",
   "required": [
    "mediaType",
    "fileBase64"
   ],
   "properties": {
    "filename": {
     "type": "string",
     "maxLength": 180,
     "minLength": 1
    },
    "mediaType": {
     "enum": [
      "application/json",
      "text/plain"
     ],
     "type": "string"
    },
    "fileBase64": {
     "type": "string",
     "maxLength": 12000000,
     "minLength": 1
    }
   },
   "additionalProperties": false
  },
  "json": {
   "type": "string",
   "maxLength": 200000
  },
  "side": {
   "enum": [
    "request",
    "response"
   ],
   "type": "string"
  },
  "after": {},
  "before": {},
  "schema": {},
  "source": {},
  "target": {},
  "example": {},
  "payload": {},
  "examples": {
   "type": "array",
   "items": {},
   "maxItems": 20
  },
  "toVersion": {
   "type": "string",
   "maxLength": 40,
   "minLength": 1
  },
  "operations": {
   "type": "array",
   "items": {
    "oneOf": [
     {
      "type": "object",
      "required": [
       "op",
       "from",
       "to"
      ],
      "properties": {
       "op": {
        "type": "string",
        "const": "rename"
       },
       "to": {
        "type": "string",
        "maxLength": 200,
        "minLength": 1
       },
       "from": {
        "type": "string",
        "maxLength": 200,
        "minLength": 1
       }
      },
      "additionalProperties": false
     },
     {
      "type": "object",
      "required": [
       "op",
       "from",
       "to"
      ],
      "properties": {
       "op": {
        "type": "string",
        "const": "copy"
       },
       "to": {
        "type": "string",
        "maxLength": 200,
        "minLength": 1
       },
       "from": {
        "type": "string",
        "maxLength": 200,
        "minLength": 1
       }
      },
      "additionalProperties": false
     },
     {
      "type": "object",
      "required": [
       "op",
       "paths"
      ],
      "properties": {
       "op": {
        "type": "string",
        "const": "pick"
       },
       "paths": {
        "type": "array",
        "items": {
         "type": "string",
         "maxLength": 200,
         "minLength": 1
        },
        "maxItems": 40,
        "minItems": 1
       }
      },
      "additionalProperties": false
     },
     {
      "type": "object",
      "required": [
       "op",
       "paths"
      ],
      "properties": {
       "op": {
        "type": "string",
        "const": "omit"
… (truncated)
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "issues": [],
  "result": {
   "a": 1,
   "b": "x"
  },
  "status": "normalized",
  "changes": [
   {
    "path": "/",
    "rule": "sort_keys",
    "original": "b,a",
    "normalized": "a,b"
   },
   {
    "path": "/b",
    "rule": "trim",
    "original": "\" x \"",
    "normalized": "\"x\""
   }
  ],
  "checkedAt": "2026-11-03T15:00:00.000Z",
  "limitations": [
   "No external API is called and no user-supplied code is executed.",
   "Validation covers type, properties, required, additionalProperties, items, enum, const, length, range, and the formats email, date, and date-time. Other JSON Schema keywords are reported and not applied.",
   "A generated schema uses only values present in the supplied examples. additionalProperties stays true.",
   "A field mapping is proposed only when the path matches or the field name matches one field on each side.",
   "Breaking and non-breaking labels are returned only when side is request or response.",
   "Transforms are rename, copy, pick, omit, cast, and default. A default is written only when the path is absent."
  ],
  "changedCount": 2,
  "codeExecuted": false,
  "externalCall": false,
  "valuesInvented": false,
  "schemaCompliance": false
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/brainiac-response-normalize-api-696024a8/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from www.brainiac.software](https://www.zero.xyz/host/www.brainiac.software/llms.txt)
