JAVA Required request body is missing
时间: 2023-09-18 14:16:18 浏览: 83
postman使用
在Java中,出现"Required request body is missing"错误通常是因为在接收请求时,需要一个请求体(request body),但实际请求中并没有提供请求体。这个错误通常发生在使用@RequestBody注解时,该注解用于接收前端传递给后端的JSON字符串。但是,GET请求没有请求体,所以应该将请求方式改为POST。<span class="em">1</span><span class="em">2</span><span class="em">3</span>
#### 引用[.reference_title]
- *1* *2* *3* [Required request body is missing:public java.*****](https://blog.csdn.net/m0_48373030/article/details/109243984)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v93^chatsearchT3_2"}}] [.reference_item style="max-width: 100%"]
[ .reference_list ]
阅读全文