This section describes how to structure configuration that is to be imported in a ZIP file or in JSON format (remote access only).
You must import configuration in a ZIP file when you are accessing Guided Search locally (that is, from the machine where Guided Search is installed) or remotely (using REST APIs with ZIP format).
To structure the configuration that you import in a ZIP file, follow these steps:
Download in a ZIP file the configuration of the resource that you want to modify.
Open the downloaded ZIP file and extract its contents. The contents will consist of
_.json
files and directories.Important: Do not delete files or directories from the exported ZIP file, or add files or directories to it. Do not move any
_.json
files into or out of the directories.Edit the configuration in the extracted
_.json
files as your application requires.ZIP up all the contents of the downloaded ZIP, including all directories and
_.json
files.
You must import configuration in a single
_.json
file when you are accessing Guided Search
remotely through REST APIs using JSON format.
The content of the _.json file depends on the resource that the imported configuration is to modify or replace, and on the HTTP method that you are using to import the configuration. The following table summarizes the HTTP methods that you can use to import configuration in JSON format.
HTTP Method |
Description |
Examples |
|
Creates configuration. |
To create a
Note: The configuration created can include child
objects of the object specified in the URL. Thus, the example above can be used
to create a
|
|
Overwrites configuration. |
To overwrite a
Note: The input to the PUT request can include
configuration of the child object ( To overwrite a
|
|
Modifies configuration. |
To modify attribute values in a
Note: PATCH cannot modify child objects of the object
specified in the URL. Thus, to modify a
|
Note the following differences between the HTTP methods that are supported for ZIP format and for JSON format:
JSON format supports two methods that are not supported for ZIP format: PUT and PATCH. These methods cannot be used with ZIP format.
With ZIP format, the POST method creates configuration, overwriting any existing configuration. With JSON format, POST can create but not overwrite; to overwrite configuration in JSON format, use the PUT method.