← 返回 Skills 市场
jack-yang-ai

KimiClaw Bridge

作者 Jack-Yang-ai · GitHub ↗ · v1.0.0 · MIT-0
cross-platform ⚠ suspicious
117
总下载
0
收藏
0
当前安装
1
版本数
在 OpenClaw 中安装
/install kimiclaw-bridge
功能描述
KimiClaw Bridge: Connect OpenClaw to Kimi K2.5 — the free, Anthropic-compatible coding model. One config change to run Claude Code, spawn coding agents, or c...
使用说明 (SKILL.md)

🦞 KimiClaw Bridge — Connect OpenClaw to Kimi K2.5

KimiClaw Bridge:一键桥接 OpenClaw 与 Kimi K2.5

Kimi Code (K2.5) is fully compatible with Anthropic Messages API. One config change and your OpenClaw runs on Kimi — Claude Code, coding agents, chat, everything.

Kimi Code (K2.5) 完全兼容 Anthropic Messages API。改一行配置,你的 OpenClaw 就跑在 Kimi 上 — Claude Code、编码 Agent、聊天,全都行。


Get Your API Key / 获取 API Key

👉 Kimi Code Console

Create a key → format: sk-kimi-...

创建密钥 → 格式:sk-kimi-...


1. OpenClaw Provider Setup / OpenClaw 配置

Add to openclaw.json:

openclaw.json 中添加:

// providers:
{
  "id": "kimi",
  "type": "anthropic",          // Kimi speaks Anthropic protocol / Kimi 用 Anthropic 协议
  "baseUrl": "https://api.kimi.com/coding",
  "apiKey": "sk-kimi-..."
}

// models (or agents.defaults.models):
{
  "kimi/kimi-k2.5": {
    "alias": "Kimi K2.5"
  }
}

Now use it anywhere / 随处可用:

/model kimi/kimi-k2.5          # Switch in chat / 聊天中切换

Or set as agent default / 或设为 Agent 默认模型:

"model": "kimi/kimi-k2.5"

2. Claude Code CLI

export ANTHROPIC_BASE_URL="https://api.kimi.com/coding"
export ANTHROPIC_API_KEY="sk-kimi-..."

claude                          # Interactive / 交互模式
claude --print "Your prompt"    # One-shot / 单次执行

Claude Code auto-appends /v1/messages. No other changes.

Claude Code 自动拼接 /v1/messages,无需其他改动。


3. Spawn Coding Agent / 启动编码 Agent

OpenClaw spawns Claude Code with Kimi backend:

OpenClaw 用 Kimi 后端启动 Claude Code:

sessions_spawn(
    runtime="acp",
    task="Refactor auth module to use JWT",
    env={
        "ANTHROPIC_BASE_URL": "https://api.kimi.com/coding",
        "ANTHROPIC_API_KEY": "sk-kimi-..."
    }
)

Or configure globally in openclaw.json — every ACP spawn uses Kimi by default.

也可在 openclaw.json 全局配置,每次 spawn 默认走 Kimi。


API Reference / API 参考

Property / 属性 Value / 值
Base URL https://api.kimi.com/coding
Endpoint / 接口 https://api.kimi.com/coding/v1/messages
Auth x-api-key: sk-kimi-...
Version anthropic-version: 2023-06-01
Model (request / 请求) kimi-k2.5
Model (response / 响应) kimi-for-coding
Streaming / 流式 "stream": true → SSE

Quick Test / 快速验证

curl -s https://api.kimi.com/coding/v1/messages \
  -H "x-api-key: sk-kimi-..." \
  -H "anthropic-version: 2023-06-01" \
  -H "content-type: application/json" \
  -d '{"model":"kimi-k2.5","max_tokens":1024,"messages":[{"role":"user","content":"Hello"}]}'

Python (no dependencies / 纯标准库)

import json, urllib.request

req = urllib.request.Request(
    "https://api.kimi.com/coding/v1/messages",
    data=json.dumps({
        "model": "kimi-k2.5",
        "max_tokens": 4096,
        "messages": [{"role": "user", "content": "Hello"}]
    }).encode(),
    headers={
        "Content-Type": "application/json",
        "x-api-key": "sk-kimi-...",
        "anthropic-version": "2023-06-01",
    },
)
with urllib.request.urlopen(req, timeout=120) as resp:
    print(json.loads(resp.read())["content"][0]["text"])

Gotchas / 注意事项

