<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def set_values(self, values):
 """ Set multiple Visual properties at once. :param values: :return: """

        if values is None:
            raise ValueError('Values are required.')

        new_values = []
        for vp in values.keys():
            new_val = {
                'visualProperty': vp,
                'value': values[vp]
            }
            new_values.append(new_val)

        requests.put(self.url, data=json.dumps(new_values), headers=HEADERS)