Update a content widget content configuration object. (See API authentication for general information how to use these APIs.)
Request
The request object is the configuration object you want to update (with the changes made). You are not allowed to change the 'siteGroupId'.
The fields 'lastUpdatedBy' and 'lastUpdatedAt' are set assigned by the system. If you provide values for these fields in the request, they are used for concurrency control (see Content widget content configuration object).
The fields createdBy and createdAt are set assigned by the system and cannot be changed.
The field description, if not provided, is kept from the existing object.
Response
The response object shows the fields that were updated and possibly some fields that were not changed.
Examples
$ cx.py /widget/content/update '{ "id": "74732be6b5b79f0953f6606870aad034369ed528", "description": "My very first widget content configuration" }'
{
"siteGroupId": "9222300742653756873",
"id": "74732be6b5b79f0953f6606870aad034369ed528",
"description": "My very first widget content configuration",
"lastUpdatedBy": "ivar.rummelhoff@cxense.com",
"lastUpdatedAt": "2013-08-21T11:00:41.619Z"
}
$ cx.py /widget/content/update '{ "id": "74732be6b5b79f0953f6606870aad034369ed528", "settings": { "type": "recs", "siteIds": [ "9222300742735526873" ], "matchingMode": { "contextual": 9, "trend": 1, "behavioral": 2 } } }'
{
"siteGroupId": "9222300742653756873",
"id": "74732be6b5b79f0953f6606870aad034369ed528",
"description": "My very first widget content configuration",
"lastUpdatedBy": "ivar.rummelhoff@cxense.com",
"lastUpdatedAt": "2013-08-21T12:31:06.316Z",
"settings": {
"type": "recs",
"siteIds": [
"9222300742735526873"
],
"matchingMode": {
"contextual": {
"weight": 9
},
"behavioral": {
"weight": 2
},
"trend": {
"weight": 1
}
},
"resultFields": [
"url",
"title",
"description",
"dominantthumbnail"
],
"maxAge": 129600
}
}