API Design Skill

Generate framework-specific API endpoints with routes, controllers, and OpenAPI documentation.

Updated Nov 5, 2025
One-click install
npx skills add https://github.com/igpastor/sng-claude-marketplace --skill api-design-skill
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: API Design Skill
Source: https://github.com/igpastor/sng-claude-marketplace/tree/main/plugins/sngular-backend/skills/api-design
Command: npx skills add https://github.com/igpastor/sng-claude-marketplace --skill api-design-skill

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires express, jsonwebtoken, zod, supertest, apollo-server-express, and includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill automates the creation of API endpoints, ensuring adherence to best practices, security, and documentation standards. It significantly reduces manual setup, potential errors, and development time for backend services.

Core Features & Use Cases

  • Comprehensive API Generation: Creates full API endpoint structures including routes, controllers, services, validation schemas, authentication middleware, tests, and OpenAPI/Swagger documentation.
  • Framework-Specific Code: Detects your backend framework (Express.js, Fastify, NestJS, FastAPI, Flask, Django) and generates tailored code.
  • Integrated Best Practices: Incorporates layered architecture, input validation, centralized error handling, JWT authentication, role-based access control, and efficient pagination.
  • Use Case: Request Claude to "create a REST API for managing users with CRUD operations, JWT authentication, and Zod validation," and receive a fully structured and tested API, ready for your specific business logic.

Quick Start

Design a new REST endpoint /api/products for GET and POST operations with authentication.

Frequently Asked Questions about API Design Skill

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

FAQPage Schema
How do I automatically generate REST API endpoints with validation and authentication?

REST API generation automatically creates complete endpoint structures including routes, controllers, services, Zod validation schemas, JWT authentication middleware, error handling, and OpenAPI documentation for your framework—Express, Fastify, NestJS, FastAPI, Flask, or Django—ready for integration.

Can I generate GraphQL APIs with this tool, or is it REST only?

Both REST and GraphQL structures are supported. The Skill detects your backend framework and generates either REST endpoints or GraphQL schemas with resolvers, validators, authentication, and Swagger/OpenAPI documentation tailored to your choice.

What frameworks does API code generation support?

API generation supports Express.js, Fastify, NestJS, FastAPI, Flask, and Django. The Skill detects your framework and produces framework-specific code with routes, controllers, services, middleware, and tests following each framework's conventions.

How does this handle authentication and authorization in generated APIs?

Generated APIs include JWT authentication middleware, role-based access control, and token validation integrated into every endpoint. Authentication logic is centralized, tested, and ready to enforce permissions across your API routes.

Do generated APIs include tests and documentation?

Yes. Generated APIs include unit and integration tests using Supertest, complete OpenAPI/Swagger documentation, and error handling. All code is production-ready and documented for immediate testing and deployment.

What input do I need to provide to generate an API endpoint?

Specify the endpoint path, HTTP method, description, authentication requirements, request body schema, and response body schema. The Skill generates the complete, framework-specific implementation with validators, middleware, services, and tests from these inputs.