简体   繁体   English

使用 CD 上的 Sitecore List Manager API

[英]Using Sitecore List Manager API on CD

In Sitecore 10.1 we have a custom submit action that creates a new contact and adds it to a specific list based on some business conditions.在 Sitecore 10.1 中,我们有一个自定义提交操作,可以创建一个新联系人并将其添加到基于某些业务条件的特定列表中。 However we found that the List Manager API is not working on CD, is there a way to enable it or alternative way to add a contact to a list from CD?但是我们发现列表管理器 API 在 CD 上不工作,有没有办法启用它或从 CD 将联系人添加到列表的替代方法? Why its been disabled?为什么它被禁用了? https://doc.sitecore.com/xp/en/developers/101/sitecore-experience-manager/the-list-manager-api.html https://doc.sitecore.com/xp/en/developers/101/sitecore-experience-manager/the-list-manager-api.html

Sitecore stores contact lists as marketing definitions. Sitecore 将联系人列表存储为营销定义。 You can access contact lists programmatically through the List Manager API only on the CM instance, you can't use the List Manager API on CD instances because the List Manager application is disabled in this case.您只能在 CM 实例上通过 List Manager API 以编程方式访问联系人列表,不能在 CD 实例上使用 List Manager API,因为在这种情况下 List Manager 应用程序被禁用。 You have to use the Email Experience Manager Client API to manage subscriptions to lists in the List Manager.您必须使用Email Experience Manager Client API来管理对列表管理器中列表的订阅。

Use the Subscribe() method in the ClientAPIService class, Sitecore.EmailCampaign.Cd.Services.ClientAPIService , to handle subscribes to your list.使用ClientAPIServiceSitecore.EmailCampaign.Cd.Services.ClientAPIService中的Subscribe()方法来处理对您的列表的订阅。 More details about how to use the EXM Client API for Sitecore version 10.1 you can find [here][1] .有关如何使用 Sitecore 版本 10.1 的 EXM 客户端 API 的更多详细信息,请参见[here][1]

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM