Create or Update Publication Configuration Item
Creates or updates the requested configuration item for the specified publication.
If it changes visibility of the language (item_name = "visible"), the visibility will be also updated in the sitemap. The request will fail if the specified publication does not exist, or if the publication does not have the specified language.
Request
URI: /v2/content/{pub}/config/{item_name}
HTTP Method: PUT
- Accept:
[application/json] OR [application/xml] - Content-Type:
[application/json] OR [application/xml]
- pub: publication id
- item_name: configuration item name
- XML:
<configitem name="title" value="LiveContent Reach Documentation"/> - JSON:
{"name":"title", "value":"LiveContent Reach Documentation"}
Response
- XML:
<result message="Action = add config item" messageKey="Action = add config item" status="SUCCESS" statusCode="0"> <info xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="configurationItemModel" name="title" value="LiveContent Reach Documentation"/> </result> - JSON:
{"statusCode":0, "messageKey":"Action = add config item", "message":"Action = add config item", "status":"SUCCESS", "info":[{"name":"title", "value":"LiveContent Reach Documentation"}]}
- XML:
<result message="Failed, Action add config item with name: test" messageKey="Failed, Action add config item with name: test" status="FAIL" statusCode="500"/> - JSON:
{"statusCode":500, "messageKey":"Failed, Action add config item with name: title", "message":"Failed, Action add config item with name: title", "status":"FAIL", "info":[]}
Permissions
"Manage publications"
Example
Request:
PUT http://example.corp:8080/LiveContent/v2/content/LiveContentDoc/config/shortdesc
Accept: applicaton/xml
Content-Type: applicaton/xml
Request Body: <configitem name="shortdesc" value="This publication about installation, maintenance and usage of the API in SDL LiveContent Reach"/>
Response:
<result message="Action = add config item" messageKey="Action = add config item" status="SUCCESS" statusCode="0"> <info xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="configurationItemModel" name="shortdesc" value="This publication about installation, maintenance and usage of the API in SDL LiveContent Reach"/> </result>