BLACK FRIDAY

Kara Cuma: Yıllıkta %50 indirim, Pro’da %30 bonus kredi

Bitimine --g --:--:--%50 indirimi al

Kling MCP & CLI Guide 2026: Setup, Commands, Limits

Kling MCP & CLI in 2026: add https://kling.ai/mcp to Claude, ChatGPT or Cursor, install @klingai/cli-global, sign in with OAuth, Kling 4.0, Flash, limits.

Kling MCP & CLI Guide 2026: Setup, Commands, Limits

Updated November 15, 2026 · Last checked November 15, 2026 against the Kling MCP & CLI Guide, the Kling MCP page FAQ, the @klingai/cli-global README (v0.2.3) and the Kling 4.0 release notes

Short answer: To use Kling MCP, add the remote server https://kling.ai/mcp to Claude, ChatGPT, Cursor or another AI assistant and sign in with your Kling account; no API key is needed. For the Kling CLI, run npm i -g @klingai/cli-global, then kling login. Both use your Kling credits and support Kling 4.0 and Kling 4.0 Flash. Install only one route per assistant.

Kling MCP vs Kling CLI, from Kling’s MCP & CLI Guide and the CLI README, checked November 15, 2026
Kling MCPKling CLI
What it isRemote MCP server for AI assistantsTerminal tool; also installable as an agent skill
SetupAdd https://kling.ai/mcp, then Connect and sign innpm i -g @klingai/cli-global or npx skills add klingai-tech/skills
Sign-inOAuth with your Kling accountkling login opens browser OAuth
API keyNot requiredNot required
Tools / commands18 tools21 commands in the guide’s table
RequirementsAn MCP client that supports remote serversNode.js 18+ on macOS, Linux or Windows
Kling 4.0 and FlashSupported, including Omni Reference and keyframesSupported; model names kling-video-v4_0 and kling-video-v4_0_flash

What are Kling MCP and Kling CLI?

The Kling MCP & CLI Guide describes Kling MCP as an MCP server that lets general-purpose AI assistants such as Cursor and Claude call Kling’s image and video generation directly. Once it is configured and authorized, you ask in plain language, for example “Turn this image into a 5-second cinematic video with camera movement”, and the result comes back inside the assistant.

The Kling CLI is a command-line tool that exposes the same generation features as terminal commands. The guide lists three uses: generating videos in bulk from the terminal, scripts or CI pipelines; plugging Kling into your own toolchain, such as ComfyUI nodes, Makefiles and shell pipelines; and installing it through an AI assistant so you can still work in natural language. The CLI README calls it a thin MCP client: each command maps one-to-one to a backend MCP tool, and the CLI handles argument translation, login, polling and file upload.

The guide now lists a third route: the Kling plugin for AI assistants. It is a client-specific wrapper that sets up the MCP server and sign-in in one click and connects to the same Kling MCP service, with the same tools. Kling publishes plugin links or install prompts for Claude, ChatGPT, Cursor, WorkBuddy and OpenClaw. This is a different product from Kling’s plugin for Adobe apps; for Premiere Pro, After Effects and Photoshop, see our Kling plugin for Adobe guide.

Before building terminal commands or an agent workflow, review the Kling 4.0 overview and write down the creative inputs your automation will need to preserve.

Both now run Kling 4.0. The Kling 4.0 release notes say MCP and CLI support Kling 4.0, including Omni Reference and video generation with keyframes, for uses such as marketing assets, short-form video at scale, storyboard previsualization and character consistency.

Kling 4.0 Flash is available through MCP and CLI too. Kling named MCP and CLI among the ways to use it in its announcement that Kling 4.0 Flash is fully available, and the CLI README lists it as kling-video-v4_0_flash.

Should I use Kling MCP or the CLI?

Kling’s guide compares four ways of working:

From the Kling MCP & CLI Guide
DimensionPluginMCPCLI (via AI assistant)CLI (direct terminal use)
Natural language support✓✓✓–
Multi-step workflows in a single conversation✓✓✓–
Easy setup (single URL)✓✓✓–
Works without an AI assistant–––✓

Two rules from Kling’s pages decide most cases. First, the guide warns: “For a given AI assistant, install only one of the plugin, MCP, or CLI. If more than one is installed, the assistant may choose between them unpredictably.” Second, the FAQ on the Kling MCP page says the CLI “works in terminals and across a wide range of AI agents, offering better compatibility and stability”, and recommends installing the CLI for the best experience.

