---
title: "Look up uploaded history import files"
method: POST
path: "/imports/{importId}/files/lookup"
tags: ["Imports"]
---

# Look up uploaded history import files

`POST /imports/{importId}/files/lookup`

## Request

- Base URL: `https://api.ando.so/v1`
- URL: `https://api.ando.so/v1/imports/{importId}/files/lookup`
- Auth: one of:
  - API key in header `x-api-key`
  - HTTP bearer

Finds source files this import already uploaded and attached, so a re-run can reuse them instead of uploading again, even with a new API key.

## Path parameters

- `importId` string, required: Import identifier.

## Request body

- HistoryImportFileLookupBody: Source file ids to look up, at most 200.
  - `external_ids` string[], required: Source file ids.

## Response `200`

Files already uploaded for this import.

- HistoryImportFileLookupResponse: The source files this import already uploaded that can still be attached. Ids not listed need uploading.
  - `data` object, required: Lookup result.
    - `files` HistoryImportMessageFile[], required: Uploaded files.
      - `external_id` string, required: The file's id in the source tool, used to find it again with files/lookup.
      - `file_id` string, required: The Ando file id returned by POST /v1/files.

## Other responses

- `400`: Bad request.
- `401`: Missing or invalid API key.
- `403`: Forbidden.
- `404`: Not found.
- `409`: Conflict.
- `429`: Rate limit or quota exceeded.
- `500`: Internal server error.

## Changes

- **2026-10-18** `aaceae49c08d`: 12 info
  - added the optional property `request_id` to the response with the `400` status
  - added the optional property `request_id` to the response with the `401` status
  - added the optional property `request_id` to the response with the `403` status
  - added the optional property `request_id` to the response with the `404` status
  - …8 more
- **2026-10-03** `c5d9fe685b8f`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/ando/apis/ando-public-api/changes/imports/:importId/files/lookup/post.md)

---

[API](https://skmtc.dev/ando/apis/ando-public-api.md) - [All operations](https://skmtc.dev/ando/apis/ando-public-api/llms.txt) - [OpenAPI document](https://skmtc.dev/ando/apis/ando-public-api/revisions/d852746d81c2?raw)
