用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
直接命令不会经过审查 Prompt;运行前请先检查来源。
npx skills add https://github.com/Integralist/agent-skills --skill go-api命令会保持在同一行。复制前请横向滚动并检查完整内容。
想先保存到本地?可下载 SkillsMP 当前能够提供的文件。
基于 SOC 职业分类
正在显示 SKILL.md
| name | go-api |
| description | Create a new Go API service with complete boilerplate, local development, and observability. |
| disable-model-invocation | true |
Create a production-ready Go API service.
When asked to create a new Go API service:
user-service, config-manager)github.com/myorg/myservice){SERVICE_NAME},
{SERVICE_NAME_SNAKE}, {SERVICE_NAME_PASCAL},
{MODULE_PATH}) with appropriate valuesScaffolding is a fixed placeholder map applied across independent
templates — a
verified-pattern fan-out. Scaffold
one representative file first (e.g. internal/api) with placeholders
resolved, and confirm the substitutions and layout with the user. Once
approved, fan out subagents to instantiate the remaining templates in
parallel — the placeholder map is fixed, so the work is mechanical.
Generate the following structure:
{SERVICE_NAME}/
├── cmd/
│ └── api/
│ └── main.go
├── internal/
│ ├── api/
│ ├── config/
│ ├── contextx/
│ ├── deps/
│ ├── env/
│ ├── errorsx/
│ ├── httpx/
│ ├── logx/
│ ├── metrics/
│ ├── middleware/
│ ├── mysql/
│ ├── redis/
│ └── traces/
├── docs/
│ ├── projects/
│ │ ├── completed/
│ │ └── README.md
│ └── architecture.md
├── e2e/
├── local/
│ ├── config/
│ ├── mysql/
│ └── observability/
├── scripts/
├── go.mod
├── go.sum
├── Makefile
├── AGENTS.md
└── README.md
handlers (HTTP) → service (business logic) → repository (data)
→ model (entities)
Use x suffix for packages that shadow stdlib: logx, httpx,
timex, errorsx, contextx
return nil, fmt.Errorf(
"service: failed to create config: %w", err)
logger.LogAttrs(ctx, slog.LevelError, "create_config",
slog.String("config_id", configID),
slog.Any("err", err),
)
spanFunc := func(ctx context.Context) error {
traces.AddAttributesToCurrentSpan(ctx,
attribute.String("config_id", configID),
)
return nil
}
err := traces.WithSpan(
ctx, s.tracer, "service.CreateConfig", spanFunc)
When generating files, use the templates in the templates/
directory:
After generation:
# First-time setup
make tools-install
# Start full stack (API + MySQL + Redis + Observability)
make run
# Run tests
make test
# Run integration tests
make test-integration
# Run all linters
make lint-all