In practice: pick the plugin or MCP if you work in Claude, ChatGPT or Cursor chat and want a one-click or one-URL setup; pick the CLI if you script jobs, run CI or want to work without an assistant.

How do I set up Kling MCP in Cursor?

These are the steps in Kling’s guide, quoted exactly:

  1. In Cursor, go to Settings → Tools & MCPs → Add Custom MCP.
  2. Add klingai:
"klingai": {"url": "https://kling.ai/mcp"}
  1. Click Connect, sign in with your Kling account and start prompting from Cursor.

The snippet is the server entry only. Kling’s guide does not show the surrounding file, so place it where Cursor’s own MCP settings ask for server entries. Sign-in is OAuth, so nothing secret goes in the config.

Kling also publishes a quick-start option for any assistant that can install MCP servers itself. Paste this instruction into the assistant:

Please help me setup a new custom MCP server via the following endpoint, and complete the authorization process, https://kling.ai/mcp

How do I set up Kling MCP in Claude and Claude Code?

Claude desktop or claude.ai, per the guide: go to Customize → Connectors, choose Add custom connector and use the same entry:

"klingai": {"url": "https://kling.ai/mcp"}

Then click Add → Connect, sign in with your Kling account and start prompting. Kling’s fashion-video tutorial notes that for Team or Enterprise Claude accounts, connector availability may depend on your organization’s settings.

Claude Code, per Kling’s Claude Code tutorial: to make Kling available across your projects, run

claude mcp add --transport http klingai --scope user https://kling.ai/mcp

Use --scope project to share the connection through the current project. Without a scope, Claude Code uses its default local scope. Then start Claude Code, run /mcp, and complete the Kling sign-in.

Kling’s tutorials suggest one safe first prompt after any setup: “Confirm that Kling MCP is connected. Show me the Kling image and video tools currently available. Do not generate anything yet.” It costs nothing and shows you what your connection actually exposes.

How do I set up Kling MCP in ChatGPT or OpenClaw?

ChatGPT, per the guide: open Settings → Plugins → Create, enter a name and the server URL https://kling.ai/mcp, and select OAuth. Accept the risk notice, click Create and complete OAuth when prompted. If you use ChatGPT on the web, Kling says to use this manual MCP setup rather than the plugin.

OpenClaw, per the guide:

openclaw mcp add kling-ai \
  --url https://kling.ai/mcp \
  --transport streamable-http \
  --auth oauth

openclaw mcp login kling-ai

How do I install the Kling CLI?

The CLI needs Node.js 18 or later and runs on macOS, Linux and Windows. Kling’s guide gives two routes. As an agent skill (the klingai-tech/skills repository):

npx skills add klingai-tech/skills

Or as a global npm package, exactly as the guide writes it:

npm i -g @klingai/cli-global --registry=https://registry.npmjs.org

Accounts are split by region. The @klingai/cli-global README says both packages install the same kling command, and to use @klingai/cli-cn instead if your account belongs to the China site. The skill’s own notes warn that installing the wrong region’s package makes login fail repeatedly, so check which site your account is on first.

To upgrade:

npm i -g @klingai/cli-global@latest
kling --version

On November 15, 2026, @klingai/cli-global was at version 0.2.3.

How do I log in, and do I need an API key?

No API key. The Kling MCP page FAQ says: “Simply add the Kling MCP server to your client, or install the CLI and sign in with your Kling account using OAuth. No API keys are required.” For the CLI, kling login opens browser OAuth. The README says credentials are saved under ~/.kling/ and that the CLI never prints tokens or secrets; the guide says the token is stored locally in .credentials. kling logout revokes and clears local login state.

One account limit matters for teams: MCP and CLI currently use only paid credits from your Personal workspace. Team workspace benefits are not available yet, and Kling says switching between Personal and Team workspaces will come in a future release.

Which tools and commands does Kling expose?

The guide lists 18 MCP tools. CLI commands use the same names, with no aliases.

Kling MCP & CLI Guide, checked November 15, 2026
GroupMCP tools / CLI commandsWhat they do (from Kling’s descriptions)
Discoverywho_am_iYour identity plus the available models and parameter specs; call it first
Videotext_to_video, image_to_video, omni_ref_videoReturn a generation_id; poll query_tasks for status and results
Imagetext_to_image, image_to_imageSame task flow as video
Motionmotion_control, motion_library_listAnimate a subject image from a Motion Library motionId or a reference video
Elementselement_create, element_list, element_get, element_update, element_deleteReusable characters or objects from images or a video
Tasks and filesquery_tasks, file_uploadStatus and final asset URL; one-time upload ticket
Accountquery_membership_and_credits (CLI: account), logoutSubscription status and available credits; log out or switch accounts
SupportfeedbackReport task problems

