# Import email accounts from CSV file This function imports email accounts from an already uploaded CSV file. Endpoint: GET /CSVImport/doimport Version: 11.134.0.5 Security: BasicAuth ## Query parameters: - `domain` (string, required) The domain under which to add the email accounts. Example: "example.com" - `id` (string, required) The unique ID of the import operation. The cPanel API 2 CSVImport::uploadimport function generates this ID and stores it in the attribute named . Example: "Leq58oid3sF3Moye3_YbJGqoMvCb7M4j" - `type` (string, required) The type of email address to add. * — A regular email account. * — A forwarder. Enum: "email", "fwd" ## Response 200 fields (application/json): - `apiversion` (integer) The version of the API. Example: 3 - `func` (string) The name of the method called. Example: "doimport" - `module` (string) The name of the module called. Example: "CSVImport" - `result` (object) - `result.data` (object) - `result.data.results` (array) The results for each attempted add operation. Example: [{"email":"j.doe@example.com","reason":"OK","status":1,"type":"email"},{"email":"jdoe@example.com","reason":"The account jdoe@example.com already exists!","status":0,"type":"email"}] - `result.data.results.email` (string) The email address or forwarder. Example: "j.doe@example.com" - `result.data.results.fwd` (string,null) The destination of the forwarder (if applicable). - `result.data.results.reason` (string) The explanation of the outcome for each operation. - `result.data.results.status` (integer) The outcome of each operation. * — Success. * — Failed. Enum: 0, 1 - `result.data.results.type` (string) The type of email address. * — A regular email account. * — A forwarder. Enum: "email", "fwd" - `result.errors` (array,null) List of errors if the API failed. Example: ["1 error(s) were encountered while importing accounts."] - `result.messages` (array,null) List of messages generated by the API. - `result.metadata` (object) - `result.status` (integer) * — Success * — Failed: One or more errors occurred. For errors related to individual account add operations, see the field in each record from for more information. Enum: 0, 1 - `result.warnings` (array,null) List of warnings generated by the API. Warnings describe non-critical failures or other problematic conditions noted while running an API.