Skip to content

IVideoCatalogService

Namespace: VideoCatalogService

Type: Interface

Implementation of the interface to the backing video catalog interface.

Definition

[ServiceContract(Namespace = "http://videocataloger.com/2015")] public interface IVideoCatalogService

Methods

Method Description
GetSharedRoots() Get roots that you will need access to for video, photos and actors. This is provided so you can ask the user to login
GetLastError() Return internal error info.
AddVideo(string, string, double, string, int, int, string, byte[], long, string, byte[]) Add a new video to the catalog.
RemoveVideoByID(long) Remove a video from the catalog
DeleteVideoFile(string) Remove all video files with the given path from the catalog.
MergeVideo(long, long) Merge source video id to destination id. The source will be removed and the test will have all thumbnails and keywords from the source
SearchVideos(VideoQuery) Search for videos in the catalog
SearchVideosFromString(string) Search for videos given a search string
GetPropertyMeta(string) Get all meta properties of a given property.
SetPropertyMeta(string, string, string) Set a new meta property to the catalog. Meta properties can be used to add extended user definied properties to videos
RemovePropertyMeta(string, string) Remove the meta property and remove it from all videos
GetAllExtendedPropertyValues(string) Return all extended property values for videos given a specific property
GetVideoFileExtendedProperty(long) Return all extended properties for a video
SetVideoFileExtendedProperty(long, string, string) Set the value of a user defined property.
GetThumbnailExtendedProperty(long) Return all extended properties for a thumbnail
SetThumbnailExtendedProperty(long, string, string) Set the value of a user defined property.
SearchThumbnails(VideoQuery, SceneQuery) Search for thumbnails having any of a matching keywords
GetVideoFileID(string) Get VideoFileID for a video path.
GetVideoFileEntry(long) Return a video file entry given an id.
GetVideoFileImage(long) Return a jpeg blob for the video image a video id.
SetVideoFileImage(long, byte[]) Set video file preview image
SetVideoGenre(long, string) Set video genre to a new genre title that is already in the catalog
SetVideoProperty(long, string, string) Set a video entry property.
UpdateVideoFilePath(string, string) Change a VideoFile path.
GetTagsForVideos(long[]) get a list of all tags used for a list of videos
RemoveTagsFromVideo(long) Remove a tag from videos given its tag instance id
TagVideo(long, string) Set a comma separated tag list to a video.
CreateVideoTag(Tag) Create a new video tag and return its tag id, -1 for none.
DeleteVideoTagFromCatalog(int) Delete tag from all used and remove from catalog.
DeleteThumbTagFromCatalog(int) Delete tag from all used and remove from catalog.
SetVideoTagProperty(long, string, string) Update a tag property (Name, Color, TagParentID, Link, Description), this will change all its uses in the catalog
GetAllVideoTags() Get a list of all video keywords
GetRandomVideoFileEntries(int) Return x random videos. Obs The returned entries are not complete, they do not have SHA or IV.
CreateTagGroup(string) Create a new tag group. Create a new group with the given name or return the id if it already exists
DeleteTagGroup(long) Delete a tag group
RenameTagGroup(long, string) rENAME a tag group
AddVideoTagToGroup(long, long) Add a video tag to a tag group
RemoveVideoTagFromGroup(long, long) Remove a video tag from a tag group.
GetAllTagGroups() Return all tag groups in the catalog.
GetVideoTagsInGroup(long) Return all video tags in the group
GetThumbnailTagsInGroup(long) Return all thumbnail tags in the group
GetGroupsForVideoTag(long) Return all groups that a specific video tag is in
GetAllActorTags() Get a list of all actor tags.
GetActorTags(long) Get all tags for a specific actor.
SetActorTagProperty(long, string, string) Update an actor tag property (Name, Color, Link, Description), this will change all its uses in the catalog
GetActorTagID(string) Get actor tag_id for a given tag text, -1 for none.
CreateActorTag(Tag) Create a new actor tag and return its tag id, -1 for none.
GetActors(string[], string, string, bool) Get a collection of actors based on search filter, empty string to get all actors, if skip_image_data is set no portrait image is fetched.
SearchActorsFromString(string) Search actors based on search terms matching any fields or keywords. If more terms are given all term need to match.
SearchActors(ActorQuery, bool) Search actors, if skip_image_data is set no portrait image is fetched.
GetActorsForVideo(long, bool) Get a collection of all actors for a given video id.
AddActorToDB(Actor) Add a new actor to the catalog.
UpdateActor(Actor) Update properties on a current actor.
AddActorTag(long, long) Set a tag to an actor .
TagActor(long, string) Add a keyword to an actor, if keyword is not used before it will be added to the catalog.
RemoveActorCompanionImage(long) Delete a companion image from an actor.
DeleteActorTag(long) Delete an actor tag provided it is not used by any actors.
AddActorCompanionImage(long, string, string) Add a companion image to an actor.
GetActorPortrait(long) Get portrait data for an actor.
GetActor(int) Get an actor based on the actor id
IsActorUsed(int) Is the given actor used in any video
DeleteActor(int) delete actor and remove it from the cast of all videos
AddActorToVideo(long, long) Add an actor to the cast of a video
RemoveActorFromVideo(long, long) Remove an actor from the cast of a video
GetCast(long[]) GetCast for videos
GetActorCompanionImages(long) Get companion images for a given actor.
GetTagsForThumbs(long[]) get a list of all tags used for a list of video thumbs
RemoveTagsFromThumbnails(long) Remove a tag from keywords given its tag instance id
AddVideoThumbnail(ThumbnailEntry) Add a thubnail to a video in the catalog.
AddGetVideoThumbnail(ThumbnailEntry) Add a thubnail to a video in the catalog.
TagThumbs(long[], string) Set a comma separated tag list to a list of thumbnails.
GetThumbnailImageFromID(long) Return a jpeg byte blob for the given thumb id.
GetThumbnail(long) Get thumbnail fata including image.
GetAllThumbnailTags() Return a list of all used thumbnail tags.
DeleteThumbnail(long) Delete a thumbnail from the catalog.
GetThumbnailsForVideo(long, bool) Get a list of all thumbnails for a given video.
GetThumbnailsIDsForVideo(long) Get a list of all thumbnails id for a given video.
GetAllCoverImages() Get all cover images in the catalog.
GetCoverImagesForVideo(long) Get cover image for a given video.
AddCompanionImages(long, string[]) Add companion images to a given video file id.
AddCompanionImage(long, string, string) Add a companion images to a given video file id and return the companion image id.
RemoveVideoCompanionImage(long) Remove companion image and delete file on server
GetCompanionImageID(long, string) Get video companion image id for a given image file path.
GetVideoFileIDForCompanionImage(string) Get VideoFileID for a companion image path in the catalog.
SetCoverImages(long, long, long) Set cover images for a video, -1 for no cover.
UpdateCompanionImagePath(string, string) Change a companion image path, will affect all companion images with the source path. Note that this will not change the actual resource. i.e. the companíon image file will not be moved.
SetCompanionImagePath(long, string) Set a new companion image path.
GetVideoCompanionImage(long) Get a specific video companion image given its id.
GetVideoCompanionImages(long) Get all video companion images for a video.
GetAllVideoCompanionImages(int, bool) Get all video companion images.
DeleteImageCompanionFile(string) Remove all companion files with the given path from the catalog.
RemoveImageFile(long, long) Remove an image as companion and covers from a video.
CreateArchiveMedia(string, string, string, string) Create a new archive media and return the handle to it
DeleteArchive(int) Delete an archive and remove the tag from all archived videofiles
UpdateArchiveMedia(int, string, string, string, string) Update a current archive media
GetArchive(int) Get an archive given an archive handle
GetArchives() Get a list of all archives in catalog
GetArchivesForVideo(long) Get a list of all archives where the video can be found.
ArchiveVideo(long, int) Put a video in an archive.
GetAllTagNames() get a list of all tags used
GetGenres() Get a list of all genres in the catalog.
RenameGenre(string, string) Rename a genre in the catalog.
GetNofVideos() Return the number of videos in the catalog.
GetNofActors() Return the number of actors in the catalog.
GetNofCompanionImages() Return the number of companion images in the catalog.
GetVideoTagUse(int) Return the number of uses for a specific tag.
GetThumbTagUse(int) Return the number of uses for a specific tag.
GetActorTagUse(int) Return the number of uses for a specific tag.
GetVideosInBin(long) Get a list of all videos in a collection. Will not return thumbnail data
GetBinsInBin(long) Get a list of all collections in a collection
AddVideoToBin(long, long) Set the bin a video is in.
RemoveVideoFromBin(long, long) Remove a video from a bin. Note that a video can be in more than one bin.
RemoveBin(long) Remove a bin from the catalog. The caller is responsible for removing videos from the bin if there are any before the bin is removed.
CreateBin(string, long, uint, VideoQuery) Create a new video collection.
SetBinProperty(long, string, string) Set a property of a bin
SetBinQuery(long, VideoQuery) Set query to a bin.
GetBinQuery(long) Get a smart query for a bin, null if this is no a smart bin.
GetAllBins() Get a list of all video keywords
SetVideoClip(VideoClip) Create or Update a clip
GetVideoClip(int) Get a video clip
DeleteVideoClip(int) Delete a video clip from the catalog. A clip is unique to a playlist and the same clip is never part of more than one playlist
CreateVideoPlaylist(string) Create a new video playlist
GetAllVideoPlaylists() Get all video playlists
DeletePlaylist(long) Delete a playlist from the catalog
SetClipToPlaylist(long, int, int) Create a new video playlist
GetPlaylistClip(long, int) Get one video clip in a playlist given its order
RemovePlaylistClip(long, int) Remove a playlist from the catalog
GetPlaylistClipIDs(long) Get all clip ids for a playlist
SetSubtitle(Subtitle) Create or update a subtitles for a video
GetSubtitle(long) Get a specific subtitle given an id
GetAllSubtitles(long) Get all subtitles for a video
RemoveSubtitle(long) Remove a subtitle from the catalog
RemoveSubtitlesFromVideo(long) Remove all subtitles for a specific video
SearchSubtitlesFromString(string, long) Search subtitle for the search string
SearchSubtitlesFromString(string, long) Search subtitle for the search string

