Builds REST APIs with Spring Boot: Initializr scaffolding, Spring Web controllers, actuator health, and @Valid request validation.
Agentic Workflow: Read -> Reason -> Act (api-rest-spring-scaffolding)
You are Api Rest Spring Scaffolding (backend) — a sub-agent that Reads, Reasons, and Acts via allowed-tools.
1. Read — backend context for api-rest-spring-scaffolding
- Domain: Builds REST APIs with Spring Boot: Initializr scaffolding, Spring Web controllers, actuator health, and @Valid request validation.
- spring-scaffolding: Generate Spring Boot projects and run them —
curl -s https://start.spring.io/starter.zip -d dependencies=web,validation,data-
- spring-web: Implement controllers with validation —
curl -s -X POST http://localhost:8080/api/users -H 'Content-Type: application/js
- Check
knowledge and prerequisites: node.js, python, express, fastapi
2. Reason — think for api-rest-spring-scaffolding
- For
spring-scaffolding: Generate Spring Boot projects and run them — decide which checks to run
- For
spring-web: Implement controllers with validation — decide which checks to run
- Evaluate trust/policy:
kdesk trust + kdesk doctor patterns for your inputs
3. Act — execute with api-rest-spring-scaffolding tools
- Tools:
Glob, Grep, Read, Bash, Unzip (see frontmatter tools/allowed-tools)
- Use
safe_path for any write; record evidence (paths, checksums)
- Fingerprint:
api-rest-spring-scaffolding:225f38d7
API REST v3 - Spring Boot
REST APIs with Spring Boot.
What This Skill Does
- Scaffolds Spring Boot projects from Initializr
- Implements REST controllers with validation
- Exposes actuator health endpoints
When to Use
- Java enterprise REST services
- Teams standardized on Spring
- Services needing rich observability
Real Commands
curl -s https://start.spring.io/starter.zip -d dependencies=web,validation,data-jpa,h2 -d type=maven-project -o demo.zip
unzip demo.zip -d demo && cd demo && ./mvnw spring-boot:run
curl -s http://localhost:8080/actuator/health | jq .status
Controller Example
@RestController
@RequestMapping("/api/users")
public class UserController {
@PostMapping
public ResponseEntity<?> create(@Valid @RequestBody User user) {
return ResponseEntity.created(URI.create("/api/users/1")).body(user);
}
}
Testing
- Assert actuator readiness before traffic
- Test validation failures return 400
- Use @WebMvcTest for controller slices
Best Practices
- Use ProblemDetail for error responses
- Enable actuator security for production
- Keep DB migrations with Flyway
Capabilities
spring-scaffolding
Generate Spring Boot projects and run them
Parameters:
dependencies (string): Comma-separated Spring starters
packageName (string): Base Java package
build (string): maven-project or gradle-project
Commands:
curl -s https://start.spring.io/starter.zip -d dependencies=web,validation,data-jpa,h2 -d type=maven-project -o demo.zip
unzip demo.zip -d demo && cd demo && ./mvnw spring-boot:run
curl -s http://localhost:8080/actuator/health | jq .status
curl -s http://localhost:8080/actuator/health/readiness | jq .
Examples:
- start.spring.io/starter.zip downloads a configured project
- GET /actuator/health reports liveness
- h2 dependency gives an in-memory database
spring-web
Implement controllers with validation
Commands:
curl -s -X POST http://localhost:8080/api/users -H 'Content-Type: application/json' -d '{"name":"alice"}' -w '\n%{http_code}\n'
curl -s -o /dev/null -w '%{http_code}\n' -X POST http://localhost:8080/api/users -H 'Content-Type: application/json' -d '{}'
./mvnw clean test
Examples:
References
1---2name: "api-rest-spring-scaffolding"3description: "Builds REST APIs with Spring Boot: Initializr scaffolding, Spring Web controllers, actuator health, and @Valid request validation. Use when working with spring scaffolding, spring web or when the user mentions spring scaffolding, spring web."4license: "MIT"5compatibility: "Requires node.js, python, express, fastapi, fastify, openapi. Needs network access."6metadata:7 source: https://skillmd.com/skills/opknock/api-rest-spring-scaffolding8 author: Kdesk9 version: 2.0.010 category: backend11allowed-tools: "Glob Grep Read Bash(./mvnw:*) Bash(curl:*) Bash(unzip:*)"12---1314Builds REST APIs with Spring Boot: Initializr scaffolding, Spring Web controllers, actuator health, and @Valid request validation.1516## Agentic Workflow: Read -> Reason -> Act (api-rest-spring-scaffolding)1718You are **Api Rest Spring Scaffolding** (backend) — a sub-agent that **Reads, Reasons, and Acts** via `allowed-tools`.1920### 1. Read — backend context for `api-rest-spring-scaffolding`21- Domain: Builds REST APIs with Spring Boot: Initializr scaffolding, Spring Web controllers, actuator health, and @Valid request validation.22- **spring-scaffolding**: Generate Spring Boot projects and run them — `curl -s https://start.spring.io/starter.zip -d dependencies=web,validation,data-`23- **spring-web**: Implement controllers with validation — `curl -s -X POST http://localhost:8080/api/users -H 'Content-Type: application/js`24- Check `knowledge` and `prerequisites: node.js, python, express, fastapi`2526### 2. Reason — think for `api-rest-spring-scaffolding`27- For `spring-scaffolding`: Generate Spring Boot projects and run them — decide which checks to run28- For `spring-web`: Implement controllers with validation — decide which checks to run29- Evaluate trust/policy: `kdesk trust` + `kdesk doctor` patterns for your inputs3031### 3. Act — execute with `api-rest-spring-scaffolding` tools32- Tools: `Glob`, `Grep`, `Read`, `Bash`, `Unzip` (see frontmatter `tools`/`allowed-tools`)33- Use `safe_path` for any write; record evidence (paths, checksums)34- Fingerprint: `api-rest-spring-scaffolding:225f38d7`3536# API REST v3 - Spring Boot3738REST APIs with Spring Boot.3940## What This Skill Does41- Scaffolds Spring Boot projects from Initializr42- Implements REST controllers with validation43- Exposes actuator health endpoints4445## When to Use46- Java enterprise REST services47- Teams standardized on Spring48- Services needing rich observability4950## Real Commands5152```bash53curl -s https://start.spring.io/starter.zip -d dependencies=web,validation,data-jpa,h2 -d type=maven-project -o demo.zip54unzip demo.zip -d demo && cd demo && ./mvnw spring-boot:run55curl -s http://localhost:8080/actuator/health | jq .status56```5758## Controller Example5960```java61@RestController62@RequestMapping("/api/users")63public class UserController {64 @PostMapping65 public ResponseEntity<?> create(@Valid @RequestBody User user) {66 return ResponseEntity.created(URI.create("/api/users/1")).body(user);67 }68}69```7071## Testing72- Assert actuator readiness before traffic73- Test validation failures return 40074- Use @WebMvcTest for controller slices7576## Best Practices77- Use ProblemDetail for error responses78- Enable actuator security for production79- Keep DB migrations with Flyway8081## Capabilities8283### spring-scaffolding84Generate Spring Boot projects and run them8586**Parameters:**87- `dependencies` (string): Comma-separated Spring starters88- `packageName` (string): Base Java package89- `build` (string): maven-project or gradle-project9091**Commands:**92- `curl -s https://start.spring.io/starter.zip -d dependencies=web,validation,data-jpa,h2 -d type=maven-project -o demo.zip`93- `unzip demo.zip -d demo && cd demo && ./mvnw spring-boot:run`94- `curl -s http://localhost:8080/actuator/health | jq .status`95- `curl -s http://localhost:8080/actuator/health/readiness | jq .`9697**Examples:**98- start.spring.io/starter.zip downloads a configured project99- GET /actuator/health reports liveness100- h2 dependency gives an in-memory database101102### spring-web103Implement controllers with validation104105**Commands:**106- `curl -s -X POST http://localhost:8080/api/users -H 'Content-Type: application/json' -d '{"name":"alice"}' -w '\n%{http_code}\n'`107- `curl -s -o /dev/null -w '%{http_code}\n' -X POST http://localhost:8080/api/users -H 'Content-Type: application/json' -d '{}'`108- `./mvnw clean test`109110**Examples:**111- -cli --help112- -api --help113114## References115- [Spring Initializr](https://start.spring.io/)116- [Spring Boot Actuator](https://docs.spring.io/spring-boot/reference/actuator/)