> ## Documentation Index
> Fetch the complete documentation index at: https://product-discovery.developer.voyado.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Data

> An import of the data feed is made through using the standard HTTP POST method, with personal cluster credentials provided during onboarding.

An import of the data feed is made through using the standard <a href="https://en.wikipedia.org/wiki/POST_(HTTP)">HTTP POST method</a>, with personal cluster credentials provided during onboarding. For information about the different import types and formats, see <a href="https://docs.elevate.voyado.cloud/elevate/4/integration/data-feed/xml-format-specification/">Format specification</a>. For information about scheduling imports, see <a href="https://docs.elevate.voyado.cloud/elevate/4/integration/catalog-imports/scheduling/">Scheduling</a>.

```http theme={null}
POST https://{cluster-id}.elevate-api.cloud/api/admin/v3/import/data
```

## Request

<AccordionGroup>
  <Accordion title="Request header parameters">
    | Name               | Description                                           | Example           |
    | ------------------ | ----------------------------------------------------- | ----------------- |
    | `Api-Key`\*        | API key supplied during onboarding.                   | `123456789..`     |
    | `Accept-Encoding`  | Allows responses to be compressed using Gzip.         | `gzip`            |
    | `Content-Encoding` | Defines which encoding was used to compress the data. | `gzip`            |
    | `Content-Type`     | application/xml                                       | `application/xml` |
  </Accordion>

  <Accordion title="Request query parameters">
    | Name              | Description                                                                                                                                                                                                       | Example |
    | ----------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------- |
    | `blockingTimeout` | Maximum time to wait, after the import have been received, before getting a response. Valid values are in the range of 0 to 5 minutes. Defaults to 5 minutes.                                                     | `PT3M`  |
    | `downgrade`       | Argument to downgrade to using v3 import format when having upgraded to Admin v4. Should only be provided for rollbacks and is only compatible with full imports.                                                 | `false` |
    | `force`           | Argument to override protection against harmful imports. For more information, see <a href="https://docs.elevate.voyado.cloud/elevate/4/integration/catalog-imports/scheduling/#force-imports">Force imports</a>. | `false` |
    | `name`            | A name to identify the import in logs                                                                                                                                                                             |         |
  </Accordion>

  <Accordion title="Request body example">
    ```xml title="application/xml" theme={null}
    <?xml version="1.0" encoding="UTF-8" ?>
    <data_import type="full">
        <modify market="UK" locale="en-GB">
            <product_groups>
                <add_or_replace>
                    <product_group key="1001">
                        <brand>Gazelle</brand>
                        <department>Men</department>
                        <products>
                            <product key="1001-100">
                                <title>Linen T-shirt</title>
                                <url>/products/1001-100</url>
                                <release_date>2019-10-27T00:00:00Z</release_date>
                                <description>Loose-fit striped T-shirt with a slightly lower neckline.</description>
                                <images>
                                    <image>
                                        <urls>
                                            <url>//cdn.example.com/images/1001-100_model.jpg?preset=200x200</url>
                                            <url>//cdn.example.com/images/1001-100_model.jpg?preset=600x600</url>
                                        </urls>
                                    </image>
                                </images>
                                <custom_attributes>
                                    <category>T-Shirts</category>
                                </custom_attributes>
                                <variants>
                                    <variant key="1001-100-1">
                                        <stock_number>12</stock_number>
                                        <selling_price>9.99</selling_price>
                                        <list_price>12.99</list_price>
                                        <cost>8.00</cost>
                                        <url>/products/1001-100?size=S</url>
                                        <sizes>
                                            <size>S</size>
                                        </sizes>
                                    </variant>
                                </variants>
                            </product>
                        </products>
                    </product_group>
                </add_or_replace>
            </product_groups>
            <content_items>
                <add_or_replace>
                    <content key="871">
                        <type>link</type>
                        <title>Shipping</title>
                        <link>/uk/customer-service/shipping</link>
                    </content>
                </add_or_replace>
            </content_items>
        </modify>
    </data_import>
    ```
  </Accordion>

  <Accordion title="Example request">
    ```bash title="bash" theme={null}
    curl -i \
    -X POST \
    -H 'Api-Key: 123456789..' \
    -H 'Accept-Encoding: null' \
    -H 'Content-Encoding: null' \
    -H 'Content-Type: null' \
    "https://{cluster-id}.elevate-api.cloud/api/admin/v3/import/data?blockingTimeout=blockingTimeout&downgrade=downgrade&force=force&name=name" \
    -T request-body.file
    ```
  </Accordion>
</AccordionGroup>

## Response

<AccordionGroup>
  <Accordion title="Response codes">
    | Status | Description                                                                                                                                                                                                    |
    | ------ | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | `202`  | The import exceeded the maximum time, and an identifier for the import will be returned which can be used to poll its progress. The maximum wait time is 5 minutes by default.                                 |
    | `204`  | The import was valid and has completed.                                                                                                                                                                        |
    | `400`  | The import was deemed dangerous according to Elevate. For more information, see <a href="https://docs.elevate.voyado.cloud/elevate/4/integration/catalog-imports/scheduling/#force-imports">Force imports</a>. |
    | `403`  | Incorrect cluster credentials.                                                                                                                                                                                 |
    | `404`  | Cluster not found.                                                                                                                                                                                             |
    | `405`  | The import is not allowed due to newer admin version usage. Use full import with flag 'downgrade' to change admin version to v3.                                                                               |
    | `409`  | An import is currently in progress.                                                                                                                                                                            |
    | `500`  | Server error such as cluster unavailable, busy or internal error. If 5xx errors persist, contact <a href="mailto:support@voyado.com">support</a> and attach any information found in the response body.        |
    | `503`  | The server in the cluster that received the request is currently unavailable or busy. It is recommended to retry the request. The time between request attempts should be increasing.                          |
  </Accordion>

  <Accordion title="Example response">
    ```json theme={null}
    {
      "id" : "5537431447739019570",
      "reason" : null,
      "status" : "IN_PROGRESS"
    }
    ```
  </Accordion>

  <Accordion title="Response body schema">
    #### StatusResponse

    The status of an import based on its id.

    | Name   | Type   | Description                                                                                                                                                                                                                                                                                                               |
    | ------ | ------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | id     | string | The id of the import<br /><br />Examples: `"5537431447739019570"`                                                                                                                                                                                                                                                         |
    | reason | string | The reason for the status. e.g. an error message from the import                                                                                                                                                                                                                                                          |
    | status | string | The current status of the import. See <a href="https://docs.elevate.voyado.cloud/elevate/4/integration/catalog-imports/scheduling/?h=in_progress#import-statuses">scheduling statuses</a>. Supported values: `NOT_FOUND`, `WAITING`, `IN_PROGRESS`, `SUCCESS`, `FAILURE`, `ABORTED`.<br /><br />Examples: `"IN_PROGRESS"` |
  </Accordion>
</AccordionGroup>
