code: public static String readFromInputStreamIntoString(InputStream inputStream) throws IOException {
          BufferedReader reader = new BufferedReader(new InputStreamReader(inputStream, "UTF-8"));
          StringBuilder text = new StringBuilder();
  
          String line;
          while( (line = reader.readLine()) != null) {
              text.append(line).append("\n");
          }
          inputStream.close();
  
          return text.toString();
      }
docs: This method reads all data from an {@code InputStream} into a String object. This method will close the stream.
  @param inputStream {@code InputStream} to read text from
  @return <code>String</code> containing all input stream data
  @throws IOException IO exception