An action that can accept user-typed text.


class UNTextInputNotificationAction : UNNotificationAction


Use UNTextInputNotificationAction objects to define an action that allows the user to provide a custom text-based response. When the user selects an action of this type, the system displays controls for the user to enter or dictate the text content. That text is then included in the response object that is delivered to your app.

For information on how to define actions and categories, see Declaring Your Actionable Notification Types.


Creating a Text Input Action

Getting the Text Input Information

var textInputButtonTitle: String

The localized title of the text input button that is displayed to the user.

var textInputPlaceholder: String

The localized placeholder text to display in the text input field.


Conforms To

See Also

Notification Categories and User Actions

Declaring Your Actionable Notification Types

Differentiate your notifications and add action buttons to the notification interface.

class UNNotificationCategory

A type of notification that your app supports and the custom actions to display with it.

class UNNotificationAction

A task to perform in response to a delivered notification.