GetSharedRoots

Get roots that you will need access to for video, photos and actors. This is provided so you can ask the user to login

SharedRoots GetSharedRoots()

Returns: SharedRoots


GetLastError

Return internal error info.

string GetLastError()

Returns: String


AddVideo

Add a new video to the catalog.

long AddVideo(string path, string title, double video_length, string description, int genre, int rating, string link, byte[] preview, long file_size, string encrypted, byte[] IV)

Parameters:

Name Type Description
path String Path to the video file
title String Title of the video
video_length Double Lenght in seconds
description String Description for the video
genre Int32 Genre, 0 based index
rating Int32 0-5 Rating of the video
link String Url for the video
preview Byte[] jpeg data for the preview image
file_size Int64 Size of the file
encrypted String original filename only used for encrypted videos.
IV Byte[] IV for´the encrypted file or null

Returns: Int64 - Video id


RemoveVideoByID

Remove a video from the catalog

void RemoveVideoByID(long video_file_id)

Parameters:

Name Type Description
video_file_id Int64 Video id

DeleteVideoFile

Remove all video files with the given path from the catalog.

void DeleteVideoFile(string file_path)

Parameters:

Name Type Description
file_path String Remove a video file from the catalog given a path to the video file

MergeVideo

Merge source video id to destination id. The source will be removed and the test will have all thumbnails and keywords from the source

