Flutter
How do I set up server-side on my mobile app?
Last updated
How do I set up server-side on my mobile app?
Last updated
To activate event collection on the Commanders Act X platform, remember to activate your collection sources in the sources module.
It is at this stage that you will find the id of your site and a source id (sourceKey) that will be useful later for installing the SDK.
To facilitate the collection of your events from your mobile application, we have developed a Flutter SDK to facilitate the transmission of data to our server-side:
You need to implement events for each action to be tracked (page view, click, etc.).
Here is an example of code used to initialise an event:
Here is an example of the code used to execute an event:
Click here for our full list of standard events:
N.B.: The new platform uses a standardised datalayer, so the datalayer for your mobile application will need to be updated.
We strongly recommend that you use the same datalayer for both the web application and the mobile application.
The main benefit: a single destination to configure for both sources! Your destination configuration will be recognised by both web and mobile.
Don't worry, you can send us your events directly using our API.
Prerequisites :
You will need a specific sourceKey to define the source. (go to step 1)
You will need a siteID to define the corresponding workspace
Optional:
You can use the TCUser class to pass relevant information about your users.
Here's an example of the code you can look at
Documentation of the initialisation method
N.B.: Please refer to the FAQ for more details.
A quality assurance test and validation are strongly recommended before going into production!
Here are a few points to help you with your recipe:
To help you implement the SDK, we have created a demonstration environment. This will enable you to see the correct way of implementing event collection on the server-side :
Your set-up is now complete, and you can configure your first destinations.
Improve your ROI by activating your audiences on the best channel and improve the on-site and off-site user experience.