You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
#### <aid="gps-adid-permission"></a>Add permission to gather Google advertising ID
141
+
142
+
If you are targeting Android 12 and above (API level 31), you need to add the `com.google.android.gms.AD_ID` permission to read the device's advertising ID. Add the following line to your `AndroidManifest.xml` to enable the permission.
For more information, see [Google's `AdvertisingIdClient.Info` documentation](https://developers.google.com/android/reference/com/google/android/gms/ads/identifier/AdvertisingIdClient.Info#public-string-getid).
If you are using Proguard, add these lines to your Proguard file:
@@ -506,7 +517,7 @@ You should use **callback parameters** for the values that you collect for your
506
517
507
518
You can register a callback URL for your events in your [dashboard]. We will send a GET request to that URL whenever the event is tracked. You can add callback parameters to that event by calling `addCallbackParameter` to the event instance before tracking it. We will then append these parameters to your callback URL.
508
519
509
-
For example, suppose you have registered the URL `http://www.adjust.com/callback` then track an event like this:
520
+
For example, suppose you have registered the URL `https://www.adjust.com/callback` then track an event like this:
510
521
511
522
```dart
512
523
AdjustEvent adjustEvent = new AdjustEvent('abc123');
In that case we would track the event and send a request to:
519
530
520
531
```
521
-
http://www.adjust.com/callback?key=value&foo=bar
532
+
https://www.adjust.com/callback?key=value&foo=bar
522
533
```
523
534
524
535
It should be mentioned that we support a variety of placeholders like `{gps_adid}` that can be used as parameter values. In the resulting callback this placeholder would be replaced with the Google Play Services ID of the current device. Also note that we don't store any of your custom parameters, but only append them to your callbacks. If you haven't registered a callback for an event, these parameters won't even be read.
@@ -660,22 +671,24 @@ Adjust SDK offers the possibility to use it for requesting user authorization in
### <aid="af-gps-adid"></a>Google Play Services advertising identifier
1038
1051
1052
+
The Google Play Services Advertising Identifier (Google advertising ID) is a unique identifier for a device. Users can opt out of sharing their Google advertising ID by toggling the "Opt out of Ads Personalization" setting on their device. When a user has enabled this setting, the Adjust SDK returns a string of zeros when trying to read the Google advertising ID.
1053
+
1054
+
> **Important**: If you are targeting Android 12 and above (API level 31), you need to add the [`com.google.android.gms.AD_ID` permission](#gps-adid-permission) to your app. If you do not add this permission, you will not be able to read the Google advertising ID even if the user has not opted out of sharing their ID.
1055
+
1039
1056
Certain services (such as Google Analytics) require you to coordinate Device and Client IDs in order to prevent duplicate reporting.
1040
1057
1041
1058
To obtain the device Google Advertising identifier, it's necessary to pass a callback function to `Adjust.getGoogleAdId` that will receive the Google Advertising ID in it's argument, like this:
**Note**: Information about **adid** is available after app installation has been tracked by the Adjust backend. From that moment on, Adjust SDK has information about your device **adid** and you can access it with this method. So, **it is not possible** to access **adid** value before the SDK has been initialised and installation of your app was tracked successfully.
1070
1087
1088
+
### <aid="set-external-device-id"></a>Set external device ID
1089
+
1090
+
> **Note** If you want to use external device IDs, please contact your Adjust representative. They will talk you through the best approach for your use case.
1091
+
1092
+
An external device identifier is a custom value that you can assign to a device or user. They can help you to recognize users across sessions and platforms. They can also help you to deduplicate installs by user so that a user isn't counted as multiple new installs.
1093
+
1094
+
You can also use an external device ID as a custom identifier for a device. This can be useful if you use these identifiers elsewhere and want to keep continuity.
1095
+
1096
+
Check out our [external device identifiers article](https://help.adjust.com/en/article/external-device-identifiers) for more information.
1097
+
1098
+
> **Note** This setting requires Adjust SDK v4.21.0 or later.
1099
+
1100
+
To set an external device ID, assign the identifier to the `externalDeviceId` property of your config instance. Do this before you initialize the Adjust SDK.
> **Important**: You need to make sure this ID is **unique to the user or device** depending on your use-case. Using the same ID across different users or devices could lead to duplicated data. Talk to your Adjust representative for more information.
1107
+
1108
+
If you want to use the external device ID in your business analytics, you can pass it as a session callback parameter. See the section on [session callback parameters](#cp-session-callback-parameters) for more information.
1109
+
1110
+
You can import existing external device IDs into Adjust. This ensures that the backend matches future data to your existing device records. If you want to do this, please contact your Adjust representative.
If you want to use the Adjust SDK to recognize users whose devices came with your app pre-installed, follow these steps.
@@ -1078,7 +1119,7 @@ If you want to use the Adjust SDK to recognize users whose devices came with you
1078
1119
```dart
1079
1120
adjustConfig.defaultTracker = '{TrackerToken}';
1080
1121
```
1081
-
Replace `{TrackerToken}` with the tracker token you created in step 1. Please note that the Dashboard displays a tracker URL (including `http://app.adjust.com/`). In your source code, you should specify only the six-character token and not the entire URL.
1122
+
Replace `{TrackerToken}` with the tracker token you created in step 1. Please note that the Dashboard displays a tracker URL (including `https://app.adjust.com/`). In your source code, you should specify only the six-character token and not the entire URL.
1082
1123
1083
1124
- Build and run your app. You should see a line like the following in your LogCat:
In order to enable data residency feature, make sure to set `urlStrategy` member of the `AdjustConfig` instance with one of the following constants:
1188
1229
@@ -1192,10 +1233,8 @@ adjustConfig.urlStrategy = AdjustConfig.DataResidencyTR; // for Turkey data resi
1192
1233
adjustConfig.urlStrategy = AdjustConfig.DataResidencyUS; // for US data residency region
1193
1234
```
1194
1235
1195
-
**Note:** This feature is currently in beta testing phase. If you are interested in getting access to it, please contact your dedicated account manager or write an email to [email protected]. Please, do not turn this setting on before making sure with the support team that this feature is enabled for your app because otherwise SDK traffic will get dropped.
1196
-
1197
-
[dashboard]: http://adjust.com
1198
-
[adjust.com]: http://adjust.com
1236
+
[dashboard]: https://adjust.com
1237
+
[adjust.com]: https://adjust.com
1199
1238
1200
1239
[example-app]: example
1201
1240
@@ -1210,14 +1249,14 @@ adjustConfig.urlStrategy = AdjustConfig.DataResidencyUS; // for US data residenc
0 commit comments