Runs a bulk update based on a uploaded file. The information will patch existing files and create new ones.
The service is intended to accept column based input with metadata being provided as parameters to the REST service call.
Each line in the comma-separated values (CSV) file is defining one document. If it exists, it will be patched, if not it will be created.
Only values of existing properties and existing sections will be replaced. In case a property name or section title is encountered that cannot be matched to an existing property or section, the referenced document is not updated.
Parameters
The following parameters are supported.
doctype
The identifier of the doctype for all documents described in the CSV file.
space-key
The key to the space where the new document will be stored.
If the space key is specified it will be a constraint on searching the document. In case there are two documents with the same name and doctype, the space key can be used to identify the intended document.
location
The location within the space that defines the parent page.
Either provide
- the title of the page (not the name of the document),
- the page identifier surrounded by curly braces (e.g.
{123456}
, the value of space-key
is not taken into account in this case), or - the keyword
{homepage}
(to store the document to the doctype's homepage).
If the page title starts with a curly brace ({
) and ends with one (}
), you need to escape it with a backslash ( \
) as in \{My Page Title}
.
section-names
A comma-separated list of names used as column headers in the CSV file that refer to sections.
Every column header not found in this list is considered to be a property.
new-version
Flag to control whether a new version should be created. If set to false
, the document is saved without creating a new version. Defaults to true
to create a new version.
The parameter is available since version 1.2.