CLI Tool

A comprehensive command-line tool for working with JSON Agents manifests. Validate, convert, format, and test your agent configurations.

Installation

# Install globally (coming soon)
npm install -g @jsonagents/cli
# Or use via npx (coming soon)
npx @jsonagents/cli --help

📦 Package publishing coming soon. For now, install from source in packages/cli

Available Commands

init

Create a new JSON Agents manifest interactively

jsonagents init

validate

Validate manifests against the JSON Schema with watch mode support

jsonagents validate manifest.json
# Watch for changes
jsonagents validate manifest.json --watch

convert

Convert between JSON and YAML formats

jsonagents convert manifest.json manifest.yaml
jsonagents convert manifest.yaml manifest.json

format

Format JSON files (pretty-print or minify)

jsonagents format manifest.json
jsonagents format manifest.json --minify

info

Display detailed information about a manifest

jsonagents info manifest.json

search

Search for agents in the registry

jsonagents search customer-support

fetch

Download manifests from the registry or URL

jsonagents fetch agent-id ./output.json
jsonagents fetch https://example.com/manifest.json

test-policy

Test policy expressions with custom context

jsonagents test-policy "user.role === 'admin'"

test-uri

Validate and parse ajson:// URIs

jsonagents test-uri ajson://example.com/agent/v1

Available Templates

The init command provides 8 pre-built templates:

Router Agent

Routes requests to specialized agents

Q&A Agent

Answers questions from knowledge base

Summarization Agent

Summarizes long documents

Content Generation

Creates various content types

Retrieval Agent

Searches and retrieves information

Classification Agent

Categorizes and tags content

Extraction Agent

Extracts structured data

Custom Agent

Start from scratch

Features

  • ✓Interactive manifest creation with Inquirer prompts
  • ✓Schema validation with detailed error reporting using AJV
  • ✓Watch mode for continuous validation during development
  • ✓Format conversion between JSON and YAML
  • ✓Pretty-print and minify JSON files
  • ✓Policy expression testing for access control rules
  • ✓URI validation for ajson:// scheme
  • ✓8 pre-built templates for common agent patterns