---
title: "Create a Data Table Upload"
method: POST
path: "/data-tables/{data_table_id}/upload"
tags: ["Data Table Uploads"]
---

# Create a Data Table Upload

`POST /data-tables/{data_table_id}/upload`

Create an upload object for a given data table to track overall upload status and corresponding parts.

## Path parameters

- `data_table_id` string, uuid, required

## Headers

- `X-Company-ID` string, required

## Request body

- SourceDataTableUpload
  - `id` string, uuid, required
  - `source_data_table` string, uuid, required
  - `source` 'USER_UPLOAD' | 'EMAIL' | 'API' | 'THIRD_PARTY_API' — * `USER_UPLOAD` - User Upload * `EMAIL` - Email * `API` - API * `THIRD_PARTY_API` - Third Party API
  - `message` string, nullable
  - `status` 'PROCESSING' | 'IMPORTED' | 'ERROR' | 'PENDING' — * `PROCESSING` - Processing * `IMPORTED` - Imported * `ERROR` - Error * `PENDING` - Pending
  - `data_import` integer, nullable
  - `upload_type` 'REPLACE' | 'TIME_BASED_REPLACE' | 'APPEND' | 'DELETE' — * `REPLACE` - Remove all existing records and replace with this uploaded data * `TIME_BASED_REPLACE` - Remove and replace existing records between the time periods specified in this uploaded data * `APPEND` - Update existing records and add new records * `DELETE` - Remove all existing records
  - `status_message` string, nullable
  - `created_at` string, date-time, required
  - `currency` integer, nullable
  - `data_can_be_downloaded` boolean, required

## Response `200`

The upload object to start uploading parts for

- SourceDataTableUpload
  - `id` string, uuid, required
  - `source_data_table` string, uuid, required
  - `source` 'USER_UPLOAD' | 'EMAIL' | 'API' | 'THIRD_PARTY_API' — * `USER_UPLOAD` - User Upload * `EMAIL` - Email * `API` - API * `THIRD_PARTY_API` - Third Party API
  - `message` string, nullable
  - `status` 'PROCESSING' | 'IMPORTED' | 'ERROR' | 'PENDING' — * `PROCESSING` - Processing * `IMPORTED` - Imported * `ERROR` - Error * `PENDING` - Pending
  - `data_import` integer, nullable
  - `upload_type` 'REPLACE' | 'TIME_BASED_REPLACE' | 'APPEND' | 'DELETE' — * `REPLACE` - Remove all existing records and replace with this uploaded data * `TIME_BASED_REPLACE` - Remove and replace existing records between the time periods specified in this uploaded data * `APPEND` - Update existing records and add new records * `DELETE` - Remove all existing records
  - `status_message` string, nullable
  - `created_at` string, date-time, required
  - `currency` integer, nullable
  - `data_can_be_downloaded` boolean, required

---

[API](https://skmtc.net/cubesoftware/apis/cube-api.md) · [All operations](https://skmtc.net/cubesoftware/apis/cube-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/cubesoftware/cube-api/revisions/67d9f45bb99b/schema)