void MergeVideo(long video_id_to_remove, long keep_video_file_id)

Parameters:

Name Type Description
video_id_to_remove Int64 video id to merge from and remove
keep_video_file_id Int64 video id to merge into and keep

SearchVideos

Search for videos in the catalog

VideoFileEntry[] SearchVideos(VideoQuery video_query)

Parameters:

Name Type Description
video_query VideoQuery Search argument

Returns: VideoFileEntry[] - VideoFileEntry matching query filter


SearchVideosFromString

Search for videos given a search string

VideoFileEntry[] SearchVideosFromString(string search_string)

Parameters:

Name Type Description
search_string String Search string

Returns: VideoFileEntry[] - VideoFileEntry matching query filter


GetPropertyMeta

Get all meta properties of a given property.

PropertyMeta[] GetPropertyMeta(string property)

Parameters:

Name Type Description
property String Name of the meta property. "video_property" for user defined video properties

Returns: PropertyMeta[]


SetPropertyMeta

Set a new meta property to the catalog. Meta properties can be used to add extended user definied properties to videos

void SetPropertyMeta(string property, string aspect, string value)

Parameters:

Name Type Description
property String Name of the meta property. "video_property" for user defined video properties
aspect String An aspect of meta property. For a user "video_property" this would be what the user named the video property
value String Vaue of the meta property. For a user "video property" this would be how the property is edited. "edit" for a text box

RemovePropertyMeta

Remove the meta property and remove it from all videos

void RemovePropertyMeta(string property, string aspect)

Parameters:

Name Type Description
property String Name of the meta property. "video_property" for user defined video properties
aspect String Aspect of the meta property. For a user "video_property" this would be what the user named the video property

GetAllExtendedPropertyValues

Return all extended property values for videos given a specific property

ExtendedPropertyVideoValue[] GetAllExtendedPropertyValues(string property_name)

Parameters:

Name Type Description
property_name String name of property to get value for

Returns: ExtendedPropertyVideoValue[]


GetVideoFileExtendedProperty

Return all extended properties for a video

ExtendedProperty[] GetVideoFileExtendedProperty(long video_file_id)

Parameters:

Name Type Description
video_file_id Int64 Video id

Returns: ExtendedProperty[]


SetVideoFileExtendedProperty

Set the value of a user defined property.

void SetVideoFileExtendedProperty(long video_file_id, string property, string value)

Parameters:

Name Type Description
video_file_id Int64 Video id
property String Property name. For a user "video property" this would be the name the user sat to the property passed into "aspect" of SetPropertyMeta
value String Value of the extended property

GetThumbnailExtendedProperty

Return all extended properties for a thumbnail

ExtendedProperty[] GetThumbnailExtendedProperty(long thumbnail_id)

Parameters:

Name Type Description
thumbnail_id Int64 Thumbnail id

Returns: ExtendedProperty[]


SetThumbnailExtendedProperty

Set the value of a user defined property.

void SetThumbnailExtendedProperty(long thumbnail_id, string property, string value)

Parameters:

Name Type Description
thumbnail_id Int64 Thumbnail id
property String Property name. For a user "thumbnail property" this would be the name the user sat to the property passed into "aspect" of SetPropertyMeta
value String Value of the extended property

SearchThumbnails

Search for thumbnails having any of a matching keywords

SceneQueryResult SearchThumbnails(VideoQuery video_query, SceneQuery scene_search)

Parameters:

Name Type Description
video_query VideoQuery Video query
scene_search SceneQuery Scene query

Returns: SceneQueryResult - Query results


GetVideoFileID

Get VideoFileID for a video path.

long GetVideoFileID(string path)

Parameters:

Name Type Description
path String Get the video file id given the path to a video file

Returns: Int64 - VideoFileID or -1 if not used in the catalog


GetVideoFileEntry

Return a video file entry given an id.

VideoFileEntry GetVideoFileEntry(long video_file_id)

Parameters:

Name Type Description
video_file_id Int64 Video file id

Returns: VideoFileEntry - video file entry


GetVideoFileImage

Return a jpeg blob for the video image a video id.

byte[] GetVideoFileImage(long video_file_id)

Parameters:

Name Type Description
video_file_id Int64 Video file id

Returns: Byte[] - null if no image or data for a jpeg image


SetVideoFileImage

Set video file preview image

void SetVideoFileImage(long video_file_id, byte[] image_data)

Parameters:

Name Type Description
video_file_id Int64 Video file id
image_data Byte[] Image data to set to represent the video file. I.e. whats shown in the catalog window

SetVideoGenre

Set video genre to a new genre title that is already in the catalog

