]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - server/models/video/video-interface.ts
Add oembed endpoint
[github/Chocobozzz/PeerTube.git] / server / models / video / video-interface.ts
index 6a3db4f3efcf5957055054a81842a88a1c276b87..1402df26a2aaf20f44403b6e16937d1c06f1df36 100644 (file)
@@ -32,6 +32,9 @@ export namespace VideoMethods {
   export type OptimizeOriginalVideofile = (this: VideoInstance) => Promise<void>
   export type TranscodeOriginalVideofile = (this: VideoInstance, resolution: number) => Promise<void>
   export type GetOriginalFileHeight = (this: VideoInstance) => Promise<number>
+  export type GetEmbedPath = (this: VideoInstance) => string
+  export type GetThumbnailPath = (this: VideoInstance) => string
+  export type GetPreviewPath = (this: VideoInstance) => string
 
   // Return thumbnail name
   export type GenerateThumbnailFromData = (video: VideoInstance, thumbnailData: string) => Promise<string>
@@ -107,7 +110,9 @@ export interface VideoInstance extends VideoClass, VideoAttributes, Sequelize.In
   getOriginalFile: VideoMethods.GetOriginalFile
   generateMagnetUri: VideoMethods.GenerateMagnetUri
   getPreviewName: VideoMethods.GetPreviewName
+  getPreviewPath: VideoMethods.GetPreviewPath
   getThumbnailName: VideoMethods.GetThumbnailName
+  getThumbnailPath: VideoMethods.GetThumbnailPath
   getTorrentFileName: VideoMethods.GetTorrentFileName
   getVideoFilename: VideoMethods.GetVideoFilename
   getVideoFilePath: VideoMethods.GetVideoFilePath
@@ -122,6 +127,7 @@ export interface VideoInstance extends VideoClass, VideoAttributes, Sequelize.In
   optimizeOriginalVideofile: VideoMethods.OptimizeOriginalVideofile
   transcodeOriginalVideofile: VideoMethods.TranscodeOriginalVideofile
   getOriginalFileHeight: VideoMethods.GetOriginalFileHeight
+  getEmbedPath: VideoMethods.GetEmbedPath
 
   setTags: Sequelize.HasManySetAssociationsMixin<TagAttributes, string>
   addVideoFile: Sequelize.HasManyAddAssociationMixin<VideoFileAttributes, string>