accountsSortValidator,
ensureAuthUserOwnsAccountValidator,
videoChannelsSortValidator,
- videosSortValidator
+ videosSortValidator,
+ videoChannelStatsValidator
} from '../../middlewares/validators'
import { AccountModel } from '../../models/account/account'
import { AccountVideoRateModel } from '../../models/account/account-video-rate'
accountsRouter.get('/:accountName/video-channels',
asyncMiddleware(accountNameWithHostGetValidator),
+ videoChannelStatsValidator,
paginationValidator,
videoChannelsSortValidator,
setDefaultSort,
accountId: res.locals.account.id,
start: req.query.start,
count: req.query.count,
- sort: req.query.sort
+ sort: req.query.sort,
+ withStats: req.query.withStats
}
const resultList = await VideoChannelModel.listByAccount(options)