npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2025 – Pkg Stats / Ryan Hefner

kuaishou-image-mcp

v1.0.0

Published

使用快手API生成AI图片的 MCP 服务

Readme

快手文生图 MCP

这是一个用于 Claude Desktop 和 Cursor 的 MCP 服务,可以通过自然语言生成 AI 图片。

示例图片

功能特点

  • 快速生成图片: 使用快手 API 生成高质量 AI 图片
  • 支持多种尺寸: 可选择不同尺寸的图片生成
  • 批量生成: 支持一次生成多张图片(1-4张)
  • 标准 MCP 协议: 符合 Model Context Protocol 规范,可与 Claude Desktop 和 Cursor 无缝集成

安装

通过 npm 全局安装

npm install -g kuaishou-image-mcp

配置 Claude Desktop

在 Claude Desktop 中添加服务器配置:

macOS: ~/Library/Application Support/Claude/claude_desktop_config.json Windows: %APPDATA%/Claude/claude_desktop_config.json

{
  "mcpServers": {
    "kuaishou-image-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "kuaishou-image-mcp"
      ],
      "env": {
        "API_KEY": "您的快手API密钥"
      }
    }
  }
}

配置 Cursor

在 Cursor 设置中添加:

{
  "mcpServers": {
    "kuaishou-image-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "kuaishou-image-mcp"
      ],
      "env": {
        "API_KEY": "您的快手API密钥"
      }
    }
  }
}

使用方法

  1. 确保已正确配置 API 密钥
  2. 在 Claude Desktop 或 Cursor 中,要求 AI 生成图片
  3. AI 会请求图片生成的提示词、尺寸和数量
  4. MCP 服务会使用快手 API 生成图片并返回结果

示例对话:

用户: 请生成一只在海滩上玩耍的猫咪图片

Claude: 我可以帮你生成一只在海滩上玩耍的猫咪图片。请稍等片刻...

[Claude 使用 MCP 服务生成图片]

Claude: 已为您生成图片,这是一只在阳光明媚的海滩上玩耍的猫咪,正在沙滩上奔跑,背景是蓝色的海洋和天空。

图片链接: https://example.com/generated-image.jpg

安全考虑

  • 您的 API 密钥存储在本地配置文件中,请妥善保管
  • MCP 服务遵循 Claude 的安全规则,不会生成不适当的内容
  • 生成的图片URL有效期为1小时,请及时保存重要图片

开发

如果您想自己开发或修改此 MCP:

  1. 克隆此仓库
  2. 安装依赖:
    npm install
  3. 修改代码 (主要在 src/index.ts 中)
  4. 构建:
    npm run build
  5. 本地测试:
    npm start

故障排除

MCP 未正确连接

  • 确认 API 密钥已正确配置
  • 检查 Claude Desktop 或 Cursor 是否有最新版本
  • 查看日志输出是否有错误信息
  • 确保网络连接正常,可以访问快手 API

生成图片失败

  • 检查 API 密钥是否有效
  • 确保提示词符合内容政策
  • 检查是否超过了 API 调用限制

许可证

MIT

项目结构

image-generate-mcp/
├── dist/              # 编译后的JavaScript文件
├── src/              # TypeScript源代码
├── package.json      # 项目配置文件
├── tsconfig.json     # TypeScript配置
└── README.md         # 说明文档

开发说明

如果你想要修改或开发此MCP:

  1. 安装依赖:
npm install
  1. 编译项目:
npm run build
  1. 在Cursor中重新加载MCP

注意事项

  • 请确保已正确设置API密钥
  • 生成的图片URL有效期为1小时
  • 请遵守API的调用频率限制
  • 建议在生成大量图片时使用较小的批量大小