Skip to content

Get the list of all nodes with the WebSocket #3882

Answered by kpine
Isotech42 asked this question in Q&A
Discussion options

You must be logged in to vote

You're correct, there's no specific command to get a list of node IDs, that doesn't even exist in the Z-Wave JS API. In JS you would just access the controller's nodes property which returns the nodes as objects. The most equivalent for the WS API would be requesting the controller state, and the response embeds the entire node states. A node state is all the node's properties along with all its values. This can be quite a bit of data for large networks.

In general, the server APIs are roughly one-to-one with the Z-Wave JS API and commands are mostly the methods, not properties.

The expectation is that you use start_listening in the connect sequence to get the bulk list of nodes and value…

Replies: 1 comment 8 replies

Comment options

You must be logged in to vote
8 replies
@robertsLando
Comment options

@kpine
Comment options

@Isotech42
Comment options

@kpine
Comment options

Answer selected by Isotech42
@robertsLando
Comment options

@Isotech42
Comment options

@Isotech42
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants