Skip to main content
Skip table of contents

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:


CODE
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 and providerResourceId
  • resourceRef – the entity (editorial or content group) being linked to the node.
    • Either:
      • id – the ID of the editorial/content group, or
      • Both providerId and providerResourceId
    • type – the type of the entity, one of:
      • editorialContent
      • contentGroup
  •  Either:
    • id – the ID of the node link, or
    • Both providerId and providerResourceId
  • 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 date
  • end – node link validity end date
  • previewDate – preview date for use by client apps
  • technicalType – the technical type of the node link
  • metadataSet – a set of locale-specific metadata blocks, each of which has:
    • locale* – the locale for the metadata element. If locale is set to none, the metadata block that it applies to is the default – it is the one that is used if there is no metadata 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.

CODE
{
    "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.

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.