Hot answers tagged

6

We faced the same issue and raised Sitecore support ticket for the same and we get to know that if you try to hit from Postman, need to remove user-agent from postman headers like below - https://www.screencast.com/t/K0BiMxHv This was only happening on Sitecore 9.3, in Sitecore 9.0.2 it was working fine for us. Also, I wrote a blog about this you can check ...


4

Email Experience Manager(ExM) doesn't send and finish all things related to email immediately. Your code will put the email into an "automated message bus". And then your email will be sent. After sending of email, other tasks will be executed, e.g. update reporting database with data about the new email. It happens quickly, but not immediately. ...


2

Code below should do the trick. It gets contacts from xDB in batches of 200 and adds them to the list. Then returns the list. public async Task<List<Contact>> GetAllContacts() { var allContacts = new List<Contact>(); try { using (var client = SitecoreXConnectClientConfiguration.GetClient()) { var ...


2

You don't need to explicitly convert Sitecore.Tracking.Analytics.Contact to XConnect.Contact as this is done on session end where data collected by the tracker is converted. You can take a look at the conversion pipelines described here https://doc.sitecore.com/developers/93/sitecore-experience-platform/en/conversion-pipelines.html, which are also ...


2

Goals of the current visit (interaction) are stored in the session and can be retrieved using Tracker API: List<PageEventData> pageGoals = Sitecore.Analytics.Tracker.Current.Interaction.Pages .SelectMany(p => p.PageEvents) .Where(evt => evt.IsGoal) ....


1

If you go with the second option (real Contact instance), you can use reflection (e.g. ReflectionUtil) to set FacetMap property on the contact instance. FacetMap is then used by Facets and GetFacet calls. [Test] public void Test1() { var contact = new Contact(); var facetMap = new Dictionary<string, Facet>(); var ...


1

I have updated the code suggested by @Marek for you without async and await: var allContacts = new List<Contact>(); using (Sitecore.XConnect.Client.XConnectClient client = Sitecore.XConnect.Client.Configuration.SitecoreXConnectClientConfiguration.GetClient()) { try { var enumerator = client....


1

The CM server does not process xDB since the role ContentDelivery or Standalone is not enabled. This is by default to prevent CM activity from polluting the xDB database. Your code will only work on the CD servers or servers with Standalone role enabled.


Only top voted, non community-wiki answers of a minimum length are eligible