What problem does it solve?
APIs often return the wrong content type or fail to support client preferences, causing integration friction and brittle clients; this skill ensures responses match client Accept headers and supported formatters for consistent interoperability.
Core Features & Use Cases
- Respect Accept headers: Choose response format (JSON, XML, CSV, etc.) based on client preferences and registered formatters.
- Consistent error reporting: Produce RFC-compliant application/problem+json responses via ProblemDetails middleware.
- Extensible formatters: Add custom output formatters for CSV, PDF, or other export formats and map URL/query-based format selections.
- Use Case: Enable an ASP.NET Core API to serve legacy XML consumers, modern JSON clients, and CSV exports for reporting while returning standardized ProblemDetails for errors.
Quick Start
Configure your API to register JSON and XML formatters, add ProblemDetails, and register any custom output formatter so endpoints respond correctly to Accept headers.