public async Task <IActionResult> GetItemActivity(Guid itemId) { ItemActivateModel result = new ItemActivateModel(); Item item = await context.Item .Where(x => x.ItemId == itemId) .FirstOrDefaultAsync(); result.itemId = itemId.ToString(); result.itemName = item.Name; result.isItemActive = item.IsActive; result.itemActivities = analyticsRepo.GetInfoForIsActive(itemId); return(Ok(result)); }