I have an endpoint which should read a string value as body.
@RestController
public class EndpointsController {
@RequestMapping( method = RequestMethod.PUT, v
If you're using Jackson as your JSON parser, you can simply declare your parameter with the type TextNode. This is the Jackson type representing JSON strings.
public String updateName(@PathVariable(MY_ID) String myId, @RequestBody TextNode name) {
You can then use its asText method to retrieve its text value.