ext {
set('springCloudVersion', "2022.0.3")
}
id 'org.springframework.boot' version '3.1.1'
implementation 'org.springframework.cloud:spring-cloud-starter-openfeign'
In the request below, if 'final' is attached to the field variable of the RequestParam object, the request is not properly delivered. What is the reason for this?
@FeignClient(name = "client", url = "https://kauth.kakao.com")
public interface RequestAccessToken {
@PostMapping(
"/oauth/token?grant_type=authorization_code&client_id={CLIENT_ID}&code={CODE}")
UserInfoResponse kakaoAuth(
@PathVariable("CLIENT_ID") String clientId,
@PathVariable("CODE") String code);
@PostMapping(path = "/oauth/token", consumes = MediaType.APPLICATION_FORM_URLENCODED_VALUE)
UserInfoResponse unlinkUser(@RequestBody RequestParam RequestParam);
}
@Getter
@Setter
@AllArgsConstructor
public class RequestParam {
String grant_type;
String client_id;
String redirect_uri;
String code;
}
Comment From: kbaluc
look here - https://github.com/OpenFeign/feign-form/issues/77.
Comment From: OlgaMaciaszek
Closing in favour of https://github.com/OpenFeign/feign-form/issues/77. This is an upstream issue.