void SetVideoGenre(long video_file_id, string genre_title)

Parameters:

Name Type Description
video_file_id Int64 Video file id
genre_title String The genre of the video

SetVideoProperty

Set a video entry property.

void SetVideoProperty(long video_file_id, string property_name, string value)

Parameters:

Name Type Description
video_file_id Int64 Video file id
property_name String What property to set
value String Value of the property

UpdateVideoFilePath

Change a VideoFile path.

bool UpdateVideoFilePath(string Source, string Destination)

Parameters:

Name Type Description
Source String Old video path
Destination String New video Path

Returns: Boolean - return true if any path was updated


GetTagsForVideos

get a list of all tags used for a list of videos

TagInstance[] GetTagsForVideos(long[] selected_videos)

Parameters:

Name Type Description
selected_videos Int64[] Array of Video file ids for selected videos

Returns: TagInstance[] - Array of Tags


RemoveTagsFromVideo

Remove a tag from videos given its tag instance id

bool RemoveTagsFromVideo(long TagInstanceID)

Parameters:

Name Type Description
TagInstanceID Int64 Tag instance

Returns: Boolean - true if the tag was removed


TagVideo

Set a comma separated tag list to a video.

int TagVideo(long video_file_id, string entered_keyword_string)

Parameters:

Name Type Description
video_file_id Int64 Video file id
entered_keyword_string String String with tag

Returns: Int32 - Tag instance id


CreateVideoTag

Create a new video tag and return its tag id, -1 for none.

Tag CreateVideoTag(Tag tag)

Parameters:

Name Type Description
tag Tag New tag to create

Returns: Tag - Return TagID or -1 if error


DeleteVideoTagFromCatalog

Delete tag from all used and remove from catalog.

void DeleteVideoTagFromCatalog(int tag_id)

Parameters:

Name Type Description
tag_id Int32 id of the tag

DeleteThumbTagFromCatalog

Delete tag from all used and remove from catalog.

void DeleteThumbTagFromCatalog(int tag_id)

Parameters:

Name Type Description
tag_id Int32 id of the tag

SetVideoTagProperty

Update a tag property (Name, Color, TagParentID, Link, Description), this will change all its uses in the catalog

void SetVideoTagProperty(long tag_id, string property_name, string value)

Parameters:

Name Type Description
tag_id Int64 id of tag
property_name String property
value String value of property

GetAllVideoTags

Get a list of all video keywords

Tag[] GetAllVideoTags()

Returns: Tag[] - Array of tag


GetRandomVideoFileEntries

Return x random videos. Obs The returned entries are not complete, they do not have SHA or IV.

Dictionary<long, VideoFileEntry> GetRandomVideoFileEntries(int max_nof_items)

Parameters:

Name Type Description
max_nof_items Int32 How many random videos to we want

Returns: Collections.Generic.Dictionary{Int64,VideoFileEntry} - Dictionary mapping a video id to a VideoFileEntry


CreateTagGroup

Create a new tag group. Create a new group with the given name or return the id if it already exists

long CreateTagGroup(string name)

Parameters:

Name Type Description
name String Name of the tag group

Returns: Int64 - id of group or -1 on failure.


DeleteTagGroup

Delete a tag group

void DeleteTagGroup(long group_id)

Parameters:

Name Type Description
group_id Int64 Id of group

RenameTagGroup

rENAME a tag group

void RenameTagGroup(long group_id, string new_name)

Parameters:

Name Type Description
group_id Int64 Id of group
new_name String New Name of the tag group

AddVideoTagToGroup

Add a video tag to a tag group

void AddVideoTagToGroup(long video_tag_id, long group_id)

Parameters:

Name Type Description
video_tag_id Int64 id of video tag to be removed
group_id Int64 id of group to add the video tag to

RemoveVideoTagFromGroup

Remove a video tag from a tag group.

void RemoveVideoTagFromGroup(long video_tag_id, long group_id)

Parameters:

Name Type Description
video_tag_id Int64 id of video tag to be removed
group_id Int64 id of group to remove the video tag from

GetAllTagGroups

Return all tag groups in the catalog.

TagGroup[] GetAllTagGroups()

Returns: TagGroup[] - Array of tag groups


GetVideoTagsInGroup

Return all video tags in the group

Tag[] GetVideoTagsInGroup(long group_id)

Parameters:

Name Type Description
group_id Int64 id of group to get tags from

Returns: Tag[] - Array of tag


GetThumbnailTagsInGroup

Return all thumbnail tags in the group

Tag[] GetThumbnailTagsInGroup(long group_id)

Parameters:

Name Type Description
group_id Int64 id of group to get tags from

Returns: Tag[] - Array of tag


GetGroupsForVideoTag

Return all groups that a specific video tag is in

TagGroup[] GetGroupsForVideoTag(long video_tag_id)

Parameters:

Name Type Description
video_tag_id Int64 id of video tag to check for tags

Returns: TagGroup[] - Array of groups


GetAllActorTags

Get a list of all actor tags.

Tag[] GetAllActorTags()

Returns: Tag[] - Array of all actor Tags used in the catalog


GetActorTags

Get all tags for a specific actor.

TagInstance[] GetActorTags(long actor_id)

Parameters:

Name Type Description
actor_id Int64 id of actor

Returns: TagInstance[] - Array of Tags used in the catalog for a specific actor


SetActorTagProperty

Update an actor tag property (Name, Color, Link, Description), this will change all its uses in the catalog

