Developer Methods
User Identification
Use the identify method to link the Apptrove session to a specific user in your system. This is typically called after a successful login or registration.
// Bind a unique Customer User ID (CUID)
window.AT("pwa", "identify", { cuid: "USER_UNIQUE_ID" });
Event Tracking
Track specific conversion milestones (e.g., Add to Cart, Subscription, or Level Up) using the trackEvent method.
window.AT("pwa", "trackEvent", {
id: "tGlfZsqwRJ", // Required: The event slug defined in your dashboard
revenue: 499.0, // Optional: Transaction value
currency: "USD", // Optional: ISO 4217 currency code
order_id: "TXN_98765", // Optional: Your internal transaction ID
event_values: {}, // Optional: Key-value map of extra event data
param1: "Silver_Tier", // Optional: Custom attribute
param2: "Yearly_Plan", // Optional: Custom attribute
mode: "testing" // Required: "live" | "testing"
});
Events Dashboard — Apptrove:
