---
title: "Preview a data-source import"
method: POST
path: "/datasources/import-preview"
tags: ["datasources"]
---

# Preview a data-source import

`POST /datasources/import-preview`

Categorizes the selected data-source files/folders into needs-review, valid, and invalid buckets using the business import folder mapping, and returns the counts plus the full needs-review list. Valid/invalid files are browsed lazily on demand as a unified tree via GET /datasources/import-preview/{preview_id}.

## Request body

- ModelsImportPreviewRequest
  - `business_node_id` string
  - `keys` string[]

## Response `200`

OK

- ModelsImportPreviewResponse
  - `counts` ModelsImportPreviewCounts
    - `invalid` integer
    - `review` integer
    - `valid` integer
  - `preview_id` string
  - `review` ModelsReviewFileEntry[]
    - `key` string
    - `name` string

## Other responses

- `400` — Bad Request
- `401` — Unauthorized
- `500` — Internal Server Error

---

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