]>
Commit | Line | Data |
---|---|---|
583eb04b C |
1 | import { Account, AccountSummary } from '../actors' |
2 | import { VideoChannel, VideoChannelSummary } from './channel/video-channel.model' | |
ad5db104 | 3 | import { VideoFile } from './file' |
583eb04b | 4 | import { VideoConstant } from './video-constant.model' |
fd45e8f4 | 5 | import { VideoPrivacy } from './video-privacy.enum' |
bbe0f064 | 6 | import { VideoScheduleUpdate } from './video-schedule-update.model' |
583eb04b | 7 | import { VideoState } from './video-state.enum' |
09209296 | 8 | import { VideoStreamingPlaylist } from './video-streaming-playlist.model' |
93e1258c | 9 | |
69818c93 | 10 | export interface Video { |
0a6658fd C |
11 | id: number |
12 | uuid: string | |
d4a8e7a6 C |
13 | shortUUID: string |
14 | ||
d592e0a9 C |
15 | createdAt: Date | string |
16 | updatedAt: Date | string | |
2922e048 | 17 | publishedAt: Date | string |
c8034165 | 18 | originallyPublishedAt: Date | string |
ae5a3dd6 C |
19 | category: VideoConstant<number> |
20 | licence: VideoConstant<number> | |
9d3ef9fe | 21 | language: VideoConstant<string> |
2243730c | 22 | privacy: VideoConstant<VideoPrivacy> |
f713f36b C |
23 | |
24 | // Deprecated in 5.0 in favour of truncatedDescription | |
69f616ab | 25 | description: string |
f713f36b C |
26 | truncatedDescription: string |
27 | ||
69f616ab C |
28 | duration: number |
29 | isLocal: boolean | |
69f616ab | 30 | name: string |
5fb2e288 | 31 | |
c6c0fa6c C |
32 | isLive: boolean |
33 | ||
69f616ab | 34 | thumbnailPath: string |
5fb2e288 C |
35 | thumbnailUrl?: string |
36 | ||
f981dae8 | 37 | previewPath: string |
5fb2e288 C |
38 | previewUrl?: string |
39 | ||
d8755eed | 40 | embedPath: string |
5fb2e288 C |
41 | embedUrl?: string |
42 | ||
ab4001aa | 43 | url: string |
5fb2e288 | 44 | |
69f616ab | 45 | views: number |
b2111066 | 46 | viewers: number |
51353d9a | 47 | |
69f616ab C |
48 | likes: number |
49 | dislikes: number | |
50 | nsfw: boolean | |
b64c950a | 51 | |
418d092a C |
52 | account: AccountSummary |
53 | channel: VideoChannelSummary | |
6e46de09 C |
54 | |
55 | userHistory?: { | |
56 | currentTime: number | |
57 | } | |
7294aab0 C |
58 | |
59 | pluginData?: any | |
2760b454 C |
60 | |
61 | // Additional attributes dependending on the query | |
62 | waitTranscoding?: boolean | |
63 | state?: VideoConstant<VideoState> | |
64 | scheduledUpdate?: VideoScheduleUpdate | |
65 | ||
66 | blacklisted?: boolean | |
67 | blacklistedReason?: string | |
68 | ||
69 | blockedOwner?: boolean | |
70 | blockedServer?: boolean | |
3c10840f C |
71 | |
72 | files?: VideoFile[] | |
73 | streamingPlaylists?: VideoStreamingPlaylist[] | |
72c7248b C |
74 | } |
75 | ||
76 | export interface VideoDetails extends Video { | |
f713f36b | 77 | // Deprecated in 5.0 |
fd45e8f4 | 78 | descriptionPath: string |
f713f36b | 79 | |
2422c46b | 80 | support: string |
72c7248b | 81 | channel: VideoChannel |
5dce26d2 | 82 | account: Account |
d48ff09d | 83 | tags: string[] |
47564bbe | 84 | commentsEnabled: boolean |
7f2cfe3a | 85 | downloadEnabled: boolean |
2186386c | 86 | |
2760b454 | 87 | // Not optional in details (unlike in parent Video) |
2186386c C |
88 | waitTranscoding: boolean |
89 | state: VideoConstant<VideoState> | |
09209296 C |
90 | |
91 | trackerUrls: string[] | |
92 | ||
3c10840f | 93 | files: VideoFile[] |
09209296 | 94 | streamingPlaylists: VideoStreamingPlaylist[] |
69818c93 | 95 | } |