flatkey-ai/flatkey-cli

Flatkey media generation CLI for images, videos, audio, text, credits, and model discovery.

What it solves

Flatkey CLI provides a unified interface for generating images, videos, audio, and text using various AI models. It eliminates the need to manage multiple API keys, separate credit balances, and different toolsets for different media types, offering a programmatic way to automate creative generation for media teams and AI agents.

How it works

The tool operates as a command-line interface that routes requests to the Flatkey router and model registry. Users can generate content via simple commands (e.g., flatkey image generate or flatkey video generate), specify models, and save outputs directly to local files. It includes a JSON mode for machine-readable output, making it easy to integrate into scripts or AI agents like Cursor or Claude Code.

Who it’s for

  • Media teams building repeatable generation pipelines.
  • Developers creating AI-agent workflows that require multimodal generation capabilities.
  • Users who want a cost-effective, programmatic alternative to closed creative suites with long queues.

Highlights

  • Unified Credit Balance: One API key and one balance for image, video, audio, and text generation.
  • Agent-Friendly: Includes a --json flag for clean stdout and a --dry-run mode to test requests without spending credits.
  • Multimodal Support: Supports text-to-image, text-to-video (with image-to-video and first/last frame control), text-to-speech, sound effects, and music generation.
  • Cross-Platform: Available as an npm package for macOS, Linux, and Windows.

Related

  • Project
  • Project
  • Project
  • Project
  • Project