@Override public String processGetOther( HttpExchange httpExchange, List<String> urlParams, Map<String, Object> requestParams) { String operation = (String) requestParams.get("operation"); if (operation.equals(RETRIEVE_TOKEN)) { String token = (String) requestParams.get("token"); Ticket ticket = ticketService.getByToken(token); Gson gson = new Gson(); String jsonTicket = gson.toJson(ticket); return jsonTicket; } return ""; }