openapi-to-application-code작성자: github

Generate complete, production-ready applications directly from OpenAPI specifications. Accepts OpenAPI specs via URL, local file, or direct content input; validates completeness and identifies endpoints, schemas, authentication requirements, and data relationships Generates full project structure with controllers, services, models, repositories, and configuration files following framework conventions and best practices Includes unit tests, README with setup instructions, environment...

npx skills add https://github.com/github/awesome-copilot --skill openapi-to-application-code

Generate Application from OpenAPI Spec

Your goal is to generate a complete, working application from an OpenAPI specification using the active framework's conventions and best practices.

Input Requirements

  1. OpenAPI Specification: Provide either:

    • A URL to the OpenAPI spec (e.g., https://api.example.com/openapi.json)
    • A local file path to the OpenAPI spec
    • The full OpenAPI specification content pasted directly
  2. Project Details (if not in spec):

    • Project name and description
    • Target framework and version
    • Package/namespace naming conventions
    • Authentication method (if not specified in OpenAPI)

Generation Process

Step 1: Analyze the OpenAPI Specification

  • Validate the OpenAPI spec for completeness and correctness
  • Identify all endpoints, HTTP methods, request/response schemas
  • Extract authentication requirements and security schemes
  • Note data model relationships and constraints
  • Flag any ambiguities or incomplete definitions

Step 2: Design Application Architecture

  • Plan directory structure appropriate for the framework
  • Identify controller/handler grouping by resource or domain
  • Design service layer organization for business logic
  • Plan data models and entity relationships
  • Design configuration and initialization strategy

Step 3: Generate Application Code

  • Create project structure with build/package configuration files
  • Generate models/DTOs from OpenAPI schemas
  • Generate controllers/handlers with route mappings
  • Generate service layer with business logic
  • Generate repository/data access layer if applicable
  • Add error handling, validation, and logging
  • Generate configuration and startup code

Step 4: Add Supporting Files

  • Generate appropriate unit tests for services and controllers
  • Create README with setup and running instructions
  • Add .gitignore and environment configuration templates
  • Generate API documentation files
  • Create example requests/integration tests

Output Structure

The generated application will include:

project-name/
├── README.md                      # Setup and usage instructions
├── [build-config]                 # Framework-specific build files (pom.xml, build.gradle, package.json, etc.)
├── src/
│   ├── main/
│   │   ├── [language]/
│   │   │   ├── controllers/       # HTTP endpoint handlers
│   │   │   ├── services/          # Business logic
│   │   │   ├── models/            # Data models and DTOs
│   │   │   ├── repositories/      # Data access (if applicable)
│   │   │   └── config/            # Application configuration
│   │   └── resources/             # Configuration files
│   └── test/
│       ├── [language]/
│       │   ├── controllers/       # Controller tests
│       │   └── services/          # Service tests
│       └── resources/             # Test configuration
├── .gitignore
├── .env.example                   # Environment variables template
└── docker-compose.yml             # Optional: Docker setup (if applicable)

Best Practices Applied

  • Framework Conventions: Follows framework-specific naming, structure, and patterns
  • Separation of Concerns: Clear layers with controllers, services, and repositories
  • Error Handling: Comprehensive error handling with meaningful responses
  • Validation: Input validation and schema validation throughout
  • Logging: Structured logging for debugging and monitoring
  • Testing: Unit tests for services and controllers
  • Documentation: Inline code documentation and setup instructions
  • Security: Implements authentication/authorization from OpenAPI spec
  • Scalability: Design patterns support growth and maintenance

Next Steps

After generation:

  1. Review the generated code structure and make customizations as needed
  2. Install dependencies according to framework requirements
  3. Configure environment variables and database connections
  4. Run tests to verify generated code
  5. Start the development server
  6. Test endpoints using the provided examples

Questions to Ask if Needed

  • Should the application include database/ORM setup, or just in-memory/mock data?
  • Do you want Docker configuration for containerization?
  • Should authentication be JWT, OAuth2, API keys, or basic auth?
  • Do you need integration tests or just unit tests?
  • Any specific database technology preferences?
  • Should the API include pagination, filtering, and sorting examples?

github의 다른 스킬

console-rendering
by github
Instructions for using the struct tag-based console rendering system in Go
acquire-codebase-knowledge
by github
Use this skill when the user explicitly asks to map, document, or onboard into an existing codebase. Trigger for prompts like "map this codebase", "document…
acreadiness-assess
by github
Run the AgentRC readiness assessment on the current repository and produce a static HTML dashboard at reports/index.html. Wraps `npx github:microsoft/agentrc…
acreadiness-generate-instructions
by github
Generate tailored AI agent instruction files via AgentRC instructions command. Produces .github/copilot-instructions.md (default, recommended for Copilot in VS…
acreadiness-policy
by github
Help the user pick, write, or apply an AgentRC policy. Policies customise readiness scoring by disabling irrelevant checks, overriding impact/level, setting…
add-educational-comments
by github
Add educational comments to code files to transform them into effective learning resources. Adapts explanation depth and tone to three configurable knowledge levels: beginner, intermediate, and advanced Automatically requests a file if none is provided, with numbered list matching for quick selection Expands files by up to 125% using educational comments only (hard limit: 400 new lines; 300 for files over 1,000 lines) Preserves file encoding, indentation style, syntax correctness, and...
adobe-illustrator-scripting
by github
Write, debug, and optimize Adobe Illustrator automation scripts using ExtendScript (JavaScript/JSX). Use when creating or modifying scripts that manipulate…
agent-governance
by github
Declarative policies, intent classification, and audit trails for controlling AI agent tool access and behavior. Composable governance policies define allowed/blocked tools, content filters, rate limits, and approval requirements — stored as configuration, not code Semantic intent classification detects dangerous prompts (data exfiltration, privilege escalation, prompt injection) before tool execution using pattern-based signals Tool-level governance decorator enforces policies at function...

NotebookLM 웹 임포터

원클릭으로 웹 페이지와 YouTube 동영상을 NotebookLM에 가져오기. 200,000명 이상이 사용 중.

Chrome 확장 프로그램 설치