Directory Compare FCRS-1.0 /llms.txt
← Back to Directory

Strapi CLI

$ strapi Official Med Risk
Strapi · Workspace & SaaS · MIT (Community) / Enterprise · macos / linux / windows

Strapi CLI (strapi, bundled in @strapi/strapi) orchestrates local Strapi CMS development (develop), production admin builds (build), TypeScript schema generation (ts:generate-types), and data export/import/transfer. Built around project-local Node.js execution rather than stateless API queries.

FCRS-1.0 Score
71 /100
Usable w/ Caveats
Medium Confidence
Zero-Friction Install
npm install @strapi/strapi
CLI vs MCP Decision CLI Only

strapi compiles the local React admin bundle, watches local content-type schemas, and writes generated TypeScript definitions directly to ./types/.

Agent-Readiness Checklist

— JSON Output
— Field Filtering
— Non-Interactive
— Dry-Run
— Read-Only Mode
— NO_COLOR Clean
✓ Self-Describing
— Official SKILL.md

Static evaluation (not yet probed on this host). Run npm run data:probe locally to capture live verification.

FCRS-1.0 6-Dimension Breakdown

Agent-Readiness 16 / 25

Project-bound CLI focused on dev server, builds, and generators; lacks global --json output and uses interactive prompts on generate.

  • No global --json output mode across strapi subcommands
  • strapi generate relies on interactive Inquirer prompts
Trust & Safety 19 / 25

Diagnostic and build commands are local, while import/transfer require explicit --force or token flags when overwriting databases.

  • Local schema typegen and routes:list do not mutate remote state
Setup & Portability 12 / 15

Bundled with @strapi/strapi via npm/npx across macOS, Linux, and Windows, but requires a full Node.js project.

  • Runs via npx strapi inside @strapi/strapi projects
Utility & Efficiency 11 / 15

Essential for Strapi builds, ts:generate-types, route inspection, and encrypted data export/transfer.

  • Covers develop, build, ts:generate-types, and export/transfer
Maintenance & Lineage 7 / 10

Official Strapi monorepo (strapi/strapi) with MIT Community Edition and commercial ee/ enterprise modules.

  • Official Strapi repository
Docs & Verifiability 6 / 10

Documented in Strapi CLI reference, though exact flags vary between Strapi v4 and v5.

  • Official docs at docs.strapi.io/cms/cli

Security, Auth & Guardrails

Auth Modes
No Auth Env API Key Config File
Credential Storage

Reads database and app secrets from project .env and config/ files; strapi transfer uses transfer tokens passed via --to-token / --from-token or prompts.

Side Effects
Read-Only Local Write Remote Write
Cost & Quotas

MIT open-source Community Edition; Enterprise features and Strapi Cloud are commercially licensed.

Copyable Guardrail for CLAUDE.md / AGENTS.md
# Strapi CLI (strapi) Agent Rules
- Run `npx strapi` inside a valid Strapi project root; avoid long-running `strapi develop` without a background task.
- Never run `strapi import` or `strapi transfer` against a production database without explicit backup confirmation.
- Pass explicit flags to `strapi admin:create-user` or `strapi export` to avoid interactive prompts.

Agent-Ready Command Recipes

Safe Read-Only Queries

List registered Strapi API routes
npx strapi routes:list

Prints all REST API routes registered by content-types and plugins in the local Strapi project.

Generate TypeScript definitions for schemas
npx strapi ts:generate-types --debug

Writes TypeScript interfaces for local Strapi content-types and components into types/.

Controlled Writes & Previews

Build Strapi admin panel for production
npx strapi build

Compiles the Strapi admin UI bundle into dist//build/ without starting a long-running server.

Strengths for Agents

  • + ts:generate-types and routes:list give coding agents immediate visibility into local CMS schemas and endpoints.
  • + Built-in export/import/transfer commands simplify moving content across environments.

Caveats & Pitfalls

  • ! Not a standalone global SaaS API CLI; must be invoked inside a Strapi project directory.
  • ! Lacks global --json output, and strapi generate / create-strapi default to interactive prompts.

Tested Agent Hosts

Claude Code Codex CLI Gemini CLI