Connect Amazon’s Alexa to Sitecore

Delivering an enterprise skill for Amazon Alexa means preparing and supporting loads of content so why not to use Sitecore the leader eXperience platform to manage your Alexa skill related content?

Here at VoiceCase we think that Sitecore is a perfect tool to manage complex SSML messages to support your Alexa skill via the Sitecore multi-channel capabilities…

Alexa skill provide different voice messages using SSML a markup language fairly similar to HTML – here  you can find extensive reference to SSML syntax


The simpler way to integrate your custom skill with Sitecore is via a synchronous call from your AWS Lambda to the Sitecore endpoint to provide the required SSML via a simple webApi endpoint (via json)


Other valid reasons for using Sitecore to store your SSML?

  • Multilanguage support
  • Approval Workflow
  • Rich Text Editor Customizations to support SSML creation for business users
  • SSML validation
  • Skill configuration settings on Sitecore

In addition to the simple integration, you may want to use Sitecore combined with Polly to generate custom audio messages to support your skill or Sitecore Media Library capabilities to host custom MP3 files to support your Alexa skill…

Here you can see how it looks a SSML message within Sitecore Rich Text Editor


We also strongly recommend the use of snipped withing the Sitecore rich text editor to support SSML speechons, this would allow business users to create wow effects for your Alexa users….


Other possible advantages of this integration would be the use of the Sitecore Personalisation features simple examples could be:

  • Personalization for anonymous devices (offer different messages for anonymous and registered users
  • Account Linking + Personalisation – deliveing personalized Voice messages for different customers, depending on the customer segment defined in Sitecore via XDB facets
  • Single view of the customer + Analytics – Sitecore Analytics could hold a 360 view of your customers across different channels and Alexa would be just an additional channel for Sitecore
  • Personalized Content leveraging XDB capabilities (behavior personalisation)
  • A/B testing capabilities to identify the more effective paths and customers preferred application paths
  • Sitecore Commerce to deliver conversational commerce

In the case you find this topic interesting, reach out and will be happy to help you to get the most out of your Amazon Alexa integration with Sitecore….

I have been presenting this topic to few user groups and here you can find additional slides–  a video & additional pictures of the presentation…

@steliodibello demonstrating Alexa integration with #sitecore @bekagool

— Ian Graham (@ianjohngraham) June 14, 2017




Sitecore Active Directory Module 1.3 setup guide

Recently I have installed Sitecore Active Directory Module 1.3 against Sitecore 8.2 update 3 – 170407 overall I got the integration fully working and I was happy with it…

I have performed the configuration on premise, but theoretically should work also in IAAS / PAAS approach assuming that you can perform the LDAP queries…

This is the list of the steps that I have performed to configure it

1) Download Sitecore Active Directory module 1.3

2) Install Sitecore Module

Upload and install the sitecore package

3) Amend the Connection string Adding:

<add name="LDAP_CONN" connectionString="LDAP://DOMAINCONTROLLERNAME:389/OU=Sitecore,OU=Dev,OU=AppStreams,OU=PARENT,OU=PARENT,OU=Locations... DC=com" />

Note OU are used to filter within the Active directory forest… Generally you do not want to have all the AD users on Sitecore but just a subset preassigned to your forest (eg. IT & Marketing users).

Also note that you need to have a service user to perform LDAP queries, in this case

4) Add Domain in the domain.config

<domain name="DOMAIN" ensureAnonymousUser="false" />

5) Amend Sitecore Config

<provider providerName="sql" storeFullNames="true" wildcard="%" domains="*" />
<provider providerName="ad" storeFullNames="false" wildcard="*" domains="DOMAIN" />

<provider providerName="sql" storeFullNames="true" wildcard="%" domains="*" ignoredUserDomains="" allowedUserDomains="" />
<provider providerName="ad" storeFullNames="false" wildcard="*" domains="DOMAIN" />

6) Amend WebConfig

Amend all the switching providers appropriately

<add name="ad" type="LightLDAP.SitecoreADMembershipProvider" connectionStringName="LDAP_CONN" applicationName="sitecore" minRequiredPasswordLength="1" minRequiredNonalphanumericCharacters="0" requiresQuestionAndAnswer="false" requiresUniqueEmail="false" connectionProtection="Secure" connectionUsername="DOMAIN\sitecoredev" connectionPassword="XXXXX" attributeMapUsername="sAMAccountName" enableSearchMethods="true" enablePasswordReset="false" />

<add name="ad" type="LightLDAP.SitecoreADRoleProvider" connectionStringName="LDAP_CONN" applicationName="sitecore" attributeMapUsername="sAMAccountName" cacheSize="2MB" username="DOMAIN\sitecoredev" password="XXXX" />

