Merge fields, probe endpoint, transformations and other updates

The latest update to Shotstack includes merge fields to create reusable templates. Transformations allow you to alter an assets appearance. The probe endpoint is now general available and we have added other improvements and bug fixes.

Merge fields

Merge fields make it easy to create reusable video and image templates. Think of them as mail merge for video, or a templating language.

You can add placeholder values to your edits and replace them at render time with key/value pairs. For example, replace a users name in a block of HTML like this:

"html": "<p>Welcome {{ FIRST_NAME }}"

with a merge field like this:

{
"find": "FIRST_NAME",
"replace": "Melissa"
}

In the real estate template below, the images, text, fonts and overlay animations all use merge fields.

To get started with merge fields have a look at the merging data documentation.

You can check out how the template above was made in Postman.

Transformations

We have added a transformations feature for manipulating assets. Rotate, skew and flip video, images and text to create new layouts and effects.

The flip transformation was used to create the mirror video effect below.

You can view the JSON in Postman and explore more in the API reference.

Probe endpoint

If you want to query information about a video or image file then the probe endpoint is what you need. Lookup metadata such as duration, framerate, width, height and file type of any media file on the internet.

The probe endpoint is useful when working with user generated content or 3rd party footage. Read more in the documentation.

Looping gifs

A simple one - gif's can now be set to loop or play once. Just set the repeat parameter to true or false. Check the output settings for more details.

Other updates and bug fixes

You can now remove the timeline from the GET status response. For some users the timeline payload is several kilobytes and it makes no sense to return the timeline if it is not needed.

Add data=false to the get render status querystring to remove it from the response. This will soon become the default behavior. If you do want the timeline in the response, explicitly set data=true.

We have improved the error message for failed downloads. The message now tells you which URL failed.

Finally we now support larger timeline payloads up to 390kb.

Jeff Shillitto

BY JEFF SHILLITTO
10th November, 2021