---
title: "Populate the dataset with records from an uploaded file"
method: POST
path: "/v1/observability/datasets/{dataset_id}/imports/from-file"
tags: ["beta.observability.datasets"]
---

# Populate the dataset with records from an uploaded file

`POST /v1/observability/datasets/{dataset_id}/imports/from-file`

## Request

- Base URL: `https://api.mistral.ai`
- URL: `https://api.mistral.ai/v1/observability/datasets/{dataset_id}/imports/from-file`
- Auth: HTTP bearer
- TypeScript: <https://skmtc.dev/mistral/apis/mistral-ai-api/docs/v1/observability/datasets/:dataset_id/imports/from-file/post.ts> (a function with typed inputs; its response is checked against the schema)

Populate the dataset with records from an uploaded file

## Path parameters

- `dataset_id` string, required: Dataset UUID or workspace-scoped slug. UUID-shaped values are always interpreted as dataset IDs.

## Request body

- ImportDatasetFromFileRequest
  - `file_id` string, required

## Response `202`

Successful Response

- DatasetImportTask
  - `id` string, uuid, required
  - `created_at` string, date-time, required
  - `updated_at` string, date-time, required
  - `deleted_at` string, date-time, nullable, required
  - `creator_id` string, uuid, required
  - `dataset_id` string, uuid, required
  - `workspace_id` string, uuid, required
  - `status` 'RUNNING' | 'COMPLETED' | 'FAILED' | 'CANCELED' | 'TERMINATED' | 'CONTINUED_AS_NEW' | 'TIMED_OUT' | 'UNKNOWN', required
  - `progress` integer, nullable
  - `message` string, nullable
  - `result` DatasetImportResult: Source-agnostic counts for a completed dataset import.
    - `requested_record_count` integer, required
    - `imported_record_count` integer, required
    - `skipped_record_count` integer, required

## Other responses

- `400`: Bad Request - Invalid request parameters or data
- `404`: Not Found - Resource does not exist
- `408`: Request Timeout - Operation timed out
- `409`: Conflict - Resource conflict
- `422`: Unprocessable Entity - Validation error

## Changes

- **2026-10-12** `6c349f3bdef6`: 20 warning, 2 info
  - added the new `OPTIMIZATION_NOT_FOUND` enum value to the `detail/error_code/anyOf[subschema #1: ObservabilityErrorCode]/` response property for the response status `400`
  - added the new `OPTIMIZATION_NOT_FOUND` enum value to the `detail/error_code/anyOf[subschema #1: ObservabilityErrorCode]/` response property for the response status `404`
  - added the new `OPTIMIZATION_NOT_FOUND` enum value to the `detail/error_code/anyOf[subschema #1: ObservabilityErrorCode]/` response property for the response status `408`
  - added the new `OPTIMIZATION_NOT_FOUND` enum value to the `detail/error_code/anyOf[subschema #1: ObservabilityErrorCode]/` response property for the response status `409`
  - …18 more
- …earlier changes not shown

[Operation history](https://skmtc.dev/mistral/apis/mistral-ai-api/changes/v1/observability/datasets/:dataset_id/imports/from-file/post.md)

---

[API](https://skmtc.dev/mistral/apis/mistral-ai-api.md) - [All operations](https://skmtc.dev/mistral/apis/mistral-ai-api/llms.txt) - [OpenAPI document](https://skmtc.dev/mistral/apis/mistral-ai-api/revisions/08a585fb75bc?raw)
