node-red-contrib-mobius-flow-base 3.0.0-rc.4 → 3.0.0-rc.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +36 -7
- package/dist/engine-api-calls.d.ts +51 -20
- package/dist/engine-api-calls.js +289 -250
- package/dist/engine-api-client.d.ts +21 -8
- package/dist/engine-api-client.js +101 -102
- package/dist/engine-websocket.d.ts +43 -58
- package/dist/engine-websocket.js +164 -247
- package/dist/node-red-ui-funcs.js +34 -23
- package/dist/nodes/mobius-change-admin-password.html +1 -1
- package/dist/nodes/mobius-clear-resource.html +4 -9
- package/dist/nodes/mobius-connection.html +9 -7
- package/dist/nodes/mobius-connection.js +42 -44
- package/dist/nodes/mobius-discover-object-list.html +1 -1
- package/dist/nodes/mobius-discover.html +1 -1
- package/dist/nodes/mobius-filter-by-rid-value.html +3 -14
- package/dist/nodes/mobius-flow-inject.html +1 -1
- package/dist/nodes/mobius-get-multi-object.html +1 -1
- package/dist/nodes/mobius-get-multi-resource.html +2 -1
- package/dist/nodes/mobius-get-object.html +4 -9
- package/dist/nodes/mobius-get-resource.html +4 -9
- package/dist/nodes/mobius-object-cov.html +3 -9
- package/dist/nodes/mobius-resource-cov.html +3 -8
- package/dist/nodes/mobius-send-bcmd.html +1 -1
- package/dist/nodes/mobius-send-dcmd.html +1 -1
- package/dist/nodes/mobius-set-multi-resource.html +3 -8
- package/dist/nodes/mobius-set-resource.html +3 -9
- package/dist/nodes/mobius-sub-bcmd.html +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,19 +1,47 @@
|
|
|
1
1
|
# node-red-contrib-mobius-flow-base
|
|
2
2
|
|
|
3
|
-
Copyright
|
|
3
|
+
Copyright 2023 [MobiusFlow](https://mobiusflow.com/).
|
|
4
4
|
|
|
5
|
-
[Node-RED](http://nodered.org) nodes to interact with
|
|
6
|
-
|
|
7
|
-
This module currently requires access to the iaconnects private NPM repository.
|
|
5
|
+
[Node-RED](http://nodered.org) nodes to interact with MobiusFlow.
|
|
8
6
|
|
|
9
7
|
## Nodes
|
|
10
8
|
|
|
11
|
-
###
|
|
12
|
-
All nodes require a connection to a
|
|
9
|
+
### Connection Config Node
|
|
10
|
+
All nodes require a connection to a MobiusFlow Engine. The `mobius connection` config nodes connectes to the MobiusFlow Engine API via http / https
|
|
13
11
|
|
|
14
12
|
### Set Resource Node
|
|
15
13
|
Sets the value of, or clears, the specified priority of resource.
|
|
16
14
|
|
|
15
|
+
### Set Multi-Resource Node
|
|
16
|
+
Sets the value of multiple resources on a given object at once
|
|
17
|
+
|
|
18
|
+
### Send BCMD Node
|
|
19
|
+
Sends a MobiusFlow broadcast command
|
|
20
|
+
|
|
21
|
+
### Send DCMD Node
|
|
22
|
+
Send a MobiusFlow direct command to a specified MobiusFlow service
|
|
23
|
+
|
|
24
|
+
### Get Multi-Resource Node
|
|
25
|
+
Get multiple resource at once
|
|
26
|
+
|
|
27
|
+
### Get Multi-Object Node
|
|
28
|
+
Get mutliple objects at once
|
|
29
|
+
|
|
30
|
+
### MobiusFlow Inject Node
|
|
31
|
+
Subscribe to change of value on a defined set of objects. Change events injected in MobiusFlow format.
|
|
32
|
+
|
|
33
|
+
### Filter Object By Rid Value Node
|
|
34
|
+
Return a filtered list of objects based on a defined filtering function and resource.
|
|
35
|
+
|
|
36
|
+
### Discover Node
|
|
37
|
+
Discover live MobiusFlow: Hubs, Services, Profiles, Objects and Resources
|
|
38
|
+
|
|
39
|
+
### Discover Object List
|
|
40
|
+
Discover live objects from a pre-defined set of potentially wildcarded URIs
|
|
41
|
+
|
|
42
|
+
### Change Admin Password
|
|
43
|
+
Change the password of the administator account of the MobiusFlow Engine
|
|
44
|
+
|
|
17
45
|
### Get Resource Node
|
|
18
46
|
Reads the current `pv` or present value of a resource.
|
|
19
47
|
|
|
@@ -27,4 +55,5 @@ Clears the specified priority of resource.
|
|
|
27
55
|
Subscribe to change of value events for an object
|
|
28
56
|
|
|
29
57
|
### Resource COV Node
|
|
30
|
-
Subscribe to change of value events for a resource
|
|
58
|
+
Subscribe to change of value events for a resource
|
|
59
|
+
|
|
@@ -1,21 +1,52 @@
|
|
|
1
1
|
import { AxiosInstance } from 'axios';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
2
|
+
interface EngineApiCallsInterace {
|
|
3
|
+
setApiClient: (apiClient: AxiosInstance) => void;
|
|
4
|
+
discover: (uri: string, callback: Function) => void;
|
|
5
|
+
writeResource: (uri: string, value: number | string | boolean, priority: number, callback: Function) => void;
|
|
6
|
+
writeMultiResource: (uri: string, updates: {
|
|
7
|
+
r: string;
|
|
8
|
+
p: number;
|
|
9
|
+
v: number | string | boolean;
|
|
10
|
+
}[], callback: Function) => void;
|
|
11
|
+
clearResource: (uri: string, priority: number, callback: Function) => void;
|
|
12
|
+
readResource: (uri: string, callback: Function) => void;
|
|
13
|
+
readObject: (uri: string, callback: Function) => void;
|
|
14
|
+
sendBroadcastCommand: (cid: string, commandData: any) => void;
|
|
15
|
+
sendDirectCommand: (uri: string, cid: string, commandData: any, timeout: number, callback: Function) => void;
|
|
16
|
+
getServiceConfig: (uri: string, callback: Function) => void;
|
|
17
|
+
updateObject: (uri: string, config: any, callback: Function) => void;
|
|
18
|
+
filterObjectsByRIDValue: (uri: string, pids: string[], rid: string, limit: number, func: (v: string | number | boolean) => boolean, callback: Function) => void;
|
|
19
|
+
getHubId: (callback: Function) => void;
|
|
20
|
+
getNodeConfig: (uri: string, callback: Function) => void;
|
|
21
|
+
changeAdminPassword: (password: string, callback: Function) => void;
|
|
22
|
+
getNodeConfigTree: (hid: string, callback: Function) => void;
|
|
23
|
+
getProfileByPid: (hid: string, pid: string, callback: Function) => void;
|
|
24
|
+
getAllObjectProfiles: (hid: string, callback: Function) => void;
|
|
25
|
+
}
|
|
26
|
+
export declare class EngineApiCalls implements EngineApiCallsInterace {
|
|
27
|
+
private apiClient;
|
|
28
|
+
constructor();
|
|
29
|
+
setApiClient: (apiClient: AxiosInstance) => void;
|
|
30
|
+
discover: (uri: string, callback: Function) => Promise<void>;
|
|
31
|
+
writeResource: (uri: string, value: number | string | boolean, priority: number, callback: Function) => Promise<void>;
|
|
32
|
+
writeMultiResource: (uri: string, updates: {
|
|
33
|
+
r: string;
|
|
34
|
+
p: number;
|
|
35
|
+
v: number | string | boolean;
|
|
36
|
+
}[], callback: Function) => Promise<void>;
|
|
37
|
+
clearResource: (uri: string, priority: number, callback: Function) => Promise<void>;
|
|
38
|
+
readResource: (uri: string, callback: Function) => Promise<void>;
|
|
39
|
+
readObject: (uri: string, callback: Function) => Promise<void>;
|
|
40
|
+
sendBroadcastCommand: (cid: string, commandData: any) => Promise<void>;
|
|
41
|
+
sendDirectCommand: (uri: string, cid: string, commandData: any, timeout: number, callback: Function) => Promise<void>;
|
|
42
|
+
getServiceConfig: (uri: string, callback: Function) => Promise<void>;
|
|
43
|
+
updateObject: (uri: string, config: any, callback: Function) => Promise<void>;
|
|
44
|
+
filterObjectsByRIDValue: (uri: string, pids: string[], rid: string, limit: number, func: (v: string | number | boolean) => boolean, callback: Function) => Promise<any>;
|
|
45
|
+
getHubId: (callback: Function) => Promise<void>;
|
|
46
|
+
getNodeConfig: (uri: string, callback: Function) => Promise<void>;
|
|
47
|
+
changeAdminPassword: (password: string, callback: Function) => Promise<void>;
|
|
48
|
+
getNodeConfigTree: (hid: string, callback: Function) => Promise<void>;
|
|
49
|
+
getProfileByPid: (hid: string, pid: string, callback: Function) => Promise<void>;
|
|
50
|
+
getAllObjectProfiles: (hid: string, callback: Function) => Promise<void>;
|
|
51
|
+
}
|
|
52
|
+
export {};
|