---
title: "POST /{projectKey}/customers/import-containers/{importContainerKey}"
method: POST
path: "/{projectKey}/customers/import-containers/{importContainerKey}"
---

# POST /{projectKey}/customers/import-containers/{importContainerKey}

`POST /{projectKey}/customers/import-containers/{importContainerKey}`

## Request

- Base URL: `https://import.europe-west1.gcp.commercetools.com`
- URL: `https://import.europe-west1.gcp.commercetools.com/{projectKey}/customers/import-containers/{importContainerKey}`
- Auth: OAuth 2
  - Client credentials
  - Token URL: `https://auth.europe-west1.gcp.commercetools.com/oauth/token` scopes: `manage_customers:{projectKey}`
- TypeScript: <https://skmtc.dev/commercetools/apis/import-api/docs/:projectKey/customers/import-containers/:importContainerKey/post.ts> (a function with typed inputs; its response is checked against the schema)

Creates an Import Request for Customers.

## Request body

- CustomerImportRequest
  - `type` 'business-unit' | 'category' | 'customer' | 'discount-code' | 'inventory' | 'order' | 'order-patch' | 'price' | 'product' | 'product-draft' | 'product-selection' | 'product-tailoring' | 'product-type' | 'product-variant' | 'product-variant-patch' | 'standalone-price' | 'variant' | 'type', required
  - `resources` CustomerImport[], required
    - `key` string, required
    - `customerNumber` string
    - `email` string, required
    - `password` string
    - `stores` StoreKeyReference[]
      - `key` string, required
      - `typeId` 'associate-role' | 'business-unit' | 'cart' | 'cart-discount' | 'category' | 'channel' | 'customer' | 'customer-group' | 'discount-code' | 'key-value-document' | 'order' | 'payment' | 'price' | 'product' | 'product-discount' | 'product-type' | 'product-variant' | 'variant' | 'shipping-method' | 'state' | 'store' | 'tax-category' | 'type', required
    - `firstName` string
    - `lastName` string
    - `middleName` string
    - `title` string
    - `salutation` string
    - `externalId` string
    - `dateOfBirth` string, date-only
    - `companyName` string
    - `vatId` string
    - `isEmailVerified` boolean
    - `customerGroup` CustomerGroupKeyReference
      - `key` string, required
      - `typeId` 'associate-role' | 'business-unit' | 'cart' | 'cart-discount' | 'category' | 'channel' | 'customer' | 'customer-group' | 'discount-code' | 'key-value-document' | 'order' | 'payment' | 'price' | 'product' | 'product-discount' | 'product-type' | 'product-variant' | 'variant' | 'shipping-method' | 'state' | 'store' | 'tax-category' | 'type', required
    - `addresses` CustomerAddress[]
      - `key` string, required
      - `country` string, required
      - `title` string
      - `salutation` string
      - `firstName` string
      - `lastName` string
      - `streetName` string
      - `streetNumber` string
      - `additionalStreetInfo` string
      - `postalCode` string
      - `city` string
      - `region` string
      - `state` string
      - `company` string
      - `department` string
      - `building` string
      - `apartment` string
      - `pOBox` string
      - `phone` string
      - `mobile` string
      - `email` string
      - `fax` string
      - `additionalAddressInfo` string
      - `externalId` string
      - `custom` Custom
        - `type` TypeKeyReference, required
          - `key` string, required
          - `typeId` 'associate-role' | 'business-unit' | 'cart' | 'cart-discount' | 'category' | 'channel' | 'customer' | 'customer-group' | 'discount-code' | 'key-value-document' | 'order' | 'payment' | 'price' | 'product' | 'product-discount' | 'product-type' | 'product-variant' | 'variant' | 'shipping-method' | 'state' | 'store' | 'tax-category' | 'type', required
        - `fields` FieldContainer
    - `defaultBillingAddress` integer
    - `billingAddresses` integer[]
    - `defaultShippingAddress` integer
    - `shippingAddresses` integer[]
    - `locale` string
    - `custom` Custom
      - `type` TypeKeyReference, required
        - `key` string, required
        - `typeId` 'associate-role' | 'business-unit' | 'cart' | 'cart-discount' | 'category' | 'channel' | 'customer' | 'customer-group' | 'discount-code' | 'key-value-document' | 'order' | 'payment' | 'price' | 'product' | 'product-discount' | 'product-type' | 'product-variant' | 'variant' | 'shipping-method' | 'state' | 'store' | 'tax-category' | 'type', required
      - `fields` FieldContainer
    - `authenticationMode` 'Password' | 'ExternalAuth'

## Response `201`

201

- ImportResponse
  - `operationStatus` ImportOperationStatus[], required
    - `operationId` string
    - `state` 'processing' | 'validationFailed', required
    - `errors` ErrorObject[]
      - `code` string, required
      - `message` string, required

## Other responses

- `400`: The request was invalid.

## Changes

- **2026-08-20** `980be2e37843`: 4 breaking
  - the request property `allOf[subschema #2]/resources/items/allOf[subschema #2]/addresses/items/custom/type/allOf[subschema #2]/typeId` became required
  - the request property `allOf[subschema #2]/resources/items/allOf[subschema #2]/custom/type/allOf[subschema #2]/typeId` became required
  - the request property `allOf[subschema #2]/resources/items/allOf[subschema #2]/customerGroup/allOf[subschema #2]/typeId` became required
  - the request property `allOf[subschema #2]/resources/items/allOf[subschema #2]/stores/items/allOf[subschema #2]/typeId` became required
- **2026-06-26** `13af4e5cda94`: 11 info
  - added `variant` discriminator mapping keys to the `allOf[#/components/schemas/ImportRequest]/` request property
  - added the new `variant` enum value to the request property `allOf[#/components/schemas/ImportRequest]/type`
  - added the new `variant` enum value to the request property `allOf[subschema #2]/resources/items/allOf[subschema #2]/addresses/items/custom/type/allOf[#/components/schemas/KeyReference]/typeId`
  - added the new `variant` enum value to the request property `allOf[subschema #2]/resources/items/allOf[subschema #2]/addresses/items/custom/type/allOf[subschema #2]/typeId`
  - …7 more
- …earlier changes not shown

[Operation history](https://skmtc.dev/commercetools/apis/import-api/changes/:projectKey/customers/import-containers/:importContainerKey/post.md)

---

[API](https://skmtc.dev/commercetools/apis/import-api.md) - [All operations](https://skmtc.dev/commercetools/apis/import-api/llms.txt) - [OpenAPI document](https://skmtc.dev/commercetools/apis/import-api/revisions/980be2e37843?raw)
