---
title: "parse json (repair) · RUAL Documentation"
description: "Recover and parse JSON from messy text (code fences, prose, trailing commas, truncation). No API call."
canonical: https://docs.rual.nl/block-types/anthropic/anthropicconnection_parse_json
language: en
---

# parse json (repair)

This block is part of the [`anthropic`](https://docs.rual.nl/block-types/anthropic) group and was last modified in core [`v15.0.0`](https://docs.rual.nl/core-versions/150000).

Recover and parse JSON from messy text (code fences, prose, trailing commas, truncation). No API call.

- flow `flow`

- input required `value` The (possibly malformed) JSON text.

- flow `flow`

- success `condition`

- json `object` The parsed value.

- repaired `condition` True if a fix was applied.

- errors `array ` Error codes when the call fails (success=false): parse_error.

- error detail `value`

| `repair json` |
| --- |
| `fix json` |
| `lenient json` |
| `json parse` |
| `clean json` |

A typical wiring for [parse JSON (repair)](https://docs.rual.nl/block-types/anthropic/anthropicconnection_parse_json): a [function trigger](https://docs.rual.nl/block-types/globals/trigger_custom_function) starts the flow; [value](https://docs.rual.nl/block-types/value/value_default) feeds the `input` pin; the `flow` out pin feeds [debug](https://docs.rual.nl/block-types/state%20ui/state_debug).

![Studio canvas example for the parse JSON (repair) block: typical wiring for parse JSON (repair).](https://docs.rual.nl/canvas-examples/anthropicconnection_parse_json.png)

### Version history

Introduced in [`v15.0.0`](https://docs.rual.nl/core-versions/150000).