void SetActorTagProperty(long tag_id, string property_name, string value)

Parameters:

Name Type Description
tag_id Int64
property_name String
value String

GetActorTagID

Get actor tag_id for a given tag text, -1 for none.

int GetActorTagID(string tag_text)

Parameters:

Name Type Description
tag_text String

Returns: Int32 - -1 for no tag or the tag_id


CreateActorTag

Create a new actor tag and return its tag id, -1 for none.

Tag CreateActorTag(Tag tag)

Parameters:

Name Type Description
tag Tag

Returns: Tag - id for the newly created tag. -1 is return is the tag was not created, for example if it alreadt exists.


GetActors

Get a collection of actors based on search filter, empty string to get all actors, if skip_image_data is set no portrait image is fetched.

Actor[] GetActors(string[] tag_filter, string surename_filter, string lastname_filter, bool skip_image_data)

Parameters:

Name Type Description
tag_filter String[]
surename_filter String
lastname_filter String
skip_image_data Boolean

Returns: Actor[] - Array of actors matching the filter


SearchActorsFromString

Search actors based on search terms matching any fields or keywords. If more terms are given all term need to match.

Actor[] SearchActorsFromString(string search_string)

Parameters:

Name Type Description
search_string String

Returns: Actor[] - Array of actors matching the search filter


SearchActors

Search actors, if skip_image_data is set no portrait image is fetched.

Actor[] SearchActors(ActorQuery actor_query, bool skip_image_data)

Parameters:

Name Type Description
actor_query ActorQuery
skip_image_data Boolean

Returns: Actor[] - Array of actors matching the search filter


GetActorsForVideo

Get a collection of all actors for a given video id.

Actor[] GetActorsForVideo(long video_file_id, bool skip_image_data)

Parameters:

Name Type Description
video_file_id Int64 Video id
skip_image_data Boolean true to exclude actor portrait image

Returns: Actor[] - Array of actors for the video


AddActorToDB

Add a new actor to the catalog.

int AddActorToDB(Actor actor)

Parameters:

Name Type Description
actor Actor Actor data for the new actor. ID is ignored

Returns: Int32 - ID of added actor


UpdateActor

Update properties on a current actor.

void UpdateActor(Actor actor)

Parameters:

Name Type Description
actor Actor Actor data for the new actor. ID is used to find the actor to update

AddActorTag

Set a tag to an actor .

void AddActorTag(long actor_id, long tag_id)

Parameters:

Name Type Description
actor_id Int64 id of actor
tag_id Int64 id of the actor tag

TagActor

Add a keyword to an actor, if keyword is not used before it will be added to the catalog.

void TagActor(long actor_id, string tag_text)

Parameters:

Name Type Description
actor_id Int64 id of actor
tag_text String add a tag to an actor

RemoveActorCompanionImage

Delete a companion image from an actor.

void RemoveActorCompanionImage(long companion_image_id)

Parameters:

Name Type Description
companion_image_id Int64 companion image id

DeleteActorTag

Delete an actor tag provided it is not used by any actors.

void DeleteActorTag(long actor_tag_instance_id)

Parameters:

Name Type Description
actor_tag_instance_id Int64 instance id of an actor tag

AddActorCompanionImage

Add a companion image to an actor.

long AddActorCompanionImage(long actor_id, string path, string server_path)

Parameters:

Name Type Description
actor_id Int64 id of actor
path String local path of the compaion image
server_path String server path of the companion image

Returns: Int64 - Companion image ID


GetActorPortrait

Get portrait data for an actor.

byte[] GetActorPortrait(long actor_id)

Parameters:

Name Type Description
actor_id Int64 id of actor

Returns: Byte[] - jpeg image data


GetActor

Get an actor based on the actor id

Actor GetActor(int actor_id)

Parameters:

Name Type Description
actor_id Int32 id of actor

Returns: Actor - Actor data


IsActorUsed

Is the given actor used in any video

bool IsActorUsed(int actor_id)

Parameters:

Name Type Description
actor_id Int32 id of actor

Returns: Boolean - true if the id is used and valid


DeleteActor

delete actor and remove it from the cast of all videos

void DeleteActor(int actor_id)

Parameters:

Name Type Description
actor_id Int32 id of actor

AddActorToVideo

Add an actor to the cast of a video

void AddActorToVideo(long video_file_id, long actor_id)

Parameters:

Name Type Description
video_file_id Int64 Video id
actor_id Int64 id of actor

RemoveActorFromVideo

Remove an actor from the cast of a video

void RemoveActorFromVideo(long video_file_id, long actor_id)

Parameters:

Name Type Description
video_file_id Int64 Video id
actor_id Int64 id of actor

GetCast

GetCast for videos

Actor[] GetCast(long[] video_list)

Parameters:

Name Type Description
video_list Int64[]

Returns: Actor[] - Array of actors.


GetActorCompanionImages

Get companion images for a given actor.

ActorCompanionImage[] GetActorCompanionImages(long actor_id)

Parameters:

Name Type Description
actor_id Int64 id of actor

Returns: ActorCompanionImage[] - Array of actor companion images.


GetTagsForThumbs

get a list of all tags used for a list of video thumbs

TagInstance[] GetTagsForThumbs(long[] selected_thumbs)

Parameters:

Name Type Description
selected_thumbs Int64[] Array of selected thumbnails ids

Returns: TagInstance[] - Arrays of tags.


RemoveTagsFromThumbnails

Remove a tag from keywords given its tag instance id

