Skip to content

Third-Party Integrations

Section titled “Third-Party SDK Integrations (Consent Signaling)”

The Secure Privacy SDK supports automatic consent signaling for third-party SDKs such as analytics and attribution platforms. This ensures compliance while reducing manual work.

You can choose how the Secure Privacy SDK interacts with your third-party SDKs:

  1. Provide Credentials in SPAuthKey
    If you include an integration config (e.g., SPSingularConfig, SPTenjinConfig, SPAirbridgeConfig) inside SPAuthKey, the Secure Privacy SDK will:

    • Automatically initialize the integration SDK.
    • Apply the correct consent state at runtime.
  2. Skip Credentials
    If you prefer to handle initialization yourself (for example, to use advanced features such as custom logging, debugging, or extra configuration options not exposed by Secure Privacy SDK):

    • Do not provide the integration config in SPAuthKey.
    • Initialize the integration SDK before initializing Secure Privacy SDK.
    • Secure Privacy SDK will only apply consent to the already-initialized SDK.

Recommendation:
If you handle initialization yourself, start the integration SDK in restricted mode (minimal tracking) until Secure Privacy SDK has loaded. It will automatically update the consent status based on the user’s locale, applicable regulations, and your backend configurations.

  • Google Consent Mode v2
  • Singular (App Attribution)
  • Tenjin (App Attribution)
  • Airbridge (App Attribution)

More integrations will be added in upcoming releases.


If your app uses Google Analytics for Firebase and you plan to enable Google Consent Mode, you must configure consent flags in your app’s Info.plist file to set default values before user consent is collected.

<key>GOOGLE_ANALYTICS_DEFAULT_ALLOW_ANALYTICS_STORAGE</key>
<false/>
<key>GOOGLE_ANALYTICS_DEFAULT_ALLOW_AD_STORAGE</key>
<false/>
<key>GOOGLE_ANALYTICS_DEFAULT_ALLOW_AD_USER_DATA</key>
<false/>
<key>GOOGLE_ANALYTICS_DEFAULT_ALLOW_AD_PERSONALIZATION_SIGNALS</key>
<false/>

Note: These values are required only if you have enabled Google Consent Mode for your app. Apps not using Firebase Analytics or Google Ads can skip this.

These default values are temporarily applied only until the Secure Privacy SDK syncs with its backend. Based on the device’s locale or regulatory region, an updated configuration is applied automatically, and consent values are later adjusted based on the user’s choice.

👉 Refer to Google’s Consent Mode Guide for full details.

Secure Privacy supports consent signaling for multiple attribution SDKs. You only need to provide the appropriate credentials during initialization.

The SDK will:

  • Automatically initialize supported SDKs at runtime (if present).
  • Apply Restricted Mode if consent is denied, and Full Mode when granted.
  • Not handle tracking or analytics logic — you’re still responsible for event logging.

To integrate the Singular SDK, provide the credentials using SPSingularConfig:

let result = await SPConsentEngineFactory.initialise(
key: SPAuthKey(
applicationId: "YOUR_APPLICATION_ID",
secondaryApplicationId: "YOUR_SECONDARY_APPLICATION_ID",
integrationConfigs: [
SPSingularConfig(apiKey: "YOUR_SINGULAR_API_KEY", secret: "YOUR_SINGULAR_SECRET")
]
)
)

To integrate the Tenjin SDK, provide the credentials using SPTenjinConfig:

let result = await SPConsentEngineFactory.initialise(
key: SPAuthKey(
applicationId: "YOUR_APPLICATION_ID",
secondaryApplicationId: "YOUR_SECONDARY_APPLICATION_ID",
integrationConfigs: [
SPTenjinConfig(apiKey: "YOUR_TENJIN_API_KEY")
]
)
)

To integrate the Airbridge SDK, provide the credentials using SPAirbridgeConfig:

let result = await SPConsentEngineFactory.initialise(
key: SPAuthKey(
applicationId: "YOUR_APPLICATION_ID",
secondaryApplicationId: "YOUR_SECONDARY_APPLICATION_ID",
integrationConfigs: [
SPAirbridgeConfig(
appName : "YOUR_APP_NAME",
appToken : "YOUR_APP_TOKEN"
)
]
)
)


Note: The actual usage of third-party SDKs (such as those mentioned above for analytics or attribution — e.g., event tracking, user properties) remains the responsibility of the app developer. The Secure Privacy SDK focuses solely on consent signaling and, when configured, initialization.