Didomi - Developers documentation
  • Introduction
  • SDKs
    • Introduction
    • Web SDK
      • Getting started
      • Tags and vendors management
        • Tags management
          • Events & Variables
            • Deprecated
            • Custom events
          • Tag managers
            • Adobe Launch/DTM
            • Eulerian
            • Google Tag Manager
              • Configure the Didomi / GTM integration
              • Didomi's GTM template
            • Tealium
            • Other tag managers
        • Custom Didomi <script> tags
        • Third-party integrations
          • Google Ad Manager / AdSense
            • GDPR via Non-Personalized Ads
              • Share consent and load/refresh ads
              • Share consent without loading or refreshing ads
            • US states laws
          • Google Consent Mode V2
          • Kameleoon
          • Piano Analytics (AT Internet)
          • Prebid
            • GDPR via IAB TCF
            • US states laws
          • Salesforce DMP (Krux)
        • IAB frameworks
        • Programmatic API
      • Configuration
        • Bots (SEO & Performance tools)
        • Configuration by URL
        • Cookies and storage
        • Custom domains for events
        • Notice
          • Behavior
          • Interactions
          • Look and feel
        • Preferences
        • Theme
      • AB tests
      • Custom domain
        • Domain delegation
        • Reverse proxy
      • Share consents between domains
      • Share consents across devices
      • Pass user choices in query string
      • Serve Didomi assets from your domain
      • Reference
        • API
          • Deprecated
        • Events
      • Performance
    • Mobile and TV SDKs
      • Android and Android TV
        • Setup
        • Logging
        • Reference
          • API
            • Deprecated
          • Events
        • Versions
      • iOS and tvOS
        • Setup
        • Logging
        • App Tracking Transparency (iOS 14.5+)
        • Reference
          • API
            • Deprecated
          • Events
        • Versions
      • Unity
        • Setup
        • Reference
        • Versions
        • Troubleshooting
      • React Native
        • Setup
        • Reference
          • Deprecated
        • Versions
      • Flutter
        • Setup
        • Reference
        • Versions
      • Consent notice
        • Getting started
        • Customize the notice
        • Customize the preferences popup
        • Customize the theme & UI
        • Load notice by ID
      • Third-party SDKs
      • Share consents across devices
      • Share consent with WebViews
      • Google Consent Mode v2
      • FAQ
    • AMP SDK
      • Blocking Behaviors
        • Load immediately on page load
        • Load only after consent (positive or negative)
        • Load only after positive consent
      • Consent status for vendors
    • Help & Support
  • API
    • Introduction
      • Authentication
      • Errors
      • Pagination
      • Filters
      • Caching
      • Rate limiting
      • Quotas
      • Translations
    • Data Manager
      • Regulations
      • Configuration Tree
      • Purposes
        • Purposes & Vendors Numerical IDs
      • Preferences Library
      • User Rights
    • Widgets
      • Consent notices
        • Notices
        • Configurations
        • Multi-Regulation Configurations
          • Migration of Existing Notices and API Updates
        • Deployments
        • Tutorials
          • Create and publish a consent notice
          • Create and publish a multi-regulation consent notice
      • Privacy widgets
        • Create a widget
        • Retrieve widgets
        • Edit a widget
          • Content & Design
            • Themes & Shapes
            • Components
              • auth
              • dsar_form
              • footer
              • header
              • preference
              • preference_value
              • save
              • section
              • sections
            • Options
          • Purposes & preferences
          • Settings
        • Deploy a Widget
          • Use your own subdomain
          • Use your own domain
          • Implement an embeddable widget on your website
        • Authentication
          • Manage authentication providers
          • Authenticate your end-user
        • Archive a widget
        • Headless widgets
          • Public Methods
          • Custom elements
          • Custom events
          • Event listeners
        • Tutorial
          • Launch a Preference Center from a mobile app
    • Compliance Reports
      • Properties
      • Reports
      • CSV format reference
      • Websites
    • Consents and Preferences
      • Events
        • Generate IAB TCF consent string
      • Links
      • Proofs
      • Tokens
      • Secrets
      • Users
      • Tutorial
        • Collect and operate data
    • Privacy Requests
      • Requests
      • Notes
      • Links
      • Emails
  • Integrations
    • Introduction
      • Quotas
    • Generic integrations
      • Batch export
        • Destinations
          • AWS S3 Bucket (owned by Didomi)
          • GCP Storage Bucket
        • Exported data
          • Notices consents
        • Logs
      • Webhooks
      • Batch import
      • Analytics export
        • Destinations
          • AWS S3 Bucket (owned by Didomi)
          • GCP Storage Bucket
    • Third-party apps
      • CMP integrations
        • Didomi-mParticle integration for your CMP
        • Deploy Didomi’s SDK for your Adobe Commerce website
      • Preference Management Platform integrations
        • Actito
        • Adobe Campaign Classic
        • Adobe Experience Cloud
        • Adobe Marketo Engage
        • Adobe Source Connector
        • Braze
        • Dotdigital
        • Hubspot
        • Mailchimp
        • Microsoft Dynamics 365
        • Salesforce Marketing Cloud
        • Salesforce Sales & Service Cloud
        • Selligent
        • Brevo (ex Sendinblue)
    • Tutorials
      • Configure a HTTP webhook
      • Configure a batch export
      • Configure an analytics export
    • Emailing
      • Configurations
        • Actito Email
        • Actito SMS
        • Adobe Campaign Classic
        • Adobe Campaign Standard
      • Emails
        • Templates
        • Manage your templates
