updateUserAttributes

suspend fun updateUserAttributes(userToken: String, isPaying: Boolean? = null, plan: String? = null, mrr: Double? = null, currency: String? = null): UserAttributesUpdateResult(source)

Reports self-declared user segmentation attributes and telemetry via PUT /api/v1/public/apps/{appKey}/user.

Parameters provided as null are left untouched on the server, allowing partial updates.

!NOTE Financial values such as mrr and isPaying are self-declared signals used for feedback prioritization and feature triage, never actual payment transaction details.

Return

UserAttributesUpdateResult indicating whether the update was saved.

Parameters

userToken

Stable anonymous token identifying the user (UserTokenStore).

isPaying

Whether the user is on a paid subscription tier.

plan

Identifier or name of the subscription plan (e.g. "pro", "enterprise").

mrr

Monthly recurring revenue associated with the user account.

currency

ISO 4217 currency code for mrr (e.g., "USD", "EUR").

Throws

on network failure.

Example:

client.updateUserAttributes(
userToken = userToken,
isPaying = true,
plan = "Pro Annual",
mrr = 9.99,
currency = "USD"
)