cli-design

Design agent-first CLIs that emit JSON envelopes with HATEOAS-driven command trees.

9|22|Updated Jan 8, 2026
One-click install
npx skills add https://github.com/godaddy/cli --skill cli-design-godaddy
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: cli-design
Source: https://github.com/godaddy/cli/tree/main/.agents/skills/cli-design
Command: npx skills add https://github.com/godaddy/cli --skill cli-design-godaddy

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Command-line tools often expose textual output that is hard for agents to interpret and for humans to verify. This guide defines patterns for agent-first CLIs that always emit JSON envelopes, expose discoverable command trees via a root discovery, and protect context in outputs to maintain useful, concise results.

Core Features & Use Cases

  • JSON-only responses for all commands, enabling reliable agent parsing and orchestration.
  • HATEOAS-driven, self-documenting command trees so agents and humans can discover next steps without external docs.
  • Context-protecting output and streaming capabilities for long-running operations, with consistent error envelopes that include actionable fixes.
  • Use Case: Build a new CLI tool or extend an existing one to support agent-driven workflows and predictable integration with automation.

Quick Start

Install the CLI and run the root command to see the full command tree and example JSON envelopes.

Frequently Asked Questions about cli-design

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
What is an agent-first CLI and how does it work with JSON envelopes?

An agent-first CLI is a command-line tool designed to emit JSON-only output, enabling reliable agent parsing and orchestration. It uses JSON envelopes to deliver self-describing command trees, protecting context and ensuring predictable, navigable responses for automation workflows.

How do I design a CLI that supports HATEOAS-driven navigation for agents?

To design a CLI with HATEOAS-driven navigation, implement a root discovery command that outputs a self-documenting command tree. This exposes prefilled next_actions within JSON envelopes, allowing agents to autonomously discover and execute subsequent steps without relying on external documentation.

When do I need streaming NDJSON output in a command-line tool?

You need streaming NDJSON output in a command-line tool for long-running operations. It maintains context-protecting output by streaming structured data incrementally, preventing context window overflow while providing agents with real-time, parseable JSON envelopes during extended tasks.

Does this approach work for extending existing CLI tools or only new ones?

This approach works for both building new CLI tools and enhancing existing ones. It targets developer teams needing agent-driven workflows, allowing you to retrofit current tools to support JSON-only output, self-describing command trees, and predictable integration with automation systems.

How should a CLI handle errors for automated agent parsing?

A CLI should handle errors by returning consistent error envelopes within its JSON output. These envelopes include actionable fixes, ensuring that agents can programmatically interpret the failure, understand the required correction, and attempt a resolution without human intervention.

Why should I replace text-based CLI output with JSON envelopes?

You should replace text-based CLI output with JSON envelopes because raw text is hard for agents to interpret and for humans to verify. JSON-only responses enable reliable agent parsing, while context-protecting output maintains useful, concise results for orchestration.