note that you need to have a service user like SitecoreDev to perform LDAP queries…

7) Test it

now you can login as a Sitecore Admin and try to add domain users and set them as Administrator…

8) Bugfix to login with AD users… within Sitecore 8.2 Update 3 you need to install the following hotfix in order to be able to login…


Copy the file in the Bin


<add name="switcher" type="Sitecore.Support.Security.SwitchingMembershipProvider, Sitecore.Support.139945" applicationName="sitecore" mappings="switchingProviders/membership" /> 

9) Test it again to login to Sitecore shell with an active directory user selected as Admin…

Happy Sitecore!!!!


Azure PAAS for your Sitecore Dev environment with Power Shell

As I have previously blogged about Sitecore 8.2 on Azure PAAS  I decided that it was arrived the right moment for me to provision my Sitecore Dev environment on an Azure WebApp…

The main reason for doing it is to keep all the environments as similar as possible and deploy my code easily from VisualStudio OnLine and simplify my build & CI pipeline for my Dev environment having a production environment PAAS…

In regard having all the environments as similar as possible,  it could be a bit expensive with a cloud consumption based model…  and you can be tempted, as I have been, to have a much simpler configuration without the Sitecore Analytics in the Dev environment.


My ideal configuration for the Dev environment is as simple as possible to keep the cost down and be able to validate my code, to do that what I really need is just one WebApp to use as CM/CD and the standard SQL databases Master, Core, Web, in addition to this you may consider to keep the Insight Analytics on to monitor the environment and notify if any error occur.

Having played a bit with the Sitecore Azure toolkit and the Sitecore Arm Templates, I realised that any of the scripts was helping me to achieve my ideal Dev environment since all the scripts provision Azure Search and Redis cache provider and so I decided to get hands dirty with PowerShell.

After few attempts to change the scripts, I decided to go for an alternative approach:

  1. Take CM scripts and the CM web deploy packages, pretty standard…
  2. Remove all the Configs that relate to Azure Search in the CM package and repackage the webdeploy and upload on Azure Storage
  3. Make a power shell script to remove: Azure Search, Redis Cache Provider, CD WebApp
  4. Happy days with a cheap Sitecore dev environment running on an Azure WebApp

Changing the CM web deployment package is a trivial task just unzip the CA package and change the configs as you wish, in my case disabling these ones and enabling the equivalent ones for Lucene…

  • Sitecore.ContentSearch.Azure.DefaultIndexConfiguration
  • Sitecore.ContentSearch.Azure.Index.Core
  • Sitecore.ContentSearch.Azure.Index.Master
  • Social/Sitecore.Social.Azure.Index.Master
  • Sitecore.Social.Azure.IndexConfiguration
  • Sitecore.ListManagement.Azure.Index.List
  • Sitecore.ListManagement.Azure.IndexConfiguration
  • Sitecore.Marketing.Azure.Index.Master
  • Sitecore.Marketing.Azure.IndexConfiguration
  • Sitecore.Marketing.Definitions.MarketingAssets.Repositories.Azure.Index.Master
  • Sitecore.Marketing.Definitions.MarketingAssets.Repositories.Azure.IndexConfiguration

In regard the power shell script, it is also very simple since it use just Azure Resource manager commands and it looks like that…


$Name = "DevResGroup";

$redisserviceName = "$Name-redis";		
$searchserviceName = "$Name-as";
$cdserviceName =  "$Name-cd";
$cdPlanserviceName =  "$Name-cd-hp";

 #Deleting Redis Cache
Remove-AzureRmRedisCache -Name $redisserviceName -ResourceGroupName $Name
 #Get Search service and store it in $resource
$resource = Get-AzureRmResource `
    -ResourceType "Microsoft.Search/searchServices" `
    -ResourceGroupName $Name `
    -ResourceName $searchserviceName `
    -ApiVersion 2015-08-19
#Deleting your service will delete all indexes and data in the service
$resource | Remove-AzureRmResource

#Deleting your CD WebApp
Remove-AzureRmWebApp -Name $cdserviceName -ResourceGroupName $Name

#Deleting your CD WebApp Service Plan
Remove-AzureRmAppServicePlan  -Name  $cdPlanserviceName -ResourceGroupName $Name

Sitecore 8.2 on Azure PAAS

As you have probably already heard, Sitecore 8.2 is “finally” fully suporting Azure PAAS

In practical terms since the Update 1 version Sitecore is shipping the full platform on Azure to run in PAAS mode and it is officially supporting it.


