as

Settings
Sign out
Notifications
Alexa
Amazon Appstore
AWS
Documentation
Support
Contact Us
My Cases
Get Started
Design and Develop
Publish
Reference
Support

IParentalControlsPreferenceWriter

Interface for writing PCON preferences including the overall enablement state as well as the enablement of various sub-features (such as PIN-protecting purchases). When PCON is disabled (isEnabled == false), all sub-features are deactivated. See IParentalControlsPreferenceReaderV2 for querying the current state of each preference.

All parental controls preferences are device-local.

Note

PIN management is an account-level setting and is managed by IPinManagement.

Extends

Methods

invokePconEnablementWorkflow()

invokePconEnablementWorkflow(enable): Promise<IEnablementWorkflowResponse>

Parameters

enable

boolean

true to enable PCON; false to disable

Returns

Promise<IEnablementWorkflowResponse>

Brief

Enable/disable PCON, gated by a PIN challenge modal dialog to establish parental consent.

This method enables or disables parental control services for the device. Changing the enablement state (in either direction) requires admin ("parental") consent, so invoking this method will present a PIN challenge to the user in the form of an unescapable modal dialog; that is, the user must either successfully validate their PIN or cancel the validation. Attempts to navigate away from the PIN challenge (such as by pressing back or a provider shortcut on the remote) will implicitly cancel PIN validation.

If a PIN is not already established, then this method instead invokes the first-time setup workflow.

The {@ref gateContentPlaybackListener} listener is invoked once the request has been resolved by PCON (either because the PIN challenge was successfully validated or was unnecessary). The modal dialog has no timeout, so integrators should take into account that the listener may not be invoked immediately. The PCON dialog will remain in the foreground until it is resolved.

Throws

NotAuthorizedError if required privilege(s) are not declared and signed in the caller's application manifest.

Throws

NotInternetConnectedError

Note

this method is idempotent, meaning that attempting to enable/disable PCON when it is already in that state will not result in either a PIN challenge nor in the issuance of a state change event.

Par

Side Effects If the enabled state of PCON changes, an event with the URI IPconStateChangeEventPayload::PCON_ON_STATE_CHANGE_TOPIC is published.

Pre

caller requires privilege com.amazon.kepler.parental_controls.write-pref-enablement

Pre

the device must be internet-connected or the PIN must be cached from a previous successful PIN challenge. First time setup cannot be completed without internet connectivity.

Inherited from

IParentalControlsPreferenceWriter.invokePconEnablementWorkflow


setContentRestrictionLevel()

setContentRestrictionLevel(contentRestrictionLevelName): Promise<void>

Sets the user's device-local content restriction preference. See IParentalControlsPreferenceReader.getContentRestrictionLevel

Parameters

contentRestrictionLevelName

string

Returns

Promise<void>

Pre

caller requires privilege com.amazon.kepler.parental_controls.write-pref-contentrestriction

Inherited from

IParentalControlsPreferenceWriter.setContentRestrictionLevel


setPconEnablement()

setPconEnablement(enable): Promise<void>

Enable/disable PCON without requiring a PIN challenge. This is a very privileged API that is reserved for extremely narrow use cases (such as device initialization and account deregistration).

This method enables or disables parental control services for the device. Typically, changing the enablement state (in either direction) is done interactively (using invokeEnablementWorkflow) and prompts the user for their PIN. This ensures they 1. consent to the configuration change and 2. know their PIN. This non-interactive method for changing Parental Controls enablement is reserved for a narrow set of uses cases where user interaction is not possible (such as initialization) or has been handled implicitly (such as with account deregistration).

Side Effects

If the enabled state of PCON changes, an event with the URI IPconStateChangeEventPayload::PCON_ON_STATE_CHANGE_TOPIC is published.

Parameters

enable

boolean

true to enable PCON; false to disable

Returns

Promise<void>

Throws

SecurityError if required privilege(s) are not declared and signed in the caller's application manifest.

!note this method is idempotent, meaning that attempting to enable/disable PCON when it is already in that state will not result in the issuance of a state change event.

Caller requires privilege com.amazon.kepler.parental_controls.write-pref-noninteractive-enable to enable Parental Controls.

Caller requires privilege com.amazon.kepler.parental_controls.write-pref-noninteractive-disable to disable Parental Controls.

The account PIN must be established in order to enable Parental Controls. (Disablement does not have this requirement).


setPinProtectAppLaunchPreference()

setPinProtectAppLaunchPreference(enable): Promise<void>

Sets the user's device-local preference of whether the launch of applications should be PIN-protected.

Parameters

enable

boolean

Returns

Promise<void>

Pre

caller requires privilege com.amazon.kepler.parental_controls.write-pref-pinprotect-applaunch

Inherited from

IParentalControlsPreferenceWriter.setPinProtectAppLaunchPreference


setPinProtectProfileSwitchPreference()

setPinProtectProfileSwitchPreference(enable): Promise<void>

Sets the user's device-local preference of whether switching to an adult profile should be PIN-protected.

Parameters

enable

boolean

Returns

Promise<void>

Pre

caller requires privilege com.amazon.kepler.parental_controls.write-pref-pinprotect-profileswitch

Inherited from

IParentalControlsPreferenceWriter.setPinProtectProfileSwitchPreference


setPinProtectPurchasePreference()

setPinProtectPurchasePreference(enable): Promise<void>

Sets the user's device-local preference of whether purchases made on this device should be PIN-protected.

Parameters

enable

boolean

Returns

Promise<void>

Pre

caller requires privilege com.amazon.kepler.parental_controls.write-pref-pinprotect-purchase

Inherited from

IParentalControlsPreferenceWriter.setPinProtectPurchasePreference


Last updated: Sep 30, 2025