# Managed Consent

### Introduction

AATKit’s Managed Consent is an easy way to facilitate [IAB TCF](https://iabeurope.eu/transparency-consent-framework/) compliant third-party [Consent Management Platforms](https://iabeurope.eu/tcf-for-cmps/) (CMPs) by providing a unified API and wrappers. In order to make use of Managed Consent, AATKit React Native plugin provides CMP implementations.

### **Google CMP Usage**

Android requires appId to be added to the `AndroidManifest` file, like

```xml
<meta-data
          android:name="com.google.android.gms.ads.APPLICATION_ID"
          android:value="YOUR-APP-ID"/>
```

For iOS you need to set the `GADApplicationIdentifier` value to the `Info.plist` file, like:

```xml
<key>GADApplicationIdentifier</key>
<string>YOUR-APP-ID</string>
```

Uncomment `configureGoogleCMP` method call in `initAATKit`:

{% code title="AATKitBinding.kt" %}

```kotlin
private fun initAATKit() {
    ...

    //Comment out the bellow line if Google CMP is needed
    configureGoogleCMP(configuration)

    ...
}
```

{% endcode %}

{% code title="AATKitBinding.swift" %}

```swift
private func initAATKit() {
    ...

    //Comment out the bellow line if Google CMP is needed
    configureGoogleCMP(configuration: configuration)

    ...
}
```

{% endcode %}

### **Source Point CMP Usage**

Uncomment `configureSourcePointCMP` method call in `initAATKit`, also make sure you pass all required parameters:

{% code title="AATKitBinding.kt" %}

```kotlin
private fun initAATKit() {
    ...

    //Comment out the bellow line if Ogury CMP is needed
    configureSourcePointCMP(configuration,<your-sccount-id>, <your-property-id>, "your-property-name", "your-pm-id")

    ...
}
```

{% endcode %}

{% code title="AATKitBinding.swift" %}

```swift
private func initAATKit() {
    ...

    //Comment out the bellow line if Ogury CMP is needed
    configureSourcePointCMP(configuration: configuration, accountId: "your-sccount-id", propertyId: "your-property-id", propertyName: "your-property-name", pmId: "your-pm-id")

    ...
}
```

{% endcode %}

### Not using the CMP wrapper <a href="#markdown-header-not-using-the-addapptr-cmp-wrapper" id="markdown-header-not-using-the-addapptr-cmp-wrapper"></a>

If for some reason you do not want to use CMP wrappers, AATKit also provides another methods for GDPR compliance. The `isConsentRequired` configuration parameter allows you to inform AATKit if the user is subject to the GDPR laws:

{% code title="AATKitBinding.kt" %}

```kotlin
private fun initAATKit() {
    ...

    configuration.isConsentRequired = true

    ...
}
```

{% endcode %}

{% code title="AATKitBinding.swift" %}

```swift
private func initAATKit() {
    ...

    configuration.consentRequired = true

    ...
}
```

{% endcode %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://aatkit.gitbook.io/aatkit-flutter-binding/start/consent/managed-consent.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
