Skip to main content
POST
/
products
/
api
/
v1
/
import
/
csv
Bulk import products from CSV
curl --request POST \
  --url https://www.closient.com/products/api/v1/import/csv \
  --header 'Content-Type: multipart/form-data' \
  --header 'X-API-Key: <api-key>' \
  --form file='@example-file'
{
  "total_rows": 1,
  "created": 1,
  "updated": 1,
  "skipped": 1,
  "error_count": 1,
  "errors": [
    {
      "line": 2,
      "message": "<string>",
      "column": "<string>"
    }
  ]
}

Documentation Index

Fetch the complete documentation index at: https://docs.closient.com/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

X-API-Key
string
header
required

Body

multipart/form-data
file
file
required

CSV file to import. Must be UTF-8 encoded.

Response

OK

Outcome of a single CSV upload to POST /import/csv.

The four counters (created / updated / skipped / error_count) sum to total_rows for any successful request. The endpoint returns 200 even when individual rows fail — per-row failures are reported in errors rather than aborting the whole upload. A non-empty errors list is therefore expected on partial success and is not itself an error condition.

total_rows
integer
required

Total number of data rows processed (excluding the header row).

Required range: x >= 0
created
integer
required

Number of new products created from the upload.

Required range: x >= 0
updated
integer
required

Number of existing products updated (matched by GTIN).

Required range: x >= 0
skipped
integer
required

Number of rows skipped because they were duplicates of an earlier row or yielded no changes.

Required range: x >= 0
error_count
integer
required

Number of rows that failed validation. Equals the length of errors.

Required range: x >= 0
errors
RowErrorOut · object[]

Per-row validation failures. Empty when every row imported cleanly.