This commit is contained in:
王文艳
2026-06-01 15:16:18 +08:00
parent d5ac4baa1d
commit 3d944d5f67
3 changed files with 15 additions and 4 deletions
@@ -479,7 +479,7 @@ public class OpenApiClient {
public static JSONObject addressStandard(String city, String address) {
if (StringUtils.isBlank(city) || StringUtils.isBlank(address)) {
if (StringUtils.isBlank(address)) {
throw new IllegalArgumentException();
}
@@ -488,7 +488,7 @@ public class OpenApiClient {
params.put("city", city);
params.put("address", address);
params.put("token", TOKEN);
String content = new HttpRequest().get("http://open.fangjia.com/address/standard", params, "utf-8")
String content = new HttpRequest().get("http://open.fangjia.com/addrSvc/structure", params, "utf-8")
JSONObject result = JSONObject.fromObject(content)
if (result.getInt("code") == 200) {
return result.getJSONObject("result");