aspnet-minimal-api-openapi — GitHub Copilot skill: install
Create typed ASP.NET Minimal API endpoints with OpenAPI documentation. Use it when an API needs a clear structure and described request and response contracts.
npx skills add github/awesome-copilot --skill aspnet-minimal-api-openapiWhat aspnet-minimal-api-openapi does
This skill guides GitHub Copilot through organizing ASP.NET Minimal API endpoints with MapGroup(), endpoint filters, and separate endpoint classes. Larger APIs can use a feature-based folder structure. Request and response DTOs are explicit, with validation attributes, record types, and standard error responses through ProblemDetailsService and StatusCodePages.
It recommends explicit route parameter types, Results for alternative responses, and TypedResults for typed results. OpenAPI guidance uses the built-in support from .NET 9, including operation summaries, descriptions, operation IDs through WithName, content types, document transformers, and schema transformers.
Install it when Copilot needs to shape both the API implementation and its OpenAPI contract. For a small endpoint with no documentation requirements, the extra guidance may be unnecessary.
What it helps with
- build ASP.NET Minimal API endpoints with OpenAPI
- group related routes with
MapGroup() - define request and response DTOs
- add operation IDs and property descriptions
- return standard API error responses
Example prompts for the agent
- Create an ASP.NET Minimal API for orders and group related routes with `MapGroup()`.
- Refactor this endpoint to use `TypedResults`, validation attributes, and an operation ID with `WithName`.
- Add OpenAPI document and schema transformers for this API.
How to install aspnet-minimal-api-openapi
1Skills CLI (Vercel)
npx skills add github/awesome-copilot --skill aspnet-minimal-api-openapi2GitHub CLI
gh skill install github/awesome-copilot aspnet-minimal-api-openapi3Manually: put the files in place
.github/skills/aspnet-minimal-api-openapi/SKILL.md1Skills CLI (Vercel)
npx skills add github/awesome-copilot --skill aspnet-minimal-api-openapi -a claude-code2Manually: put the files in place
~/.claude/skills/aspnet-minimal-api-openapi/SKILL.mdCopy the whole skill folder; for one project use .claude/skills/aspnet-minimal-api-openapi/
Manually: put the files in place
.agents/skills/aspnet-minimal-api-openapi/SKILL.mdFor all projects use ~/.agents/skills/
Manually: put the files in place
.cursor/skills/aspnet-minimal-api-openapi/SKILL.mdCursor also reads .agents/skills/ and .claude/skills/
Platform CLI
gemini skills install https://github.com/github/awesome-copilot --path skills/aspnet-minimal-api-openapiManually: put the files in place
.devin/skills/aspnet-minimal-api-openapi/SKILL.mdThe legacy .windsurf/skills/ path still works
Claude.ai
Zip the folder and upload it in Settings → Capabilities → Skills
From the same set554
The whole set →Similar
Questions about aspnet-minimal-api-openapi
How do I install aspnet-minimal-api-openapi in GitHub Copilot?
Run npx skills add github/awesome-copilot --skill aspnet-minimal-api-openapi, then use .github/skills/aspnet-minimal-api-openapi/SKILL.md. You can also run gh skill install github/awesome-copilot aspnet-minimal-api-openapi.
What does aspnet-minimal-api-openapi do?
It guides Copilot in creating structured ASP.NET Minimal API endpoints with typed requests, typed responses, standard errors, and OpenAPI documentation.
What .NET version does the OpenAPI guidance use?
The skill uses the built-in OpenAPI document support added in .NET 9. It also references C# 10+ features such as nullable annotations and init-only properties.
Source text
SKILL.md · MIT
--- name: aspnet-minimal-api-openapi description: 'Create ASP.NET Minimal API endpoints with proper OpenAPI documentation' --- # 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
© github · MIT · github/awesome-copilot