Powered by GitBook
On this page
  • User Status
  • getDisabledPurposes
  • getDisabledPurposeIds
  • getDisabledVendors
  • getDisabledVendorIds
  • getEnabledPurposes
  • getEnabledPurposeIds
  • getEnabledVendors
  • getEnabledVendorIds
  • getUserConsentStatusForPurpose
  • getUserConsentStatusForVendor
  • getUserConsentStatusForVendorAndRequiredPurposes
  • getUserLegitimateInterestStatusForPurpose
  • getUserLegitimateInterestForVendor
  • getUserLegitimateInterestStatusForVendorAndRequiredPurposes
  • getUserStatus
  • getUserStatusForVendor
  1. SDKs
  2. Mobile and TV SDKs
  3. React Native
  4. Reference

Deprecated

PreviousReferenceNextVersions

Last updated 2 months ago

User Status

getDisabledPurposes

Removed since version 2.0.0, use instead.

The result of this method has been replaced by getUserStatus().purposes.consent.disabled.

getDisabledPurposeIds

Removed since version 2.0.0, use instead.

The result of this method has been replaced by getUserStatus().purposes.consent.disabled.

getDisabledVendors

Removed since version 2.0.0, use instead.

The result of this method has been replaced by getUserStatus().vendors.consent.disabled.

getDisabledVendorIds

Removed since version 2.0.0, use instead.

The result of this method has been replaced by getUserStatus().vendors.consent.disabled.

getEnabledPurposes

The result of this method has been replaced by getUserStatus().purposes.global.enabled.

getEnabledPurposeIds

The result of this method has been replaced by getUserStatus().purposes.global.enabled.

getEnabledVendors

The result of this method has been replaced by getUserStatus().vendors.consent.enabled.

getEnabledVendorIds

The result of this method has been replaced by getUserStatus().vendors.consent.enabled.

getUserConsentStatusForPurpose

Search the purposeId in getUserStatus().purposes.consent.enabled or getUserStatus().purposes.consent.disabled.

Get the user consent status for a given purpose. You must also check that the user has given consent to a vendor before being able to load a vendor.

Parameters

Name
Type
Description

purposeId

string

The ID of the purpose to check the user consent for

Returns

A Promise<boolean> that indicates if the user has given consent or not to the specific purpose.

undefined is returned if the consent status is not known yet. From a GDPR perspective, you'll want to treat undefined as false (ie no consent given) but it is helpful to know that the user has not interacted with the consent UI yet so that you can subscribe to events and wait for consent information to be collected.

If consent is not required because GDPR does not apply to that user, this function will return true.

Example

await Didomi.getUserConsentStatusForPurpose("analytics");

getUserConsentStatusForVendor

Search the vendorId in getUserStatus().vendors.consent.enabled or getUserStatus().vendors.consent.disabled.

getUserConsentStatusForVendorAndRequiredPurposes

Search the purposeId in getUserStatus().vendors.global_consent.enabled or getUserStatus().vendors.global_consent.disabled.

getUserLegitimateInterestStatusForPurpose

Search the purposeId in getUserStatus().purposes.legitimate_interest.enabled or getUserStatus().purposes.legitimate_interest.disabled.

getUserLegitimateInterestForVendor

Search the vendorId in getUserStatus().vendors.legitimate_interest.enabled or getUserStatus().vendors.legitimate_interest.disabled.

getUserLegitimateInterestStatusForVendorAndRequiredPurposes

Search the vendorId in getUserStatus().vendors.global_legitimate_interest.enabled or getUserStatus().vendors.global_legitimate_interest.disabled.

getUserStatus

Get all the user consent status.

Returns

A UserStatus object describing all the available and computed user information.

Parameter
Type
Description

