Communitygithub.com

API连接器构建器

根据目标仓库的现有模式,构建一个新的API连接器或提供程序(Provider)。

API连接器构建器 是什么?

API连接器构建器技能专为需要以仓库原生方式添加集成层(而非仅通用HTTP客户端)的AI代理设计。核心思想是匹配宿主仓库的现有模式,包括连接器布局、配置架构、认证模型、错误处理、测试风格以及注册/发现机制。该技能适用于直接使用现有集成架构的场景,如为项目构建Jira连接器或添加Slack提供程序。其工作流包括学习仓库的内部模式、限定目标集成范围、以仓库原生层级构建组件,并最终验证新连接器是否与代码库融为一体。它支持Python、TypeScript等常见技术栈的多种连接器结构,并附有质量标准清单以确保与宿主仓库风格一致。相关技能包括后端模式、MCP服务器模式和GitHub操作。

兼容平台~Claude Code~Codex CLI~Cursor
npx skills add https://github.com/affaan-m/ECC/tree/main/skills/api-connector-builder

在你喜欢的 AI 中提问

打开一个已预加载此 Agent Skill 的新对话。

文档

API连接器构建器 是做什么的?

在需要为仓库添加原生集成层,而非仅仅一个通用HTTP客户端时使用。

关键在于匹配宿主仓库的模式:

  • 连接器布局
  • 配置架构
  • 认证模型
  • 错误处理
  • 测试风格
  • 注册/发现机制

何时使用

  • “为这个项目构建一个Jira连接器”
  • “按照现有模式添加一个Slack提供程序”
  • “为此API创建一个新的集成”
  • “构建一个匹配仓库连接器风格的插件”

约束条件

  • 如果仓库已有集成架构,不要发明新的架构
  • 不要仅从供应商文档开始;先参考仓库内现有的连接器
  • 如果仓库期望注册机制、测试和文档,不要只停留于传输代码
  • 如果仓库有更新的当前模式,不要盲目复制旧连接器

工作流

1. 学习内部风格

检查至少两个现有的连接器/提供程序,并记录:

  • 文件布局
  • 抽象边界
  • 配置模型
  • 重试/分页约定
  • 注册钩子
  • 测试夹具和命名

2. 限定目标集成范围

仅定义仓库实际需要的外层:

  • 认证流程
  • 关键实体
  • 核心读写操作
  • 分页和速率限制
  • Webhook或轮询模型

3. 以仓库原生层级构建

典型层级:

  • 配置/架构
  • 客户端/传输层
  • 映射层
  • 连接器/提供程序入口点
  • 注册
  • 测试

4. 对照源模式进行验证

新连接器在代码库中应显得自然,而非从不同生态系统中导入而来。

参考结构

提供程序风格

providers/
  existing_provider/
    __init__.py
    provider.py
    config.py

连接器风格

integrations/
  existing/
    client.py
    models.py
    connector.py

TypeScript 插件风格

src/integrations/
  existing/
    index.ts
    client.ts
    types.ts
    test.ts

质量检查清单

  • 匹配仓库内现有的集成模式
  • 存在配置验证
  • 认证和错误处理显式定义
  • 分页/重试行为遵循仓库规范
  • 注册/发现机制完善
  • 测试镜像宿主仓库的风格
  • 如果仓库要求,更新文档和示例

相关技能

  • backend-patterns
  • mcp-server-patterns
  • github-ops

Individual skills in this repo

This repo contains 20 individual skills — each has its own dedicated page.

accessibility

Design, implement, and audit inclusive digital products using WCAG 2.2 Level AA. Use when building or auditing UI that must meet WCAG 2.2 Level AA, or when reviewing a change for keyboard, contrast, or screen-reader support.

affaan-m/content-engine

Create platform-native content systems for X, LinkedIn, TikTok, YouTube, newsletters, and repurposed multi-platform campaigns. Use when the user wants social posts, threads, scripts, content calendars, or one source asset adapted cleanly across platforms.

affaan-m/ECC

Multi-platform content distribution across X, LinkedIn, Threads, and Bluesky. Adapts content per platform using content-engine patterns. Never posts identical content cross-platform. Use when the user wants to distribute content across social platforms.

affaan-m/fal-ai-media

