heshengtao/super-agent-party / skills/sap-extension-creator
sap-extension-creator
VerifiedCreate Super Agent Party (SAP) extensions. This skill should be used when users want to create, build, or scaffold a new extension for Super Agent Party - including static HTML extensions (pure frontend) and Node.js backend extensions. Triggers on requests like "create a new SAP extension", "build an extension for Super Agent Party", "scaffold a plugin", "make a chat UI extension", or when working with sap extension projects.
| File | Kind | Size |
|---|---|---|
| SKILL.md | skill md | 23.7 KB |
| assets/node-template/index.html | other | 16.5 KB |
| assets/node-template/index.js | script | 1.4 KB |
| assets/node-template/package.json | manifest | 381 B |
| assets/static-template/index.html | other | 15.8 KB |
| assets/static-template/package.json | manifest | 295 B |
| references/node-entry-spec.md | markdown | 3.4 KB |
| references/package-json-spec.md | markdown | 6.8 KB |
assets/node-template/index.js
View on GitHub/**
* SAP Extension — Node.js Template
*
* Supports both:
* 1. Node service mode: node index.js <port> (managed by SAP)
* 2. Static file mode: node index.js (open index.html in browser)
*/
const path = require('path');
const fs = require('fs');
const EXT_DIR = __dirname;
const HTML_FILE = path.join(EXT_DIR, 'index.html');
/* ---- Mode 1: Node service (SAP-managed) ---- */
if (process.argv[2]) {
const PORT = parseInt(process.argv[2], 10);
const express = require('express');
const app = express();
// Serve all static assets from extension directory
app.use(express.static(EXT_DIR));
// Root → index.html
app.get('/', (req, res) => res.sendFile(HTML_FILE));
// Health check for SAP readiness polling
app.get('/health', (req, res) => res.json({ status: 'ok' }));
// TODO: Add custom API routes here
// app.get('/api/data', (req, res) => { ... });
app.listen(PORT, '127.0.0.1', () => {
const msg = `[ext] Node service ready at http://127.0.0.1:${PORT}`;
console.log(msg);
fs.writeFileSync(path.join(EXT_DIR, 'port.log'), String(PORT));
});
return;
}
/* ---- Mode 2: Standalone / double-click ---- */
const { spawn } = require('child_process');
const BROWSER = process.platform === 'darwin' ? 'open'
: process.platform === 'win32' ? 'start'
: 'xdg-open';
spawn(BROWSER, [HTML_FILE], { shell: true, stdio: 'ignore' });
console.log('[ext] Opening in browser:', HTML_FILE);
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| brainstormingobra/superpowersYou MUST use this before any creative work - creating features, building components, adding functionality, modifying behavior, or planning anything new, in software or out of it (a talk, a business, a renovation). | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| brand-guidelinesanthropics/skillsApplies Anthropic's official brand colors and typography to any sort of artifact that may benefit from having Anthropic's look-and-feel. Use it when brand colors or style guidelines, visual formatting, or company design standards apply. | Stars: 198k | Updated | Claude CodeCodex | Verified | Install |
| frontend-designanthropics/skillsGuidance for distinctive, intentional visual design when building new UI or reshaping an existing one. Helps with aesthetic direction, typography, and making choices that don't read as templated defaults. | Stars: 198k | Updated | Claude CodeCodex | Verified | Install |
| mcp-builderanthropics/skillsGuide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when building MCP servers to integrate external APIs or services, whether in Python (FastMCP) or Node/TypeScript (MCP SDK). | Stars: 198k | Updated | Claude CodeCodex | Verified | Install |