Reputation: 392
Can any here suggest how can i implement the two GET request with different parameter on the same resource's function.
ex:
GetMapping("/Transaction") GetMapping("/Transactions")
Upvotes: 3
Views: 92
Reputation: 49646
@GetMapping(path = {"/Transaction", "/Transactions"})
path is a String[], so you can specify more than one path.
path
String[]
Upvotes: 2