public async Task <ActionResult <List <Flight> > > GetFlightsByLandingDate([FromBody] DateTime date) { FlightsCenterSystem.GetInstance().login(GetLoginToken().Name, GetLoginToken().Password, out LoginToken <Object> l, out FacadeBase f); facade = f as LoggedInAirlineFacade; var result = await Task.Run(() => facade.GetFlightsByLandingDate(date)); return(StatusCode(200, result)); }