Why configure sync
Section titled “Why configure sync”Content synchronization connects your CMS editorial workflow to the Graph delivery layer. While basic sync works automatically after Graph setup, configuring it properly ensures reliable delivery, fast updates, and the ability to diagnose issues when they arise.
Read Content Synchronization Pipeline to understand the architecture before configuring.
Step 1: Verify sync credentials
Section titled “Step 1: Verify sync credentials”Confirm that your Graph credentials are correctly configured in the CMS. The sync service uses the AppKey and Secret for authenticated communication with Graph.
{
"Optimizely": {
"ContentGraph": {
"GatewayAddress": "https://cg.optimizely.com",
"AppKey": "your-app-key",
"Secret": "your-secret-key",
"SingleKey": "your-single-key",
"AllowSendingLog": true
}
}
} Step 2: Run the initial full sync
Section titled “Step 2: Run the initial full sync”Before incremental sync can work, Graph needs a baseline index of all published content. Trigger the initial full sync through the CMS admin interface or the API.
# Trigger a full content synchronization
curl -X POST \
https://cg.optimizely.com/api/content/v3/sync \
-H 'Content-Type: application/json' \
-H 'Authorization: Basic {base64(AppKey:Secret)}' \
-d '{"action": "full"}' Via CMS Admin UI:
- Navigate to CMS Admin > Scheduled Jobs
- Find “Content Graph Content Synchronization”
- Click Start Manually
The initial sync duration depends on content volume. Expect roughly 1 minute per 1,000 content items.
Step 3: Verify incremental sync
Section titled “Step 3: Verify incremental sync”After the full sync completes, test that incremental sync works for new publishes.
- Publish a new page or update an existing page in the CMS
- Wait 5-10 seconds
- Query Graph for the updated content
query VerifySync {
Content(
where: {
_metadata: {
published: { gte: "2026-03-25T00:00:00Z" }
}
}
orderBy: { _metadata: { published: DESC } }
limit: 5
) {
items {
_metadata {
key
types
published
url { default }
}
}
total
}
} If your recently published content appears in the results, incremental sync is working correctly.
Step 4: Configure sync logging
Section titled “Step 4: Configure sync logging”Enable sync logging to capture detailed information about sync operations. This is valuable for diagnosing issues in production.
{
"Optimizely": {
"ContentGraph": {
"AllowSendingLog": true
}
},
"Logging": {
"LogLevel": {
"Optimizely.ContentGraph": "Information"
}
}
} Set the log level to Debug temporarily when troubleshooting sync issues. Return it to Information for normal operation to avoid excessive log volume.
Step 5: Monitor sync health
Section titled “Step 5: Monitor sync health”Check the sync status endpoint regularly to ensure the pipeline is healthy.
curl -s \
https://cg.optimizely.com/api/content/v3/sync/status \
-H 'Authorization: Basic {base64(AppKey:Secret)}' \
| jq '.'
# Response includes:
# - lastSyncTime: timestamp of last successful sync
# - pendingItems: number of items waiting to sync
# - status: "healthy" | "syncing" | "error" Set up alerts when pendingItems stays above zero for more than 5 minutes or when status is error.
Troubleshooting sync issues
Section titled “Troubleshooting sync issues”| Symptom | Cause | Resolution |
|---|---|---|
| No content in Graph after full sync | Invalid credentials | Verify AppKey and Secret in configuration |
| Content appears in Graph but stale | Incremental sync not firing | Check CMS event system; restart CMS application |
| Some content types missing | Types not registered with Graph | Ensure content types have the correct attributes and run a full resync |
| Sync job completes but content missing | Content is in Draft status | Only Published content syncs to Graph |
| Slow full sync performance | Large content volume | Schedule full syncs during off-peak hours |