Members
(readonly) CtrlOp :string
Control message operations.
Type:
- Source:
(readonly) Errors :string
Errors.
Type:
- Source:
(readonly) MgrStatus :Symbol
ApplicationMgr/NetworkMgr status.
Type:
- Source:
Methods
authMiddleware(authUri) → {function}
Generate the Express authentication middleware.
Parameters:
Name |
Type |
Description |
authUri |
string
|
The authentication endpoint. For example
`http://localhost:1080/auth/api/v1/auth/tokeninfo`. |
- Source:
Returns:
The Express middleware.
-
Type
-
function
get(client, callback)
`GET /coremgr/api/v1/user`.
Parameters:
Name |
Type |
Description |
client |
Client
|
|
callback |
function
|
Properties
Name |
Type |
Attributes |
Description |
err |
Error
|
<nullable>
|
|
data |
GetResData
|
|
|
|
- Source:
Throws:
-
Wrong arguments.
-
-
Type
-
Error
update(client, data, callback)
`PATCH /coremgr/api/v1/user`
Parameters:
Name |
Type |
Description |
client |
Client
|
|
data |
PatchReqData
|
|
callback |
function
|
Properties
Name |
Type |
Attributes |
Description |
err |
Error
|
<nullable>
|
|
|
- Source:
Throws:
-
Wrong arguments.
-
-
Type
-
Error
Type Definitions
AppDlData
Downlink data from application to broker.
Type:
Properties:
Name |
Type |
Attributes |
Description |
correlationId |
string
|
|
|
deviceId |
string
|
<optional>
|
|
networkCode |
string
|
<optional>
|
|
networkAddr |
string
|
<optional>
|
|
data |
Buffer
|
|
|
extension |
Object
|
<optional>
|
|
- Source:
AppDlDataResp
Downlink data response for `AppDlData`.
Type:
Properties:
Name |
Type |
Attributes |
Description |
correlationId |
string
|
|
|
dataId |
string
|
<optional>
|
|
error |
string
|
<optional>
|
|
message |
string
|
<optional>
|
|
- Source:
AppDlDataResult
Downlink data result when processing or completing data transfer to the device.
Type:
Properties:
Name |
Type |
Attributes |
Description |
dataId |
string
|
|
|
status |
number
|
|
|
message |
string
|
<optional>
|
|
- Source:
AppMgrMsgHandlers
Type:
Properties:
- Source:
AppUlData
Uplink data from broker to application.
Type:
Properties:
Name |
Type |
Attributes |
Description |
dataId |
string
|
|
|
time |
Date
|
|
|
pub |
Date
|
|
|
deviceId |
string
|
|
|
networkId |
string
|
|
|
networkCode |
string
|
|
|
networkAddr |
string
|
|
|
isPublic |
boolean
|
|
|
data |
Buffer
|
|
|
extension |
Object
|
<optional>
|
|
- Source:
ClientOptions
Options of the HTTP client `Client` that contains OAuth2 information.
Type:
Properties:
Name |
Type |
Description |
authBase |
string
|
`sylvia-iot-auth` base path with scheme. For example
`http://localhost:1080/auth`. |
coremgrBase |
string
|
`sylvia-iot-coremgr` base path with scheme. For example
`http://localhost:1080/coremgr`. |
clientId |
string
|
Client ID. |
clientSecret |
string
|
Client secret. |
- Source:
CtrlAddDevice
Type:
Properties:
Name |
Type |
Description |
networkAddr |
string
|
|
- Source:
CtrlAddDeviceBulk
Type:
Properties:
Name |
Type |
Description |
networkAddrs |
Array.<string>
|
|
- Source:
CtrlAddDeviceRange
Type:
Properties:
Name |
Type |
Description |
startAddr |
string
|
|
endAddr |
string
|
|
- Source:
CtrlDelDevice
Type:
Properties:
Name |
Type |
Description |
networkAddr |
string
|
|
- Source:
CtrlDelDeviceBulk
Type:
Properties:
Name |
Type |
Description |
networkAddrs |
Array.<string>
|
|
- Source:
CtrlDelDeviceRange
Type:
Properties:
Name |
Type |
Description |
startAddr |
string
|
|
endAddr |
string
|
|
- Source:
DataMqStatus
Detail queue connection status.
Type:
Properties:
Name |
Type |
Description |
uldata |
Status
|
|
dldata |
Status
|
|
dldataResp |
Status
|
|
dldataResult |
Status
|
|
ctrl |
Status
|
|
- Source:
FullTokenInfo
Type:
Properties:
Name |
Type |
Description |
token |
string
|
The access token. |
info |
Object
|
Properties
Name |
Type |
Description |
userId |
string
|
|
account |
string
|
|
roles |
Object
|
pairs. |
name |
string
|
|
clientId |
string
|
|
scopes |
Array.<string>
|
|
|
- Source:
GetResData
Type:
Properties:
Name |
Type |
Attributes |
Description |
userId |
string
|
<optional>
|
|
account |
string
|
|
|
createdAt |
Date
|
|
|
modifiedAt |
Date
|
|
|
verifiedAt |
Date
|
<optional>
|
|
roles |
Object
|
|
pairs. |
name |
string
|
|
|
info |
Object
|
|
|
- Source:
NetCtrlMsg
Network control message from broker to network.
Type:
Properties:
- Source:
NetDlData
Downlink data from broker to network.
Type:
Properties:
Name |
Type |
Attributes |
Description |
dataId |
string
|
|
|
pub |
Date
|
|
|
expiresIn |
number
|
|
|
networkAddr |
string
|
|
|
data |
Buffer
|
|
|
extension |
Object
|
<optional>
|
|
- Source:
NetDlDataResult
Downlink data result when processing or completing data transfer to the device.
Type:
Properties:
Name |
Type |
Attributes |
Description |
dataId |
string
|
|
|
status |
number
|
|
|
message |
string
|
<optional>
|
|
- Source:
NetMgrMsgHandlers
Type:
Properties:
- Source:
NetUlData
Uplink data from network to broker.
Type:
Properties:
Name |
Type |
Attributes |
Description |
time |
Date
|
|
|
networkAddr |
string
|
|
|
data |
Buffer
|
|
|
extension |
Object
|
<optional>
|
|
- Source:
OnAppDlDataResp(mgr, data, callback)
Parameters:
Name |
Type |
Description |
mgr |
ApplicationMgr
|
|
data |
AppDlDataResp
|
|
callback |
function
|
Properties
Name |
Type |
Attributes |
Description |
err |
Error
|
<nullable>
|
Use error to NACK the message. |
|
- Source:
OnAppDlDataResult(mgr, data, callback)
Parameters:
Name |
Type |
Description |
mgr |
ApplicationMgr
|
|
data |
AppDlDataResult
|
|
callback |
function
|
Properties
Name |
Type |
Attributes |
Description |
err |
Error
|
<nullable>
|
Use error to NACK the message. |
|
- Source:
OnAppUlData(mgr, data, callback)
Parameters:
Name |
Type |
Description |
mgr |
ApplicationMgr
|
|
data |
AppUlData
|
|
callback |
function
|
Properties
Name |
Type |
Attributes |
Description |
err |
Error
|
<nullable>
|
Use error to NACK the message. |
|
- Source:
OnNetCtrl(mgr, data, callback)
Parameters:
Name |
Type |
Description |
mgr |
NetworkMgr
|
|
data |
NetCtrlMsg
|
|
callback |
function
|
Properties
Name |
Type |
Attributes |
Description |
err |
Error
|
<nullable>
|
Use error to NACK the message. |
|
- Source:
OnNetDlData(mgr, data, callback)
Parameters:
Name |
Type |
Description |
mgr |
NetworkMgr
|
|
data |
NetDlData
|
|
callback |
function
|
Properties
Name |
Type |
Attributes |
Description |
err |
Error
|
<nullable>
|
Use error to NACK the message. |
|
- Source:
Options
The options of the application/network manager.
Type:
Properties:
Name |
Type |
Attributes |
Default |
Description |
unitId |
string
|
<optional>
|
|
The associated unit ID of the application/network. Empty or undefined
for public network. |
unitCode |
string
|
<optional>
|
|
The associated unit code of the application/network. Empty or
undefined for public network. |
id |
string
|
|
|
The associated application/network ID. |
name |
string
|
|
|
The associated application/network code. |
prefetch |
number
|
<optional>
|
100
|
AMQP prefetch option. |
persistent |
boolean
|
<optional>
|
false
|
AMQP persistent option. |
sharedPrefix |
string
|
<optional>
|
|
MQTT shared queue prefix option. |
- Source:
PatchReqData
Type:
Properties:
Name |
Type |
Attributes |
Description |
password |
string
|
<optional>
|
|
name |
string
|
<optional>
|
|
info |
Object
|
<optional>
|
|
- Source: