The data model does not have a direct association between devices and sites. The original idea was that devices could be used at multiple sites and the device assignment would include the current site. This approach does not allow queries to find all devices for a site. It also does not allow on-the-fly creation of unassociated assignments for data received when a device is not assigned. Update data model and APIs to add site information for devices. Update UI to require site as a device creation field and make it possible to change the site for a device if the device is not currently assigned.