logInAppPurchase method

Future<void> logInAppPurchase(
  1. String transactionId
)

Log an in-app purchase from the platform store

Tracks a store purchase for revenue attribution.

transactionId - The platform-specific transaction identifier:

  • iOS: The StoreKit transaction ID (pass as string, e.g. transaction.id.description)
  • Android: The purchase original JSON (e.g. purchase.originalJson)

Throws GrovsException if the operation fails

Example:

await Grovs().logInAppPurchase('12345');

Implementation

Future<void> logInAppPurchase(String transactionId) {
  return GrovsPlatform.instance.logInAppPurchase(transactionId);
}