snowstorm
Preparing search index...
services/tauri
commands
Variable commands
Const
commands
:
{
createShare
(
uses
:
number
,
ttlSecs
:
number
,
)
:
Promise
<
Result
<
string
,
string
>
>
;
fetchMeta
()
:
Promise
<
Result
<
string
,
string
>
>
;
fetchRoutes
(
token
:
string
,
secrets
:
string
[]
,
)
:
Promise
<
Result
<
string
,
string
>
>
;
getPeerId
()
:
Promise
<
string
>
;
getRoutes
()
:
Promise
<
Result
<
string
,
string
>
>
;
getSharedSecrets
()
:
Promise
<
Result
<
string
[]
,
string
>
>
;
getState
()
:
Promise
<
State
>
;
getUserId
()
:
Promise
<
string
|
null
>
;
greet
(
name
:
string
)
:
Promise
<
string
>
;
isDebugMode
()
:
Promise
<
boolean
>
;
isDeviceLinked
()
:
Promise
<
Result
<
boolean
,
string
>
>
;
killClient
()
:
Promise
<
void
>
;
panic
()
:
Promise
<
string
>
;
redeemShare
(
n
:
string
,
sig
:
string
)
:
Promise
<
Result
<
string
,
string
>
>
;
refreshProfile
(
token
:
string
)
:
Promise
<
Result
<
string
,
string
>
>
;
refreshUserToken
(
key
:
string
)
:
Promise
<
Result
<
string
,
string
>
>
;
registerDevice
(
token
:
string
,
peerId
:
string
,
devType
:
string
,
devId
:
string
,
devName
:
string
,
)
:
Promise
<
Result
<
string
,
string
>
>
;
registerLicense
(
key
:
string
)
:
Promise
<
Result
<
string
,
string
>
>
;
removeShare
(
secret
:
string
)
:
Promise
<
Result
<
null
,
string
>
>
;
reroute
(
roles
:
string
[]
,
staticRoutesStr
:
string
,
)
:
Promise
<
Result
<
SerializableTunnelInfo
,
string
>
>
;
resetSharedState
()
:
Promise
<
Result
<
null
,
string
>
>
;
rotateIdentity
()
:
Promise
<
string
>
;
setAccessToken
(
token
:
string
)
:
Promise
<
Result
<
null
,
string
>
>
;
setTrayIcon
(
color
:
string
)
:
Promise
<
Result
<
null
,
string
>
>
;
startClient
()
:
Promise
<
Result
<
SerializableTunnelInfo
,
string
>
>
;
startSdk
(
roles
:
string
[]
,
staticRoutesStr
:
string
)
:
Promise
<
void
>
;
stop
()
:
Promise
<
void
>
;
trackEvent
(
eventName
:
string
,
payload
:
string
,
)
:
Promise
<
Result
<
null
,
string
>
>
;
unregister
(
token
:
string
,
deviceId
:
string
)
:
Promise
<
Result
<
null
,
string
>
>
;
}
= ...
user-defined commands *
Type Declaration
createShare
:
function
createShare
(
uses
:
number
,
ttlSecs
:
number
)
:
Promise
<
Result
<
string
,
string
>
>
Main method for creating a share code
uses - how many times the code can be used
ttl_secs - how long the code will last
See:
https://www.notion.so/sstorm/Sharing-Trust-Model-1d0582318d1180d1889bfb2d6921b5f8
Parameters
uses
:
number
ttlSecs
:
number
Returns
Promise
<
Result
<
string
,
string
>
>
fetchMeta
:
function
fetchMeta
()
:
Promise
<
Result
<
string
,
string
>
>
Returns
Promise
<
Result
<
string
,
string
>
>
fetchRoutes
:
function
fetchRoutes
(
token
:
string
,
secrets
:
string
[]
)
:
Promise
<
Result
<
string
,
string
>
>
Parameters
token
:
string
secrets
:
string
[]
Returns
Promise
<
Result
<
string
,
string
>
>
getPeerId
:
function
getPeerId
()
:
Promise
<
string
>
Returns
Promise
<
string
>
getRoutes
:
function
getRoutes
()
:
Promise
<
Result
<
string
,
string
>
>
Returns
Promise
<
Result
<
string
,
string
>
>
getSharedSecrets
:
function
getSharedSecrets
()
:
Promise
<
Result
<
string
[]
,
string
>
>
Returns
Promise
<
Result
<
string
[]
,
string
>
>
getState
:
function
getState
()
:
Promise
<
State
>
Returns
Promise
<
State
>
getUserId
:
function
getUserId
()
:
Promise
<
string
|
null
>
Returns
Promise
<
string
|
null
>
greet
:
function
greet
(
name
:
string
)
:
Promise
<
string
>
Parameters
name
:
string
Returns
Promise
<
string
>
isDebugMode
:
function
isDebugMode
()
:
Promise
<
boolean
>
Returns
Promise
<
boolean
>
isDeviceLinked
:
function
isDeviceLinked
()
:
Promise
<
Result
<
boolean
,
string
>
>
Returns
Promise
<
Result
<
boolean
,
string
>
>
killClient
:
function
killClient
()
:
Promise
<
void
>
Returns
Promise
<
void
>
panic
:
function
panic
()
:
Promise
<
string
>
Returns
Promise
<
string
>
redeemShare
:
function
redeemShare
(
n
:
string
,
sig
:
string
)
:
Promise
<
Result
<
string
,
string
>
>
Parameters
n
:
string
sig
:
string
Returns
Promise
<
Result
<
string
,
string
>
>
refreshProfile
:
function
refreshProfile
(
token
:
string
)
:
Promise
<
Result
<
string
,
string
>
>
Parameters
token
:
string
Returns
Promise
<
Result
<
string
,
string
>
>
refreshUserToken
:
function
refreshUserToken
(
key
:
string
)
:
Promise
<
Result
<
string
,
string
>
>
Parameters
key
:
string
Returns
Promise
<
Result
<
string
,
string
>
>
registerDevice
:
function
registerDevice
(
token
:
string
,
peerId
:
string
,
devType
:
string
,
devId
:
string
,
devName
:
string
,
)
:
Promise
<
Result
<
string
,
string
>
>
Parameters
token
:
string
peerId
:
string
devType
:
string
devId
:
string
devName
:
string
Returns
Promise
<
Result
<
string
,
string
>
>
registerLicense
:
function
registerLicense
(
key
:
string
)
:
Promise
<
Result
<
string
,
string
>
>
Parameters
key
:
string
Returns
Promise
<
Result
<
string
,
string
>
>
removeShare
:
function
removeShare
(
secret
:
string
)
:
Promise
<
Result
<
null
,
string
>
>
Parameters
secret
:
string
Returns
Promise
<
Result
<
null
,
string
>
>
reroute
:
function
reroute
(
roles
:
string
[]
,
staticRoutesStr
:
string
,
)
:
Promise
<
Result
<
SerializableTunnelInfo
,
string
>
>
Parameters
roles
:
string
[]
staticRoutesStr
:
string
Returns
Promise
<
Result
<
SerializableTunnelInfo
,
string
>
>
resetSharedState
:
function
resetSharedState
()
:
Promise
<
Result
<
null
,
string
>
>
Returns
Promise
<
Result
<
null
,
string
>
>
rotateIdentity
:
function
rotateIdentity
()
:
Promise
<
string
>
Returns
Promise
<
string
>
setAccessToken
:
function
setAccessToken
(
token
:
string
)
:
Promise
<
Result
<
null
,
string
>
>
Parameters
token
:
string
Returns
Promise
<
Result
<
null
,
string
>
>
setTrayIcon
:
function
setTrayIcon
(
color
:
string
)
:
Promise
<
Result
<
null
,
string
>
>
Parameters
color
:
string
Returns
Promise
<
Result
<
null
,
string
>
>
startClient
:
function
startClient
()
:
Promise
<
Result
<
SerializableTunnelInfo
,
string
>
>
Returns
Promise
<
Result
<
SerializableTunnelInfo
,
string
>
>
startSdk
:
function
startSdk
(
roles
:
string
[]
,
staticRoutesStr
:
string
)
:
Promise
<
void
>
Parameters
roles
:
string
[]
staticRoutesStr
:
string
Returns
Promise
<
void
>
stop
:
function
stop
()
:
Promise
<
void
>
Returns
Promise
<
void
>
trackEvent
:
function
trackEvent
(
eventName
:
string
,
payload
:
string
)
:
Promise
<
Result
<
null
,
string
>
>
Parameters
eventName
:
string
payload
:
string
Returns
Promise
<
Result
<
null
,
string
>
>
unregister
:
function
unregister
(
token
:
string
,
deviceId
:
string
)
:
Promise
<
Result
<
null
,
string
>
>
Parameters
token
:
string
deviceId
:
string
Returns
Promise
<
Result
<
null
,
string
>
>
Settings
Member Visibility
Protected
Private
Inherited
Theme
OS
Light
Dark
snowstorm
Loading...
user-defined commands *