-
Notifications
You must be signed in to change notification settings - Fork 0
Respecting data privacy f69123
So that you can respect user privacy and be in accordance with the regulations in different countries, the tracker makes two features available:
- Disabling user tracking
- Hashing user IDs
- Gestion de la sauvegarde des hits hors ligne (si l’option est activée)
If your application offers a screen allowing the user to enable or disable statistical tracking, you can save this information via the static optOut property of the ATInternet class.
Hits will nonetheless be sent. Only the idclient variable enabling use tracking will contain the value �opt-out�
To change this behavior, you can use the configuration key sendHitWhenOptOut available since version 2.13.0 of the Tracker. By passing the value to false (true by default), you will prevent the hits from being sent when the user is in �opt-out� mode.
let tracker: Tracker = ATInternet.sharedInstance.defaultTracker
tracker.setSendHitWhenOptOutEnabled(false, sync: true, completionHandler: nil)
// Tracker is now preventing hit from being sent when the user is in opt-out modeTracker* tracker = [ATInternet sharedInstance].defaultTracker;
[tracker.ecommerce setSendHitWhenOptOutEnabled:NO sync:YES completionHandler:nil];
// Tracker is now preventing hit from being sent when the user is in opt-out mode-
Disabling user tracking
@IBAction func disableTracking(sender: UIButton) {
// deprecated : Tracker.doNotTrack = true
ATInternet.optOut = true
}- (IBAction)disableTracking:(UIButton *)sender {
// deprecated : Tracker.doNotTrack = YES;
Tracker.optOut = YES;
}-
Recovering user tracking status
override func viewDidLoad() {
super.viewDidLoad()
// deprecated : Tracker.doNotTrack
let optOut = ATInternet.optOut
}- (void)viewDidLoad {
[super viewDidLoad];
// deprecated : Tracker.doNotTrack
BOOL optOut = ATInternet.optOut;
}The SDK allows for the automatic addition of user ID in your hits (uuid, idfv, idfa). You may also add your own user ID via the tracker�s setParam method.
To ensure visitor anonymity, all while keeping their identification in your analyses, it is possible to hash the unique ID (SHA-256). To do this, use the tracker�s setHashUserIdEnabledmethod as follows:
import UIKit
import Tracker
class ViewController: UIViewController {
let tracker: Tracker = ATInternet.sharedInstance.defaultTracker
override func viewDidLoad() {
super.viewDidLoad()
tracker.setHashUserIdEnabled(true, completionHandler: { isSet in
print("User ID will now be hashed")
}
}
}#import "ViewController.h"
#import "SmartTracker/SmartTracker-Swift.h"
@interface ViewController ()
@property (nonatomic, strong) Tracker *tracker;
@end
@implementation ViewController
- (void)viewDidLoad {
[super viewDidLoad];
[self.tracker setHashUserIdEnabled:YES completionHandler:^(BOOL isSet) {
NSLog(@"hashing enabled")
}];
}
@endOffline hits are saved in the application documentDirectory directory. However Apple allows this directory to be synchronized with iCloud. To disable any backup, you can use the flag preventICloudSync of the ATInternet class.
You can also configure where the offline hit are saved with the static property databaseDirectory of the ATInternet class.
If the path is incorrect, the database won’t be initialized and the offline hits will be lost
-
Deactivation of the iCloud backup
// Before any Tracker usage
ATInternet.preventICloudSync = true // Before any Tracker usage
ATInternet.preventICloudSync = YES;-
Database path customization
// Before any Tracker usage
ATInternet.databaseDirectory = FileManager.default.urls(for: .cachesDirectory, in: .userDomainMask).last! // Before any Tracker usage
ATInternet.databaseDirectory = ATInternet.databaseDirectory = [[NSURL alloc] initWithString:[NSSearchPathForDirectoriesInDomains(NSCachesDirectory, NSUserDomainMask, YES) objectAtIndex:0]];-
Data API
- Data flow
- Advice optimizations data flow
- Error codes data flow
- Faq data flow
- General information data flow
- Technical information data flow
- Reporting API v3
- Getting started
- Methods
- Parameters
- Technical information
- REST API
- Campaigns
- Custom variables
- Getting started rest
- Methods rest
- Response structure parameters rest
- Fixed periods
- Parameters compatibility
- Relative periods
- Structure of the response
- “code” parameter
- “columns” parameter
- “evo” parameter
- “filter” parameter
- “include” parameter
- “lng” parameter
- “max-results” parameter
- “page-num” parameter
- “period” parameter
- “period” parameter: “H” v. “He” & “MN” v. “MNe”
- “retention” parameter
- “segmentdesc” parameter
- “segment” parameter
- “sep” parameter
- “sort” parameter
- “space” parameter
- Technical specifications rest
- Data flow
-
Data collection
- Android
- Advanced features
- Campaigns
- Changelog
- Content
- Ecommerce
- Getting started
- Users
- Apple
- Advanced features
- Campaigns
- Changelog
- Content
- Ecommerce
- Getting started
- Users
- General
- Cddc renew staging process
- Changelog
- Craft your hit
- Encoded parameters
- Server side cookie management
- Supported taggings
- Tagging deletion
- Utilisation of dispatch sdks
- JavaScript
- Advanced features
- Campaigns
- Changelog
- Content
- Ecommerce
- Getting started
- Partners javascript
- Users
- Piano Analytics
- Event tagging piano analytics
- Getting started piano analytics
- Piano analytics tagging
- Feeding piano analytics with as2 tagging
- Tagging custom properties sdk
- Android