Overview
Anysite CLI is agent-native — it auto-detects when stdout is a pipe or subprocess (non-TTY) and switches all output to structured JSON. No flags, no configuration. AI agents like Claude Code, n8n, Make, and custom scripts get machine-readable responses out of the box. Every command returns:- A JSON envelope with
ok,result/error,hints, andmeta - Exit codes for programmatic flow control
- Error codes with
retryableflag andsuggestions - Next-step hints so agents discover follow-up commands without documentation
Auto-Detection
--non-interactive flag disables interactive prompts (confirmations, selections). It is auto-enabled when stdin is not a TTY.
JSON Envelope
Success Response
Error Response
ok field first. Use error.code for programmatic handling, error.retryable to decide whether to retry, and error.suggestions for recovery steps.
Exit Codes
Error Codes
API Errors
API Errors
Database Errors
Database Errors
Dataset Errors
Dataset Errors
LLM Errors
LLM Errors
Hints
Every command returns next-step hints — suggested follow-up commands based on what you just did. In JSON mode, hints appear in thehints array. In human mode, they are printed as dim text on stderr.
Agents use hints to discover follow-up actions without consulting documentation:
Discovery Payload
Runanysite with no arguments in a pipe to get a full discovery payload describing all CLI capabilities:
This allows an agent to introspect the CLI on first run and plan its workflow without any prior knowledge.
Built-in Guide
The CLI includes a comprehensive dataset configuration guide accessible via the command line:Integration Examples
Pipe to jq
Shell Script with Error Handling
Agent Workflow
A typical AI agent workflow with the CLI:Next Steps
Data Agent
AI agent for automated data collection using the agent protocol
Installation
Install the CLI and configure global options