---
title: "import completed jobs from backup/migration"
method: POST
path: "/w/{workspace}/jobs/completed/import"
tags: ["job"]
---

# import completed jobs from backup/migration

`POST /w/{workspace}/jobs/completed/import`

## Path parameters

- `workspace` string, required

## Request body

- ExportableCompletedJob[]
  - `id` string, uuid, required
  - `parent_job` string, uuid
  - `created_by` string, required
  - `created_at` string, date-time, required
  - `started_at` string, date-time
  - `completed_at` string, date-time
  - `duration_ms` integer
  - `script_path` string
  - `script_hash` string
  - `args` object — Full job arguments without size restrictions
  - `result` object — Full job result without size restrictions
  - `logs` string — Complete job logs from v2_job table
  - `raw_code` string
  - `raw_lock` string
  - `canceled_by` string
  - `canceled_reason` string
  - `job_kind` 'script' | 'preview' | 'dependencies' | 'flow' | 'flowdependencies' | 'appdependencies' | 'flowpreview' | 'script_hub' | 'identity' | 'deploymentcallback' | 'singlestepflow' | 'flowscript' | 'flownode' | 'appscript' | 'aiagent' | 'unassigned_script' | 'unassigned_flow' | 'unassigned_singlestepflow', required
  - `trigger` string — Trigger path for the job (replaces schedule_path)
  - `trigger_kind` 'webhook' | 'http' | 'websocket' | 'kafka' | 'email' | 'nats' | 'schedule' | 'app' | 'ui' | 'postgres' | 'sqs' | 'gcp'
  - `permissioned_as` string, required
  - `permissioned_as_email` string
  - `flow_status` object — Flow status from v2_job_status table
  - `workflow_as_code_status` object
  - `raw_flow` object
  - `is_flow_step` boolean
  - `language` 'python3' | 'deno' | 'go' | 'bash' | 'powershell' | 'postgresql' | 'mysql' | 'bigquery' | 'snowflake' | 'mssql' | 'oracledb' | 'graphql' | 'nativets' | 'bun' | 'php' | 'rust' | 'ansible' | 'csharp' | 'nu' | 'java' | 'ruby' | 'rlang' | 'duckdb' | 'bunnative' | 'dbt'
  - `is_skipped` boolean
  - `email` string, required
  - `visible_to_owner` boolean, required
  - `mem_peak` integer
  - `tag` string
  - `priority` integer
  - `labels` string[]
  - `same_worker` boolean
  - `flow_step_id` string
  - `flow_innermost_root_job` string, uuid
  - `concurrent_limit` integer
  - `concurrency_time_window_s` integer
  - `timeout` integer
  - `cache_ttl` integer
  - `self_wait_time_ms` integer
  - `aggregate_wait_time_ms` integer
  - `preprocessed` boolean
  - `worker` string
  - `status` string — Actual job status from database

## Response `200`

Successfully imported completed jobs

---

[API](https://skmtc.net/windmill/apis/windmill-api.md) · [All operations](https://skmtc.net/windmill/apis/windmill-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/windmill/windmill-api/versions/155a35b3caff/schema)
