Logs an event with the Salesforce Marketing Cloud SDK as an SFMC custom event, where each
parameter of the event is defined as a key-value pair within the data object.
Supported value types for the data object are: string, number, and boolean.
The eventName and the keys of data are passed to the SFMC SDK verbatim as the custom
event's name and attributes, so they should follow your Marketing Cloud event naming
conventions.
Example:
const modules = await Eitri.modules();
const logEvent = modules?.salesforce?.logEvent;
if (!logEvent) return;
await logEvent({
eventName: "product_view",
data: {
revenue: 29.99,
currency: "BRL",
productId: "sku-001"
}
})
Object describing the event.
Object describing the event's data. Values must be primitives (string, number, or boolean).
Name of the event.
Collection of functions responsible for tracking user activity in an Eitri-App using the Salesforce Marketing Cloud (SFMC) SDK.
This module exposes user-activity tracking only. The wider Salesforce integration also covers user identification and MobilePush, but those have no dedicated bridge surface here: identity is driven by session.notifyLogin / session.notifyLogout, and push registration/receipt is wired natively. In-app messaging is not integrated.
Requirements: This feature must be enabled in the Eitri Shopping App native configuration by providing the
salesforceconfiguration (Marketing Cloud app id, access token and server URL) in the app configuration file.