Comment on page
CCPA
As of November 13, 2023, Ogury Choice Manager is deprecated, meaning it will no longer be supported or updated.
Consequently, no new consent notices will be delivered through Ogury Choice Manager's APIs. Therefore, it is strongly advised against using Ogury Choice Manager in new versions of applications. In case you have migrated to a new Consent Management Platform (CMP), ensure that Ogury and its partners are included as vendors.
For earlier versions of applications still using Ogury Choice Manager, the API will maintain its functionality, continuing to return consent for users who have previously responded to a consent notice. This will remain in effect until their consent expires.
There are several options to access and pass the consent signal to your partners: You can get and transmit the USP string if your vendor's SDK is able to handle it, as the USP string contains the complete consent signal. Alternatively, you can check if user opted out from sale of their personal data, if notice has been shown to the user, or check the Limited Service Provider Agreement (LSPA) configuration used to generate the US privacy string.
The consent signal is stored in a specific
UserDefaults
and is automatically passed to the vendors supporting the USPrivacy string (CCPA).While being registered to the IAB CCPA, some vendors need to explicitly receive the USP string. Check with your vendors to ensure that they process the consent signal by themselves. Otherwise, you can use the following method to obtain and pass the USP string:
Swift
Objective C
OguryChoiceManager.shared().ccpaV1.getUspString()
[[[OguryChoiceManager sharedManager] ccpaV1] getUSPString];
We recommend to use this method only in the completion block of the
ask
and edit
methods to get the updated value of the consent signal. If there is no consent signal for a given user, this method returns an empty string as default value. In this case, you should start the vendor's SDK as if the user had not provided their consent. The consent notice will be displayed at the next
ask
call, and the consent status will then be updated.Per CCPA regulation, just showing Consent notice to the user and explaining its rights constitutes the positive signal for publishers. In order for a user to preserve its personal data, they must choose an option to opt-out from selling its personal data. To see if Consent notice was served to the user and regulation was being followed, call:
Swift
Objective C
OguryChoiceManager.shared().ccpaV1.hasSeenNotice()
[[[OguryChoiceManager sharedManager] ccpaV1] hasSeenNotice];
We recommend to use this method only in the completion block of the
ask
and edit
methods to get the updated value of the consent signal. Per CCPA regulation, a user can choose to opt-out from selling of its personal data.
To see the status of user choice call:
Swift
Objective C
OguryChoiceManager.shared().ccpaV1.isOptOutSale();
[[[OguryChoiceManager sharedManager]ccpaV1]isOptOutSale];
We recommend to use this method only in the completion block of the
ask
and edit
methods to get the updated value of the consent signal. To see if publisher is a signatory to the IAB Limited Service Provider Agreement(LSPA) and that the publisher declares that the transaction is covered as a “Covered Opt Out Transaction” or a “Non Opt Out Transaction” as those terms are defined in the Agreement, call:
Swift
Objective C
OguryChoiceManager.shared().ccpaV1.isLspa();
[[[OguryChoiceManager sharedManager] ccpaV1] isLspa];
We recommend to use this method only in the completion block of the
ask
and edit
methods to get the updated value of the consent signal. Swift
Objective C
import OguryChoiceManager
class ViewController: UIViewController {
override func viewDidLoad() {
super.viewDidLoad()
// you can initialize SDK here or in Application.onCreate() method
let config = OguryChoiceManagerConfig.default()
OguryChoiceManager.shared().setup(withAssetKey: "ASSET_KEY", andConfig: config)
// get user consent
OguryChoiceManager.shared().ask(with: self) { (error, response) in
// pass user consent to vendors' SDKs
self.passConsentToVendorSdks()
// initialize vendors' SDKs
self.startSdks()
// load ad formats
self.loadAdFormats()
}
}
func passConsentToVendorSdks() {
if (OguryChoiceManager.shared().ccpaApplies()) {
// pass consent through CCPA string
let ccpaString = OguryChoiceManager.shared().ccpaV1.getUSPString()
vendorSdk.setConsentFromCCPAString(ccpaString)
// check if has see the notice
let hasSeenNotice = OguryChoiceManager.shared().ccpaV1.hasSeenNotice()
anotherVendorSdk.setHasSeenNotice(hasSeenNotice)
// check if is out of sale
let isOptOutSale = OguryChoiceManager.ccpafV1.isOptOutSale();
anotherVendorSdk.setIsOptOutSale(isOptOutSale);
// check LSPA status
let isLspa = OguryChoiceManager.ccpafV1.isLspa();
anotherVendorSdk.setIsLspa(isLspa);
} else if (OguryChoiceManager.shared().gdprApplies()) {
// pass consent through IAB string
let iabString = OguryChoiceManager.shared().tcfV2.getIABConsentString()
vendorSdk.setConsentFromIABString(iabString)
// check if a vendor is accepted
let vendorAccepted = OguryChoiceManager.shared().tcfV2.isAccepted(vendorId)
anotherVendorSdk.setConsent(vendorAccepted)
// check consent for yourself and for your analytics solution
let meAccepted = OguryChoiceManager.shared().tcfV2.isAccepted(yourVendorId)
let analyticsVendorAccepted = OguryChoiceManager.shared().tcfV2.isAccepted(analyticsVendorId)
// for analytics we check the MEASUREMENT purpose
let measurementPurposeAccepted = OguryChoiceManager.shared().tcfV2.isPurposeAccepted(.measureAdPerformance)
analyticsSdk.setConsent(meAccepted && analyticsVendorAccepted && measurementPurposeAccepted)
}
}
func startSdks() {
// call the start methods of vendors' SDKs
vendorSdk.start()
anotherVendorSdk.start()
analyticsSdk.start()
}
func loadAdFormats() {
// load ad formats
yourAdFormat.load();
}
}
#import <OguryChoiceManager/OguryChoiceManager.h>
@interface ViewController : UIViewController
@end
@implementation ViewController
- (void)viewDidLoad {
[super viewDidLoad];
// you can initialize SDK here or in AppDelegate
OguryChoiceManagerConfig *config = [[OguryChoiceManagerConfig defaultConfig];
[[OguryChoiceManager sharedManager] setupWithAssetKey:@"ASSET_KEY" andConfig:config];
// get user consent
[[OguryChoiceManager sharedManager] askWithViewController:self andCompletionBlock:^(NSError *error, OguryChoiceManagerAnswer answer) {
// pass user consent to vendors' SDKs
[self passConsentToVendorSdks];
// initialize vendors' SDKs
[self startSdks];
// load ad formats
[self loadAdFormats];
}];
}
- (void) passConsentToVendorSdks {
if ([[OguryChoiceManager sharedManager] ccpaApplies]) {
// pass consent through CCPA string
NSString *uspString = [[[OguryChoiceManager sharedManager] ccpaV1] getUSPString];
[vendorSdk setConsentFromUSPString:uspString];
// check if has see the notice
BOOL hasSeenNotice = [[[OguryChoiceManager sharedManager] ccpaV1] hasSeenNotice];
[vendorSdk setHasSeenNotice:hasSeenNotice];
// check if is out of sale
BOOL isOptOutSale = [[[OguryChoiceManager sharedManager] ccpaV1] isOptOutSale];
[vendorSdk setIsOutOptSale:isOptOutSale];
// check LSPA status
BOOL isLspa = [[[OguryChoiceManager sharedManager] ccpaV1] isOptOutSale];
[vendorSdk isLspa:isLspa];
} else if ([[OguryChoiceManager sharedManager] gdprApplies]) {
// pass consent through IAB string
NSString *iabString = [[[OguryChoiceManager sharedManager] tcfV2] getIABConsentString];
[vendorSdk setConsentFromIABString:iabString];
// check if a vendor is accepted
BOOL vendrAccepted = [[[OguryChoiceManager sharedManager] tcfV2] isAccepted:vendorId];
[anotherVendorSdk setConsent:vendrAccepted];
// check consent for yourself and for your analytics solution
BOOL meAccepted = [[[OguryChoiceManager sharedManager] tcfV2] isAccepted:yourVendorId];
BOOL analyticsVendorAccepted = [[[OguryChoiceManager sharedManager] tcfV2] isAccepted:analyticsVendorId];
// for analytics we check the MEASUREMENT purpose
BOOL mesurementPurposeAccepted = [[[OguryChoiceManager sharedManager] tcfV2] isPurposeAccepted:OguryChoiceManagerPurposeMeasureContentPerformance];
[analyticsSdk setConsent:meAccepted && analyticsVendorAccepted && mesurementPurposeAccepted];
}
}
- (void)startSdks {
// start vendors' SDKs
[vendorSdk start];
[anotherVendorSdk start];
[analyticsSdk start];
}
- (void)loadAdFormats {
// load ad formats
[yourAdFormat load];
}
@end