Custom domains for events
This section describes how to configure the Didomi consent notice through its programmatic API and the window.didomiConfig object.
Most configuration options are available through the Didomi Console, and this documentation only applies to edge cases or custom implementations that require it.
In some hybrid apps (Electron, Cordova, etc.), the location.host value used by the Web SDK is not defined. This can cause the following issue in analytics data and events:
Your organization has a lot of page views with no consent rate.
A custom domain can be set as part of the didomiConfig object to ensure that some domain is associated with API events for those applications.
You can add a customDomain property to the app object in the configuration:
window.didomiConfig = {
app: {
customDomain: "custom.app.domain",
},
};Please ensure that you specify a valid domain in one of the following formats:
A valid DNS name
Example:
sandbox.domain.io,www.domain.ioA valid iOS bundle ID or Android package ID
Example:
com.example.app,com.example.app.ios,com.example.app.macos
Otherwise, it will be filtered out and not included in your analytics event data.
This configuration option is also available in the Didomi Console as part of the Custom JSON field in the Customization tab.
Last updated