JSON Fixer
Pricing
from $0.50 / 1,000 json cleaneds
Go to Apify Store
JSON Fixer
Repairs malformed JSON such as LLM output: strips Markdown fences, fixes curly quotes and trailing commas, and optionally validates the result against a JSON Schema.
JSON Fixer
Pricing
from $0.50 / 1,000 json cleaneds
Repairs malformed JSON such as LLM output: strips Markdown fences, fixes curly quotes and trailing commas, and optionally validates the result against a JSON Schema.
You can access the JSON Fixer programmatically from your own applications by using the Apify API. You can also choose the language preference from below. To use the Apify API, you’ll need an Apify account and your API token, found in API & Integrations in Apify Console.
$echo '{< "raw_text": "Here is the result:\\n{\\"name\\": \\"Lin\\", \\"tags\\": [\\"json\\", \\"cleanup\\",], \\"quote\\": “hello”}"<}' |<apify call flyerlin/json-fixer --silent --output-datasetThe Apify CLI is the official tool that allows you to use JSON Fixer locally, providing convenience functions and automatic retries on errors.
Using installation script (macOS/Linux):
$curl -fsSL https://apify.com/install-cli.sh | bashUsing installation script (Windows):
$irm https://apify.com/install-cli.ps1 | iexUsing Homebrew:
$brew install apify-cliUsing npm:
$npm install -g apify-cliOther API clients include: