This repository was archived by the owner on May 5, 2026. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Sending hits according to the application state
Benjamin Diolez edited this page May 5, 2026
·
1 revision
The Internet AT SDK allows you to condition the sending of hits, depending on the application state (Active, Inactive, other).
The SDK has a configuration key “sendOnApplicationState” which can take different values:
- “activeOnly”: to send hits when the application is in active mode only.
- “activeOrInactive”: to send hits when the application is in active or inactive mode.
- “all” (default value): to send hits without considering the application state.
The settings can be changed in the application code via the dedicated helper “setSendOnApplicationState” or via the “setConfig” configuration update method.
The “setSendOnApplicationState” helper is only available on Swift.
Using the helper:
let tracker = ATInternet.sharedInstance.defaultTracker
// Send hits without considering application state
tracker.setSendOnApplicationState(SendApplicationState.all, sync: true, completionHandler: nil)
// Send hits when application is active only
tracker.setSendOnApplicationState(SendApplicationState.activeOnly, sync: true, completionHandler: nil)
// Send hits when application is active or inactive
tracker.setSendOnApplicationState(SendApplicationState.activeOrInactive, sync: true, completionHandler: nil)Using the configuration update method:
let tracker = ATInternet.sharedInstance.defaultTracker
// Send hits without considering application state
tracker.setConfig("sendOnApplicationState", value: "all", sync: true, completionHandler: nil)
// Send hits when application is active only
tracker.setConfig("sendOnApplicationState", value: "activeOnly", sync: true, completionHandler: nil)
// Send hits when application is active or inactive
tracker.setConfig("sendOnApplicationState", value: "activeOrInactive", sync: true, completionHandler: nil)Tracker* tracker = [ATInternet sharedInstance].defaultTracker;
// Send hits without considering application state
[tracker setConfig:@"sendOnApplicationState" value:@"all" sync:YES completionHandler:nil];
// Send hits when application is active only
[tracker setConfig:@"sendOnApplicationState" value:@"activeOnly" sync:YES completionHandler:nil];
// Send hits when application is active or inactive
[tracker setConfig:@"sendOnApplicationState" value:@"activeOrInactive" sync:YES completionHandler:nil];-
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