Open-source CLI for AI agents

LinkModel CLI for image and video AI agents.

LinkModel CLI turns terminal-capable AI agents into multimodal creators. One safe installation prompt, one API key, and a complete generation workflow from request to downloaded artifact.

CodexClaude CodeCursor
View on GitHub
$
Three steps

From conversation to creation.

Your agent can install, validate, authenticate, and operate the CLI without a separate integration layer.

01

Hand the runbook to your agent.

Copy the official prompt. The agent follows a canonical installation guide and validates the CLI without triggering a billable request.

lkm doctor --json
02

Connect an API key safely.

Credentials stay in a local file with restricted permissions and remain masked in human and JSON output.

lkm auth login --api-key YOUR_API_KEY
03

Ask for an image or video.

Describe the output in natural language. Your agent selects the command, waits for the task, and downloads the artifact.

lkm image "a cinematic product shot"
Real workflow

One lifecycle, end to end.

Create synchronously, leave a long task running asynchronously, or resume it later. The same commands work for people, scripts, and coding agents.

linkmodel-cli
Agent-native by design

Predictable enough to automate.

The CLI exposes explicit state instead of hiding behavior, so agents can reason about every step.

Stable JSON output

Use --json for machine-readable responses that are easy to inspect, pipe, and validate.

Meaningful exit codes

Success, validation, authentication, timeout, and task failures remain distinguishable.

Model-aware options

Selected-model help exposes the exact supported flags, defaults, ranges, and enums.

Resumable tasks

Start with --no-wait, keep the task ID, then inspect or wait for completion later.

Artifact delivery

Completed images and videos download automatically with extensions derived from their content type.

Masked credentials

Stored API keys use restricted file permissions and are masked in command output.

Safe defaults for autonomous work.

The installation prompt gives every agent clear boundaries before it touches credentials or paid generation.

  • Never print, log, or commit a complete API key.
  • Never run paid generation without explicit user authorization.
  • Validate installation with lkm doctor --json before generating.

Open source and ready today.

LinkModel CLI is MIT licensed, published on npm, and developed in the official LinkModel GitHub organization.

Common questions

Everything your agent needs to start.

What is LinkModel CLI?

LinkModel CLI is an open-source command-line client for generating images and videos through LinkModel from a terminal, script, or AI coding agent.

Which AI agents can use LinkModel CLI?

Any agent that can run terminal commands can use it, including Codex, Claude Code, Cursor, and similar coding agents.

How is the API Key stored?

The CLI stores credentials locally with restricted file permissions and masks the Key in human-readable and JSON output.

Can it generate both images and videos?

Yes. The CLI supports image and video generation, asynchronous task status checks, resumable waits, and automatic artifact downloads.