public async Task <IActionResult> GetActiveOrders([FromBody] AccessTokenModel model) { IAccessToken accessToken = await m_token_service.GetToken(model.Token); if (accessToken == null || accessToken.HasExpired) { return(BadRequest()); } return(Ok((await m_order_provider.GetActiveOrders(accessToken.User)).Select(x => new OrderModel(accessToken, x)).ToArray())); }