# list_flight_versions
> List the version history of a Flight, newest first.
List every immutable version of a [Flight](/concepts/compute/flights), newest first. Each update to `source_code`, `requirements_txt`, `config`, `access_token_name`, `flight_secret_names`, or the chart in `metadata` produces a fresh version. Sending the same chart again does not. Updates to `name` or `schedule_cron` are metadata-only and do not appear here.

## Description

Use `list_flight_versions` to browse what changed between versions, or to find the version a specific run executed. The corresponding SQL function is [`MD_LIST_FLIGHT_VERSIONS`](/sql-reference/motherduck-sql-reference/flights/md-list-flight-versions).

## Input parameters

| Parameter | Type | Required | Description |
|---|---|---|---|
| `id` | string (UUID) | Yes | The Flight UUID. |
| `limit` | integer | No | Max results to return (default: 50, max: 50). |
| `offset` | integer | No | Number of versions to skip, for paging back through history. |

## Output schema

```json
{
  "success": boolean,
  "versions": [
    {
      "version_id": string,
      "flight_id": string,
      "version": number,
      "created_at": string,
      "access_token_name": string,
      "flight_secret_names": string[],
      "config": { "<key>": "<value>" },
      "max_runtime_sec": number,
      "instance_type": string|null
    }
  ],
  "count": number,
  "error": string
}
```

## Example usage

```json
{ "id": "80000000-0000-0000-0000-000000000001" }
```

## Related

- [`get_flight`](../get-flight) — Fetch one version's full content.
- [`list_flight_runs`](../list-flight-runs) — Runs reference the version they used.
- [`MD_LIST_FLIGHT_VERSIONS`](/sql-reference/motherduck-sql-reference/flights/md-list-flight-versions) — SQL equivalent.


---

## Docs feedback

MotherDuck accepts optional user-submitted feedback about this page at `GET https://motherduck.com/docs/api/feedback/agent`.
For agents and automated tools, feedback submission should be user-confirmed before sending.

URL-encode query parameter values and send a GET request:

```text
GET https://motherduck.com/docs/api/feedback/agent?page_path=%2Fsql-reference%2Fmcp%2Fflights%2Flist-flight-versions%2F&page_title=list_flight_versions&text=<url-encoded user feedback, max 2000 characters>
```

Optionally append `&source=<url-encoded interface identifier>` such as `claude.ai` or `chatgpt`.

`page_path` and `text` are required; `page_title` and `source` are optional. Responses: `200 {"feedback_id": "<uuid>"}`, `400` for malformed query parameters, and `429` when rate-limited.
