Form-data传输file参数,这个大家都比较清楚,那么针对于Fegin参数file参数该如何操作呢!下面截图来找到对应的参数关系。
一、之前我们在postMan中是这种传参的,那么如果使用Feigin来传输文件File
二、在Fegin中传form-data参数:
@FeignClient(url = "http://aaa.com", name = "testApi")
public interface TestApi {
    @PostMapping(value = "/api/test", consumes = MediaType.MULTIPART_FORM_DATA_VALUE)
    JSONObject openApiPic(
            @RequestPart String type,
            @RequestPart String content,
            @RequestPart MultipartFile file
    );
   
}



















