I attempt to send POST request with body like this
{
  "method": "getAreas",
  "methodProperties": {
      "prop1" : "value1",
      "prop2" : "value2",
   }
}
Here is my code
static final String HOST = "https://somehost.com";
  public String sendPost(String method,
      Map<String, String> methodProperties) throws ClientProtocolException, IOException {
    HttpPost post = new HttpPost(HOST);
    List<NameValuePair> urlParameters = new ArrayList<>();
    urlParameters.add(new BasicNameValuePair("method", method));
    List<NameValuePair> methodPropertiesList = methodProperties.entrySet().stream()
                .map(entry -> new BasicNameValuePair(entry.getKey(), entry.getValue()))
                .collect(Collectors.toList());
    // ??? urlParameters.add(new BasicNameValuePair("methodProperties", methodPropertiesList));
    post.setEntity(new UrlEncodedFormEntity(urlParameters));
    try (CloseableHttpClient httpClient = HttpClients.createDefault();
        CloseableHttpResponse response = httpClient.execute(post)) {
      return EntityUtils.toString(response.getEntity());
    }
  }
But constructor of BasicNameValuePair applies (String, String). So I need another class instead. 
Is there any way to add methodPropertiesList to urlParameters?