Conversion matrix structure

The media matrix is a JSON array composed of a JSON configuration for each of its processing flows. Each flow has the following structure:

{
  "name": "FlowName",
  "priority": 100,
  "extensions": [
   "extension_1",
   "extension_2"
  ],
  "flow": {
   "tasks": {
     ...
    }
  },
  "output": {
   "location": "local",
   "renditions": {
    ...
   }
  }
 }

The following table describes the parameters of this JSON:

ParameterTypeDescription
nameStringProcessing flow name.
priorityIntegerPriority of the processing flow.
extensionsArray of stringsArray of file types to which the flow applies.
flowListList of tasks.
tasksListList of JSON-formatted processing tasks.
outputListConfiguration parameters of the output file.
locationStringLocation for the output.
renditionsListList of JSON-formatted rendition links.

Processing task parameters

The tasks parameter contained in flow is a list of task objects, each following the structure:

"[task_name]": {
 "property_1": value_1,
 "property_2": value_2,
 ...
}

where [task_name] is the name of the processing task and the valid properties, listed on the following tabs, depend on the task type.

Store file

ParameterTypeDescription
contentdispositionStringDefines whether the file is an attachment or provided inline.
contenttypeStringContentType/MimeType for the output file.
inputStringName of the property where the source file key is found.
outputStringName of the property to which the output file key is saved.
outputfileproviderStringThe name of the file provider where the output file is saved.
typeStringTask type.

Convert image

ParameterTypeDescription
clippingpathStringName of an embedded clipping path from an 8BIM image profile when more than one path is available. This applies the conversion to the selected pixels under the specified path only. If a clipping path is set, the extra conversion parameters are ignored.
colorprofileStringColor profile applied to the output image.
colorspaceStringColor space applied to the output image.
contentdispositionStringDefines whether the file is an attachment or provided inline.
contenttypeStringContentType/MimeType for the output file.
conversionparameterorderListOrder in which the ImageMagick parameters occur.
conversionparametersStringAdditional ImageMagick parameters to use in a command.
croppingStringLinked to imageresizeoptions parameter.
densityIntegerDPI used for the output image. Parameter required with ImageMagick.
embeddedpreviewprioritiesStringAn ordered, comma-separated list of previews. The processing agent checks for availability of these previews in the RAW file metadata. If a preview is available, the agent applies default image conversion to it to generate the target image. If none of the listed previews are available, the agent applies default image conversion to the original image instead.
heightIntegerHeight of the output image when resizing.
imagemagickexecutabletimeoutIntegerPeriod, in seconds, after which ImageMagick times out. The maximum permitted time-out for ImageMagick is 120 seconds.
imagemagickidentifyexecutabletimeoutIntegerPeriod, in seconds, after which the Identify application within ImageMagick times out.
imageresizeoptionStringMethod use to resize images.
inputStringName of the property where the source file key is found.
jpegcompressionIntegerQuality level of conversion when the output is a JPEG file.
keepbackgroundtransparencyBooleanDetermines whether existing transparency should be kept or when converting PDF to PNG.
multipageBooleanDefines whether only the first page or multiple pages of the file should have its renditions created.
outputStringName of the property to which the output file key is saved.
outputfileproviderStringThe name of the file provider where the output file is saved.
resizealgorithmStringAlgorithm use for cropping.
resizeforcropbehaviorStringLinked to imageresizeoptions parameter. Defines whether the image needs cropping or simple scaling.
resizelogoscalefactorDoubleLinked to imageresizeoptions parameter.
targetextensionStringExtension of the output file.
typeStringTask type.
widthIntegerWidth of the output image when resizing.

Convert video

ParameterTypeDescription
bitratepercentageIntegerDefines the quality of the rendition based on the original file.
contentdispositionStringDefines whether the file is an attachment or provided inline.
contenttypeStringContentType/MimeType for the output file.
conversionparametersStringAdditional ImageMagick parameters to use in a command.
heightIntegerHeight of the output video when resizing.
inputStringName of the property where the source file key is found.
lengthIntegerDuration of the output file, in seconds.
outputStringName of the property to which the output file key is saved.
outputfileproviderStringThe name of the file provider where the output file is saved.
numberofpreviewframesIntegerThe maximum number of frames from the video to use in the preview.
seekTimecodeThe time point in the video from which the rendition starts. For example, with a value of 5 the output file starts at the fifth second of the original file.
targetextensionStringExtension of the output file.
trimendTimecodeSpecific end point of a video you wish to extract (used for clipping feature).
trimstartTimecodeSpecific start point in a video you wish to extract (used for clipping feature).
typeStringTask type.
widthIntegerWidth of the output video when resizing.

Convert document

