// Create a UMPRequestParameters object.letparameters=RequestParameters()// Indicate the user is under age of consent.parameters.isTaggedForUnderAgeOfConsent=true// Request an update for the consent information.ConsentInformation.shared.requestConsentInfoUpdate(with:parameters){[weakself]requestConsentErroringuardletselfelse{return}// ...}
Objective-C
// Create a UMPRequestParameters object.UMPRequestParameters*parameters=[[UMPRequestParametersalloc]init];// Indicate the user is under age of consent.parameters.tagForUnderAgeOfConsent=YES;// Request an update for the consent information.[UMPConsentInformation.sharedInstancerequestConsentInfoUpdateWithParameters:parameterscompletionHandler:^(NSError*_NullablerequestConsentError){// ...}];
[[["容易理解","easyToUnderstand","thumb-up"],["確實解決了我的問題","solvedMyProblem","thumb-up"],["其他","otherUp","thumb-up"]],[["缺少我需要的資訊","missingTheInformationINeed","thumb-down"],["過於複雜/步驟過多","tooComplicatedTooManySteps","thumb-down"],["過時","outOfDate","thumb-down"],["翻譯問題","translationIssue","thumb-down"],["示例/程式碼問題","samplesCodeIssue","thumb-down"],["其他","otherDown","thumb-down"]],["上次更新時間:2025-09-06 (世界標準時間)。"],[[["\u003cp\u003eThis guide explains how to integrate the US state regulations message into your iOS app using the User Messaging Platform (UMP) SDK.\u003c/p\u003e\n"],["\u003cp\u003eBefore starting, update to UMP SDK v2.1.0 or higher, set up a privacy options entrypoint, create a US state regulations message in Ad Manager, and review message display logic.\u003c/p\u003e\n"],["\u003cp\u003eUse the \u003ccode\u003etagForUnderAgeOfConsent\u003c/code\u003e parameter in your UMP request to indicate users under the age of consent, crucial for complying with COPPA and other regulations.\u003c/p\u003e\n"],["\u003cp\u003eAccess user consent choices after they interact with the US state regulations message by reading data stored according to the Global Privacy Platform (GPP) specifications.\u003c/p\u003e\n"],["\u003cp\u003eUtilize \u003ccode\u003edebugGeography\u003c/code\u003e settings, such as \u003ccode\u003eUMPDebugGeographyRegulatedUSState\u003c/code\u003e, to simulate different locations and test your implementation thoroughly.\u003c/p\u003e\n"]]],[],null,[]]