getContents

Retrieves a list of published content from an enhanced CMS workspace for an enhanced LWR site, non-enhanced LWR site, or Aura site in Experience Cloud.

To get Salesforce CMS content from a non-enhanced CMS workspace for an Aura or non-enhanced LWR site, use the lightning/cmsDeliveryApi module listContent wire adapter instead.

With channelId parameter:

With siteId parameter:

  • channelOrSiteId—(Required) The ID for the enhanced LWR site on which you want to use CMS content.
  • contentKeys—The content keys for the CMS content that you want to use on your enhanced LWR site.
  • managedContentIds—The managed content IDs for the CMS content that you want to use on your enhanced LWR site.
  • contentTypeFQN—Fully qualified name of the managed content type.
  • referenceDepth—An integer 0–3 specifying the depth of references.
  • page—Number of the page you want returned. Starts at 0. If you don’t specify a value or if you specify 0, the first page is returned.
  • pageSize—Specifies the number of items per page. Valid values are from 1 through 250. If unspecified, the default size is 25.
  • includeContentBody—Specifies whether to return the content body (true) or summaries of references (false) in the response body. If unspecified, the default value is false.