The only place the id for the updating device appears is buried in the middle of the topic field. That’s an important field if we’re using BPUP to maintain state in a Home Automation system.
Is the intent of BPUP to just report commands sent to devices, or to report on changes of the devices? Because it’s not really designed to do the latter, which is the main requirement for HA integration.
I know I am late to the conversation here, but it seems to me the BPUP was designed to allow each device to have one method for processing state, whether it was requested through the REST API or reported by BPUP. So the body (“b”) portion of the BPUP message is intended to mimic the REST API response. I agree, however, that it could have been a cleaner design to have a type field and a device ID field instead of pushing the HTTP path of the equivalent REST call and forcing you to parse the device ID and message type from it.
I actually like the flexibility of the current design. They can theoretically push out any state at any path, regardless of the number of ids that may be embedded in a given path. Parsing the paths is pretty standard and well supported in most environments.