For each video, there must be a corresponding Sophora document. The configuration of the document type must either comply to the rules stated below, or the video document must be processed by a pre-processor script first. Every time the AVTool processes a video, the pre-processor script is called with the ISophoraDocument
node of the video document. The script can then change the node to match the rules used by the AVTool.
Table of Files
The video files that are available for a document have to be listed in a dynamic table. Each child node, representing a row in the table, has to have the name avtool:file
and has to be of type avtool-nt:file
. The following properties are supported:
avtool:format
(String): The video format of the file. The AVTool supports videos in different formats, e.g. MP4 hq, MP4 low, Windows Media. The configuration of the YouTube channel contains a sorted list of formats that are enabled for this channel. The AVTool will go through this list of formats in the given order and upload the first file that matches this format.avtool:sequence
(String): The name of the video sequence. This is usually the file name without the suffix. It is used as the file ID for the YouTube Content ID API.avtool:name
(String): The name of the file, including the suffix. May be a sub path inside the server folders.- avtool:targetPaths (String) multiple: The Paths that this file should be uploaded to.
- avtool:previousTargetPaths (String) multiple: The Paths that this file should be removed from (even on publication).
Property for YouTube Channel Selection
The AVTool supports multiple YouTube channels, with the restriction that each video document can only be associated with one channel at a time. The video document must contain a property through which one can choose a YouTube channel (the property can be configured under youtubeAccountPropertyName
in the mediaconfig.xml). Only videos with a specified YouTube channel are uploaded to YouTube. The property must be a string property containing the ID of a YouTube-Channel-Configuration document, which can be found in the Sophora Admin View. Usually, this property is configured as a Select Value property.
Properties for YouTube Video ID and Status Messages
After uploading a video to YouTube, the AVTool saves information about the upload into the video document. The data is appended as a yellow data with three string properties. The following information is saved into the document:
- The YouTube ID of the uploaded video.
- A result code message.
- An error message in case of errors.
The content of the result codes messages can be configured in the media configuration document (deskclientFeedbackErrTypeConf
). If nothing is configured, only the YouTube ID will be saved as yellow data.
Sticky Note for Upload Result
After a successful upload or if an error occurs, the AVTool adds a sticky note to the document. Thanks to that, the editor can easily see that the file transfer is no longer running in the background. There are two types of sticky notes that may show up: one for successful transfers, and one for errors. Each type has its own color, which can be configured in the global configuration document as avtool.successColor
or avtool.errorColor
. The defaults are "129,199,132" (green) and "229,115,115" (red) respectively.
You can disable sticky notes by setting feedback.stickyNotes.disabled = true
in the properties file.
Pre-Publishing Workflow
If you wish to use the pre-publishing workflow for video documents, the video document type must have the mixin sophora-mix:prePublishRequired
. If that is the case, the video document will go into the pre-published state when it is published by a user using the DeskClient. The AVTool will then upload the video to YouTube and, once it is finished, finish the publication. If the mixin is not configured, the video is uploaded when the document is published as well, but the document will directly go into the published state.