Updating a node link by ID
Request
To update a node link (that is, an entity that allows you to associate multiple nodes with a single editorial content or content group) specified by its ID, send a PUT request to:
https://<host>:<port>/metadata/content/v1/nodeLinks/{id}
Headers
Content-Type: application/json
Mandatory arguments
id
– the ID of the node link is mandatory and it should be passed as path parameter.
Other arguments
All of the following arguments are part of the request body:
nodeRefSet
- list of node references that identify the the nodes that the link applies to.nodeRef
– the node the node link applies to. Either:id
– the ID of the node, or- Both
providerId
andproviderResourceId
resourceRef
– the entity (editorial or content group) being linked to the node.- Either:
id
– the ID of the editorial/content group, or- Both
providerId
andproviderResourceId
type
– the type of the entity, one of:editorialContent
contentGroup
- Either:
- Either:
id
– the ID of the node link, or- Both
providerId
andproviderResourceId
publishToEndUser
– flag to indicate to a client app whether it should display the content to the user or not (true or false)start
– node link validity start dateend
– node link validity end datepreviewDate
– preview date for use by client appstechnicalType
– the technical type of the node linkmetadataSet
– a set of locale-specificmetadata
blocks, each of which has:locale*
– the locale for themetadata
element. If locale is set to none, themetadata
block that it applies to is the default – it is the one that is used if there is nometadata
block for the user's locale.metadata*
– a block containing one or more key/value pairs in the following form:[{
"key": "<key_name>",
"value": "<value>"
}]
If there are any changes in nodeRefSet
as compared to the existing node link, the node link will be updated to include only the newly updated nodes, which replace the existing ones.
Example
A PUT request with this payload updates a node link with technicalType
to HD.
{
"technicalType": "HD"
}
Response
A successful request returns an HTTP 200 status.
A bad request returns an HTTP 400 status.
If the specified node link id does not exist, the request returns an HTTP 404 status.
See also
For full details of this API, see Content and Product Manager (CPM) API documentation: content v1.