SDK init / ATS DT Exchange SDK

API init Method and Callback


- (void)initWithAppID:(NSString * _Nonnull)appID
      completionBlock:(IASDKCoreInitBlock _Nullable)completionBlock
      completionQueue:(dispatch_queue_t _Nullable)completionQueue;

App ID:
initWithAppID: : NSString
A mandatory param which defines the application id.

Callback (optional):
completionBlock: : ^(BOOL success, NSError * _Nullable error)
A completion block.

Completion block queue (optional):
completionQueue: : dispatch_queue_t
An optional queue for completion block to invoke on.

API init Flag


@property (atomic, readonly, getter=isInitialised) BOOL initialised;

Indicates whether the SDK is initialised.

Callback Completion Error Codes


typedef NS_ENUM(NSInteger, IASDKCoreInitErrorType) {
    IASDKCoreInitErrorTypeUnknown = 0,
    IASDKCoreInitErrorTypeFailedToDownloadMandatoryData = 1,
    IASDKCoreInitErrorTypeMissingModules = 2,
    IASDKCoreInitErrorTypeInvalidAppID = 3,
    IASDKCoreInitErrorTypeCancelled = 4

If an error occurs (NSError) an error is returned with one of the provided codes.

ATS DT Exchange SDK

Assuming the DT Exchange SDK is integrated in a way it expects both HTML and VIDEO content - the following table summarises the security flow per application configuration.

Final Outgoing
Yes - - - Non-secure
Any Present - - Secure
Any - Present - Secure
Any - - Present Secure
No / - Any Any Any Secure

" - " Indicates the flag is not present
" Any " Indicates YES or NO, or was not explicitly configured

App Transport Security (ATS)

The NSAllowsArbitraryLoadsInWebContent key for Info.plist file gives a convenient way to allow non-secured ad requests for HTML/MRAID content ads.

If you use this key in combination with video ads, the DT Secure Mode should be enabled. If your ATS global restriction is enabled, DT Secure Mode should be enabled as well.
It can be enabled in the IAAdRequest object.

Enabling the secure mode
IAAdRequest *request = [IAAdRequest build:^(id<IAAdRequestBuilder>  _Nonnull builder) {
    builder.useSecureConnections = YES;


Starting from the iOS 10.0, in case there are two keys present in the info.plist - both NSAllowsArbitraryLoadsInWebContent and NSAllowsArbitraryLoads, the NSAllowsArbitraryLoads will not have any effect.

If you need a global permission, you should keep only the NSAllowArbitraryLoads with YES in your .plist file, and the key NSAllowArbitraryLoadsInWebContent should be deleted. Otherwise, it won't work, because the NSAllowArbitraryLoadsInWebContent cancels out the previous one.

The same is for these keys as well:

  • NSAllowsArbitraryLoadsForMedia
  • NSAllowsLocalNetworking

Also it is important to understand, that the NSAllowsArbitraryLoadsForMedia does not exclude the VAST videos, in terms of ATS, it does not have any effect on the DT Exchange SDK and will only override the global NSAllowsArbitraryLoads key, which will result in a secure request, even it was not intended so.

The DT Exchange SDK will not necessarily send a secure request. If the SDK determines, that the request can be sent as insecure, it will be sent as insecure. This is in order to improve a fill, since there are more DSP sources for such requests.

On the other hand - if the SDK detects inconsistency in the ATS configuration, it will send a secure request, regardless of the ATS/IAAdRequest configuration/intention.

Apple has recently extended their secure networking obligation to an unknown date. Updates will be sent out to all publishers once Apple reinstates their security demands.

Enabling Global Permissions

To enable a global permission to a non-secured HTTP request, you'll need to add this to your Info.plist file:




There is no need in the location permissions. DT Exchange SDK does not use the location services, it only expects to receive the CLLocation object in order to fetch the location data from it and pass it in the ad request.

IDFA Key Information

Starting with iOS 10: in the event that a user has enabled the Privacy -> Advertising -> Limit Ad Tracking, the IDFA key will be "filled" with zeroes: 00000000-0000-0000-0000-000000000000.

Bitcode Support

The IASDK static library is compiled with bitcode flag enabled. This means the project that integrates IASDK could be compiled with bitcode flag enabled.

More information about Bitcode can be found here

Multitasking Enhancements for iPad (Slide Over, Split View)

IASDK supports the new screen modes for iPad - Slide Over, Split View.

More information about Multitasking Enhancements for iPad can be found here.

Back to Top ⇧