
Set or modify MarkLogic REST API instance configuration properties.
| URL Parameters | |
|---|---|
| format? |
You can use this parameter as a fallback to the request Content-type
header. The Content-type header takes precedence
over format in most cases; for details, see
Controlling Input and Output Content Type in the REST Application Developer's Guide.
Accepted values: json or xml.
|
| Request Headers | |
|---|---|
| Content-Type? |
The MIME type of the data in the request body, one of
application/xml or application/json.
|
Upon success, MarkLogic Server responds with a 204 (Updated) status.
rest-admin role, or the
following privileges:
http://marklogic.com/xdmp/privileges/rest-admin
http://marklogic.com/xdmp/privileges/rest-writer
http://marklogic.com/xdmp/privileges/rest-reader
For more details, see Configuring Instance Properties in the REST Application Developer's Guide.
$ cat ./settings
<properties xmlns="http://marklogic.com/rest-api">
<debug>false</debug>
</properties>
$ curl --anyauth --user user:password -X PUT -d@'./settings' -i \
"Content-Type: application/xml" \
http://localhost:8000/v1/config/properties
==> MarkLogic Server updates the settings for the properties named
in the settings file.
HTTP/1.1 204 Updated
Server: MarkLogic
Content-Type: text/plain; charset=UTF-8
Content-Length: 5
Connection: close
$ cat ./settings
{"validate-options":"false"}
$ curl --anyauth --user user:password -X PUT -d@'./settings' -i \
"Content-Type: application/json" \
http://localhost:8000/v1/config/properties
==> MarkLogic Server updates the settings for the properties named
in the settings file.
HTTP/1.1 204 Updated
Server: MarkLogic
Content-Type: text/plain; charset=UTF-8
Content-Length: 5
Connection: close
Stack Overflow: Get the most useful answers to questions from the MarkLogic community, or ask your own question.