reset() restores the Mapp Intelligence singleton to its default state. Use this only for debugging and testing during integration — not in production.
Important: This method clears the current Track ID, Track Domain, everID, and resets internal session counters. After calling
reset(), you must callinitWithConfiguration(...)again before any further tracking.
What reset() does
Deletes the current everID (used to identify the user).
Clears the Track ID and Track Domain.
Resets the "one" parameter to
0(creates a new user).Resets the
fnsparameter to1(opens a new session).
Method
Method | Description |
|---|---|
| Resets the singleton to defaults. Re-initialize the SDK afterwards. |
Example
@IBAction func resetTracking(_ sender: Any) {
MappIntelligence.shared()?.reset()
// Re-initialize the SDK before tracking again:
MappIntelligence.shared()?.initWithConfiguration(
[123451234512345],
onTrackdomain: "https://your-trackdomain.com"
)
}- (IBAction)resetTracking:(id)sender {
[[MappIntelligence shared] reset];
// Re-initialize the SDK before tracking again:
[[MappIntelligence shared]
initWithConfiguration:@[@123451234512345]
onTrackdomain:@"https://your-trackdomain.com"];
}When to use it
To clear the SDK state during integration testing.
Before changing fundamental setup (Track ID, Track Domain) and you want to be sure no stale state remains.
When not to use it
In production. Resetting in production can cause data quality issues, lost session continuity, and unexpected behavior.
To opt the user out of tracking — use Opt-out of Tracking instead.
To change Track IDs at runtime — use Change Track IDs and Domain at Runtime instead.