zwave-bridge (crate)
The bridge as a library: the same code as the binary. API docs.
run(config, port, shutdown)runs the bridge on an open port untilshutdowncompletes.load_or_create_keys(dir)readskeys.json, or creates it with new keys.config::Configis the configuration file;Config::parseparses one.discoverybuilds the Home Assistant discovery messages.
The MQTT API and configuration reference document the behavior.