Skip to content
Skillpedia
APIs & servers (backend)40k · #7067

aspnet-minimal-api-openapi

What it does

This tool helps create code snippets for a website or web application using ASP.NET. It ensures that information sent and received is organized and that the documentation (like a manual) is clear and complete.

When to use it

  • ✓When you need to create new features for a website.
  • ✓When organizing multiple parts of a web application.
  • ✓To ensure your code's documentation is always up-to-date.

Skill link

https://github.com/github/awesome-copilot/blob/main/skills/aspnet-minimal-api-openapi/SKILL.md

Copy it and paste it into your AI (Claude, ChatGPT or Cursor), asking it to follow the instructions.

How to use

The easiest way: copy the message and paste it into your AI. It reads the skill and follows the instructions.

Ready-to-paste message

Use this skill to help me: https://github.com/github/awesome-copilot/blob/main/skills/aspnet-minimal-api-openapi/SKILL.md Read the SKILL.md file at that link and follow its instructions for my task.
Want your AI to find skills like this on its own?Install the free Skillpedia MCP: one line, and it searches 15,000+ skills before each task.Install in 1 minute →

Example of what to ask your AI

“Create an endpoint to register a new user with name and email, and return the ID of the created user.”

5 new skills a week. 1 minute to read.

How it works

You describe the information your code needs to receive and what it should return. The tool organizes this and automatically generates documentation, like a map for other developers.

Technical content (original SKILL.md)

Original text by the author, straight from GitHub.

ASP.NET Minimal API with OpenAPI

Your goal is to help me create well-structured ASP.NET Minimal API endpoints with correct types and comprehensive OpenAPI/Swagger documentation.

API Organization

  • Group related endpoints using MapGroup() extension
  • Use endpoint filters for cross-cutting concerns
  • Structure larger APIs with separate endpoint classes
  • Consider using a feature-based folder structure for complex APIs

Request and Response Types

  • Define explicit request and response DTOs/models
  • Create clear model classes with proper validation attributes
  • Use record types for immutable request/response objects
  • Use meaningful property names that align with API design standards
  • Apply [Required] and other validation attributes to enforce constraints
  • Use the ProblemDetailsService and StatusCodePages to get standard error responses

Type Handling

  • Use strongly-typed route parameters with explicit type binding
  • Use Results<T1, T2> to represent multiple response types
  • Return TypedResults instead of Results for strongly-typed responses
  • Leverage C# 10+ features like nullable annotations and init-only properties

OpenAPI Documentation

  • Use the built-in OpenAPI document support added in .NET 9
  • Define operation summary and description
  • Add operationIds using the WithName extension method
  • Add descriptions to properties and parameters with [Description()]
  • Set proper content types for requests and responses
  • Use document transformers to add elements like servers, tags, and security schemes
  • Use schema transformers to apply customizations to OpenAPI schemas
FAQ

What are 'endpoints'?

They are like entry points for your application to send and receive specific information.

What is 'OpenAPI/Swagger'?

It's a standard way to describe and document APIs (the 'entry points') so others can understand how to use them.

What are 'DTOs/models'?

These are structures that define how data should be organized when it's sent or received by your application.

Details

Original description by the author

Create ASP.NET Minimal API endpoints with proper OpenAPI documentation

repo: github/awesome-copilot

Popularity

GitHub stars
40k
Ranking position
#7067
License
MIT
Updated
10/15/2026

Is this skill useful?

0

Sign in to vote.

Comments

  • …

More skills from this repository

Similar skills