def save(self):
        tmp_path = self.path + '.tmp'
        with open(tmp_path, 'w') as f:
            f.write(json.dumps(self.body_labels.items()))
        os.rename(tmp_path, self.path)
def create_on_device(self):
        resource = self.client.api.cm.shared.licensing.pools_s.pool.create(
            name=self.want.name,
            baseRegKey=self.want.base_key,
            method="AUTOMATIC"
        )
        return self._wait_for_license_pool_state_to_activate(resource)