def edit(self, instance_id, userdata=None, hostname=None, domain=None,
             notes=None, tags=None):

        obj = {}
        if userdata:
            self.guest.setUserMetadata([userdata], id=instance_id)

        if tags is not None:
            self.guest.setTags(tags, id=instance_id)

        if hostname:
            obj['hostname'] = hostname

        if domain:
            obj['domain'] = domain

        if notes:
            obj['notes'] = notes

        if not obj:
            return True

        return self.guest.editObject(obj, id=instance_id)
Edit hostname, domain name, notes, and/or the user data of a VS.
dataset/ETHPy150Open softlayer/softlayer-python/SoftLayer/managers/vs.py/VSManager.edit