Unified media generation via fal.ai MCP — image, video, and audio. Covers text-to-image (Nano Banana), text/image-to-video (Seedance, Kling, Veo 3), text-to-speech (CSM-1B), and video-to-audio (ThinkSound). Use when the user wants to generate images, videos, or audio with AI.

affaan-m/manim-video

日本語翻訳:このファイルは manim-video 用の日本語翻訳が必要です

affaan-m/remotion-video-creation

Remotion のベストプラクティス - React で動画を作成する。3D、アニメーション、音声、字幕、チャート、トランジションなどをカバーするドメイン固有の29のルール。

affaan-m/video-editing

AI-assisted video editing workflows for cutting, structuring, and augmenting real footage. Covers the full pipeline from raw capture through FFmpeg, Remotion, ElevenLabs, fal.ai, and final polish in Descript or CapCut. Use when the user wants to edit video, cut footage, create vlogs, or build video content.

agent-architecture-audit

Full-stack diagnostic for agent and LLM applications. Audits the 12-layer agent stack for wrapper regression, memory pollution, tool discipline failures, hidden repair loops, and rendering corruption. Produces severity-ranked findings with code-first fixes. Essential for developers building agent applications, autonomous loops, or any LLM-powered feature. Use when an agent or LLM feature misbehaves and the failing layer is unknown, or before shipping an agent stack.

agent-eval

Head-to-head comparison of coding agents (Claude Code, Aider, Codex, etc.) on custom tasks with pass rate, cost, time, and consistency metrics. Use when choosing between coding agents, or when a change to an agent setup needs measured pass rate, cost, and time rather than an impression.

agent-harness-construction

Design and optimize AI agent action spaces, tool definitions, and observation formatting for higher completion rates. Use when defining or revising an agent

agentic-engineering

Operate as an agentic engineer using eval-first execution, decomposition, and cost-aware model routing. Use when planning or executing engineering work that agents will carry out end to end.

agentic-os

Build persistent multi-agent operating systems on Claude Code. Covers kernel architecture, specialist agents, slash commands, file-based memory, scheduled automation, and state management without external databases. Use when building a persistent multi-agent system on Claude Code with its own memory, commands, and scheduling.

agent-introspection-debugging

Structured self-debugging workflow for AI agent failures using capture, diagnosis, contained recovery, and introspection reports. Use when an agent run fails and you need a reproducible diagnosis instead of a retry.

agent-payment-x402

Add x402 payment execution to AI agents with per-task budgets, spending controls, and non-custodial wallets. Supports Base through agentwallet-sdk and X Layer through OKX Payments / OKX Agent Payments Protocol. Use when an agent must pay for something itself and needs per-task budgets, spending controls, and a non-custodial wallet.

agent-self-evaluation

Use after completing any non-trivial task. The agent self-rates its output on 5 axes — accuracy, completeness, clarity, actionability, conciseness — with concrete evidence per criterion. Produces a structured 1-5 scorecard with specific improvement suggestions.

agent-sort

Build an evidence-backed ECC install plan for a specific repo by sorting skills, commands, rules, hooks, and extras into DAILY vs LIBRARY buckets using parallel repo-aware review passes. Use when ECC should be trimmed to what a project actually needs instead of loading the full bundle.

ai-first-engineering

Engineering operating model for teams where AI agents generate a large share of implementation output. Use when setting team process, review gates, or ownership rules for a codebase largely written by agents.

ai-regression-testing

Regression testing strategies for AI-assisted development. Sandbox-mode API testing without database dependencies, automated bug-check workflows, and patterns to catch AI blind spots where the same model writes and reviews code. Use when adding regression coverage to AI-assisted code, or when the same model both wrote and reviewed a change.

android-clean-architecture

Clean Architecture patterns for Android and Kotlin Multiplatform projects — module structure, dependency rules, UseCases, Repositories, and data layer patterns. Use when structuring modules, layers, or data flow in an Android or KMP project.

angular-developer

Generates Angular code and provides architectural guidance. Trigger when creating projects, components, or services, or for best practices on reactivity (signals, linkedSignal, resource), forms, dependency injection, routing, SSR, accessibility (ARIA), animations, styling (component styles, Tailwind CSS), testing, or CLI tooling.

相关技能