---
title: "Import Timelines"
method: POST
path: "/api/timeline/_import"
tags: ["Security Timeline API"]
---

# Import Timelines

`POST /api/timeline/_import`

**Spaces method and path for this operation:**

<div><span class="operation-verb post">post</span>&nbsp;<span class="operation-path">/s/{space_id}/api/timeline/_import</span></div>

Refer to [Spaces](https://www.elastic.co/docs/deploy-manage/manage-spaces) for more information.

Import Timelines.

## Request body

- object
  - `file` unknown, required
  - `isImmutable` 'true' | 'false' — Whether the Timeline should be immutable

## Response `200`

Indicates a successful call.

- SecurityTimelineAPIImportTimelineResult
  - `errors` object[] — The list of failed Timeline imports
    - `error` object — The error containing the reason why the timeline could not be imported
      - `message` string — The reason why the timeline could not be imported
      - `status_code` number — The HTTP status code of the error
    - `id` string — The ID of the timeline that failed to import
  - `success` boolean — Indicates whether any of the Timelines were successfully imports
  - `success_count` number — The amount of successfully imported/updated Timelines
  - `timelines_installed` number — The amount of successfully installed Timelines
  - `timelines_updated` number — The amount of successfully updated Timelines

## Other responses

- `400` — Bad Request response.
- `404` — Not found response.
- `409` — Indicates the import of Timelines was unsuccessful.

---

[API](https://skmtc.net/elastic/apis/kibana-apis.md) · [All operations](https://skmtc.net/elastic/apis/kibana-apis/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/elastic/kibana-apis/versions/531c9e2a7d23/schema)
