Packagecom.distriqt.extension.adverts.consent
Interfacepublic interface Consent extends flash.events.IEventDispatcher

Gives access to the Consent SDK to obtain consent from users



Public Properties
 PropertyDefined By
  isSupported : Boolean
[read-only] Returns true if the current platform supports the Consent SDK If this returns false you should try the User Messaging Platform (ump) for consent gathering.
Consent
Public Methods
 MethodDefined By
  
addTestDevice(deviceId:String):void
Whitelist your device to be a debug device using the advertising ID from logcat
Consent
  
askForConsent(options:ConsentOptions):Boolean
Presents the consent form if appropriate to ask for user consent.
Consent
  
getConsentStatus(publisherId:String):void
Asynchronously gather the current consent status for your user.
Consent
  
setConsentStatus(status:String):void
Set the consent status if you displayed a custom dialog
Consent
  
setDebugGeography(debugGeography:int):void
Set your preferred geography for testing purposes
Consent
Events
 Event Summary Defined By
   Dispatched when the consent form has been closed and the user has selected an option Consent
   Dispatched when there was error loading or displaying the consent form Consent
   Dispatched when there was an error retrieving the consent status Consent
   Dispatched when the consent status has been updated Consent
Property Detail
isSupportedproperty
isSupported:Boolean  [read-only]

Returns true if the current platform supports the Consent SDK If this returns false you should try the User Messaging Platform (ump) for consent gathering.


Implementation
    public function get isSupported():Boolean
Method Detail
addTestDevice()method
public function addTestDevice(deviceId:String):void

Whitelist your device to be a debug device using the advertising ID from logcat

Parameters

deviceId:String

askForConsent()method 
public function askForConsent(options:ConsentOptions):Boolean

Presents the consent form if appropriate to ask for user consent. You must as a minimum specify the url for your privacy policy in the options for this form.

Parameters

options:ConsentOptions — An instance of ConsentOptions specifying specify options to show in the form

Returns
Booleantrue if the form was successfully created
getConsentStatus()method 
public function getConsentStatus(publisherId:String):void

Asynchronously gather the current consent status for your user.

Find your publisher id: https://support.google.com/admob/answer/2784578

Parameters

publisherId:String

setConsentStatus()method 
public function setConsentStatus(status:String):void

Set the consent status if you displayed a custom dialog

Parameters

status:String — A ConsentStatus

See also

setDebugGeography()method 
public function setDebugGeography(debugGeography:int):void

Set your preferred geography for testing purposes

Parameters

debugGeography:int

See also

Event Detail
consent:form:closed Event
Event Object Type: com.distriqt.extension.adverts.events.ConsentEvent
ConsentEvent.type property = com.distriqt.extension.adverts.events.ConsentEvent.FORM_CLOSED

Dispatched when the consent form has been closed and the user has selected an option
consent:form:error Event  
Event Object Type: com.distriqt.extension.adverts.events.ConsentEvent
ConsentEvent.type property = com.distriqt.extension.adverts.events.ConsentEvent.FORM_ERROR

Dispatched when there was error loading or displaying the consent form
consent:status:error Event  
Event Object Type: com.distriqt.extension.adverts.events.ConsentEvent
ConsentEvent.type property = com.distriqt.extension.adverts.events.ConsentEvent.STATUS_ERROR

Dispatched when there was an error retrieving the consent status
consent:status:updated Event  
Event Object Type: com.distriqt.extension.adverts.events.ConsentEvent
ConsentEvent.type property = com.distriqt.extension.adverts.events.ConsentEvent.STATUS_UPDATED

Dispatched when the consent status has been updated