⚠️ EN 中文
Model name Request: kimi-k2.5 → Response: kimi-for-coding. Don't assert on response. 请求发 kimi-k2.5,响应返回 kimi-for-coding,不要断言响应模型名。
Format Anthropic only (/v1/messages). OpenAI format (/v1/chat/completions) → 404. 仅支持 Anthropic 格式,OpenAI 格式返回 404。
moonshot.cn api.moonshot.cn is a different product — different models, different auth. api.moonshot.cn 是另一个产品,模型和认证都不同。
Timeout Set ≥120s for complex prompts. 复杂提示词设 ≥120 秒。
Provider type Must be "type": "anthropic" in OpenClaw config. OpenClaw 配置里必须写 "type": "anthropic"
安全使用建议
This skill's instructions look coherent for connecting OpenClaw to a Kimi coding API, but note the registry metadata did not declare any required environment variables while the SKILL.md expects you to supply an API key (ANTHROPIC_API_KEY / x-api-key) and/or put the key into openclaw.json. Before installing or using it: 1) Verify the Kimi domain (https://api.kimi.com) and the provider's trustworthiness. 2) Avoid committing API keys into repo-tracked openclaw.json; prefer environment variables or secrets storage and restrict key scopes/quotas. 3) Test with a low-privilege or rate-limited key first. 4) If you rely on the registry metadata for automated permission reviews, update the skill metadata to declare the required env vars/credentials so automated checks can surface this dependency. If you want me to, I can suggest a safer configuration example that keeps the API key out of committed config files.
功能分析
Type: OpenClaw Skill Name: kimiclaw-bridge Version: 1.0.0 The skill bundle 'kimiclaw-bridge' is a documentation-only package providing configuration instructions and code snippets for integrating the Kimi K2.5 LLM with OpenClaw. All code examples (Python, curl, and JSON config) are standard API interaction patterns directed at legitimate endpoints (api.kimi.com), and there are no signs of data exfiltration, malicious execution, or prompt injection attacks in SKILL.md.
能力评估
Purpose & Capability
The skill's stated purpose (bridge OpenClaw to Kimi K2.5) matches the instructions (OpenClaw config snippets, curl/Python examples, and spawn examples). However, the registry metadata declares no required environment variables or credentials while the SKILL.md repeatedly instructs the user/agent to supply an API key (e.g., ANTHROPIC_API_KEY / x-api-key / apiKey in openclaw.json). That mismatch is likely an oversight but is an inconsistency between declared requirements and runtime instructions.
Instruction Scope
SKILL.md stays on-topic: it shows how to configure openclaw.json, set ANTHROPIC_BASE_URL/ANTHROPIC_API_KEY, call the Kimi coding endpoint, and spawn agents with those env vars. It does not ask the agent to read unrelated host files, system secrets, or exfiltrate data to unexpected endpoints. Note: it suggests placing API keys in openclaw.json (a config file) which has security implications for secret storage.
Install Mechanism
This is an instruction-only skill with no install spec and no code files — lowest risk for supply-chain installs. Nothing is downloaded or written by the skill itself according to the provided data.
Credentials
The only secret implied by the instructions is an API key for Kimi (sk-kimi-...). That is proportionate to the stated purpose. However, the skill metadata lists no required env vars while the instructions require ANTHROPIC_API_KEY/ANTHROPIC_BASE_URL and show storing apiKey in openclaw.json — the metadata omission reduces transparency about what credentials will be needed and where they might be stored.
Persistence & Privilege
always:false and no install steps mean the skill does not request permanent presence or elevated platform privileges. It does not modify other skills' configs per the provided instructions.
如何使用
  1. 确保已安装 OpenClaw(本地或 Docker 部署)
  2. 在对话框中输入安装命令:/install kimiclaw-bridge
  3. 安装完成后,直接呼叫该 Skill 的名称或使用 /kimiclaw-bridge 触发
  4. 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v1.0.0
KimiClaw Bridge v1.0: Connect OpenClaw to Kimi K2.5. One-click setup for OpenClaw provider, Claude Code CLI, and ACP coding agents. Bilingual EN+CN.
元数据
Slug kimiclaw-bridge
版本 1.0.0
许可证 MIT-0
累计安装 0
当前安装数 0
历史版本数 1
常见问题

KimiClaw Bridge 是什么?

KimiClaw Bridge: Connect OpenClaw to Kimi K2.5 — the free, Anthropic-compatible coding model. One config change to run Claude Code, spawn coding agents, or c... 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 117 次。

如何安装 KimiClaw Bridge?

在 OpenClaw 或 Claude Code 对话框中运行命令「/install kimiclaw-bridge」即可一键安装,无需额外配置。

KimiClaw Bridge 是免费的吗?

是的,KimiClaw Bridge 完全免费,采用 MIT-0 许可证,可自由下载、安装和使用。

KimiClaw Bridge 支持哪些平台?

KimiClaw Bridge 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。

谁开发了 KimiClaw Bridge?

由 Jack-Yang-ai(@jack-yang-ai)开发并维护,当前版本 v1.0.0。

💬 留言讨论