The CLI adds client-side commands: kling --help, kling <command> --help, login and tool_list, which lists the tools the backend server currently advertises. Useful flags from the README: --model <name> (required for generation), --poll [N] (wait up to N seconds; bare --poll means 60) and --quiet for one-line JSON. Output is JSON on stdout, and exit codes are 0 for success, 1 for failure and 130 for user cancellation.

How do I make a Kling 4.0 video from the CLI?

Start by asking the server what your account can use. The README says models, required arguments, defaults and allowed values are declared by the server, and that you should run who_am_i for the authoritative spec:

kling login
kling who_am_i

Text-to-video with Kling 4.0, from the README:

kling text_to_video --model kling-video-v4_0 "drone shot flying over a snowy mountain peak" \
  --duration 10 --aspectRatio 16:9 --poll 300

First and last frames:

kling image_to_video --model kling-video-v4_0 --image ./first.jpg --tailImage ./last.jpg \
  "slow camera push-in" --duration 6 --poll 300

Keyframes in the middle of the clip use named slots:

kling image_to_video --model kling-video-v4_0 \
  --input first_image=./first.jpg --input keyframe_1=./middle.jpg \
  --input tail_image=./last.jpg --prompt "" --poll 300

The README’s current declaration for standard Kling 4.0 allows 3–30 seconds and 720p/1080p (subject to account access), with first_image, tail_image and keyframe_1..10 sharing a combined limit of 10 images. Flash (kling-video-v4_0_flash) allows 3–20 seconds at 720p and is first-frame only, so --tailImage is rejected. Omni-Ref with Kling 4.0 accepts up to 10 images, 5 videos and 7 Elements (up to 3 video Elements), 15 references combined, and is billed per second including input video duration.

If you submit without --poll, check later with kling query_tasks <generationId> --poll. Results arrive in works[].url, and unwatermarked URLs, when available, in works[].urlWithoutWatermark. Download promptly: generated file URLs stay valid for 24 hours.

What are the credit and rate limits?

Kling MCP & CLI Guide FAQ and Kling MCP page FAQ, checked November 15, 2026
LimitWhat Kling’s docs say
Credit pricingSame pricing and consumption rules as Kling’s own platforms; credits depend on model, duration and resolution
Off-peak free generationNot available through AI assistants
Which creditsPaid credits from your Personal workspace only; Team workspace not supported yet
Bonus creditsCannot currently be used with MCP or CLI
Rate limit5 QPS
ConcurrencyNon-subscribers: one concurrent video task. Subscribers: no task limits
Result URLsValid for 24 hours
Cancel a submitted jobNot possible once submitted
Generation timeComparable to the web app; depends on queue and subscription tier
Asset storageSynced to your Kling web asset library

Kling’s guide does not publish per-model credit prices for MCP or CLI. The credits a job used come back with the job: the skill’s reference says the submit response can include a creditsConsumed field, and kling account shows your membership and available credits.

Will chaining jobs also mass-produce failed clips?

Yes, a chain can multiply clips you don’t want, because every submitted job is billed and none can be recalled. Jobs that fail outright are a different case: Kling’s Credits Policy says credits are refunded when a generation fails. Kling’s documents give the rules and a working method.

What the docs say about cost:

  • Each generation submission consumes credits, and the submit response can report how many (the kling-cli skill’s billing rules). MCP and CLI follow the same credit rules as Kling’s own platforms (guide FAQ).
  • Kling’s Credits Policy: credits are deducted immediately upon generation, and if the generation fails, the corresponding credits are refunded.
  • Generation tasks cannot be canceled once submitted (guide FAQ).
  • The skill tells agents not to rewrite a prompt and resubmit after a failure without asking you first, and to get your approval before any retry.
  • feedback reports a stuck task, billing anomaly or unexpected result, but the skill says it does not retry, refund or repair the original task.
  • Non-subscribers can run only one video task at a time; subscribers have no task limits.

What Kling recommends: its MCP batch workflow article says to ask the agent to “show me the plan before generating any media”, to “start with a few videos before generating the full set”, and, when the same problem shows up in several results, to update the shared instruction rather than rewriting every prompt. Its Claude Code tutorial adds: check an existing task before submitting a duplicate request.

Not documented: any refund for a job that completes but looks wrong. The refund line in the Credits Policy covers failed generations only, and Kling’s MCP pages add nothing for unwanted results, so budget every completed clip as spent.

