My error is as follows:
my code:
My mistake is because the path of String path = "/v1/convert" in the code is wrong and should be written completely
Note: The url in the parameter needs to be processed
String str="自己的需要转成pdf 的 路径";
String encode = URLEncoder.encode(str, "UTF-8");
Use the documentation link:
https://apis.baidu.com/store/detail/26ccebe8-1964-4cba-bd46-42a7d8ee53fc