Initialization Options
We support an additional TapInitOptions hash to handle aditional configuration. It's current structure is looks like this below (kotlin example):
data class TapInitOptions(
val userAttributes: HashMap<String, Any>? = null,
val clearPreviousAttributes: Boolean? = false,
)
Values and usages
Key | Description | Required? |
---|---|---|
userAttributes | User attributes hash, see usages here | No |
clearPreviousAttributes | Will clear our any attributes stored on tapresearch backend for the current user | No |
userAttributes in TapInitOptions
If user attributes are known at SDK initialization, it is preferable to pass them through initOptions
compared to using sendUserAttributes
. This will result in quicker load times for targeted content.
Clearing previous attributes
Any time user attributes are sent from the sdk. Either through TapInitOptions or from the sendUserAttributes method, we store them on our end to use for user targeting. clearPreviousAttributes will remove any previous values attributes stored for that user.