Desktop SDK API
To configure and manage your Plus Six integration, use the following integration tools:
Config options
Config options are passed in on initialization via a config json file. You can find the full list of config options and their defaults in the Browser SDK, but there are additional Desktop-specific configuration options outlined below:
API setup
As the Desktop SDK is actually a standalone app rather than a traditional SDK, there's an embedded web server that cann accept commands from any app that can make http requests. As such, you can choose which port the web server should listen to.
Property | Type | Default | Description |
---|---|---|---|
webServerPort |
number |
8082 |
Which port to accept commands on |
QR Widget appearance
Since different displays might necessitate a different size for the widget, you can use the following desktop-specific properties to help place it on your screen.
Property | Type | Default | Description |
---|---|---|---|
widgetScale |
number |
1 |
Scale factor for QR Widget window |
widgetLocationX |
number |
100 |
x-coordinate for QR Widget window |
widgetLocationY |
number |
100 |
y-coordinate for QR Widget window |
Pointer appearance
The custom cursor is an additional transparent app window that moves around the screen. While it's large appearance can help users see where the cursor is, it could also cause problems with certain screen configurations.
Property | Type | Default | Description |
---|---|---|---|
pointerCustomImage |
boolean |
true |
If true , uses the fancy custom pointer image. If this causes issues with your kiosk, try setting to false |
Touchpad input
The following touchpad-specific properties can adjust incoming .
Property | Type | Default | Description |
---|---|---|---|
touchpadScrollDeltaMult |
number |
0.5 |
A multiplier for the Touchpad's two-finger vertical scroll feature |
Text config
Custom text can be configured in the Touchpad
UI by creating a data/text-config.json
file. You can start by renaming the example file, and you only need to include properties for text that you want to override. For example, your text-config.json
file could look like this:
{
textQuit: "Quit",
}
Public API
The public API for the desktop version comes in the form of an internal web server that can receive http requests to perform specific actions. For these examples, we're assuming a default web server port of 8082. When the app is running, you can find a test page with these commands at http://localhost:8082.
Native app-specific functions
Position, show, and hide the app window
Position the window at an x/y coordinate of 1760, 880:
http://localhost:8082/position/1760/880
Hide the window:
http://localhost:8082/show/true
Show the window
http://localhost:8082/show/false
Quit the app
http://localhost:8082/quit
SDK public functions
End the user session and recycle the QR code
http://localhost:8082/recycle-qr-code
End the user session and recycle the QR code
http://localhost:8082/session-reset-timeout
Key Commands
There are several key commands that can help while setting up the SDK. You can turn all key commands by adding appDebug=true
to the launch command.
ESC
Quits the app.
w
Launches the local web page to test the http-based public API.