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

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

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

## Request

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

Creates an Import Request for Variants.

This endpoint is only available for Projects with `productCatalogModel` set to `Modular`.

## Request body

- VariantImportRequest
  - `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` VariantImport[], required
    - `key` string, required
    - `sku` string, required
    - `product` ProductKeyReference, 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
    - `publish` boolean
    - `images` Image[]
      - `url` string, required
      - `dimensions` AssetDimensions, required
        - `w` number, double, required
        - `h` number, double, required
      - `label` string
    - `attributes` Attribute[]
      - `name` string
      - `type` string, required
    - `assets` Asset[]
      - `key` string, required
      - `sources` AssetSource[], required
        - `uri` string, required
        - `key` string
        - `dimensions` AssetDimensions
          - `w` number, double, required
          - `h` number, double, required
        - `contentType` string
      - `name` LocalizedString, required
      - `description` LocalizedString
      - `tags` 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

## 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`: 2 breaking
  - the request property `allOf[subschema #2]/resources/items/allOf[subschema #2]/assets/items/custom/type/allOf[subschema #2]/typeId` became required
  - the request property `allOf[subschema #2]/resources/items/allOf[subschema #2]/product/allOf[subschema #2]/typeId` became required
- **2026-06-26** `13af4e5cda94`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/commercetools/apis/import-api/changes/:projectKey/variants/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)
