Secondary methods
Ad impression
The event is used for individual tracking of ad revenue on user devices. The method is used if there are CPI data available on the client device (they can be obtained from the ad network SDK).
network
String
from 1 to 100 symbols
Name of the ad network responsible for the impression
revenue
Double
from 0,0 to Double.max
Reward for banner display in USD
placement
String?
from 1 to 100 symbols, optional
Banner placement
unit
String?
from 1 to 100 symbols, optional
Banner name
DTDAnalytics.adImpression(network: "Network name",
revenue: 0.15,
placement: "Placement of the banner",
unit: "Banner title")network
NSString
from 1 to 100 symbols
Name of the ad network responsible for the impression
revenue
double
from 0,0 to Double.max
Reward for banner display in USD
placement
NSString _Nullable
from 1 to 100 symbols, optional
Banner placement
unit
NSString _Nullable
from 1 to 100 symbols, optional
Banner name
[DTDAnalytics adImpressionWithNetwork:@"Network name"
revenue:0.15f
placement:@"Placement of the banner"
unit:@"Banner title"];network
String
from 1 to 100 symbols
Name of the ad network responsible for the impression
revenue
Double
from 0,0 to Double.max
Reward for banner display in USD
placement
String?
from 1 to 100 symbols, optional
Banner placement
unit
String?
from 1 to 100 symbols, optional
Banner name
DTDAnalytics.adImpression(
network = "Network name",
revenue = 0.45,
placement = "Placement of the banner",
unit = "Banner title"
)network
String
from 1 to 100 symbols
Name of the ad network responsible for the impression
revenue
Double
from 0,0 to Double.max
Reward for banner display in USD
placement
String?
from 1 to 100 symbols, optional
Banner placement
unit
String?
from 1 to 100 symbols, optional
Banner name
network
String
from 1 to 100 symbols
Name of the ad network responsible for the impression
revenue
Double
from 0,0 to Double.max
Reward for banner display in USD
placement
String?
from 1 to 100 symbols, optional
Banner placement
unit
String?
from 1 to 100 symbols, optional
Banner name
network
String
from 1 to 100 symbols
Name of the ad network responsible for the impression
revenue
Double
from 0,0 to Double.max
Reward for banner display in USD
placement
String?
from 1 to 100 symbols, optional
Banner placement
unit
String?
from 1 to 100 symbols, optional
Banner name

Parameter
Type
Restrictions
Description
socialNetwork
FString
from 1 to 100 symbols
The name of the ad network that delivered the impression.
revenue
float
form 0.0 to float.MaxValue
Reward for displaying a banner in USD.
placement
FString
from 1 to 100 symbols
Placement of the banner.
unit
FString
from 1 to 100 symbols
Banner title.
network
String
from 1 to 100 symbols
Name of the ad network responsible for the impression
revenue
Float
from 0,0 to Double.max
Reward for banner display in USD
placement
String
from 1 to 100 symbols, optional
Banner placement
unit
String
from 1 to 100 symbols, optional
Banner name
Connecting to social networks
The event is used to track connections to social media channels.
Use the following constants to specify a social network:
.facebook, .vkontakte , .twitter, .googleplus, .whatsapp, .viber, .evernote, .googlemail, .linkedin, .pinterest, .qzone, .reddit, .renren, .tumblr
Or create an object with the desired social media name.
let network = DTDSocialNetwork(name: "NetworkName")
DTDAnalytics.socialNetworkConnect(socialNetwork: network)Use the following constants to specify a social network:
.facebook, .vkontakte , .twitter, .googleplus, .whatsapp, .viber, .evernote, .googlemail, .linkedin, .pinterest, .qzone, .reddit, .renren, .tumblr
Or create an object with the desired social media name.
DTDSocialNetwork *network = [[DTDSocialNetwork alloc] initWithName:@"NetworkName"];
[DTDAnalytics socialNetworkConnect:network];Use the following constants to specify a social network:
DTDSocialNetwork.facebook, DTDSocialNetwork.vkontakte , DTDSocialNetwork.twitter, DTDSocialNetwork.googleplus, DTDSocialNetwork.whatsapp, DTDSocialNetwork.viber, DTDSocialNetwork.evernote, DTDSocialNetwork.googlemail, DTDSocialNetwork.linkedin, DTDSocialNetwork.pinterest, DTDSocialNetwork.qzone, DTDSocialNetwork.reddit, DTDSocialNetwork.renren, DTDSocialNetwork.tumblr
Or create an object with the desired social media name.
DTDAnalytics.socialNetworkPost(
socialNetwork = DTDSocialNetwork.facebook
)Use the following constants to specify a social network:
DTDSocialNetwork.Companion.getFacebook(), DTDSocialNetwork.Companion.getVkontakte(), DTDSocialNetwork.Companion.getTwitter(), DTDSocialNetwork.Companion.getGoogleplus(), DTDSocialNetwork.Companion.Whatsapp(), DTDSocialNetwork.Companion.getViber(), DTDSocialNetwork.Companion.getEvernote(), DTDSocialNetwork.Companion.getGooglemail(), DTDSocialNetwork.Companion.getLinkedin(), DTDSocialNetwork.Companion.getPinterest(), DTDSocialNetwork.Companion.getQzone(), DTDSocialNetwork.Companion.getReddit(), DTDSocialNetwork.Companion.getRenren(), DTDSocialNetwork.Companion.getTumblr()
Or create an object with the desired social media name.
DTDAnalytics.INSTANCE.socialNetworkConnect(DTDSocialNetwork.Companion.getFacebook());Use the following constants to specify a social network:
DTDSocialNetwork.facebook, DTDSocialNetwork.vkontakte , DTDSocialNetwork.twitter, DTDSocialNetwork.googleplus, DTDSocialNetwork.whatsapp, DTDSocialNetwork.viber, DTDSocialNetwork.evernote, DTDSocialNetwork.googlemail, DTDSocialNetwork.linkedin, DTDSocialNetwork.pinterest, DTDSocialNetwork.qzone, DTDSocialNetwork.reddit, DTDSocialNetwork.renren, DTDSocialNetwork.tumblr
Or create an object with the desired social media name:
Use the following constants to specify a social network:
DTDSocialNetwork.facebook, DTDSocialNetwork.vkontakte , DTDSocialNetwork.twitter, DTDSocialNetwork.googleplus, DTDSocialNetwork.whatsapp, DTDSocialNetwork.viber, DTDSocialNetwork.evernote, DTDSocialNetwork.googlemail, DTDSocialNetwork.linkedin, DTDSocialNetwork.pinterest, DTDSocialNetwork.qzone, DTDSocialNetwork.reddit, DTDSocialNetwork.renren, DTDSocialNetwork.tumblr
Or create an object with the desired social media name:

