spring-mvc-webflux-api-builder

Generate Kotlin Spring API layers with controllers, DTOs, validation, and error handling.

14|1|Updated Mar 6, 2026
One-click install
npx skills add https://github.com/kbrgnj/kotlin-backend-agent-skills --skill spring-mvc-webflux-api-builder-kbrgnj
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: spring-mvc-webflux-api-builder
Source: https://github.com/kbrgnj/kotlin-backend-agent-skills/tree/main/.agents/skills/spring-mvc-webflux-api-builder
Command: npx skills add https://github.com/kbrgnj/kotlin-backend-agent-skills --skill spring-mvc-webflux-api-builder-kbrgnj

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Design and generate Kotlin Spring HTTP APIs with correct controller signatures, DTOs, validation, serialization assumptions, error handling, and web tests. Use when building or changing REST endpoints, choosing between MVC and WebFlux, modeling request and response payloads, standardizing error responses, or avoiding Kotlin-specific validation and Jackson mistakes.

Core Features & Use Cases

  • Define endpoint contracts with method, path, and auth requirements.
  • Generate request/response DTOs with proper Kotlin @field: validation targets and explicit nullability.
  • Create controller, service boundaries, mappers, and error handling scaffolding, plus a focused web-layer test.
  • Support both Spring MVC and WebFlux patterns and align with existing project conventions.

Quick Start

Design and generate a Kotlin Spring API module with correct controller signatures, DTOs, validation, error handling, and web test scaffolding.

Frequently Asked Questions about spring-mvc-webflux-api-builder

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

FAQPage Schema
How do I generate Kotlin Spring API controllers with correct DTOs and validation?

Generate Kotlin Spring API layers by defining endpoint contracts, then producing controllers, DTOs with field-level validation, and error handling scaffolding. This ensures correct controller signatures and robust input validation across MVC and WebFlux.

Why does Kotlin validation fail on Spring DTO fields with @NotNull or @NotBlank?

Kotlin validation fails when annotations target the wrong element. Apply validation constraints using the @field: target prefix on DTO properties to ensure Spring processes them correctly during request binding.

What's the best way to standardize error responses across Spring MVC and WebFlux in Kotlin?

Standardize error responses by generating exception handling strategy scaffolding that aligns with both Spring MVC and WebFlux patterns. This creates consistent error contracts across different web frameworks in the same project.

How do I map request and response DTOs in a Spring Kotlin application?

Map request and response DTOs by generating service boundaries and mappers alongside controller layers. This separates payload mapping from business logic while maintaining explicit nullability and serialization assumptions.

Does this approach support generating web-layer tests for Kotlin Spring REST endpoints?

Yes, generating Kotlin Spring API layers includes focused web-layer test scaffolding. This provides test coverage for controller signatures, validation rules, and error handling strategies immediately after endpoint generation.

Can I use this to add new REST endpoints to an existing Kotlin Spring project?

Yes, generating Kotlin Spring API layers supports evolving existing REST endpoints. It aligns with current project conventions for MVC or WebFlux, adding contracts, DTOs, and validation without rewriting existing modules.