code: public static String asJson(String key, Object value) {
  		try {
  			JSONObject json = new JSONObject();
  			json.put(key, value);
  			return json.toString();
  		} catch (Exception e) {
  			ApptentiveLog.e(e, "Exception while creating json-string { %s:%s }", key, value);
  			return null;
  		}
  	}
docs: Creates a simple json string from key and value