← ClaudeAtlas

json-validatorlisted

Validate, format, and fix JSON data. Use this skill when working with JSON files, API responses, or configuration files that need validation or formatting.
aiskillstore/marketplace · ★ 329 · Data & Documents · score 79
Install: claude install-skill aiskillstore/marketplace
# JSON Validator Validate, format, and fix JSON data with helpful error messages and suggestions. ## When to Use This Skill Use this skill when you need to: - Validate JSON syntax and structure - Format/prettify JSON data - Fix common JSON errors - Convert between JSON and other formats - Analyze JSON structure ## Validation When validating JSON: 1. **Check syntax**: Identify syntax errors with line numbers 2. **Provide context**: Show the problematic section 3. **Suggest fixes**: Offer specific corrections 4. **Explain issues**: Describe what's wrong and why ### Common JSON Errors to Check - Missing or extra commas - Unclosed brackets/braces - Unquoted keys - Trailing commas (invalid in strict JSON) - Single quotes instead of double quotes - Comments (not allowed in JSON) - Undefined/NaN/Infinity values ### Example Validation Output ``` ❌ JSON Validation Failed Line 5: Trailing comma after last object property "name": "example", "value": 123, ← Remove this comma } ✅ Suggested fix: { "name": "example", "value": 123 } ``` ## Formatting When formatting JSON: 1. **Use 2-space indentation** (standard) 2. **Sort keys alphabetically** (optional, ask user) 3. **Remove unnecessary whitespace** 4. **Ensure consistent structure** ### Example **Input (minified):** ```json {"name":"test","items":[1,2,3],"active":true} ``` **Output (formatted):** ```json { "name": "test", "items": [ 1, 2, 3 ], "active": true } ``` ## Fixing Common Issues ##