spring-controller

Generate Spring Boot REST controllers, DTOs, mappers, advice, and unit tests.

Updated Aug 27, 2026
One-click install
npx skills add https://github.com/edercnj/ia-dev-environment --skill spring-controller
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: spring-controller
Source: https://github.com/edercnj/ia-dev-environment/tree/main/src/main/resources/claude/skills/spring-controller
Command: npx skills add https://github.com/edercnj/ia-dev-environment --skill spring-controller

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Automates the creation of a complete Spring Boot REST controller stack for new resources, reducing boilerplate and accelerating delivery.

Core Features & Use Cases

  • Generates a fully wired @RestController with endpoints (CRUD or custom) following hexagonal architecture conventions.
  • Creates Request/Response DTOs with proper validation annotations and reflection bindings.
  • Produces a static mapper class for converting between domain objects and DTOs.
  • Generates a RestControllerAdvice for centralized exception handling and predictable error responses.
  • Includes unit tests for controller and mapper to ensure correct behavior.
  • Uses existing knowledge patterns to align with project conventions and test coverage.

Quick Start

Invoke the skill with /spring-controller <ResourceName> to generate a complete Spring REST controller stack for your resource.

Frequently Asked Questions about spring-controller

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

FAQPage Schema
How do I generate a Spring Boot REST controller with DTOs and unit tests?

You can generate a Spring Boot REST controller with DTOs and unit tests by invoking the /spring-controller command with your resource name. It creates a complete stack including mappers, exception advice, and reflection-bound DTOs following hexagonal architecture.

Can I generate DTOs and mappers for a Spring REST controller automatically?

Yes, you can generate DTOs and mappers automatically for a Spring REST controller. The skill produces Request/Response DTOs with validation annotations and a static mapper class for converting between domain objects and DTOs.

How do I set up global exception handling for a Spring REST controller?

To set up global exception handling for a Spring REST controller, the skill generates a RestControllerAdvice class. This provides centralized exception handling and ensures predictable error responses across your generated controller endpoints.

Does this Spring controller generator work with hexagonal architecture projects?

Yes, this Spring controller generator works with Java projects using hexagonal architecture. It aligns generation with project conventions, producing a fully wired RestController with endpoints, DTOs, mappers, and tests that fit the architecture.

What is the best way to reduce Spring Boot controller boilerplate for new resources?

The best way to reduce Spring Boot controller boilerplate for new resources is to automate the creation of the complete REST controller stack. This skill generates controllers, DTOs, mappers, advice, and unit tests instantly to accelerate delivery.

Are unit tests included when generating a Spring REST controller stack?

Yes, unit tests are included when generating a Spring REST controller stack. The skill produces unit tests for both the controller and the mapper to verify correct behavior and mappings according to project conventions.