+ }
+ if fields:
+ data['values'].update(fields)
+ result = self.request('Contact', 'create', data)
+ return result['values'][0]['id']
+
+ def update_phone(self, contact_id, phone):
+ if self.request('Phone', 'get', {'where': [['phone', "=", phone], ['contact_id', "=", contact_id]]})['count']:
+ return
+ self.request('Phone', 'create', {'values': {'phone': phone, 'contact_id': contact_id}})
+
+ def update_contact(self, contact_id, fields):