Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/rdn87/cordova-plugin-sirikit-available

SiriKit Permission (Cordova) Plugin for iOS
https://github.com/rdn87/cordova-plugin-sirikit-available

cordova cordova-ios-plugin cordova-plugin hybrid objective-c permission-requests siri sirikit

Last synced: about 13 hours ago
JSON representation

SiriKit Permission (Cordova) Plugin for iOS

Awesome Lists containing this project

README

        

# cordova-plugin-sirikit-available

SiriKit Permission **Cordova Plugin for iOS**

Author: [Giulio Caruso aka rdn](https://twitter.com/giuliordn87)

[![Language](https://img.shields.io/badge/language-objective--c-green.svg)](https://developer.apple.com/reference/objectivec)
[![License](https://img.shields.io/badge/license-MIT-blue.svg)](https://github.com/rdn87/cordova-plugin-sirikit-available/blob/master/LICENSE)

## Adding the Plugin ##

Use the Cordova CLI and type in the following command:

`cordova plugin add https://github.com/rdn87/cordova-plugin-sirikit-available --variable SIRI_DESC=SiriKit Use`

## Description

With this plug-in you can execute the native method `requestSiriAuthorization` for use *SiriKit*.

## Sample Code

The Plugin is only iOS Platform required iOS 10.0+.

### Execute requestPermission method in your Javascript

cordova.plugins.SiriKitPermission.requestPermission(function(response) {
// success function
}, function() {
// failed function
});

response is flag (true/false) and identifies the state
true = INSiriAuthorizationStatusAuthorized
false = INSiriAuthorizationStatusDenied, INSiriAuthorizationStatusNotDetermined, INSiriAuthorizationStatusRestricted

## License

cordova-plugin-sirikit-available is available under the MIT license. See the **[LICENSE](https://github.com/rdn87/cordova-plugin-sirikit-available/blob/master/LICENSE)** file for more info.