request(Permissions.PERMISSIONS.IOS. BLUETOOTH_PERIPHERAL) returns unavailable after pressing `OK` on iOS version 13
Hello everyone!
I've faced an issue regarding request functionality in iOS. I'm trying to request the Bluetooth service permission and after pressing OK to allow my application to use the Bluetooth, the request returned Unavailable, when I'm expecting to receive Granted status. After that, any attempt to enable Bluetooth ends with the app crash. I will add a screenshot below. On pressing Don't allow it returns Blocked status as it should. It basically means that functionality is not available for usage, even with allowing to use it. Does anyone have a similar issue?
Thank you in advance.
Steps to reproduce:
- Launch app with
react-native-permissionslibrary - Perform
request(PERMISSIONS.IOS.BLUETOOTH_PERIPHERAL) - Press
OK. The request returns theunavailableresponse - Enable Bluetooth
Received error message:
NOTES:
- Using a real device (iPhone XS)
- iOS 13.3 version
- Both NSBluetoothAlwaysUsageDescription and NSBluetoothPeripheralUsageDescription were added to Info.plist
@BohdanIvanov Are you working in the simulator? Please fill the issue template for more informations.
@zoontek I'm using actual devices. Did check on iPhone XS multiple times.
await request(PERMISSIONS.IOS.BLUETOOTH_PERIPHERAL) returns an unavailable response after OK was pressed.
@BohdanIvanov Did you added bluetooth-peripheral in your app supported capabilities?
@zoontek Didn't notice any bluetooth-peripheral option in capabilities inside of Xcode. Can you please share a screenshot?
Sure (Bluetooth peripheral = Acts as a Bluetooth LE accessory)

@BohdanIvanov Any progress?
@zoontek Sorry that couldn't answer earlier. For now, I've decided to go another way, without using the request method. I'll try to test in the nearest time and will let you know. Thank you :)
I tried the mentioned steps but bluetooth permissions are not working. I am using iOS 14.2
Also seeing this :( not working ios 14.
The critical question @dorthwein is this I think:
@BohdanIvanov Did you added bluetooth-peripheral in your app supported capabilities?
...additionally it appears the example app tests every single one, does the example app demonstrate this one? Worth confirming, and if it does, does the example app work?
Does it still work on iOS real device for Bluetooth on iOS 17.5 if I have followed all steps above?
@zoontek
@esiltu Yes
If you're encountering the issue where requesting Bluetooth permission returns unavailable, add this line to your iOS -> Podfile: pod 'Permission-BluetoothPeripheral', :path => "../node_modules/react-native-permissions/ios/BluetoothPeripheral" and rebuild your app to resolve the issue. I'm using version 17.5.
@zoontek thanks !
@esiltu Or read the documentation (iOS setup especially)