go-cms-api

Designs and implements HTTP API endpoints for a Go CMS backend.

Updated Jun 15, 2026
One-click install
npx skills add https://github.com/vernal96/go-cms --skill go-cms-api-vernal96
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: go-cms-api
Source: https://github.com/vernal96/go-cms/tree/main/.codex/skills/go-cms-api
Command: npx skills add https://github.com/vernal96/go-cms --skill go-cms-api-vernal96

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? It guides the design and implementation of public and admin HTTP APIs in the Go CMS backend so endpoints follow consistent route contracts, DTO mapping, validation, error handling, and authorization boundaries instead of ad-hoc handler logic. ## Core Features & Use Cases - CRUD and route conventions: Enforces resource-oriented endpoint patterns, common pagination/filtering/sorting vocabulary, and deterministic list ordering. - Transport boundary discipline: Keeps handlers as thin transport adapters with separate syntactic validation, domain validation, and authorization, plus typed error-to-status mapping. - Optional feature APIs: Prevents optional modules like Mail, Forms, Search, or Audit from leaking feature-specific imports into the generic kernel/app package. - Use Case: When adding a new management endpoint for the Forms module, use this Skill to wire it through a generic contribution contract, validate site context, and map domain errors to correct HTTP statuses. ## Quick Start Use the go-cms-api skill to design a new admin CRUD endpoint for the Forms module with proper validation, error mapping, and authorization wiring.

Frequently Asked Questions about go-cms-api

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I add a new CRUD endpoint to a Go CMS backend?▼

Follow the resource-oriented pattern: GET/POST on the collection and GET/PATCH/DELETE on the item. Keep the handler as a thin transport adapter that parses input, resolves site and actor context, calls the application service, and maps results to HTTP responses.

How should Go HTTP handlers map domain errors to status codes?▼

Map errors by meaning using typed or sentinel domain errors, not string matching. Distinguish 400 malformed input, 401 unauthenticated, 403 forbidden, 404 not found, 409 conflict, 422 domain validation failure, and 500 unexpected failures.

How do optional feature modules expose management APIs without bloating the kernel?▼

Use a generic contribution contract or registry so feature modules like Mail, Forms, or Search register their own HTTP surface. The generic kernel/app package must not gain one field, method, or import per optional feature.

When should I not use this API design skill?▼

Do not use it for domain-only changes with no HTTP contract impact. It targets endpoint design, transport validation, and authorization wiring, not pure domain model or persistence work.

How do I handle pagination for large collections in a Go API?▼

Use bounded list endpoints with a common query vocabulary and deterministic ordering with a stable tie-breaker. For high-cardinality collections, prefer cursor or keyset pagination over large OFFSET scans, and never fetch all rows to paginate in memory.