Thumbnails Set

Similar to thumbnail capture, but using the thumbnailset output allows multiple thumbnail images at distinct times to be captures in a single request.

<?xml version="1.0"?>
<query>
    <userid>[UserID]</userid> {/* required */}
    <userkey>[UserKey]</userkey> {/* required */}
    <action>[Action]</action> {/* required */}
    <source>[SourceFile]</source> {/* required */}
    <format>
        <output>thumbnailset</output>
        <thumbnail>
            <time>[Time]</time>
            <width>[Width]</width>
            <height>[Height]</height>
            <quality>[Quality]</quality>
            <file_extension>jpg</file_extension>
            <keep_aspect_ratio>[yes|no]</keep_aspect_ratio>
            <scale_mode>[pad|stretch|fit|cover|center]</scale_mode>
            <allow_upscale>[yes|no]</allow_upscale>
            <size_divisible_by>[N]</size_divisible_by>
            <destination>[DestinationURL]</destination>
        </thumbnail>
        {/* Multiple thumbnails may be included */}
        <thumbnail>
           {/* thumbnail params */}
        </thumbnail>
        {/* Format params */}
    </format>
</query>
{
    "query": {
        "userid": "[UserID]", // required
        "userkey": "[UserKey]", // required
        "action": "[Action]", // required
        "source": "[SourceFile]", // required
        "format": {
            "output": "thumbnailset", // required
            "thumbnail": [
                {
                    "time": "[Time]",
                    "width": "[Width]",
                    "height": "[Height]",
                    "quality": "[Quality]",
                    "file_extension": "jpg",
                    "keep_aspect_ratio": "[yes|no]",
                    "scale_mode": "[pad|stretch|fit|cover|center]",
                    "allow_upscale": "[yes|no]",
                    "size_divisible_by": "[N]",
                    "destination": "[DestinationURL]"
                },
                {
                    // thumbnail params
                }
                // Multiple thumbnails params may be included
            ]
            // Format params
        }
    }
}
ParameterDescriptionAllowed ValuesDefault Value
timeSpecify the timestamp in seconds, percentage, or interval to capture thumbnails.hh:mm:ss.ms – once created thumbnail from given timestamp.
Example: <time>00:01:43.10</time>

N% – Positive percentage number from 1 to 100%.
Will generate thumbnail on N% of video duration.
Example: <time>4%</time>

N – Positive number greater than 0.01.
Will generate thumbnail on N second.
Example: <time>5.01</time>

N! – Positive integer number greater or equals to 1.
Will generate thumbnail on every N second.
Example: <time>5!</time>
5
widthSpecify the thumbnail width in pixels.Positive integernone
heightSpecify the thumbnail height in pixels.Positive integernone
qualityImage QualityPositive integer between 1 and 10083
file_extensionFile Extensionjpgnone
keep_aspect_ratioKeep image aspect ratioyes, nono
scale_modeSpecifies how the picture fits into width and height.
pad – keep the aspect ratio and pad the picture, same as keep_aspect_ratio=yes.
stretch – scale the picture to width and height, same as keep_aspect_ratio=no.
fit – keep the aspect ratio without padding: the image fits within width and height, e.g. a square video in 210x158 gives 158x158.
cover – keep the aspect ratio and fill width and height, the overflow is cropped evenly from both sides.
center – no scaling: the picture is centered, cropped or padded to width and height.
pad, stretch, fit, cover, centerpad when keep_aspect_ratio=yes, stretch when keep_aspect_ratio=no
allow_upscaleWhen no, the picture is never scaled up: a source smaller than the size keeps its size with fit and cover or is padded to the size without scaling with pad. Can't be used with stretch.yes, noyes
size_divisible_byWidth and height calculated by fit or from width or height only are rounded to the nearest multiple of this value, never above the size.Even integer from 2 to 642
destinationThumbnail destinationValid URLnone