Using the bluetooth API
Bluetooth API
Overview: Available API Routes
Mode
The mode endpoint allows changing the bluetooth mode of an android device.
Can only be used on a device locked by the same user.
Parameters
- <code class="dcode">device_address</code> the device to change
- <code class="dcode">use_hsp</code> true to use HSP mode, false to switch back to A2DP mode
Example
Response:
Pair
The pair endpoint should not normally be needed, but in some cases a bluetooth device can lose the audio pairing and pair can be used to try and automatically pair it to the correct audio device again. The pair endpoint is to be used exclusively for android devices. Note that pairing can take a long time (up to a minute) and the endpoint will only return once completed.
Can only be used on a device locked by the same user.
Parameters
- <code class="dcode">device_address</code> the device to pair
Example
Response: