Endpoint is used to import existing clients from your system to Repsly.
Request definition
Keys that determine which records to update or insert are marked with a blue diamond 🔹, while the required keys are marked with a red triangle 🔺
Any planned changes to existing endpoints are marked with an orange diamond 🔸.
Name | Type | Description |
---|---|---|
Code 🔺 🔹 | String (50) | Unique client code. |
Name 🔺 | String (255) | Client name |
Active | Boolean | Active client |
Tag | String | Tags associated with this client (separated with commas) |
Territory | Each territory in hierarchy: String (80) | Full territory path this client belongs to. The delimiter between territory levels is “>”(meaning that a territory in a two-level hierarchy is given as “ParentTerritory>ChildTerritory”) Important: The full path must always be given in import data (and will be returned by the export). If a non-existent territory is assigned to a client in the import data, the existing territory hierarchy will be expanded to accommodate the new territory. |
RepresentativeCode | String (20) | Unique representative code (assigned to thisclient) |
RepresentativeName | String (80) | Representative name (assigned to this client) |
StreetAddress | String (255) | Client street address |
ZIP | String (20) | Client ZIP code |
ZIPExt | String (20) | Client ZIP extension |
City | String (255) | Client city |
State | String (255) | Client state |
Country | String (255) | Client country |
String (128) | Client email address | |
Phone | String (128) | Client phone number |
Mobile | String (128) | Client mobile phone number |
Website | String (255) | Client website |
ContactName | String (255) | Contact person name |
ContactTitle | String (50) | Contact person title |
Note | String (255) | Additional client note |
Status | Text | Client status name in sales cycle |
CustomFields\Item\Field | String (255) | Custom field name |
CustomFields\Item\Value | Text | Custom field value |
PriceLists\Name | Text | List of price list names connected to this client. 🚩 null and empty list doesn’t have the same meaning. In case a request has null value on this parameter system will ignore that parameter but in case it has empty list as parameter, system will break all connections between client and price lists. |
AccountCode | Text | Code of the account assigned to this client. 🚩 Will be deleted if empty. Will be ignored if not sent in at all. |
Response definition
Name | Type | Description |
---|---|---|
Code | Integer | Error identifier (0 = no errors) |
Message | String (255) | Response affirmative or error message |
For a successful HTTP request (code 200), you will always receive a status response with Code equal to 0 (no error) and Message = “Client import job started asynchronously under ID: {ImportJobID}”, where {ImportJobID} is the key you can use to check the current status of the import.
To check the status of the import job you can use Import job status endpoint.
In case of a HTTP bad request (code 400), you will also receive a status response with Code not equal to 0 and a descriptive message. For incorrect format or other unhandled errors you will receive an HTMLRequest error page.