Amazon Developer

as

Settings
Sign out
Notifications
Alexa
Amazon Appstore
Ring
AWS
Documentation
Support
Contact Us
My Cases
Get Started
Design and Develop
Publish
Reference
Support
Skip to main content
Launches an alert dialog with the specified title and message. Optionally provide a list of buttons. Tapping any button will fire the respective onPress callback and dismiss the alert. By default, the only button will be an ‘OK’ button.

Example

Vega

Vega mimics the behavior of Android’s alert with at most three buttons and its positive/negative/neutral semantics.
  • If you specify one button, it will be the ‘positive’ one (such as ‘OK’)
  • Two buttons mean ‘negative’, ‘positive’ (such as ‘Cancel’, ‘OK’)
  • Three buttons mean ‘neutral’, ‘negative’, ‘positive’ (such as ‘Later’, ‘Cancel’, ‘OK’)
The alert may be dismissed by providing an optional AlertOptions parameter with the cancelable property set to true i.e. {cancelable: true}. The cancel event can be handled by providing an onDismiss callback property inside the options parameter.

Example


Reference

Methods

alert()

Parameters:

Type definitions

AlertButton

An object describing the configuration of a button in the alert. Objects properties:

AlertOptions

Properties:
Last modified on December 10, 2025