purposes.global.disabled

string[]

Computed sets/lists of disabled IDs of purposes that have been chosen by the user regarding the consent or legitimate interest Legal Basis.

purposes.global.enabled

string[]

Computed sets/lists of enabled IDs of purposes that have been chosen by the user regarding the consent or legitimate interest Legal Basis. Purposes considered as essential will be part of the enabled IDs.

purposes.consent.disabled

string[]

Disabled IDs of purposes that have been explicitly chosen by the user regarding the consent Legal Basis.

purposes.consent.enabled

string[]

Enabled IDs of purposes that have been explicitly chosen by the user regarding the consent Legal Basis.

purposes.legitimate_interest.disabled

string[]

Disabled IDs of purposes that have been explicitly chosen by the user regarding the legitimate interest Legal Basis.

purposes.legitimate_interest.enabled

string[]

Enabled IDs of purposes that have been explicitly chosen by the user regarding the legitimate interest Legal Basis.

purposes.essential

string[]

IDs of purposes that are considered essential.

vendors.global.disabled

string[]

Computed sets/lists of disabled IDs of vendors that have been chosen by the user regarding the consent or legitimate interest Legal Basis. This takes into account the consent and legitimate interest required purposes linked to vendors. When computing this property, essential purposes will be considered as enabled.

vendors.global.enabled

string[]

Computed sets/lists of enabled IDs of vendors that have been chosen by the user regarding the consent or legitimate interest Legal Basis. This takes into account the consent and legitimate interest required purposes linked to vendors. When computing this property, essential purposes will be considered as enabled.

vendors.global_consent.disabled

string[]

Computed sets/lists of disabled IDs of vendors that have been chosen by the user regarding the consent Legal Basis. This takes into account the consent required purposes linked to vendors. When computing this property, essential purposes will be considered as enabled.

vendors.global_consent.enabled

string[]

Computed sets/lists of enabled IDs of vendors that have been chosen by the user regarding the consent Legal Basis. This takes into account the consent required purposes linked to vendors. When computing this property, essential purposes will be considered as enabled.

vendors.global_legitimate_interest.disabled

string[]

Computed sets/lists of disabled IDs of vendors that have been chosen by the user regarding the legitimate interest Legal Basis. This takes into account the legitimate interest required purposes linked to vendors. When computing this property, essential purposes will be considered as enabled.

vendors.global_legitimate___interest.enabled

string[]

Computed sets/lists of enabled IDs of vendors that have been chosen by the user regarding the legitimate interest Legal Basis. This takes into account the legitimate interest required purposes linked to vendors. When computing this property, essential purposes will be considered as enabled.

vendors.consent.disabled

string[]

Disabled IDs of vendors that have been explicitly chosen by the user regarding the consent Legal Basis.

vendors.consent.enabled

string[]

Enabled IDs of vendors that have been explicitly chosen by the user regarding the consent Legal Basis.

vendors.legitimate_interest.disabled

string[]

Disabled IDs of vendors that have been explicitly chosen by the user regarding the legitimate interest Legal Basis.

vendors.legitimate_interest.enabled

string[]

Enabled IDs of vendors that have been explicitly chosen by the user regarding the legitimate interest Legal Basis.

user_id

String

Didomi user id.

created

String

User choices creation date.

updated

String

User choices update date.

consent_string

String

TFC consent as string.

additional_consent

String

Example

let userStatus = await Didomi.getUserStatus();

// Enabled consent ids for vendors
let enabledVendorsConsentIds = userStatus.vendors.consent.enabled;

getUserStatusForVendor

Search the vendorId in getUserStatus().vendors.global.enabled or getUserStatus().vendors.global.disabled.

Removed since version 2.0.0, use instead.

Removed since version 2.0.0, use instead.

Removed since version 2.0.0, use instead.

Removed since version 2.0.0, use instead.

Deprecated, use instead.

Removed since version 2.0.0, use instead.

Removed since version 2.0.0, use instead.

Removed since version 2.0.0, use instead.

Removed since version 2.0.0, use instead.

Removed since version 2.0.0, use instead.

Deprecated, use instead.

Additional consent for .

Removed since version 2.0.0, use instead.

Google Additional Consent Mode
getCurrentUserStatus
getCurrentUserStatus
getCurrentUserStatus
getCurrentUserStatus
getCurrentUserStatus
getCurrentUserStatus
getCurrentUserStatus
getCurrentUserStatus
getCurrentUserStatus
getCurrentUserStatus
getCurrentUserStatus
getCurrentUserStatus
getCurrentUserStatus
getCurrentUserStatus
getCurrentUserStatus
getCurrentUserStatus