Argument
Type
Description
socialNetwork
EDTDSocialNetwork
Predefined social network.
Or use special method for custom social network:

Argument
Type
Description
socialNetwork
FString
Custom social network.
Use the following constants to specify a social network:
.facebook, .vkontakte , .twitter, .googleplus, .whatsapp, .viber, .evernote, .googlemail, .linkedin, .pinterest, .qzone, .reddit, .renren, .tumblr
Or create an object with the desired social media name.
Posting to social networks
Track social media posts and analyze their effectiveness and virality. Pass the event after the post has been approved by social media.

Argument
Type
Description
socialNetwork
EDTDSocialNetwork
Predefined social network.

Argument
Type
Description
socialNetwork
FString
Custom social network.
Referrer
If you have referral information, you can pass it using the following method:

Argument
Type
Description
utmData
TMap<EDTDReferralProperty, FString>
UTM data.
Force dispatch of accumulated events
To send an event packet before it is full (10 events, by default) or before the end of the period of its formation (2 minutes, by default), you can use immediate dispatch.

Setters & Getters
For example:

Argument
Type
Description
onResult
FAnalyticsDynamicGetterStringDelegate
FDTDGetterStringDelegate
Callback.
Setting User Tracking Status (GDPR)
This method denies/allows tracking of user data and also implements the right to be forgotten in accordance with the requirements of the GDPR.
When this method is called with the 'false' value, the SDK sends a command to the server to delete all personal user data that was collected by devtodev in this application, blocking further user data collection.
The user will remain in the devtodev system only as an impersonal unit in the previously aggregated metrics.
If it is set to ‘true', tracking can be enabled again. In this case, the user will be considered new.
To enable/disable user tracking by the devtodev system. Bool type.

Getting device ID
Get device ID. String type.

Argument
Type
Description
onResult
FAnalyticsDynamicGetterStringDelegate
FDTDGetterStringDelegate
Callback.
Getting the devtodev SDK version
Get the version of the integrated devtodev SDK. String type.

Argument
Type
Description
onResult
FAnalyticsDynamicGetterStringDelegate
FDTDGetterStringDelegate
Callback.
Obtaining user tracking status (GDPR)
Retrieving the saved state of the user tracking permission by the devtodev system. See “Setting User Tracking Status”. Bool type.

Argument
Type
Description
onResult
FAnalyticsDynamicGetterBoolDelegate
FDTDGetterBoolDelegate
Callback.
Getting devtodev ID
devtodev ID is the primary numeric identifier for the device/user account in the devtodev database. Using devtodev ID, you are sure to find the user in devtodev.
The identifier will be received from the server some time after the initialization of the SDK.
If you have set counting by users, a separate devtodev id will be issued for each device user.
To obtain the devtodev ID, you need to pass the listener to DTDAnalytics:
The delegate must implement the func didReceiveDevtodevId(with devtodevId: Int)
The didReceiveDevtodevId method will be called with every ID change on the server side.
To obtain the devtodev ID, you need to pass the listener to DTDAnalytics:
The delegate must implement the (void)didReceiveDevtodevIdWith:(NSInteger)devtodevId;
The didReceiveDevtodevId method will be called with every ID change on the server side.
To obtain the devtodev ID, you need to pass the DTDIdentifiersListener listener to DTDAnalytics:
The didReceiveDevtodevId method will be called with every ID change on the server side.
To obtain the devtodev ID, you need to pass the DTDIdentifiersListener listener to DTDAnalytics:
The didReceiveDevtodevId method will be called with every ID change on the server side.
To obtain the devtodev ID, you need to pass the DTDIdentifiersListener listener delegate to DTDAnalytics:
The delegate method will be called with every ID change on the server side.
To obtain the devtodev ID, you need to pass the DTDIdentifiersListener listener delegate to DTDAnalytics:
The delegate method will be called with every ID change on the server side.

Argument
Type
Description
listener
FAnalyticsDynamicGetterLongDelegate
FDTDGetterLongDelegate
devtodev ID Listener.
To obtain the devtodev ID, you need to pass the Callable to DTDAnalytics:
The didReceiveDevtodevId method will be called with every ID change on the server side.
Initialization callback
To receive a callback when the SDK initialization is complete, you can use a method that will implement the initialization callback. When the SDK completes the initialization, the callback will be called on the main application thread.
Last updated
Was this helpful?