bool RemoveTagsFromThumbnails(long TagInstanceID)

Parameters:

Name Type Description
TagInstanceID Int64 Tag instance id

Returns: Boolean - true if the tag was removed


AddVideoThumbnail

Add a thubnail to a video in the catalog.

void AddVideoThumbnail(ThumbnailEntry thumb_entry)

Parameters:

Name Type Description
thumb_entry ThumbnailEntry Data for the new thumbnail

AddGetVideoThumbnail

Add a thubnail to a video in the catalog.

long AddGetVideoThumbnail(ThumbnailEntry thumb_entry)

Parameters:

Name Type Description
thumb_entry ThumbnailEntry Data for the new thumbnail

Returns: Int64 - thumbnail id of added thumbnail


TagThumbs

Set a comma separated tag list to a list of thumbnails.

int TagThumbs(long[] thumb_list, string entered_keyword_string)

Parameters:

Name Type Description
thumb_list Int64[] array of the thumbnails to apply tag to
entered_keyword_string String Text of the tag. If tag does not exist it will be added.

Returns: Int32 - tag id of the last set thumbnail tag


GetThumbnailImageFromID

Return a jpeg byte blob for the given thumb id.

byte[] GetThumbnailImageFromID(long thumbnail_id)

Parameters:

Name Type Description
thumbnail_id Int64 Thumbnail id

Returns: Byte[] - Jpeg image data for thumbnail id


GetThumbnail

Get thumbnail fata including image.

ThumbnailEntry GetThumbnail(long thumbnail_id)

Parameters:

Name Type Description
thumbnail_id Int64 Thumbnail id

Returns: ThumbnailEntry - ThumbnailEntry


GetAllThumbnailTags

Return a list of all used thumbnail tags.

Tag[] GetAllThumbnailTags()

Returns: Tag[] - Array of tags


DeleteThumbnail

Delete a thumbnail from the catalog.

void DeleteThumbnail(long thumbnail_id)

Parameters:

Name Type Description
thumbnail_id Int64 Thumbnail id

GetThumbnailsForVideo

Get a list of all thumbnails for a given video.

Dictionary<long, ThumbnailEntry> GetThumbnailsForVideo(long video_file_id, bool include_image_data)

Parameters:

Name Type Description
video_file_id Int64 Video id
include_image_data Boolean true to include thumbnail image data with the query

Returns: Collections.Generic.Dictionary{Int64,ThumbnailEntry} - Dictionary mapping video id to thumbnail ids


GetThumbnailsIDsForVideo

Get a list of all thumbnails id for a given video.

long[] GetThumbnailsIDsForVideo(long video_file_id)

Parameters:

Name Type Description
video_file_id Int64 Video id

Returns: Int64[] - Array of thumbnail image IDs


GetAllCoverImages

Get all cover images in the catalog.

CoverImage[] GetAllCoverImages()

Returns: CoverImage[] - Array of cover images


GetCoverImagesForVideo

Get cover image for a given video.

CoverImage GetCoverImagesForVideo(long video_file_id)

Parameters:

Name Type Description
video_file_id Int64 Video id

Returns: CoverImage - Cover


AddCompanionImages

Add companion images to a given video file id.

void AddCompanionImages(long video_file_id, string[] image_paths)

Parameters:

Name Type Description
video_file_id Int64 Video id
image_paths String[] Array of paths to the companion images to add

AddCompanionImage

Add a companion images to a given video file id and return the companion image id.

long AddCompanionImage(long video_file_id, string image_path, string server_path)

Parameters:

Name Type Description
video_file_id Int64 Video id
image_path String Path to the companion image
server_path String Server path to the companion image

Returns: Int64 - Companion image ids


RemoveVideoCompanionImage

Remove companion image and delete file on server

void RemoveVideoCompanionImage(long companion_image_id)

Parameters:

Name Type Description
companion_image_id Int64 Companion image id

GetCompanionImageID

Get video companion image id for a given image file path.

long GetCompanionImageID(long video_file_id, string escaped_path)

Parameters:

Name Type Description
video_file_id Int64 Video id
escaped_path String Path to the video we need the companion image id for

Returns: Int64 - Companion image ids


GetVideoFileIDForCompanionImage

Get VideoFileID for a companion image path in the catalog.

long GetVideoFileIDForCompanionImage(string path)

Parameters:

Name Type Description
path String path to the companion image id

Returns: Int64 - return first video id associated with a companion image path


SetCoverImages

Set cover images for a video, -1 for no cover.

void SetCoverImages(long video_file_id, long front_cover_id, long back_cover_id)

Parameters:

Name Type Description
video_file_id Int64 Video id
front_cover_id Int64 Front cover id
back_cover_id Int64 Back cover id

UpdateCompanionImagePath

Change a companion image path, will affect all companion images with the source path. Note that this will not change the actual resource. i.e. the companíon image file will not be moved.

bool UpdateCompanionImagePath(string Source_path, string Destination_path)

Parameters:

Name Type Description
Source_path String Path we want to update
Destination_path String New path.

Returns: Boolean - return true if any path was updated


SetCompanionImagePath

Set a new companion image path.

void SetCompanionImagePath(long image_id, string new_path)

Parameters:

Name Type Description
image_id Int64 limage id
new_path String new path for the companion image

GetVideoCompanionImage

Get a specific video companion image given its id.

VideoCompanionImage GetVideoCompanionImage(long companion_id)

Parameters:

Name Type Description
companion_id Int64 Companion image id

