9.4 How to set up the Self service components?
Challenge:
When using our Self Service, customers can face the challenge of customizing it according to their specific requirements. They need a way to configure various components and elements to create a tailored Self Service experience.
Solution:
To address this challenge, we have developed multiple components that can be reused in Flows. These components provide flexibility and allow customers to customize their Self Service to suit their needs. In the following section, we will explain all the configurable options available:
Version | 2.135 and up |
---|---|
License | Self Service |
- 1 Challenge:
- 2 Solution:
- 2.1 Flow creation
- 2.2 Campaign creation
- 2.3 Audience
- 2.3.1 Available filters
- 2.4 Select Products
- 2.4.1 Linear split
- 2.5 Shopping cart
- 2.6 Creating records
- 2.7 Payment
- 2.8 Create Invoices
- 2.9 Error Handling
- 2.9.1 Validate inputs
- 2.9.2 Faults for DML operations
- 2.9.3 Faults in the Invoicing Process
Please find a full list of the components below:
Component | Purpose |
---|---|
Campaign creation | Set campaign parameters such as name, campaign goal, runtime and budget. |
Audience selection | Define the audiences you would like to reach with your ads. |
Result list | Receive products that fit to your search criteria and add them to your basket. |
Shopping cart | Get an overview of your basket and make some last minute changes such as quantities or removing products from the basket. |
Payment | Get an invoice in order to pay the invoice. |
Create records / Save | Simplifying the save process and taking care of saving applied Commitment Conditions as well as Targeting Groups (audiences) which were matched. |
You can start setting up your Self Service by creating a Digital Experience. Please find the steps right here: 9.1 Create a Portal (Digital Experience)
Flow creation
After the Community is set up you will need to create a flow or you can choose to edit our flow template. You can do this by entering the Setup of your Salesforce org.
When you enter “Flows” in the Quick Search Bar you will be able to open that point under the section Process Automation.
If you do not know Flows well we recommend doing the following trailhead from Salesforce: https://trailhead.salesforce.com/content/learn/modules/flow-basics
Create a new flow and select the type screen flow. You can select a layout type. Choose whatever you prefer.
You can select the existing flow called “Self Service ADvendio Package Flow Version 1”.
Campaign creation
The first step is to add a new screen component to the flow.
On the left side under the section, Custom you will find the component Campaign Creation. Add it to the screen.
Sometimes you might need to cancel the component and add it again in order to see all components on the left side (only initially).
The parameters on the right-hand side of the component are explained below. The output parameters need to be defined by setting the checkbox “Manually assign variables (advanced)” to true in the Advanced section for the component. You should also set the radio button in the “Revisit Screen Values” section to true saying “Refresh inputs to incorporate changes elsewhere in the flow”.
Input/Output | Required? | Parameter | Meaning | Value format | Default value |
---|---|---|---|---|---|
Input | no | Budget Selection | Please select the budget selection mode that should be used in the campaign creation. Possible values are:
This will result in showing either a sliding bar or a text input field for you to specify your budget amount/impressions. | text | slider |
Input | no | Budget Type | Please select the budget type that should be used in the campaign. You can take the decision for the user already or leave the choice to him. Possible values are:
| text | Revenue |
Input | no | budgetMax | Set the maximum number of revenue budget that should be selectable. | number | 20,000 |
Input | no | budgetMin | Set the minimum number of revenue budget that should be selectable. | number | 500 |
Input | no | budgetStep | Set the step value for revenue budget that should be applied while using the slider. | number | 500 |
Input | no | goals | Enter a custom setup of the Campaign Goals to customize them for your needs. | JSON string | please see below the table |
Input | no | impressionsBudgetMax | Set the maximum number of impression budget that should be selectable. | number | 20,000 |
Input | no | impressionsBudgetMin | Set the minimum number of impression budget that should be selectable. | number | 500 |
Input | no | impressionsBudgetStep | Set the step value for impression budget that should be applied while using the slider. | number | 500 |
Input | no | Info Text | Enter an info text that will be shown below the budget in order to give a hint to the user. | text | empty |
Input | no | Media Campaign Id | If you are working with already saved campaigns please set the Media Campaign id here. | id of a Media Campaign | empty |
Input | yes | mediaCampaign | Enter the variable of a Media Campaign that can be used for saving the Media Campaign to be configured virtually. | record variable of data type Media Campaign | empty |
Output | yes | mediaCampaign | Enter the variable of the Media Campaign from above in order to hand over the entered parameters to the next component. | record variable of data type Media Campaign | empty |
This Campaign Creation component uses input for goals
in order to be more dynamic. This is the default configuration if no other input is provided in the setup of the component:
[
{
"label":"Brand Awareness",
"description":"Increase the awareness and visibility of a brand.",
"iconName":"standard:catalog",
"picklistValue":"brand awareness"
},
{
"label":"Conversion",
"description":"Execute specific actions such as making a purchase.",
"iconName":"custom:custom26",
"picklistValue":"conversion"
},
{
"label":"Reach",
"description":"Reach the maximum number of people in your target group.",
"iconName":"standard:customers",
"picklistValue":"reach"
}
]
The format can be built like this:
label
: Define how the goal name should be displayed.description
: Enter a description to let the users understand what this goal means.iconName
: Enter a name for the icon that fits to your goal. You can use all icons from this library: https://www.lightningdesignsystem.com/icons/
Please keep in mind to add “standard:” or “custom:” in front of the icon name as you can see in the example above.picklistValue
: Enter the API name of the goal value in your Media Campaigns Campaign Goal field in order to match it later to the results.translations
: You can add translations for other languages to your setup. Please find below an example for a German translation. If you want to translate this for another language please replace “de” with the language code from this list: https://help.salesforce.com/articleView?id=faq_getstart_what_languages_does.htm&type=5"translations": { "de": { "label": "Markenbekanntheit", "description": "Ziel ist es die Bekanntheit je Zielgruppe zu erhöhen." } }
We recommend using a JSON online formatter to ensure a correct JSON string. For example you could use this one: https://jsonformatter.curiousconcept.com/#
After adding the component to your screen flow connect an arrow from the start object to the Campaign Creation component.
Audience
The second step is to add a new screen component to the flow.
On the left side under the section, Custom you will find the component Audience. Add it to the screen.
Available filters
There is a total of 5 available filters for your Audience. Available filters are Media Type, Formats, Ad Type, Impressions and Price.
Only 3 of these filters can be displayed on your result page. The combination of filters can be configured based on your selection. See the screenshot below:
The parameters on the right-hand side of the component are explained below. The output parameters need to be defined by setting the checkbox “Manually assign variables (advanced)” to true in the Advanced section for the component. You should also set the radio button in the “Revisit Screen Values” section to true saying “Use values from when the user last visited the screen”.
Input/Output | Required? | Parameter | Meaning | Value format | Default value |
---|---|---|---|---|---|
Input | yes | Media Campaign | Enter the variable of the Media Campaign from the first component to take over the Media Campaign parameters. | record variable of data type Media Campaign | empty |
Input | yes | Selected Targeting Groups | Enter a variable for Targeting Groups in order to load the entered parameters when navigating between different screens. | collection (Allow multiple values) variable of data type Targeting Group | empty |
Input | no | Media Campaign Id | If you are working with already saved campaigns please set the Media Campaign id here. | id of a Media Campaign | empty |
Input | no | Targetings | Enter a custom setup of the Audience selection to customize it for your needs. | JSON string | please see below |
Output | no | Media Campaign | Enter the variable of the Media Campaign from the first screen in order to hand over the parameters to the next component. | record variable of type Media Campaign → should be left empty | empty |
Output | no | Media Campaign Id | (not relevant for now) | id of a Media Campaign | empty |
Output | yes | Selected Targeting Groups | Enter a variable of Targeting Groups in order to hand over the entered parameters to the next component. | collection (Allow multiple values) variable of data type Targeting Group | empty |
This Audience component uses an input for targetings
in order to be more dynamic. This is the default configuration if no other input is provided in the setup of the component:
[{
"categories": "Geography - Country;Geography - City;Geography - Region",
"header": "Where do your potential customers live?",
"categoryText": "Countries",
"type": "lookup"
},
{
"categories": "Age",
"header": "What are the age cohorts you wish to target?",
"categoryText": "Age",
"type": "picker"
},
{
"categories": "Gender",
"header": "What genders do you wish to target?",
"categoryText": "Gender",
"type": "checkbox"
},
{
"categories": "Interest",
"header": "Do your potential customers have any of these interests?",
"categoryText": "Interest",
"type": "checkbox"
}
]
The format can be built like this:
categories
: Targeting Group category, it can be multiple ones, if thats the case they must be separated with a “;” like “category1;category2”.header
: The header that will be shown above the input. You can use it as a question to explain to the users what to enter here.categoryText
: A label that will be shown above the input field and below the header. Here you could use the category name.type
: The type of the input, currently there are 3 types accepted which you can use interchangeably:checkbox
lookup
picker
We recommend using a JSON online formatter to ensure a correct JSON string. For example you could use this one: https://jsonformatter.curiousconcept.com/#
After adding the component to your screen flow connect an arrow from the Campaign Creation component to your newly created Audience component.
Select Products
The third step is to add another new screen component to the flow.
On the left side under the section, Custom you will find the component Result List. Add it to the screen.
Linear split
When the Linear split is enabled, it helps distribute the budget quantity evenly across campaign items, see Linear Split Enabled below:
The parameters on the right-hand side of the component are explained below. The output parameters need to be defined by setting the checkbox “Manually assign variables (advanced)” to true in the Advanced section for the component. You should also set the radio button in the “Revisit Screen Values” section to true saying “Refresh inputs to incorporate changes elsewhere in the flow”.
Input/Output | Required? | Parameter | Meaning | Value format | Default value |
---|---|---|---|---|---|
Input | yes | campaignItems | Enter a variable to save the Campaign Items that will start to be created in this component. | collection (Allow multiple values) variable of data type Campaign Item | empty |
Input | no | Check Availability Enabled | Please enter a value that defines if an availability check should be done when starting the Result List or not. | boolean | false |
Input | no | Items per Check Availability Job | This value defines how many items will be included in one availability job at the same time. The number affects the speed how fast results are coming in. The default of 10 is a well balanced value between not waiting too long but putting enough items together to not have too many jobs running in the end. | number | 10 |
Input | yes | Media Campaign | Enter the variable of the Media Campaign from the first component to take over the Media Campaign parameters. | record variable of data type Media Campaign | empty |
Input | no | Media Campaign Id | If you are working with already saved campaigns please set the Media Campaign id here. | id of a Media Campaign | empty |
Input | yes | Targeting Group Ids | Enter the existing variable for Targeting Groups in order to load the entered parameters on this screen. | collection (Allow multiple values) variable of data type Targeting Group | empty |
Output | yes | Campaign Item Related List | The variable to hold all the information about Campaign items with related records, e.g. applied Commitment Conditions, Contents or Targeting Groups. | text variable | empty |
Output | yes | campaignItems | Enter the variable from the Input parameters again to hand over the Campaign Items in the basket to the next component. | collection (Allow multiple values) variable of data type Campaign Item | empty |
Output | yes | Media Campaign | Enter the variable of the Media Campaign from the first screen in order to hand over the parameters to the next component. | record variable of type Media Campaign | empty |
Output | no | Media Campaign Id | (not relevant for now) | id of a Media Campaign | empty |
Output | yes | Targeting Group Ids | Enter the existing variable of Targeting Groups in order to hand over the values to the next component. | collection (Allow multiple values) variable of data type Targeting Group | empty |
Shopping cart
The fourth step is to add another new screen component to the flow.
On the left side under the section, Custom you will find the component Summary. Add it to the screen.
The parameters on the right-hand side of the component are explained below. The output parameters need to be defined by setting the checkbox “Manually assign variables (advanced)” to true in the Advanced section for the component. You should also set the radio button in the “Revisit Screen Values” section to true saying “Refresh inputs to incorporate changes elsewhere in the flow”.
Input/Output | Required? | Parameter | Meaning | Value format | Default value |
---|---|---|---|---|---|
Input | yes | Campaign Item Related List | The variable to hold all the information about Campaign items with related records, e.g. applied Commitment Conditions, Contents or Targeting Groups. | text variable | empty |
Input | yes | Campaign Items | Enter the variable from the third screen to load the basket items into this component. | collection (Allow multiple values) variable of data type Campaign Item | empty |
Input | yes | Media Campaign | Enter the variable of the Media Campaign from the first component to take over the Media Campaign parameters. | record variable of data type Media Campaign | empty |
Input | no | Media Campaign Id | If you are working with already saved campaigns please set the Media Campaign id here. | id of a Media Campaign | empty |
Input | yes | Targeting Group Ids | Enter the existing variable for Targeting Groups in order to load the entered parameters on this screen. | collection (Allow multiple values) variable of data type Targeting Group | empty |
Output | yes | Campaign Item Related List | The variable to hold all the information about Campaign items with related records, e.g. applied Commitment Conditions, Contents or Targeting Groups. | text variable | empty |
Output | yes | campaignItems | Enter the variable from the third screen to hand over the Campaign Items in the basket to the next component. | collection (Allow multiple values) variable of data type Campaign Item | empty |
Output | yes | Media Campaign | Enter the variable of the Media Campaign from the first screen in order to hand over the parameters to the next component. | record variable of type Media Campaign | empty |
Output | no | Media Campaign Id | (not relevant for now) | id of a Media Campaign | empty |
Output | yes | Targeting Group Ids | Enter the existing variable of Targeting Groups in order to hand over the values to the next component. | collection (Allow multiple values) variable of data type Targeting Group | empty |
The Summary component will calculate the VAT values based on the Media Campaign information. To calculate VAT rates please keep in mind to
either set manually the needed information in the virtual Media Campaign by using an assignment component (Fields to be set then are the debtor and depending on your VAT set up the following: VAT Rate % Type 1A, Type 1B, Type 2A and Type 2B).
or you could also receive the relevant details by creating the Media Campaign before getting to the screen and then query the calculated details for the VAT calculation before starting the summary screen. You would still need to define the debtor to be set in the Media Campaign before creation.
Creating records
Now you might want to create the records in order to prepare everything for the payment.
To save all the rest of the configured records we created the Save component for records. We recommend you use this after the summary component and before the Payment and Creative components.
Add a new screen component to the flow.
On the left side under the section, Custom you will find the component selfSave. Add it to the screen.
The parameters on the right-hand side of the component are explained below. The output parameters need to be defined by setting the checkbox “Manually assign variables (advanced)” to true in the Advanced section for the component. You should also set the radio button in the “Revisit Screen Values” section to true saying “Refresh inputs to incorporate changes elsewhere in the flow”.
Input/Output | Required? | Parameter | Meaning | Value format | Default value |
---|---|---|---|---|---|
Input | yes | Campaign Item Related List | The variable to hold all the information about Campaign items with related records, e.g. applied Commitment Conditions, Contents or Targeting Groups. | text variable | empty |
Input | yes | campaignItems | Enter the variable from the third screen to load the basket items into this component. | collection (Allow multiple values) variable of data type Campaign Item | empty |
Input | yes | Media Campaign | Enter the variable of the Media Campaign from the first component to take over the Media Campaign parameters. If you are working with already saved campaigns please make sure to have the record id field filled in the Media Campaign variable. | record variable of data type Media Campaign | empty |
Output | yes | Media Campaign | Enter the variable of the Media Campaign from the first screen in order to hand over the parameters to the next component. | record variable of type Media Campaign | empty |
Output | yes | Media Campaign Id | (not relevant for now) | id of a Media Campaign | empty |
Output | yes | saved Campaign Items | Enter the variable from the third screen to update the basket items which were saved in component. | collection (Allow multiple values) variable of data type Campaign Item | empty |
The Save component will
Save the Media Campaign (if not done before)
Save the Campaign Items related to the Media Campaign
Save related Targeting Groups (and their connected Contents if applicable)
Save related Commitments conditions (if applicable)
Payment
The next step is to add another new screen component to the flow.
On the left side under the section, Custom you will find the component Payment. Add it to the screen.
The parameters on the right-hand side of the component are explained below. The output parameters need to be defined by setting the checkbox “Manually assign variables (advanced)” to true in the Advanced section for the component. You should also set the radio button in the “Revisit Screen Values” section to true saying “Refresh inputs to incorporate changes elsewhere in the flow”.
Input/Output | Required? | Parameter | Meaning | Value format | Default value |
---|---|---|---|---|---|
Input | yes | Campaign Items |