https://api.weixin.qq.com/dat...
POST 内容示例:
{
"begin_date" : "20170313",
"end_date" : "20170313"
}
CloseableHttpClient httpClient = createSSLClientDefault();
HttpPost httpPost = new HttpPost();
httpPost.setURI(new URI(url));
httpPost.setEntity(new UrlEncodedFormEntity(nvps));
CloseableHttpResponse response = httpClient.execute(httpPost);
HttpEntity entity = response.getEntity();
if (entity != null) {
String result = EntityUtils.toString(entity, "UTF-8");
System.out.println("Response content: " + result);
return result;
}
Response content: {"errcode":61500,"errmsg":"date format error hint: [Dy5YZa0787e541]"}
httpPost.setEntity(new StringEntity(params.toString(), "UTF-8"));