/giuseppe-trisciuoglio:spring-boot-crud-patternsfrom giuseppe-trisciuoglio
Provides repeatable CRUD workflows for Spring Boot 3 services with Spring Data JPA and feature-focused architecture. Use when modeling aggregates, repositories, controllers, and DTOs for REST APIs.
Ships in giuseppe-trisciuoglio. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Deliver feature-aligned CRUD services that separate domain, application, presentation, and infrastructure layers while preserving Spring Boot 3.5+ conventions. This skill distills the essential workflow and defers detailed code listings to reference files for progressive disclosure.
Follow these steps to implement feature-aligned CRUD services:
Create feature// directories with domain, application, presentation, and infrastructure subpackages to maintain architectural boundaries.
Create entity classes with invariants enforced through factory methods (create, update). Keep domain logic framework-free without Spring annotations.
Define domain repository interfaces in domain/repository that describe persistence contracts without implementation details.
Create JPA entities in infrastructure/persistence that map to domain models. Implement Spring Data repositories that delegate to domain interfaces.
Create @Service classes with @Transactional methods that orchestrate domain operations, repository access, and DTO mapping.
Use Java records or immutable classes for API contracts. Apply jakarta.validation annotations for input validation.
Create @RestController classes mapped to /api endpoints. Return ResponseEntity with appropriate status codes (201 for POST, 204 for DELETE).
Unit test domain logic in isolation. Use @DataJpaTest and Testcontainers for integration testing of persistence layer.
spring-boot-starter-web and spring-boot-starter-data-jpa.@RequiredArgsConstructor or explicit constructors).jakarta.validation) and error handling (ResponseStatusException).feature/<name>/ directories for domain, application, presentation, and infrastructure.create and update.domain/repository describing persistence contracts.infrastructure/persistence that map domain models to JPA entities and delegate to JpaRepository.application/service that orchestrate aggregates, repositories, and mapping logic.presentation/rest, expose endpoints with proper status codes, and wire validation annotations.Consult references/examples-product-feature.md for complete code listings that align with each step.
Product.create) to centralize invariants.Money, Stock) to enforce type safety and encapsulate validation.@Entity annotations in the domain package when using adapters.@Service classes using constructor injection and @Transactional.JpaRepository<ProductEntity, String>) and custom queries for pagination or batch updates.application.yml; see references/spring-official-docs.md.ProductController) and expose REST paths (/api/products).ResponseEntity with appropriate codes: 201 Created on POST, 200 OK on GET/PUT/PATCH, 204 No Content on DELETE.@Valid on request DTOs and handle errors with @ControllerAdvice or ResponseStatusException.references/examples-product-feature.md integration test snippets.@DataJpaTest and Testcontainers to validate persistence mapping, pagination, and batch operations.info for lifecycle events (create, update, delete) and use structured logging for audit trails.{
"name": "Wireless Keyboard",
"description": "Ergonomic wireless keyboard with backlight",
"price": 79.99,
"stock": 50
}
{
"id": "prod-123",
"name": "Wireless Keyboard",
"description": "Ergonomic wireless keyboard with backlight",
"price": 79.99,
"stock": 50,
"createdAt": "2024-01-15T10:30:00Z",
"_links": {
"self": "/api/products/prod-123",
"update": "/api/products/prod-123",
"delete": "/api/products/prod-123"
}
}
{
"price": 69.99,
"stock": 45
}
{
"id": "prod-123",
"name": "Wireless Keyboard",
"description": "Ergonomic wireless keyboard with backlight",
"price": 69.99,
"stock": 45,
"updatedAt": "2024-01-15T11:45:00Z",
"_links": {
"self": "/api/products/prod-123"
}
}
curl -X DELETE http://localhost:8080/api/products/prod-123
HTTP/1.1 204 No Content
curl "http://localhost:8080/api/products?page=0&size=10&sort=name,asc"
{
"content": [
{
"id": "prod-123",
"name": "Wireless Keyboard",
"price": 69.99,
"stock": 45
},
{
"id": "prod-456",
"name": "Wireless Mouse",
"price": 29.99,
"stock": 100
}
],
"pageable": {
"page": 0,
"size": 10,
"total": 2,
"totalPages": 1
},
"_links": {
"self": "/api/products?page=0&size=10",
"next": null,
"last": "/api/products?page=0&size=10"
}
}
python skills/spring-boot-crud-patterns/scripts/generate_crud_boilerplate.py --spec entity.json --package com.example.product --output ./generatedskills/spring-boot-crud-patterns/references/ or pass --templates-dir <path>; no fallback to built-ins. See references/README.md.skills/spring-boot-crud-patterns/assets/specs/product.jsonskills/spring-boot-crud-patterns/assets/specs/product_with_rel.jsonassets/specs/product.json (opens in a new tab)assets/specs/product_with_rel.json (opens in a new tab)references/crud-reference.md (opens in a new tab)references/examples-product-feature.md (opens in a new tab)references/generator-usage.md (opens in a new tab)references/spring-official-docs.md (opens in a new tab)references/templates/Controller.java.tpl (opens in a new tab)references/templates/CreateService.java.tpl (opens in a new tab)references/templates/DeleteService.java.tpl (opens in a new tab)references/templates/DomainModel.java.tpl (opens in a new tab)references/templates/DomainRepository.java.tpl (opens in a new tab)references/templates/DomainService.java.tpl (opens in a new tab)references/templates/DtoRequest.java.tpl (opens in a new tab)references/templates/DtoResponse.java.tpl (opens in a new tab)references/templates/EntityExceptionHandler.java.tpl (opens in a new tab)references/templates/ErrorResponse.java.tpl (opens in a new tab)references/templates/ExistException.java.tpl (opens in a new tab)references/templates/GetService.java.tpl (opens in a new tab)references/templates/GlobalExceptionHandler.java.tpl (opens in a new tab)references/templates/JpaEntity.java.tpl (opens in a new tab)What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub ulpi-io/plugin-marketplace --plugin giuseppe-trisciuoglio95 skills in this plugin
/aws-cloudformation-auto-scalingaws-rds-spring-boot-integrationProvides patterns to configure AWS RDS (Aurora, MySQL, PostgreSQL) with Spring Boot applications. Use when setting up datasources, connection pooling, security, and production-ready database configuration./aws-cloudformation-bedrockaws-sdk-java-v2-bedrockProvides Amazon Bedrock patterns using AWS SDK for Java 2.x. Use when working with foundation models (listing, invoking), text generation, image generation, embeddings, streaming responses, or integrating generative AI with Spring Boot applications./aws-cloudformation-cloudfrontOther plugins' skills for the same job