Input Parameters
- Last Updated: April 14, 2026
- 2 minute read
- MarkLogic Server
- Version 11.0
- Documentation
The content parameter is an object containing data about the original input document. The content parameter has the following form:
{ uri: string,
value: node}
The type of node your function receives in content.value depends on the input document type, as determined by mlcp from the -document_type option or URI extension. For details, see How mlcp Determines Document Type. The type of node your function returns in the value property should follow the same guidelines.
The table below outlines the relationship between document type and the node type your transform function should expect (or return).
Document Type |
“value” node type |
|---|---|
XML |
document-node |
JSON |
document-node |
BINARY |
binary-node |
TEXT |
text-node |
The context parameter can contain context information about the insertion, such as any transform-specific parameters passed on the mlcp command line. The context parameter has the following form:
{ transform_param: string, collections: [ string, ... ],
permissions: [ object, ... ],
quality: number,
temporalCollection: string}
The following table describes the properties of the input parameters in more detail:
Parameter |
Description |
|---|---|
content |
|
|
The collections, permissions, quality, and temporal collection metadata from the mlcp command line is made available to your function so that you can modify or replace the values. If a given metadata category is not specified on the command line, the property will not be present in the context object.