Docs
/
/
Platform
Knock AI
Knock CLI

Knock CLI

Use the Knock CLI as the local-first surface for AI coding agents to read and write Knock resources from your codebase.

The Knock CLI is the local-first AI agent surface for Knock. It's fast, lightweight, and leans on tooling already available in your code editor. Reach for the CLI when you're working in Cursor, Claude Code, or another IDE on a Knock-aware codebase and you want the agent to manage workflows, templates, and other resources alongside your application code.

What an agent can do with the CLI

#

When the Knock CLI is installed and authenticated, an AI coding agent can use it to:

  • Pull workflows, templates, email layouts, partials, guides, and message types into your repo.
  • Scaffold new resources locally, including new partials and guides.
  • Edit resources as code, then validate them before pushing.
  • Push changes back to Knock, commit them in an environment, and promote between environments.
  • Wire Knock into your CI/CD pipeline.

The CLI exposes the full set of Knock resource operations. The MCP server exposes a curated subset focused on managing resources, manipulating data, and inspecting environments — it does not currently support local file scaffolding, local validation, or deletion. Use the CLI when you need any of those.

Install the Knock CLI

#

Install the CLI with npm:

Then authenticate with knock login. See the Knock CLI docs for full installation, authentication, and command reference.

Pair with the knock-cli skill

#

The CLI gives an agent the tools to manage Knock resources. The knock-cli skill gives the agent the procedural knowledge to use those tools well — which commands exist, when to reach for each one, and how to structure the resource files the CLI expects.

Install the skill alongside the CLI:

When you ask "add a comment-created workflow to this repo," the agent reads the skill, runs the right knock commands, and writes the resulting files into your project.

You can pair this setup with the MCP server when you also want the agent to perform live API operations against your Knock account from outside the IDE.

See also

#
  • Knock AI overview. See how the CLI fits alongside the dashboard agent, agent function, MCP server, and skills.
  • Knock CLI reference. Full installation, authentication, and command reference.
  • Skills. Procedural knowledge that complements the CLI and MCP server.
  • MCP server. Connect external clients and your own apps to Knock as tools.
New chat