Simple Consent

Handle consent using AATKit simple consent

Introduction

To set if the user has given or withheld consent for the collection and use of personal data (used for non-IAB partners), use the AATSimpleConsent default initializer and pass any value of the NonIABConsent enum

  • .obtained if the user has given consent.

  • .withheld if the user has declined.

  • .unknown if the user has not set a preference.

If AATSimpleConsent is used, AATKit will automatically read the IAB consent string stored (by third-party CMP) in NSUserDefaults (if available) and respect the settings for Gravite.

Usage

func configureAATKit() {
    let configuration = AATConfiguration()
    ...
    let consent = AATSimpleConsent(nonIABConsent: .obtained)
    configuration.consent = consent
    ...
    AATSDK.initAATKit(with: configuration)
}

Last updated