diff --git a/intaro.intarocrm/classes/general/RestApi.php b/intaro.intarocrm/classes/general/RestApi.php index 9576d9e7..7bb0542e 100644 --- a/intaro.intarocrm/classes/general/RestApi.php +++ b/intaro.intarocrm/classes/general/RestApi.php @@ -211,6 +211,22 @@ class RestApi return $result; } + /** + * Обновление externalId у клиентов с переданными id + * + * @param array $customers- массив, содержащий id и externalId заказа + * @return array + */ + public function customerFixExternalIds($customers) + { + $dataJson = json_encode($customers); + $this->parameters['customers'] = $dataJson; + + $url = $this->apiUrl.'customers/fix-external-ids'; + $result = $this->curlRequest($url, 'POST'); + return $result; + } + /** * Удаление клиента *