npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

jsonyo

v2.0.0

Published

JSON swiss army knife. validate, format, convert, generate types. bruh.

Readme

jsonyo

JSON swiss army knife. bruh.

npm license

Documentation · Report Bug · Get PRO

What's New in v2.0.0

  • 13 FREE commands — validate, format, minify, query, keys, type, diff, stats, merge, flatten, unflatten, sort, filter
  • 5 PRO commands — convert, schema, generate, batch, watch
  • Format conversion — JSON ↔ YAML, TOML, CSV, XML
  • Type generation — TypeScript, Go, Python, Rust
  • Batch processing — process multiple files at once
  • Watch mode — auto-process on file changes

Install

npm install -g jsonyo

Quick Start

# validate JSON
jsonyo validate data.json
# ✓ valid JSON. nice.

# pretty print
jsonyo format data.json
jsonyo format data.json -i 4  # 4 spaces indent

# minify
jsonyo minify data.json -o data.min.json

# query by JSONPath
jsonyo query data.json -p "$.users[0].name"
jsonyo query data.json -p "$.users[*].email"
jsonyo query data.json -p "$..name"  # recursive

# list keys
jsonyo keys data.json --depth 2

# compare files
jsonyo diff old.json new.json

# merge files
jsonyo merge a.json b.json -o combined.json

# flatten/unflatten
jsonyo flatten nested.json
jsonyo unflatten flat.json

# sort
jsonyo sort data.json --path "$.items" --by "name"
jsonyo sort data.json --path "$.items" --by "price" --desc --numeric

# filter arrays
jsonyo filter data.json --where "age > 18"
jsonyo filter data.json --path "$.users" --where "active == true"

# pipe from stdin
cat data.json | jsonyo format
curl api.example.com/data | jsonyo query -p "$.results"

FREE Commands

| Command | Alias | Description | |---------|-------|-------------| | validate | v | Check if JSON is valid | | format | f | Pretty print JSON | | minify | m | Remove whitespace | | query | q | Extract value by JSONPath | | keys | k | List all keys | | type | t | Show type and info | | diff | d | Compare two files | | stats | s | Show statistics | | merge | - | Merge JSON files (2 max) | | flatten | - | Flatten nested JSON | | unflatten | - | Unflatten dotted keys | | sort | - | Sort keys or arrays | | filter | - | Filter array elements |

FREE Tier Limits

  • 100KB max file size
  • 20 operations per day
  • Merge limited to 2 files

PRO Commands

# Convert formats (PRO)
jsonyo convert data.json --to yaml
jsonyo convert data.yaml --to json
jsonyo convert data.json --to csv
jsonyo convert data.json --to xml

# JSON Schema (PRO)
jsonyo schema generate data.json
jsonyo schema validate data.json --schema schema.json

# Generate types (PRO)
jsonyo generate types data.json -o types.ts
jsonyo generate go data.json -o types.go
jsonyo generate python data.json -o types.py
jsonyo generate rust data.json -o types.rs

# Batch processing (PRO)
jsonyo batch format ./data/*.json
jsonyo batch validate ./configs/*.json --schema schema.json
jsonyo batch convert ./data/*.json --to yaml

# Watch mode (PRO)
jsonyo watch format ./data/*.json
jsonyo watch validate ./configs/*.json --schema schema.json

| Command | Description | |---------|-------------| | convert | JSON ↔ YAML/TOML/CSV/XML | | schema | Generate/validate JSON Schema | | generate | Generate TypeScript/Go/Python/Rust types | | batch | Process multiple files at once | | watch | Watch files and auto-process |

PRO Features

  • 100MB max file size
  • Unlimited operations
  • Merge unlimited files
  • Format conversion
  • Type generation
  • Batch processing
  • Watch mode

Options

| Flag | Description | Default | |------|-------------|---------| | -i, --indent | Spaces for format | 2 | | --tabs | Use tabs for indent | false | | -p, --path | JSONPath for query | - | | --depth | Depth for keys | 1 | | --by | Field to sort by | - | | --desc | Sort descending | false | | --numeric | Numeric sort | false | | --where | Filter condition | - | | --to | Target format | - | | --schema | Schema file | - | | --strategy | Merge strategy | overwrite | | --separator | Flatten separator | . | | -o, --output | Output file | stdout | | -h, --help | Show help | - |

Activate PRO

jsonyo activate XXXX-XXXX-XXXX-XXXX

Buy PRO License → — $11.99 one-time

API Usage

const jsonyo = require('jsonyo');

// Parse & stringify
const { data, success, error } = jsonyo.parse('{"a": 1}');
const formatted = jsonyo.stringify(data, 2);
const minified = jsonyo.minify(data);

// Query
const value = jsonyo.query(data, '$.users[0].name');
const all = jsonyo.queryAdvanced(data, '$..name');

// Transform
const flat = jsonyo.flatten(data);
const nested = jsonyo.unflatten(flat);
const merged = jsonyo.merge(obj1, obj2);
const sorted = jsonyo.sortKeys(data);

// Validate
const schema = jsonyo.generateSchema(data);
const errors = jsonyo.validateAgainstSchema(data, schema);

// Convert (PRO)
const yaml = jsonyo.toYAML(data);
const csv = jsonyo.toCSV(data);

// Generate (PRO)
const ts = jsonyo.generateTypeScript(data);
const go = jsonyo.generateGo(data);

More tools from bruh.tools

View all tools →

License

MIT © bruh.tools


bruh.tools — no cap, fr fr