New building blocks of your PAAS deployment model will be:

  • Content Delivery servers on Web Apps (Azure App Service) – it means autoscaling + Application Insight
  • Azure Redis Cache for Session State Provider
  • Azure Search as distributed Search Provider
  • XDB – is still not fully supported in native PAAS mode, but you can provision it on MLAB or in IAAS mode on your VM – Note that Document DB x Mongo is not supported
  • SQL Azure – Master -Core-Web + reporting DB
  • Content Management as a different Azure App Service
  • Processing & Reporting as a different Web Apps or consolidated in the CM role

What has drastically changed? – Logs management now it is part of Application Insight, support for Azure Redis for the Session State Provider, Azure Search is now recommended instead of SOLR.

How do I deploy Sitecore on Azure?

Sitecore reccomend you also the Sizes to run Sitecore on PAAS

My personal recommendation having played with it is to go definitively with Update 3 or a following version and not to use the Azure Market Place to provision your production environment.


WebAPI 2 native support in Sitecore 8.2


Here we go with an other episode of the WebAPI and Sitecore saga…

As you probably know each version of Sitecore has managed WebAPI in a different way….

Within 8.2 finally Sitecore is officially supporting WebApi NATIVELY

So what do you need to do to write your first WebAPI Controller and start using it?

very simple:

public class MyCustomController : Controller
   public ActionResult Test()
      return Content("This is a test");

and this is the Url where you can access your controller

Url: http://yourInstanceName/api/sitecore/MyCustom/test

public class MyOtherCustomController : Controller
   public ActionResult OtherTest(string mycustomId)
      return Content("This is a test with params" + mycustomId);

Url: http://yourInstanceName/api/sitecore/MyOtherCustom/OtherTest/thisIsMyParam

will return “This is a test with params thisIsMyParam”

Happy Sitecore and happy webApi to everybody!

Sitecore Dictionaries Best Practices

Sitecore Dictionaries are a powerful tool if used correctly… Unfortunately Sitecore Dictionaries are often misused from Sitecore newbie developers and I have seen dictionaries leading to catastrophic consequences for the project…
let’s go with order:
What are Sitecore Dictionaries
Sitecore allow the developer to define Dictionary when you need to define a simple association Key Name – value Name for your resources.
Typically the developers will hardCode the keyName of the dictionary within the code of the Rendering.
Domain dictionaries:
You could have global dictionaries and you could define global dictionaries that could variate for each site of your multisite implementation.
More reference on domain dictionary can be found here
Dictionaries Localization:
Dictionaries support multiple languages and it reuse Sitecore logic for localization (such as language fall back etc)
further reference on the language fallback of Dictionaries can be found here
When shall you use Dictionaries:
The more common scenario where you should use Dicitonary is for static labels that you use for your website, eg.  the text that you display for a button.
The main difference between using a Dictionary versus the Datasource item association  is that Sitecore dictionaries have a simple structure and do not allow the content authors to change the datasource/behavior of your rendering but allow the content authors just editing the text of the label.
Typically you would use a dictionary for content that does not change very often and for simple content elements such labels of a button
When you should not use it:
Since Dictionaries are “Hardcoded” in the rendering, the use of Dictionaries for certain resources would mean that you cannot take advantage of the personalisation and testing functionalities for the resources stored in the dictionary
you have also to take in account the fact that you “loose” the flexibility for Content Authors to associate the Item Datasource in the name of a SIMPLER solution…
How could you use it:
There are several way to reference to a dictionary key:
Directly in your View


Directly in your Controller
return Sitecore.Globalization.Translate.Text("myKeyName");
Exposing the Dictionary values as a WebApi Endpoint (especially in the case that you can cache with your CDN) there are several examples that explain how to build your webApi endpoint..
Creating a static JSON file for each language when the content authors publish the Dictionary item
I hope this post helped you to clarify all what you need to know about Sitecore Dictionaries…

Sitecore 8 Profiling Visitors for Beginners

The first step to deliver Personalisation for Anonymous Visitors of your web site is knowing your Visitors through the pages that they have visited…

Sitecore allow you to Profile your customers interests and behavior through the Profile framework where you can define the Profile Keys, Profile Cards and PatternMatch Cards.

In order to be able to fully benefit from this feature, you need to have XDB & Analytics enabled so that you can fully track your customer behavior.




As you can see, there is not always a clear classification, but often the definition touch multiple dimensions…

Once that you have defined your Profiles, it is time to TAG your content so that you can classify your visitors….



Once that you have defined your Profiles and Tagged your content you can easily identify your Anonymous visitors and start delivering personalized content based on the interest and behavior that you were able to track….

Some example of personalisation rules are reported here…