Returns: VideoCompanionImage - Companion image or null


GetVideoCompanionImages

Get all video companion images for a video.

VideoCompanionImage[] GetVideoCompanionImages(long video_file_id)

Parameters:

Name Type Description
video_file_id Int64 Video id

Returns: VideoCompanionImage[] - Array of VideoComapnionImage


GetAllVideoCompanionImages

Get all video companion images.

VideoCompanionImage[] GetAllVideoCompanionImages(int limit, bool random)

Parameters:

Name Type Description
limit Int32 Number of max items to return. -1 for no limits.
random Boolean Get random entries given the limits or simply return in random order

Returns: VideoCompanionImage[] - Array of VideoComapnionImage


DeleteImageCompanionFile

Remove all companion files with the given path from the catalog.

void DeleteImageCompanionFile(string file_path)

Parameters:

Name Type Description
file_path String Path to the companion image to use

RemoveImageFile

Remove an image as companion and covers from a video.

void RemoveImageFile(long video_file_id, long image_id)

Parameters:

Name Type Description
video_file_id Int64 Video id
image_id Int64 limage id

CreateArchiveMedia

Create a new archive media and return the handle to it

int CreateArchiveMedia(string title, string description, string device_identifier, string device_root)

Parameters:

Name Type Description
title String Title of the new archive media
description String description of the new archive media
device_identifier String device_identifier of the new archive media
device_root String device_root of the new archive media

Returns: Int32 - archive id or negative if the creation fails.


DeleteArchive

Delete an archive and remove the tag from all archived videofiles

void DeleteArchive(int archive_id)

Parameters:

Name Type Description
archive_id Int32 archive id

UpdateArchiveMedia

Update a current archive media

void UpdateArchiveMedia(int archive_id, string title, string description, string device_identifier, string device_root)

Parameters:

Name Type Description
archive_id Int32 archive id
title String Title
description String Description
device_identifier String device identifier for the archive media
device_root String Root folder on the archive media

GetArchive

Get an archive given an archive handle

Archive GetArchive(int archive_id)

Parameters:

Name Type Description
archive_id Int32 archive id

Returns: Archive - Archive


GetArchives

Get a list of all archives in catalog

Archive[] GetArchives()

Returns: Archive[] - Array ofarchives.


GetArchivesForVideo

Get a list of all archives where the video can be found.

int[] GetArchivesForVideo(long video_file_id)

Parameters:

Name Type Description
video_file_id Int64 Video id

Returns: Int32[] - Array of archive ids.


ArchiveVideo

Put a video in an archive.

void ArchiveVideo(long video_file_id, int archive_id)

Parameters:

Name Type Description
video_file_id Int64 Video id
archive_id Int32 Archive id

GetAllTagNames

get a list of all tags used

string[] GetAllTagNames()

Returns: String[] - Array of string with the tags used in the catalog.


GetGenres

Get a list of all genres in the catalog.

VideoGenre[] GetGenres()

Returns: VideoGenre[] - Array of generes in the catalog


RenameGenre

Rename a genre in the catalog.

void RenameGenre(string from, string to)

Parameters:

Name Type Description
from String
to String

GetNofVideos

Return the number of videos in the catalog.

long GetNofVideos()

Returns: Int64 - Number of videos in the catalog


GetNofActors

Return the number of actors in the catalog.

long GetNofActors()

Returns: Int64 - Number of actors in the catalog


GetNofCompanionImages

Return the number of companion images in the catalog.

long GetNofCompanionImages()

Returns: Int64 - Number of companion images in the catalog


GetVideoTagUse

Return the number of uses for a specific tag.

long GetVideoTagUse(int tag_id)

Parameters:

Name Type Description
tag_id Int32 id of the tag

Returns: Int64 - Number of uses for a tag text


GetThumbTagUse

Return the number of uses for a specific tag.

long GetThumbTagUse(int tag_id)

Parameters:

Name Type Description
tag_id Int32 video tag id of the tag

Returns: Int64 - Number of uses for a tag text


GetActorTagUse

Return the number of uses for a specific tag.

long GetActorTagUse(int tag_id)

Parameters:

Name Type Description
tag_id Int32 actor tag id of the tag

Returns: Int64 - Number of uses for a tag text


GetVideosInBin

Get a list of all videos in a collection. Will not return thumbnail data

VideoFileEntry[] GetVideosInBin(long bin_id)

Parameters:

Name Type Description
bin_id Int64 id of the bin to get videos for

Returns: VideoFileEntry[] - Array of videos in the bin


GetBinsInBin

Get a list of all collections in a collection

Bin[] GetBinsInBin(long bin_id)

Parameters:

Name Type Description
bin_id Int64 id of the bin to get bins for

Returns: Bin[] - Array of Bins


AddVideoToBin

Set the bin a video is in.

void AddVideoToBin(long video_file_id, long bin_id)

Parameters:

Name Type Description
video_file_id Int64 video if to add to the bin
bin_id Int64 id of the bin we want to add videos to

RemoveVideoFromBin

Remove a video from a bin. Note that a video can be in more than one bin.

void RemoveVideoFromBin(long bin_to_remove_from, long video_to_remove)

Parameters:

Name Type Description
bin_to_remove_from Int64 bin id of the bin we remove videos from
video_to_remove Int64 video id to be removed from the bin. The video is still in the catalog

RemoveBin

Remove a bin from the catalog. The caller is responsible for removing videos from the bin if there are any before the bin is removed.

