User ID

  • iOS
  • watchOS
  • tvOS
 

Foreword

AT Internet’s SDK allows you to choose from three types of user ID in order to track your visitors. You can also choose to use a custom ID. You’ll be able to find this ID in the idclient variable present in hits.

 

Get off to a good start

The choice of type of ID to use is first made in the Tag Composer setup interface. It is also possible to modify this parameter directly in your application’s code. The different types are:

  • UUID

The SDK generates a unique ID (called UUID) for a user when s/he uses the application for the first time. It will then always be used, unless you change the type of ID, or unless the user deletes the application from his/her phone.

The SDK uses the unique ID (UUID) as the default ID type.

  • IDFV

The SDK recovers this ID provided by iOS. This ID will be the same for the same publisher on a device (e.g. A user downloads two applications from the publisher AT Internet onto his iPhone, the IDFV will be the same on this device.) For the terms of use of this type of ID, please read Apple’s documentation.

  • IDFA

The Advertising Identifier (IDFA) is a unique ID for each iOS device that mobile ad networks typically use to serve targeted ads.
Users can choose to limit ad tracking by turning off this setting on their devices. (opt-out). To use this option, you have to include the AdSupport.framework framework in your project

With this identification mode, the user will be considered by default as an opt-out and therefore excluded from the analyses if he has activated the limited ad tracking.

Since version 2.12.2, the AT Internet SDK allows you to modify this behavior with the configuration key ignoreLimitedAdTracking. When this configuration is active and the user has enabled limited ad tracking, the identification mode automatically switches to UUID.

  • Custom ID

With our SDK, you can force the use of a custom type of customer ID.

 

Tagging examples

  1. Selecting UUID as ID type
    • Using the method setConfig()

      ATInternet.sharedInstance.defaultTracker.setConfig("identifier", value: "uuid") { (isSet) -> Void in
          print("SDK is now using UUID as visitor identifier")
      }
      
      [[ATInternet sharedInstance].defaultTracker setConfig:@"identifier" value:@"uuid" sync:NO completionHandler:^(BOOL isSet) {
          NSLog(@"%@", @"SDK is now using UUID as visitor identifier");
      }];
    • Using the method setIdentifierType()

      ATInternet.sharedInstance.defaultTracker.setIdentifierType(IdentifierTypeKey.uuid) { (isSet) -> Void in
          print("SDK is now using UUID as visitor identifier")
      }
      
  2. Selecting IDFV as ID type
    • Using the method setConfig()

      ATInternet.sharedInstance.defaultTracker.setConfig("identifier", value: "idfv") { (isSet) -> Void in
          print("SDK is now using IDFV as visitor identifier")
      }
      
      [[ATInternet sharedInstance].defaultTracker setConfig:@"identifier" value:@"idfv" sync:NO completionHandler:^(BOOL isSet) {
          NSLog(@"%@", @"SDK is now using IDFV as visitor identifier");
      }];
    • Using the method setIdentifierType()

      ATInternet.sharedInstance.defaultTracker.setIdentifierType(IdentifierTypeKey.idfv) { (isSet) -> Void in
          print("SDK is now using IDFV as visitor identifier")
      }
      
  3. Selecting IDFA as ID type
    • Using the method setConfig()

      ATInternet.sharedInstance.defaultTracker.setConfig("identifier", value: "idfa") { (isSet) -> Void in
          print("SDK is now using IDFA as visitor identifier")
      }
      
      [[ATInternet sharedInstance].defaultTracker setConfig:@"identifier" value:@"idfa" sync:NO completionHandler:^(BOOL isSet) {
          NSLog(@"%@", @"SDK is now using IDFA as visitor identifier");
      }];
    • Using the method setIdentifierType()

      ATInternet.sharedInstance.defaultTracker.setIdentifierType(IdentifierTypeKey.idfa) { (isSet) -> Void in
          print("SDK is now using IDFA as visitor identifier")
      }
      
    • Activation of the configuration related to limited advertising tracking

      ATInternet.sharedInstance.defaultTracker.setIgnoreLimitedAdTrackingEnabled(false, sync:true, completionHandler:nil)
      
      [[ATInternet sharedInstance].defaultTracker setIgnoreLimitedAdTrackingEnabled:YES sync:YES completionHandler:nil];
  4. Selecting a custom ID

    ATInternet.sharedInstance.defaultTracker.setParam("idclient", value: "123ABC")
    [[ATInternet sharedInstance].defaultTracker setStringParam:@"idclient" value:@"123ABC"];
 

Was this post helpful?

Last update: 05/06/2019