Does Archify Have an API? Understanding the CLI Architecture and Programmatic Interface

Archify does not expose a public HTTP API for remote calls; instead, it provides a command‑line interface (CLI) as its primary programmable surface.

Archify is a CLI‑based tool in the tt-a1i/archify repository that generates interactive architecture diagrams from natural‑language prompts or JSON specifications. While it lacks a traditional network‑accessible API, it offers multiple programmatic ways to invoke its functionality — through direct CLI calls, agent skill integration, and scripted scenario guides.

How Archify Exposes Its Functionality

The core entry point for all Archify operations is archify/bin/archify.mjs. This file implements the CLI dispatcher that handles commands like render, deliver, preview, guide, and doctor.

The CLI as Archify's API

Unlike tools that ship with REST or GraphQL endpoints, Archify treats its CLI as the contract for programmatic access. The render command in archify/bin/archify.mjs processes diagram specifications and outputs HTML files:


# Render an architecture diagram from JSON input

node archify/bin/archify.mjs render architecture examples/web-app.architecture.json out.html

The deliver command adds validation and receipt generation:


# Deliver with JSON output for pipeline integration

node archify/bin/archify.mjs deliver architecture examples/web-app.architecture.json out.html --json

For iterative development, the preview command starts a local server and opens the browser automatically:


# Live preview with hot reload

node archify/bin/archify.mjs preview architecture examples/web-app.architecture.json

Agent Skill Integration: Archify as a Coding Assistant Extension

Archify ships with a formal skill contract defined in archify/SKILL.md. This enables installation into AI coding agents including Raven, Cursor, Claude Code, and Codex.

When installed as a skill, the agent forwards natural‑language prompts directly to Archify. The skill parses the request, invokes the appropriate CLI command, and returns the generated diagram. This pattern allows Archify to integrate into agentic workflows without requiring an HTTP API.

The skill contract specifies available commands, expected inputs, and output formats. Agents use this metadata to determine when and how to invoke Archify on behalf of the user.

Programmatic Workflows with Scenarios and Health Checks

Scripted Scenario Guides

The guide command in archify/bin/archify.mjs provides access to built‑in recipe scenarios defined in archify/recipes/scenarios.mjs. These recipes codify common architecture patterns and can be executed programmatically:


# List available scenarios as JSON for automation

node archify/bin/archify.mjs guide --json

This output can be consumed by CI/CD pipelines or other scripts to standardize diagram generation across projects.

Health Verification

The doctor command performs a readiness check to ensure the skill is properly configured:


# Verify installation and dependencies

node archify/bin/archify.mjs doctor

The "API Server" Misconception in Example Diagrams

Archify's example diagrams — such as examples/web-app.html — contain nodes labeled "API Server" at lines 4977-4980. This represents a conceptual component of the system being modeled, not an actual service provided by Archify itself.

When Archify renders a diagram, it creates visual representations of architectural components. An "API Server" node in the output indicates that the modeled system includes such a component. It does not mean Archify exposes that endpoint.

Comparing Archify's Interface Patterns

Interface Type Availability Use Case
HTTP REST API Not provided Remote service calls
CLI commands Primary interface Shell scripts, CI/CD, local automation
Agent skill Via SKILL.md AI‑assisted development workflows
Scenario recipes Via guide command Standardized architecture templates

Summary

  • Archify has no public HTTP API — interaction happens through the CLI entry point archify/bin/archify.mjs.
  • The CLI supports five core commands: render, deliver, preview, guide, and doctor.
  • Agent integration is formalized through archify/SKILL.md for Raven, Cursor, Claude Code, and Codex.
  • "API Server" nodes in output diagrams are illustrative components, not actual endpoints.
  • Programmatic automation is achieved via shell calls, JSON output flags, and scenario recipes.

Frequently Asked Questions

Can I call Archify over HTTP from another service?

No. According to the tt-a1i/archify source code, there is no HTTP server or REST endpoint exposed. The tool is designed as a CLI utility. For service‑to‑service integration, invoke the CLI as a subprocess or child process and parse the JSON output where available.

How do I integrate Archify into my CI/CD pipeline?

Use the deliver command with the --json flag to generate machine‑readable receipts. The command exits with appropriate status codes for success or failure, and the JSON output includes validation results. Example: node archify/bin/archify.mjs deliver architecture spec.json out.html --json.

What is the difference between the render and deliver commands?

render generates the diagram output file only. deliver adds a validation layer and writes a receipt file documenting the operation. Use deliver for production pipelines where traceability is required. Both commands are implemented in archify/bin/archify.mjs.

Can I extend Archify with custom commands?

The CLI structure in archify/bin/archify.mjs follows a command‑dispatcher pattern. New subcommands can be added by extending the dispatch logic and implementing the handler in the appropriate renderer under archify/renderers/*/. However, there is no plugin API documented in SKILL.md or the README.

Have a question about this repo?

These articles cover the highlights, but your codebase questions are specific. Give your agent direct access to the source. Share this with your agent to get started:

Share the following with your agent to get started:
curl -s "https://instagit.com/install.md"

Works with
Claude Codex Cursor VS Code OpenClaw Any MCP Client

Maintain an open-source project? Get it listed too →