Configuration
An overview of all available configuration options.
About Examples
All examples in this section are partial code snippets. They do not represent complete/valid configurations.
credentials
This is the login information required to connect your application to the Kalapa CMP system.
- Type:typescriptRequired: All fields (url, key, trackingId) must be fully filled in.
interface Credentials { url: string; key: string; trackingId: string; }
Details:
url: The address of the Kalapa CMP server you are connecting to.
key: The API key for authentication.
trackingId: Your customer’s tracking ID.
Example:
javascriptcredentials: { url: "provided-url", key: "provided-key", trackingId: "your-customer-tracking-id" }Note:
Security: Store the login information (URL, key, tracking ID) securely.
Replace the sample values (provided-url, provided-key, your-customer-tracking-id) with your actual information.
options
guiOptions
Customize the main interface of modals/popups.
- Type:typescript
interface GuiOptions { consentModal?: ConsentModalOptions; preferencesModal?: PreferencesModalOptions; }
guiOptions.consentModal
Type:
typescriptinterface ConsentModalOptions { layout?: string; position?: string; }Default:
javascript{ layout: 'cloud', position: 'bottom center', }Details:
All options for
layoutandposition.Layout Variant(s) Position-Y Position-X boxwide,inlinetop,middle,bottomleft,center,rightcloudinlinetop,middle,bottomleft,center,rightbarinlinetop,bottom- Note
The valid value for
layout:<layoutName> <layoutVariant>.
The valid value forposition:<positionY> <positionX>.Example:
javascriptguiOptions: { consentModal: { layout: 'cloud inline', position: 'bottom center' } }
guiOptions.preferencesModal
Type:
typescriptinterface PreferencesModalOptions { layout?: string; position?: string; }Default:
javascript{ layout: 'box', position: 'right', }Details:
All options for
layoutandposition.Layout Variant(s) Position-Y Position-X box- - - barwide- left,rightNote
The valid value for
layout:<layoutName> <layoutVariant>.
The valid value forposition:<positionY> <positionX>.Example:
javascriptguiOptions: { preferencesModal: { layout: 'bar wide', position: 'left', } }
forceConsent
Create a dark overlay and block user interaction on the website until the user gives consent.
- Type:
boolean - Default:
true
darkMode
Enable/Disable dark mode.
- Type:
boolean - Default:
false
language
Set the language for the user interface.
- Type:
string - Default:
en