
Introduction
On this series of blog posts, I am documenting my journey of delivering personalized content to end users of a mobile app.
- Sitecore personalize and mobile app projects series – part 1 – Introduction and overview of the solution
- Sitecore personalize and mobile app projects series – part 2a – Enabling Sitecore Experience Edge (Sitecore Content Hub)
- Sitecore personalize and mobile app projects series – part 2b – Enabling Sitecore Experience Edge (Sitecore XM Cloud)
- Sitecore personalize and mobile app projects series – part 3 – Connecting Sitecore Personalize to Sitecore Experience Edge
- Sitecore personalize and mobile app projects series – part 4a – Explore Sitecore Personalize APIs and security considerations.
- Sitecore personalize and mobile app projects series – part 4b (this post) – Sitecore Personalize API Flow executions.
- GitHub Repo – Contains code samples and related artifacts referenced in this blog series
- YouTube Channel – My YouTube Channel with videos accompanying this blog series
Sitecore Personalize API Flow executions
As follow up to the previous blog post on Personalize APIs, let us look at how you can leverage the Personalize REST API flow execution service to automate running a flow for you experiments or experiences.
Experiences vs Experiments
Below is a summary key capabilities with experiences and experiments:
- Experiences – Web allows you to add experience to your website and monitor performance.
- Experiences – Full stack drives API triggered and interactive experiences.
- Experiences – Flows export segments to external third-party systems for highly targeted campaigns
- Experiments – Web runs A/B tests for your website
- Experiments – Full stack runs A/B tests on API driven triggered and interactive experiences
Characteristics of API flow execution service
A flow execution service allows you to run a flow for either web-based or mobile apps, in order to deliver great personalization in real-time. A simple use-case will be trying to encourage your guest to add a product into their shopping basket.
Below are characteristics of a flow execution service:
- Facilitates personalization in experiences and experiments, including interactive and web
- Invokes real-time responses
- Supports using decision models in interactive experiments to return the next best offer or action
How to send a flow execution request
Two options are available:
- You can send a flow execution request using either the
browserId,email, oridentifiersattribute. This flexibility is particularly useful when interacting with guests who have never been identified online and do not have abrowserIdattribute. You can use theemailoridentifiersattribute to execute a flow that uses a decision model to return the next best offer or action. - You can also send a flow execution request for an experiment or experience when you want to send the output of the decision model in real-time to an external system such as a marketing cloud. The
browserIdattribute is not relevant or captured by this type of external system, so we recommend using theemailoridentifiersattribute to execute the flow
Calling the Personalize API
You will typically initiate an asynchronous call using POST REST API.
Below is a sample request to achieve this.
HTTP POST
/v2/callFlows
This will run an interactive experiment over any web-based or mobile app. As expected, you will need to specify either browserId or email or identifiers
Flow execution request using browserId
HTTP POST {{apiEndpoint}}/v2/callFlows
{
"clientKey": "{{ClientKey}}",
"channel": "MOBILE_APP",
"language": "en",
"currencyCode": "EUR",
"pointOfSale": "{{myPOS}}",
"browserId": "{{ref}}",
"friendlyId": "{{friendlyId}}"
}
Where:
- {{apiEndpoint}} will be the base url to your Personalize tenant, .e.g., api-engage-eu.sitecorecloud.io
- {{ClientKey}} will be your public Client key
- {{myPOS}} will be your Point of Sale
- {{ref}} will be your
browserId - {{friendlyId}} when you create an experiment or experience, Sitecore Personalize automatically creates an ID when you name the experiment or experience.
Next Steps
This completes this blog, where I have walked you through Personalize API Flow executions. I hope you find this useful, and feel free to leave me any comments or thoughts.
In my next blog, I will be looking at sharing more details on my Sitecore Personalize integrations with my mobile app project. Stay tuned.




























