+ "\"threatInfo\": {\"threatTypes\": [\"MALWARE\", \"SOCIAL_ENGINEERING\", \"UNWANTED_SOFTWARE\", \"POTENTIALLY_HARMFUL_APPLICATION\"],"
+ "\"threatEntryTypes\": [\"URL\", \"IP_RANGE\"],"
Map<String, Object> finalJson = new LinkedHashMap<>();
Map<String, Object> clientDetails = new LinkedHashMap<>();
clientDetails.put( "\"clientId\"", "\"clientId\"" );
clientDetails.put( "\"clientVersion\"", "\"1.0.0\"");
Map<String, Object> threatTypes = new HashMap<>();
threatTypes.put( "\"threatTypes\"", Arrays.asList("\"MALWARE\"", "\"SOCIAL_ENGINEERING\"", "\"UNWANTED_SOFTWARE\"", "\"POTENTIALLY_HARMFUL_APPLICATION\"") );
Map<String, Object> platformTypes = new HashMap<>();
platformTypes.put("\"platformTypes\"", Arrays.asList("\"ANY_PLATFORM\""));
Map<String, Object> threatEntryTypes = new HashMap<>();
threatEntryTypes.put("\"threatEntryTypes\"", Arrays.asList("\"URL\"", "\"IP_RANGE\""));
Map<String, Object> threatEntryUrl = new HashMap<>();
Map<String, Object> threatEntries = new HashMap<>();
threatEntries.put("\"threatEntries\"", Arrays.asList( threatEntryUrl ));
finalJson.put( "\"client\"", clientDetails);
finalJson.put( "\"threatInfo\"", Arrays.asList(threatTypes, platformTypes, threatEntryTypes, threatEntries));
System.out.println("FinalJson"+ finalJson );
System.out.println( googleSafeBrowserResponse.statusCode() );
System.out.println( googleSafeBrowserResponse.asString() );