Contentful is a headless content management system (CMS) platform that allows users to create, manage, and distribute content across various digital platforms in a flexible and API-first approach.
With the Contentful connector, you can manage content within the Contentful platform while managing personalization logic on Dynamic Yield. When you create server-side campaigns in Experience OS, you simply select the content that you previously created in your Contentful CMS.
Implement the integration
1. Activate the connector:
- In the Experience OS store, go to Contentful › Learn More and then click Install.
The Web Personalization Extensions tab appears. - Click the status button and select Activate.
2. Configure the connector:
- Space ID: The ID of the Contentful space to sync with.
- Environment ID: The ID of the Contentful environment to sync with.
- content_type_uid: The ID of the content type to sync with Dynamic Yield and use in your Dynamic Yield campaigns.
- Content Delivery API Access Token: Your Contentful API key.
Use the Preview Entries panel to ensure that your space, environment, and content IDs are correct.
3. Save the configuration. You're ready to create campaigns with Contentful entries.
Create variations with Contentful entries
The integration adds a Contentful Entry ID variable type to your templates and variations in the following campaign types:
- Web Personalization: API Custom Code and API Recommendations
- App Personalization: API Custom Code and API Recommendations
To use this variable in your variation or template:
- In the JSON tab, create a variable, and then change its type to Contentful Entry ID.
- In the Variables tab, in the Content ID field, search for Contentful entries by name or ID, and then select the content you want to use. The content ID is added to the JSON code.
The API response
When users are targeted with this variation, the API response includes the content ID. Use this information to create the reference between the Contentful content (such as images or texts) and your app front end.