CMS + CMP/DAM + Graph
How to integrate Optimizely Content Management System with Optimizely Content Marketing Platform and Optimizely Graph.
Optimizely Content Management System (CMS) can fetch data from Optimizely Content Marketing Platform (CMP) asset metadata when integrated with Optimizely Graph. If you use CMP, you also have access to Optimizely Graph and can fetch metadata from it instead of relying on the CMP API.
The Graph integration provides better performance than using the CMP REST API to fetch meta data, and it also allows other use cases like querying for images, videos, renditions, folders and more.
Note
Starting in November 2024, you should use the Optimizely Graph-supported version of this integration for optimal performance.
The Graph integration require v2.0.0 or later of
EPiServer.Cms.WelcomeIntegration.UI
andEPiServer.Cms.WelcomeIntegration.Graph
Install and configure
- Install or Update the
EPiServer.Cms.WelcomeIntegration.UI
package to version 2.0.0 or later. - Install
EPiServer.Cms.WelcomeIntegration.Graph
. - Ensure there is
services.AddDAMUi()
call inStartup.cs
. - Add
services.AddDAMGraphIntegration();
call toStartup.cs
. - If you do not already have a CMS-to-Graph integration, then add this configuration in
appsettings.json
. You can keep theAppKey
,Secret
andSingleKey
as dummy values because they are not used by the DAM integration. If you already have Graph for CMS configured, leave the values as-is."Optimizely": { "ContentGraph": { "GatewayAddress": "https://cg.optimizely.com", "AppKey": "APPKEY", "Secret": "SECRET", "SingleKey": "SINGLE_KEY", } }
- The CMP+Graph integration uses a different schema and a separate
SingleKey
. Configure the following code inappsettings.json
.Or in"EPiServer": { "Cms": { "CMPGraph": { "SingleKey": "SINGLE_KEY_FROM_CMP" } } }
Startup.cs
.services.Configure<CMPGraphOptions>(options => { options.SingleKey = "SINGLE_KEY_FROM_CMP"; });
Getting the CMP Graph Single Key
If your CMP/DAM instance has Graph-enabled, you can find the key on the Misc tab under the Organization settings in CMP. The Single Key is the value of the
auth
query parameter of the URL listed under Content Graph Settings/DAM.If you do not see Content Graph Settings, contact Optimizely Support to enable it. Provide the name and SSO ID for your CMP instance (you can find the SSO ID under the General tab of the Organization settings.
Query Graph Data
The CMS+ CMP/DAM integration queries Optimizely Graph for metadata automatically, and you do not need to understand the schema or create your own GraphQL queries to use it. However, you have access to the Graph and can query it using your favorite GraphQL client. The following example lists images with a public Url
in the folder Hotels
.
Updated 8 days ago