The default channel ID of new email campaign items

Current version: 9.0

When you send an email campaign, the Email Experience Manager creates a new email campaign item and adds a channel ID to the campaign item.

By default, the channel is Email Marketing. You can change the default channel ID in the CampaignClassification.Channel setting in the Sitecore.EmailExperience.Core.config file.

RequestResponse
<!--The Channel Id associated with the campaign-->
<setting name="CampaignClassification.Channel" value="{DDAFB85B-1511-48B8-9374-2A8A1F371645}" />

For the value of this setting, use the item ID of the channel item that you want to use as the default.

Email Marketing channel showing the default channel ID.

When a recipient clicks a link in an email, Sitecore uses the channel ID in the campaign item to track the campaign.

Classification section for a New Campaign showing the channel ID.

You can read the channel ID in a campaign item using the Sitecore Taxonomy API:

RequestResponse
IDefinitionManager<ICampaignActivityDefinition> campaignDefinitionManager = ServiceLocator.ServiceProvider.GetService<IDefinitionManager<ICampaignActivityDefinition>>();
var campaignActivity = campaignDefinitionManager.Get(campaignId, CultureInfo.InvariantCulture);
var channelId = campaignActivity.ChannelUri.TaxonId;

Do you have some feedback for us?

If you have suggestions for improving this article,