Uploads

Replace upload data

Changed on
<Note> **Organization Admin** permissions are required to use this endpoint. </Note>

Replace the data in an existing CSV upload.

The view's uploaded_table_name property and references to it (returned as refreshedModelIds) will automatically update, but the upload's ID will remain unchanged. This means that any documents, queries, views, etc. using the upload will be re-pointed to the new data. The previous data's artifacts are left untouched.

put/v1/uploads/{uploadId}

Request

  • Base URL
    https://blobsrus.omniapp.co/api
  • URL
    https://blobsrus.omniapp.co/api/v1/uploads/{uploadId}
  • Auth
    HTTP bearer

Path parameters

uploadIdstring uuid required

The unique identifier of the upload

Request body multipart/form-data

filestring binary required

The replacement CSV file (must have .csv extension). Fully replaces the existing data; existing columns keep their saved type and date format. Column renames/removals may break content referencing the old columns.

Response

Upload data replaced successfully

idstring uuid required

The upload ID. This will not change after uploading new data.

fileNamestring required

File name of the replacement upload

viewNamestring required

View name. This will not change after uploading new data.

inDbAsTableNamestring required

Database table name in the table upload (scratch) schema. This will be empty if the underlying connection doesn't have a table upload schema configured.

refreshedModelIdsstring[] required

Models whose view of this upload was re-pointed at the new data, including the upload's workbook model, or the connection's shared models holding a view backed by this upload.

rowCountinteger required

Number of rows in the replacement file

truncatedboolean required

Whether the file was truncated due to row limit

Example response

{
  "id": "550e8400-e29b-41d4-a716-446655440000",
  "fileName": "users_updated.csv",
  "viewName": "users",
  "inDbAsTableName": "omni_upload_t7c1e22ab",
  "refreshedModelIds": [
    "880e8400-e29b-41d4-a716-446655440003"
  ],
  "rowCount": 152
}

Changes