本文档为个人博客文档系统的备份版本、作者:小游、作者博客:点击访问
get请求
# 地址
String url = "https://api.weixin.qq.com/cgi-bin/token?grant_type=client_credential&appid={id}&secret={secret}";
# 发送的get数据
Map<String,Object> map = new HashMap<>(3);
map.put("id", APPID);
map.put("secret", SECRET);
# 发请求获取内容
ResponseEntity<String> entity = restTemplate.getForEntity(url, String.class,map);
ObjectMapper objectMapper