# Import computers from a CSV file Imports computers into the Scope of Management from a CSV file upload. The CSV file should contain computer names and domain information. ## Endpoints `POST /dcapi/som/computers/import` ## Request URL `https://{server-hostname}:8383/dcapi/som/computers/import` ## Scope `SOM.CREATE` ## Header `Authorization: d92d4xxxxxxxxxxxxx15f52` ## Request Parameters ### Request Headers - **Content-Type** `string` — **Mandatory**: `multipart/form-data` - **Accept** `string` — **Mandatory**: `application/importComputers.v1+json` ### Request Body `multipart/form-data` - **computerCSVFile** `string` — **Mandatory** - A CSV file containing the computer details required for bulk import. [Refer](https://www.manageengine.com/sites/meweb/images/desktop-central/help/sommanagedcomputers-sample-import.csv) to the sample CSV file for the supported format and field values. ### Sample Request ```curl curl --request POST \ --url https://appdomain/dcapi/som/computers/import \ --header 'Accept: application/importComputers.v1+json' \ --header 'Authorization: d92d4xxxxxxxxxxxxx15f52' \ --header 'Content-Type: multipart/form-data' \ -F 'computerCSVFile=CSV File' ``` ### Sample Request Body Import bulk computers using a CSV file upload ```text computerCSVFile = CSV File ``` ## Response Parameters ### HTTP Code 202 Response Body — `application/json` - **csvImportInProgress** `boolean` - Indicates whether the CSV import process has been accepted and is currently running. ### HTTP Code 400 Response Body — `application/json` - **statusCode** `string` - HTTP status code (400). - **errorCode** `string` - API-specific error code identifying the validation failure. - **message** `string` - Error message describing the validation failure. ### HTTP Code 412 Response Body — `application/json` - **statusCode** `string` - HTTP status code (412). - **errorCode** `string` - Precondition failed error code identifying the business logic violation. - **message** `string` - Error message describing the precondition failed while processing request. ## Possible Response Codes - `202` — HTTP code - `400` — HTTP code - `412` — HTTP code ## Sample Responses ### HTTP 202 CSV import initiated ```json { "csvImportInProgress": true } ``` ### HTTP 400 Empty CSV file ```json { "errorCode": "30047", "message": "No data to import", "statusCode": 400 } ``` ### HTTP 412 Another import is already running ```json { "errorCode": "30013", "message": "An import operation is already in progress", "statusCode": 412 } ``` ## API Rate Limit **Duration:** 1 minute | **Threshold:** 30 | **Lock period:** 5 minutes Duration — Time window for the threshold. Threshold — Number of API calls allowed within the specified duration. Lock Period — Wait time before consecutive API requests.