SpeechTilesAndamento Docs
Get started
SDK Reference · Method

requestSpeechRecognitionPermission

Requests operating-system permission to use speech recognition.

Declaration

public func requestSpeechRecognitionPermission() -> STResult

Overview

Requests permission for speech recognition. A .permissionPending result means the decision is not final; the application receives the eventual .permissionGranted or .permissionDenied through a media event.

The method can return .permissionGranted, .permissionDenied, or .permissionPending. When the result is .permissionPending, the user's eventual decision is delivered asynchronously through a media event.

Application Configuration — macOS

In Xcode, open Application Target → Info → Custom macOS Application Target Properties and add Privacy - Speech Recognition Usage Description (NSSpeechRecognitionUsageDescription). Provide a user-facing explanation, such as: “This application needs permission to convert spoken words into text during voice interactions.”

The usage-description property is required for the system permission request; adding it does not itself grant permission. When authorization has not previously been decided, macOS may display a permission dialog. The request remains pending until the system reports the user’s grant or denial through the documented permission callback or event. When a decision already exists, macOS may return that status without displaying another dialog.

See Also