merge

In Control Scripts, the root level instance of the object merge is the entry point from where you can query and change the way contexts are merged. It gives access to the template: the Print context with all its sections.
For more information about Control Scripts, see Control Scripts and Control Script API.
Some of the objects are also useful in Post Pagination Scripts; see Post Pagination Scripts and Post Pagination Script API.
For sample scripts, follow the links to the respective objects.

Field Type Description

channel

Channel

The final output channel: PRINT.

context Context The context rendered by this merge run.
Pagination Pagination Contains the total page count and sheet count of all sections in the Print context after pagination.
section Section

In Standard Scripts, this object defines the section that is being merged.

Note! In Control Scripts, merge.section is not available.

To retrieve any section in a Control Script, use: merge.template.contexts.ContextType.Section['Section name']; (for example: merge.template.contexts.PRINT.sections["Section EN"]).

In Post Pagination Scripts, only Print sections are available.

template Template This object contains the template and all of its contexts. It can be used to find out which contexts are available in the template, using merge.template.contexts (see context) and to manipulate the sections in those contexts (see section).