JSON Linter for Openclaw

A lightweight utility for recursively scanning workspaces to identify and report syntax errors in JSON files.

wanng-ide
v1.0.0
Feb 16, 2026
1
1.7k
0

Install & Download

1. ClawHub CLI

The fastest way to install a skill directly from the registry.

npx clawhub@latest install json-linter

2. Manual Installation

Copy the skill folder to one of these locations

Global
~/.openclaw/skills/
Workspace
<project>/skills/

Priority: Workspace > Local > Bundled

3. Prompt Installation

Copy this prompt to OpenClaw to install it automatically.

Help me install json-linter using Clawhub. If Clawhub is not installed, install it first (npm i -g clawhub).

Prefer to download?

Get the raw skill files in a ZIP archive.

What is JSON Linter?

The JSON Linter is a developer-centric tool designed to maintain data integrity across complex workspaces. By recursively scanning for .json files, it ensures that configuration files, memory assets, and data structures are syntactically correct, preventing runtime failures caused by malformed data. As part of the Openclaw Skills ecosystem, this tool provides a fast and reliable way to audit large projects for hidden syntax issues.

JSON Linter Use Cases

  • Automated validation of configuration files before deployment.
  • Checking the integrity of memory files or data assets in AI agent workspaces.
  • Debugging Unexpected token errors in large JSON datasets.
  • Pre-commit checks to ensure all JSON files in the repository are valid.

How JSON Linter Works

  1. The skill initiates a recursive scan starting from the current directory or a specified path.
  2. It identifies all files with the .json extension.
  3. Each file is read and processed through a standard validation engine using JSON.parse().
  4. Successes and failures are tracked, capturing specific error messages and character positions for invalid files.
  5. A comprehensive JSON report is generated summarizing the workspace health.

JSON Linter Setup

To scan the entire workspace from the root, execute the following command:

node skills/json-linter/index.js

To scan a specific subdirectory, provide the directory path with the --dir flag:

node skills/json-linter/index.js --dir path/to/dir

JSON Linter Data Schema & Taxonomy

The skill generates a structured JSON report detailing the scan results. The schema includes:

Field Description
scanned_at ISO 8601 timestamp of the scan execution
total_files Total number of .json files discovered
valid_files Number of files with correct syntax
invalid_files Number of files containing syntax errors
errors An array containing the relative path and the specific error message for each invalid file

JSON Linter Advanced Features

  • Targeted directory scanning to limit scope and improve performance.
  • Precise error location reporting to facilitate quick manual fixes.
  • Clean JSON output suitable for ingestion by other Openclaw Skills or automation scripts.
  • Recursive workspace auditing to catch errors deep within nested folder structures.

SKILL.md


Loading

Related Openclaw Skills

METADATA

Github Stars: 0
forks: 0

Featured*