1
0
Fork 0
peertube/shared/models/search/videos-common-query.model.ts
Wicklow 2a4c0d8bbe
Feature/filter already watched videos (#5739)
* filter already watched videos

* Updated code based on review comments
2023-04-12 09:32:20 +02:00

49 lines
997 B
TypeScript

import { VideoPrivacy } from '@shared/models'
import { VideoInclude } from '../videos/video-include.enum'
import { BooleanBothQuery } from './boolean-both-query.model'
// These query parameters can be used with any endpoint that list videos
export interface VideosCommonQuery {
start?: number
count?: number
sort?: string
nsfw?: BooleanBothQuery
isLive?: boolean
// FIXME: deprecated in 4.0 in favour of isLocal and include, to remove
filter?: never
isLocal?: boolean
include?: VideoInclude
categoryOneOf?: number[]
licenceOneOf?: number[]
languageOneOf?: string[]
privacyOneOf?: VideoPrivacy[]
tagsOneOf?: string[]
tagsAllOf?: string[]
hasHLSFiles?: boolean
hasWebtorrentFiles?: boolean
skipCount?: boolean
search?: string
excludeAlreadyWatched?: boolean
}
export interface VideosCommonQueryAfterSanitize extends VideosCommonQuery {
start: number
count: number
sort: string
// FIXME: deprecated in 4.0, to remove
filter?: never
}