ParameterTypeDescription
contentdispositionStringDefines whether the file is an attachment or provided inline.
contenttypeStringContentType/MimeType for the output file.
extractcontentBooleanDetermines whether to use text from the document for full-text searches.
inputStringName of the property where the source file key is found.
lowresBooleanDefines whether the output file uses compression methods to reduce the file size.
outputStringName of the property to which the output file key is saved.
outputfileproviderStringThe name of the file provider where the output file is saved.
multipageBooleanDefines whether only the first page or multiple pages of the file should have its renditions created.
typeStringTask type.

Convert HTML

ParameterTypeDescription
contenttypeStringContentType/MimeType for the output file.
contentdispositionStringDefines whether the file is an attachment or provided inline.
inputStringName of the property where the source file key is found.
outputStringName of the property to which the output file key is saved.
outputfileproviderStringThe name of the file provider where the output file is saved.
typeStringTask type.

Create storyboard

ParameterTypeDescription
colorspaceStringColor space applied to the output image.
contenttypeStringContentType/MimeType for the output file.
contentdispositionStringDefines whether the file is an attachment or provided inline.
densityIntegerDPI use for the output image. Parameter required with ImageMagick.
inputStringName of the property where the source file key is found.
outputStringName of the property to which the output file key is saved.
outputfileproviderStringThe name of the file provider where the output file is saved.
seekthumb_widthIntegerWidth of the thumbnail when seeking in a video.
seekthumb_heightIntegerHeight of the thumbnail when seeking in a video.
seekthumb_amountIntegerNumber of frames used for seeking in a video.
storythumb_widthIntegerWidth of the thumbnail for the storyboard rendition.
storythumb_heightIntegerHeight of the thumbnail for the storyboard rendition.
storythumb_amountIntegerNumber of frames used for the storyboard rendition.
targetextensionStringExtension of the output file.
typeStringTask type.

Extracting clipping paths

ParameterTypeDescription
inputStringName of the property where the source file key is found.
outputStringName of the property to which the output file key is saved.
outputfileproviderStringThe name of the file provider where the output file is saved.
typeStringTask type.

Extract metadata

ParameterTypeDescription
contenttypeStringContentType/MimeType for the output file.
contentdispositionStringDefines whether the file is an attachment or provided inline.
inputStringName of the property where the source file key is found.
outputStringName of the property to which the output file key is saved.
outputfileproviderStringThe name of the file provider where the output file is saved.
typeStringTask type.

Extract vision data

ParameterTypeDescription
contentdispositionStringDefines whether the file is an attachment or provided inline.
contenttypeStringContentType/MimeType for the output file.
detailsStringTypes of content to analyze.
endpointStringSend a request to either the OCR endpoint for text recognition both to the Analyze endpoint for image features recognition.
featuresListFeatures to extract.
detectorientationBooleanDetermines whether the OCR feature detects the orientation of text.
inputStringName of the property where the source file key is found.
outputStringName of the property to which the output file key is saved.
outputfileproviderStringThe name of the file provider where the output file is saved.
minimumconfidenceDoubleThe minimum accuracy level for analysis.
typeStringTask type.

Extract video indexer data

ParameterTypeDescription
batchsizeIntegerDetermines the number of key frames in a single rendition.
contentdispositionStringDefines whether the file is an attachment or provided inline.
contenttypeStringContentType/MimeType for the output file.
imageformatStringOutput format for the storyboard and face renditions.
inputStringName of the property where the source file key is found.
outputStringName of the property to which the output file key is saved.
outputfileproviderStringThe name of the file provider where the output file is saved.
facethumbnailheightIntegerHeight for the face thumbnail renditions.
facethumbnailwidthIntegerWidth for the face thumbnail renditions.
keyframeheightIntegerHeight for the key frame renditions.
keyframewidthIntegerWidth for the key frame renditions.
qualityIntegerOutput quality as a percentage of the source file.
typeStringTask type.

Run external web task

ParameterTypeDescription
contentdispositionStringDefines whether the file is an attachment or provided inline.
contenttypeStringContentType/MimeType for the output file.
urlStringURL of the external task.
headersStringJSON containing web request headers.
inputStringName of the property where the source file key is found.
outputStringName of the property to which the output file key is saved.
outputfileproviderStringThe name of the file provider where the output file is saved.
parametersJSONJSON containing web request parameters.
longevityIntegerThe number of days in which the file is publicly available.
typeStringTask type.

The renditions parameter, contained in output, is a series of rendition link objects, objects, each with the following structure:

"[name]": {
 "initial": {
  "status": "pending"
 },
 "file": "massive",
 "properties": [
  "width",
  "height"
 ]
}

The following table describes the parameters of this JSON:

ParameterTypeDescription
[name]StringName of the output.
initialListList of initial parameters.
statusStringStatuses of the output.
fileStringName of the output file.
propertiesArrayArray of properties to store with the output file.
If you have suggestions for improving this article, let us know!