Example
siteKiosk.siteRemote.registration.register(
//the connection info
{
server: 'siteremote.server',
port: 1234,
guid: 'your-machine-guid',
token: 'your-token'
},
//the registration info
{
displayName: 'myDevice',
street1: 'foobar blvd.',
street2: '42',
postalCode: 48161,
city: 'MS',
state: 'NRW',
country: 'GER',
notes: 'Nope, no notes'
},
//replace an existing registration
true,
function(error, token, guid) {
//your error handling goes here
//the error is a registrationError (see below)
}
)
Members
-
<static> errorType :number
-
Error types.
Type:
- number
Properties:
Name Type Default Description parseError
number -32700 invalidRequest
number -32600 methodNotFound
number -32601 invalidParams
number -32602 internalError
number -32603 machineNotAuthenticated
number 0 exceededFileSize
number 1 userNotAuthenticated
number 2 notAuthorized
number 3 serviceNotAvailable
number 4 itemNotFound
number 5 itemAlreadyExists
number 6 -
<static> invalidParamsErrorType :number
-
Invalid param error types.
Type:
- number
Properties:
Name Type Default Description country
number 0 state
number 1 -
<static> itemAlreadyExistsErrorType :number
-
Not authorized error types.
Type:
- number
Properties:
Name Type Default Description requiresReplaceMachineBehaviour
number 0 inRecycleBin
number 1 multipleDevices
number 2 mobileDevice
number 3 -
<static> notAuthorizedErrorType :number
-
Not authorized error types.
Type:
- number
Properties:
Name Type Default Description addMachinesRightMissing
number 0 invalidLicense
number 1 unlicensedClientType
number 2 clientCountHasExceededLicense
number 3
Methods
-
<static> deleteRegistrationInfo()
-
Deletes the registration information.
-
<static> getConnectionInfo() → {siteKiosk.siteRemote.registration~connectionInfo}
-
Gets the connection information.
Returns:
The connection information -
<static> isRegistered() → {boolean}
-
Returns whether this machine is registered with SiteRemote.
Returns:
Whether this machine is registered with SiteRemote- Type
- boolean
-
<static> register(connectionInfo, registrationInfo, replace, completed)
-
Registers this machine with SiteRemote.
Parameters:
Name Type Description connectionInfo
siteKiosk.siteRemote.registration~connectionInfo The information needed to connect to and authenticate with a SiteRemote server registrationInfo
siteKiosk.siteRemote.registration~registrationInfo The information to register with a SiteRemote server replace
boolean Whether to force the replacement of an existing machine with the same display name completed
siteKiosk.siteRemote.registration~registerCallback The callback, which is invoked, when the machine registration operation has been completed -
<static> unregister(connectionInfo, completed)
-
Unregisters this machine with SiteRemote.
Parameters:
Name Type Description connectionInfo
siteKiosk.siteRemote.registration~connectionInfo The information needed to connect to and authenticate with a SiteRemote server completed
siteKiosk.siteRemote.registration~unregisterCallback The callback, which is invoked, when the machine unregistration operation has been completed
Type Definitions
-
connectionInfo
-
Represents the information needed to connect to and authenticate with a SiteRemote server
Properties:
Name Type Description server
string The servers hostname port
number The servers port for machine communication guid
string The machine GUID, which is the username for the machine token
string The machine token, which is the password for the machine -
registerCallback(error, token, guid)
-
A callback, which is invoked, when the machine registration operation has been completed.
Parameters:
Name Type Description error
siteKiosk.siteRemote.registration~registrationError Represents information about the error, which might occur when registering with a SiteRemote server token
string The machine token, which is the password for the machine guid
string The machine GUID, which is the username for the machine -
registrationError
-
Represents information about the error, which might occur when registering with a SiteRemote server.
Properties:
Name Type Description code
number An general error type detail
number A specific error type, which actual type dependent on the general error type message
string An textual error message -
registrationInfo
-
Represents the information to register with a SiteRemote server.
Properties:
Name Type Description displayName
string The machines display name street1
string The first street field of the machines address street2
string The second street field of the machines address postalCode
number The postal code of the area, where the machine is located city
string The city, where the machine is located state
string The state, where the machine is located country
string The country, where the machine is located notes
string Additional notes -
unregisterCallback(error)
-
A callback, which is invoked, when the machine unregistration operation has been completed.
Parameters:
Name Type Description error
siteKiosk.siteRemote.registration~registrationError Represents information about the error, which might occur when unregistering with a SiteRemote server