Back to course

GET Mapping and Path Variables

Spring Boot 0 to Hero: The Complete Java Backend Masterclass

Fetching Data

Use @GetMapping to retrieve resources. Use @PathVariable to extract data from the URL.

GET /users/5 -> @PathVariable Long id