aboutsummaryrefslogtreecommitdiffhomepage
path: root/shared/models/videos
diff options
context:
space:
mode:
Diffstat (limited to 'shared/models/videos')
-rw-r--r--shared/models/videos/channel-sync/index.ts3
-rw-r--r--shared/models/videos/channel-sync/video-channel-sync-create.model.ts4
-rw-r--r--shared/models/videos/channel-sync/video-channel-sync-state.enum.ts6
-rw-r--r--shared/models/videos/channel-sync/video-channel-sync.model.ts14
-rw-r--r--shared/models/videos/index.ts1
5 files changed, 28 insertions, 0 deletions
diff --git a/shared/models/videos/channel-sync/index.ts b/shared/models/videos/channel-sync/index.ts
new file mode 100644
index 000000000..7d25aaac3
--- /dev/null
+++ b/shared/models/videos/channel-sync/index.ts
@@ -0,0 +1,3 @@
1export * from './video-channel-sync-state.enum'
2export * from './video-channel-sync.model'
3export * from './video-channel-sync-create.model'
diff --git a/shared/models/videos/channel-sync/video-channel-sync-create.model.ts b/shared/models/videos/channel-sync/video-channel-sync-create.model.ts
new file mode 100644
index 000000000..753a8ee4c
--- /dev/null
+++ b/shared/models/videos/channel-sync/video-channel-sync-create.model.ts
@@ -0,0 +1,4 @@
1export interface VideoChannelSyncCreate {
2 externalChannelUrl: string
3 videoChannelId: number
4}
diff --git a/shared/models/videos/channel-sync/video-channel-sync-state.enum.ts b/shared/models/videos/channel-sync/video-channel-sync-state.enum.ts
new file mode 100644
index 000000000..3e9f5ddc2
--- /dev/null
+++ b/shared/models/videos/channel-sync/video-channel-sync-state.enum.ts
@@ -0,0 +1,6 @@
1export const enum VideoChannelSyncState {
2 WAITING_FIRST_RUN = 1,
3 PROCESSING = 2,
4 SYNCED = 3,
5 FAILED = 4
6}
diff --git a/shared/models/videos/channel-sync/video-channel-sync.model.ts b/shared/models/videos/channel-sync/video-channel-sync.model.ts
new file mode 100644
index 000000000..73ac0615b
--- /dev/null
+++ b/shared/models/videos/channel-sync/video-channel-sync.model.ts
@@ -0,0 +1,14 @@
1import { VideoChannelSummary } from '../channel/video-channel.model'
2import { VideoConstant } from '../video-constant.model'
3import { VideoChannelSyncState } from './video-channel-sync-state.enum'
4
5export interface VideoChannelSync {
6 id: number
7
8 externalChannelUrl: string
9
10 createdAt: string
11 channel: VideoChannelSummary
12 state: VideoConstant<VideoChannelSyncState>
13 lastSyncAt: string
14}
diff --git a/shared/models/videos/index.ts b/shared/models/videos/index.ts
index 05497bda1..f8e6976d3 100644
--- a/shared/models/videos/index.ts
+++ b/shared/models/videos/index.ts
@@ -11,6 +11,7 @@ export * from './playlist'
11export * from './rate' 11export * from './rate'
12export * from './stats' 12export * from './stats'
13export * from './transcoding' 13export * from './transcoding'
14export * from './channel-sync'
14 15
15export * from './nsfw-policy.type' 16export * from './nsfw-policy.type'
16 17