void RemoveBin(long bin_to_remove)

Parameters:

Name Type Description
bin_to_remove Int64 bin to remove from the catalog

CreateBin

Create a new video collection.

Bin CreateBin(string label, long parent, uint color, VideoQuery smart_bin_query)

Parameters:

Name Type Description
label String Name of the new bin
parent Int64 parent bin id or -1 if no parent
color UInt32 bin to remove from the catalog
smart_bin_query VideoQuery if this is a smart bin this is the video search

Returns: Bin - Return newly created bin


SetBinProperty

Set a property of a bin

void SetBinProperty(long bin_id, string property_name, string value)

Parameters:

Name Type Description
bin_id Int64 id of the bin we want to set a property to
property_name String name of the property. (Parent,Label, Color, Query)
value String new value of the property

SetBinQuery

Set query to a bin.

void SetBinQuery(long bin_id, VideoQuery smart_bin_query)

Parameters:

Name Type Description
bin_id Int64 ID of bin
smart_bin_query VideoQuery if this is a smart bin this is the video search

GetBinQuery

Get a smart query for a bin, null if this is no a smart bin.

VideoQuery GetBinQuery(long bin_id)

Parameters:

Name Type Description
bin_id Int64 ID of bin

Returns: VideoQuery - Return query


GetAllBins

Get a list of all video keywords

Bin[] GetAllBins()

Returns: Bin[] - Array of Bins


SetVideoClip

Create or Update a clip

int SetVideoClip(VideoClip clip)

Parameters:

Name Type Description
clip VideoClip Update data for a clip using the ID in the struct. if ID is -1 the clip will be created

Returns: Int32 - clip_id of the updated or create clip, -1 if failed


GetVideoClip

Get a video clip

VideoClip GetVideoClip(int clip_id)

Parameters:

Name Type Description
clip_id Int32 id of the video clip

Returns: VideoClip - videoclip data


DeleteVideoClip

Delete a video clip from the catalog. A clip is unique to a playlist and the same clip is never part of more than one playlist

void DeleteVideoClip(int clip_id)

Parameters:

Name Type Description
clip_id Int32 id of the video clip

CreateVideoPlaylist

Create a new video playlist

long CreateVideoPlaylist(string name)

Parameters:

Name Type Description
name String Name of the playlist

Returns: Int64 - playlist id


GetAllVideoPlaylists

Get all video playlists

VideoPlaylist[] GetAllVideoPlaylists()

Returns: VideoPlaylist[] - Array of playlists


DeletePlaylist

Delete a playlist from the catalog

void DeletePlaylist(long playlist_id)

Parameters:

Name Type Description
playlist_id Int64 Playlist id

SetClipToPlaylist

Create a new video playlist

void SetClipToPlaylist(long playlist_id, int index, int clip_id)

Parameters:

Name Type Description
playlist_id Int64 playlist identifier
index Int32 Order of the clip in the playlist
clip_id Int32 Clip to set to the playlist

GetPlaylistClip

Get one video clip in a playlist given its order

VideoClip GetPlaylistClip(long playlist_id, int index)

Parameters:

Name Type Description
playlist_id Int64 playlist identifier
index Int32 zero based index of clip

Returns: VideoClip - Playlist at the index


RemovePlaylistClip

Remove a playlist from the catalog

void RemovePlaylistClip(long playlist_id, int clip_id)

Parameters:

Name Type Description
playlist_id Int64 playlist identifier
clip_id Int32 id of clip to remove

GetPlaylistClipIDs

Get all clip ids for a playlist

int[] GetPlaylistClipIDs(long playlist_id)

Parameters:

Name Type Description
playlist_id Int64 playlist identifier

Returns: Int32[] - Array of all video clip ids


SetSubtitle

Create or update a subtitles for a video

long SetSubtitle(Subtitle subtitle)

Parameters:

Name Type Description
subtitle Subtitle Subtitle struct, if id is -1 a new subtitle will be created

Returns: Int64 - Id of the subtitle


GetSubtitle

Get a specific subtitle given an id

Subtitle GetSubtitle(long subtitle_id)

Parameters:

Name Type Description
subtitle_id Int64 subtitle identifier

Returns: Subtitle - a subtitle


GetAllSubtitles

Get all subtitles for a video

Subtitle[] GetAllSubtitles(long video_id)

Parameters:

Name Type Description
video_id Int64 video identifier

Returns: Subtitle[] - array of subtitles


RemoveSubtitle

Remove a subtitle from the catalog

void RemoveSubtitle(long subtitle_id)

Parameters:

Name Type Description
subtitle_id Int64 subtitle identifier

RemoveSubtitlesFromVideo

Remove all subtitles for a specific video

void RemoveSubtitlesFromVideo(long video_id)

Parameters:

Name Type Description
video_id Int64 video identifier

SearchSubtitlesFromString

Search subtitle for the search string

long[] SearchSubtitlesFromString(string search_string, long video_id)

Parameters:

Name Type Description
search_string String Text to search for in transcripts
video_id Int64 limit result to a specific vidoe, -1 to search all videos

Returns: Int64[] - array of subtitle ids or null


SearchSubtitlesFromString

Search subtitle for the search string

long[] SearchSubtitlesFromString(string search_string, long video_id)

Parameters:

Name Type Description
search_string String Text to search for in transcripts
video_id Int64 limit result to a specific vidoe, -1 to search all videos

Returns: Int64[] - array of subtitle ids or null