Stay organized with collections
Save and categorize content based on your preferences.
Utility methods for managing consent information from users.
Summary
Properties
Public static functions
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-08-20 UTC.
[null,null,["Last updated 2025-08-20 UTC."],[[["\u003cp\u003e\u003ccode\u003eConsentInformation\u003c/code\u003e provides utility methods for managing user consent information, including status and privacy options.\u003c/p\u003e\n"],["\u003cp\u003eIt allows checking if ads can be requested (\u003ccode\u003eCanRequestAds\u003c/code\u003e) and if a consent form is available (\u003ccode\u003eIsConsentFormAvailable\u003c/code\u003e).\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003eUpdate\u003c/code\u003e method requests a consent information update based on provided parameters.\u003c/p\u003e\n"],["\u003cp\u003e\u003ccode\u003eReset\u003c/code\u003e clears all stored consent status, and \u003ccode\u003eConsentStatus\u003c/code\u003e and \u003ccode\u003ePrivacyOptionsRequirementStatus\u003c/code\u003e provide cached status values.\u003c/p\u003e\n"]]],["This documentation outlines methods for managing user consent. Key actions include: checking the user's `ConsentStatus` and `PrivacyOptionsRequirementStatus`, and determining if ads (`CanRequestAds`) or a `ConsentForm` (`IsConsentFormAvailable`) are available. The `Reset` function clears stored consent data. The `Update` function initiates an update to consent information using `ConsentRequestParameters` and triggers a callback with a `FormError` if necessary.\n"],null,["# GoogleMobileAds.Ump.Api.ConsentInformation Class Reference\n\nGoogleMobileAds.Ump.Api.ConsentInformation\n==========================================\n\nUtility methods for managing consent information from users.\n\nSummary\n-------\n\n| ### Properties ||\n|----------------------------------------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| [ConsentStatus](#class_google_mobile_ads_1_1_ump_1_1_api_1_1_consent_information_1abacd73007dac5a12f2ba707803b42423) | `static `[ConsentStatus](/ad-manager/mobile-ads-sdk/unity/reference/namespace/google-mobile-ads/ump/api#namespace_google_mobile_ads_1_1_ump_1_1_api_1aa83ad2ecf6f2a08c584b60cef06f5133) The user's consent status. |\n| [PrivacyOptionsRequirementStatus](#class_google_mobile_ads_1_1_ump_1_1_api_1_1_consent_information_1ac36628db375fe88760d15c5ffbf71a11) | `static `[PrivacyOptionsRequirementStatus](/ad-manager/mobile-ads-sdk/unity/reference/namespace/google-mobile-ads/ump/api#namespace_google_mobile_ads_1_1_ump_1_1_api_1a60f41ef4f7e14d5ae1fb5f23b7e0244b) Privacy options requirement status. |\n\n| ### Public static functions ||\n|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| [CanRequestAds](#class_google_mobile_ads_1_1_ump_1_1_api_1_1_consent_information_1a9a0eec58c07401d66549f5ebaf512696)`()` | `bool` Check if the app has finished all the required consent flow and can request ads now. |\n| [IsConsentFormAvailable](#class_google_mobile_ads_1_1_ump_1_1_api_1_1_consent_information_1a2050b297b2ec27745446e8ef50daf628)`()` | `bool` Returns `true` if a [ConsentForm](/ad-manager/mobile-ads-sdk/unity/reference/class/google-mobile-ads/ump/api/consent-form#class_google_mobile_ads_1_1_ump_1_1_api_1_1_consent_form) is available, otherwise returns `false`. |\n| [Reset](#class_google_mobile_ads_1_1_ump_1_1_api_1_1_consent_information_1a73df3ea825acf03628988f28ceb897e5)`()` | `void` Clears all consent status from persistent storage. |\n| [Update](#class_google_mobile_ads_1_1_ump_1_1_api_1_1_consent_information_1ab1ba02caaef0508da01eeb3d537d8c69)`(`[ConsentRequestParameters](/ad-manager/mobile-ads-sdk/unity/reference/class/google-mobile-ads/ump/api/consent-request-parameters#class_google_mobile_ads_1_1_ump_1_1_api_1_1_consent_request_parameters)` request, Action\u003c `[FormError](/ad-manager/mobile-ads-sdk/unity/reference/class/google-mobile-ads/ump/api/form-error#class_google_mobile_ads_1_1_ump_1_1_api_1_1_form_error)` \u003e consentInfoUpdateCallback)` | `void` Requests consent information update. |\n\nProperties\n----------\n\n### ConsentStatus\n\n```c#\nstatic ConsentStatus ConsentStatus\n``` \nThe user's consent status.\n\nThis value is cached between app sessions and can be read before requesting updated parameters. \n\n### PrivacyOptionsRequirementStatus\n\n```c#\nstatic PrivacyOptionsRequirementStatus PrivacyOptionsRequirementStatus\n``` \nPrivacy options requirement status.\n\nPublic static functions\n-----------------------\n\n### CanRequestAds\n\n```c#\nbool CanRequestAds()\n``` \nCheck if the app has finished all the required consent flow and can request ads now. \n\n### IsConsentFormAvailable\n\n```c#\nbool IsConsentFormAvailable()\n``` \nReturns `true` if a [ConsentForm](/ad-manager/mobile-ads-sdk/unity/reference/class/google-mobile-ads/ump/api/consent-form#class_google_mobile_ads_1_1_ump_1_1_api_1_1_consent_form) is available, otherwise returns `false`. \n\n### Reset\n\n```c#\nvoid Reset()\n``` \nClears all consent status from persistent storage. \n\n### Update\n\n```c#\nvoid Update(\n ConsentRequestParameters request,\n Action\u003c FormError \u003e consentInfoUpdateCallback\n)\n``` \nRequests consent information update.\n\n\u003cbr /\u003e\n\n| Details ||\n|------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| Parameters | |-----------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| | `request` | The request params. | | `consentInfoUpdateCallback` | Called when client updates ConsentStatus or returns a [FormError](/ad-manager/mobile-ads-sdk/unity/reference/class/google-mobile-ads/ump/api/form-error#class_google_mobile_ads_1_1_ump_1_1_api_1_1_form_error) argument with ErrorCode and Message. | |"]]