A practical guard for scripts: run who_am_i, submit two or three test jobs, review them, then loop over the approved list only, with a fixed list length rather than an open-ended retry loop.

What has not been published

  • MCP endpoint for China-site accounts: Kling’s blog gives https://kling.ai/mcp for international accounts; the MCP pages checked do not list a separate endpoint. The CLI handles the region through the @klingai/cli-cn package.
  • Codex config snippet: Codex is listed as supported, but Kling publishes no Codex-specific MCP config. Use the quick-start prompt or the CLI.
  • Per-model credit prices for MCP/CLI: Not listed; Kling says pricing matches its own platforms.
  • Refunds for completed but unwanted results: Not documented. Failed generations are refunded under the Credits Policy.
  • Job cancellation: not supported.

Which should you choose: MCP, CLI or a browser?

If you…Use
Chat with Claude, ChatGPT or Cursor and want a quick setupThe Kling plugin for that assistant, or Kling MCP
Script batches or run CIKling CLI
Use Claude Code across many projectsMCP with --scope user, or the CLI skill — not both
Have a China-site Kling account@klingai/cli-cn
Build your own app with an API keyThe Kling 4.0 API
Want no installs, keys or terminalsA browser generator such as Kling 4.0

Kling MCP and CLI are built for people who already work with AI agents or scripts. If you only want to type a prompt and get a clip, a browser is faster.

FAQ

What is the Kling MCP server URL?

The endpoint is https://kling.ai/mcp. Kling’s blog gives it for international accounts on kling.ai.

Do I need an API key for Kling MCP or CLI?

No. You sign in with your Kling account through OAuth, and Kling says no API keys are required.

Should I install both MCP and the CLI?

No. Kling’s guide says to install only one of the plugin, MCP or CLI in a given assistant, because the assistant may switch between them unpredictably.

Which AI assistants work with Kling MCP?

Kling lists Codex, Claude, Cursor, OpenClaw and WorkBuddy, among others. Its guide publishes setup steps for Claude, ChatGPT, Cursor and OpenClaw, and Kling’s blog covers Claude Code.

Does Kling MCP support Kling 4.0?

The Kling 4.0 release notes say MCP and CLI support Kling 4.0, including Omni Reference and keyframes.

Can I use Kling 4.0 Flash through MCP and CLI?

Yes. Kling’s announcement that Kling 4.0 Flash is fully available names MCP and CLI among the ways to use it, and the CLI uses the model name kling-video-v4_0_flash.

How are credits charged through MCP and CLI?

They use the same credit pricing and rules as Kling’s own platforms, based on model, duration and resolution.

What are the rate limits?

The rate limit is 5 QPS. Non-subscribers can run one video task at a time, while subscribers have no task limits.

Can I cancel a Kling MCP job?

No. Generation tasks cannot be canceled once submitted, so review the plan before you send it.

How long do result links last?

Generated file URLs stay valid for 24 hours. Download the files you want to keep, and find them later in your Kling web asset library.

Do failed MCP or CLI jobs still cost credits?

Kling’s Credits Policy says credits for a failed generation are refunded, and MCP and CLI follow the same credit rules. A job that completes but looks wrong is a finished generation, so test a small set before you scale a chain.

Where do these facts come from?

  • Kling MCP & CLI Guide — plugin, MCP and CLI setup, config snippets, tools, commands and FAQ. Checked November 15, 2026.
  • Kling MCP page FAQ — CLI recommendation, supported agents, OAuth, billing, features, storage. Checked November 15, 2026.
  • @klingai/cli-global README (v0.2.3) and @klingai/cli-cn — install, commands, flags, Kling 4.0 examples and limits. Checked October 18, 2026.
  • klingai-tech/skills — skill install, region packages, billing and retry rules. Checked October 18, 2026.
  • Kling 4.0 release notes — MCP/CLI support for Kling 4.0. Checked November 15, 2026.
  • Kling 4.0 Flash Is Now Fully Available, Kling AI on X — MCP and CLI named for Kling 4.0 Flash. Checked November 15, 2026.
  • Kling Credits Policy — deduction on generation, refund on failed generation. Checked October 18, 2026.
  • Kling blog: MCP batch workflow and Claude Code tutorial — endpoint note, Claude Code command, test-first batching. Checked October 18, 2026.

Related: Kling 4.0 vs Seedance 2.5 · Seedance 2.5 overview · Kling 4.0 vs Kling 3.0 · Kling AI pricing

Try Kling AI Today

Start on Kling 4.0.

Open the Kling 4.0 generator