Overview

You can use this request to check the progress of your import.

The Method

TypeRequestMethod
RESTGEThttps://[Your URL]/api/2.0/contacts/import/:batch_id
XML-RPCCallcontacts.ImportProgress

Your method must be structured as follows:

Parameters

Required Parameters

The following parameters are required for this request to work.

Property TypeDescriptionDefaultRequired
batch_idstringThe identifier hash of the import batch you want to get progress information about.emptyyes

Responses

TypeDescription
stringThe call will return the status of the import: complete / in progress If the import is incomplete, the call will also return the number of items still to be imported.

Code Samples

$url = '(Your URL)/api/2.0/contacts/import/:batch_id';
$method = 'GET';
$cSession = curl_init();
$headers = array();
$auth = base64_encode($username . ':' . $apikey);
$headers[] = 'Authorization: Basic ' . $auth;
curl_setopt($cSession, CURLOPT_URL, $url);
curl_setopt($cSession, CURLOPT_RETURNTRANSFER, true);
curl_setopt($cSession, CURLOPT_HEADER, false);
curl_setopt($cSession, CURLOPT_CUSTOMREQUEST, strtoupper($method));
curl_setopt($cSession, CURLOPT_HTTPHEADER, $headers);
$result = curl_exec($cSession);
curl_close($cSession);