AppAnalytics Class

Contains methods to help with AppExchange App Analytics use cases, such as minimizing subscriber attrition and obtaining product insights.

Namespace

IsvPartners

Usage

Use AppAnalytics and its methods to log App Analytics custom interactions.

Example

1public void submitClicked() {
2        Id jobId = System.enqueueJob(new MyQueueable(colorValue));
3        IsvPartners.AppAnalytics.logCustomInteraction(
4             MyPageInteractions.SUBMIT_CLICKED, jobId);
5

AppAnalytics Methods

These are methods for AppAnalytics.

logCustomInteraction(interactionLabel, interactionId)

Logs the custom interaction using a label that you provide as an enum value and an interaction ID.

Signature

public static void logCustomInteraction(Object interactionLabel, Id interactionId)

Parameters

interactionLabel
Type: Object
A value used to label the custom interaction. The value of interactionLabel must be an enum with the same namespace as the code that calls the logCustomInteraction method.
interactionId
Type: Id
An Apex ID that is associated with the custom interaction. The interactionId that you provide is hashed and tokenized before it’s included in AppExchange App Analytics package usage logs.

Return Value

Type: Void

logCustomInteraction(interactionLabel, interactionUuid)

Logs the custom interaction using a label that you provide as an enum value and an interaction ID that you provide as an Apex UUID.

Signature

public static void logCustomInteraction(Object interactionLabel, System.UUID interactionUuid)

Parameters

interactionLabel
Type: Object
A value used to label the custom interaction. The value of interactionLabel must be an enum with the same namespace as the code that calls the logCustomInteraction method.
interactionUuid
Type: System.UUID
An Apex UUID that is associated with the custom interaction. The interactionId that you provide is hashed and tokenized before being included in AppExchange App Analytics package usage logs.

Return Value

Type: Void

logCustomInteraction(interactionLabel)

Logs the custom interaction using a label that you provide as an enum value.

Signature

public static void logCustomInteraction(Object interactionLabel)

Parameters

interactionLabel
Type: Object
A value used to label the custom interaction. The value of interactionLabel must be an enum with the same namespace as the code that calls the logCustomInteraction method.

Return Value

Type: Void